# :necktie: NPC Clothes
Documentation relating to the **jo_clothingstore_npc** add-on for [Clothing store script](clothing-store).

:::: tabs
::: tab BUY
[Buy the add-on](https://jumpon-studios.com/redm/npc-clothes)
:::

::: tab PREVIEW
Coming soon...
:::
::::

## 1. Installation
::: warning
[Clothing store script](clothing-store) is required to use this add-on
:::

To install jo_clothingstore_npc:
- Drag and drop the resource into your resources folder
  - jo_clothingstore_npc 
- Add this ensure in your server.cfg after `ensure jo_clothingstore`
  - `ensure jo_clothingstore_npc`

Congratulation, the **NPC Clothes** add-on is ready to be used!

## 2. Usage

The scripts add a new intermediate menu in the store which allow you to choose between `Classic Clothes` or `NPC Clothes`. NPC clothing categories share some categories with classic clothes, but there are also many new categories.

With `jo_clothingstore` v4.4.0 or newer, every variation of the NPC clothes has its thumbnail, displayed with the clothing store's thumbnail options.

## 3. Number of clothes

The add-on adds 5,019 unique clothes (50,737 variations):
* 3,903 unique clothes for male (39,357 variations)
* 1,116 unique clothes for female (11,380 variations)

Here are charts of the number of clothes by categories:
:::details Unique clothes by categories (5,019)
| Category | Male | Female |
| --- | --- | --- |
| shirts_full | 490 | 201 |
| coats | 492 | 85 |
| pants | 484 | 45 |
| boots | 342 | 112 |
| vests | 416 | 13 |
| hats | 154 | 122 |
| neckerchiefs | 177 | 14 |
| gunbelts | 141 | 13 |
| neckties | 152 | 1 |
| belts | 76 | 58 |
| skirts | 5 | 126 |
| gloves | 85 | 28 |
| holsters_right | 87 | 6 |
| accessories | 55 | 20 |
| suspenders | 72 | 2 |
| jewelry_necklaces | 25 | 47 |
| unionsuits_full | 61 | 0 |
| masks | 59 | 1 |
| boot_accessories | 49 | 6 |
| neckwear | 25 | 25 |
| loadouts | 33 | 8 |
| vest_accessories | 41 | 0 |
| badges | 34 | 0 |
| satchels | 31 | 2 |
| coat_accessories | 25 | 7 |
| shirts_full_overpants | 32 | 0 |
| eyewear | 28 | 3 |
| jewelry_rings | 31 | 0 |
| shawls | 0 | 30 |
| cloaks | 16 | 13 |
| aprons | 15 | 13 |
| dresses | 4 | 21 |
| holsters_knife | 25 | 0 |
| overalls_full | 23 | 2 |
| chaps | 16 | 1 |
| chemises | 0 | 17 |
| jewelry_bracelets | 6 | 10 |
| knickers | 0 | 16 |
| headwear | 6 | 8 |
| jewelry_earrings | 0 | 14 |
| pants_accessories | 12 | 1 |
| holsters_left | 9 | 3 |
| overalls_modular_uppers | 12 | 0 |
| corsets | 0 | 9 |
| wrist_bindings | 7 | 2 |
| hat_accessories | 3 | 5 |
| outfits | 6 | 1 |
| coats_heavy | 6 | 0 |
| overalls_modular_lowers | 6 | 0 |
| ankle_bindings | 4 | 1 |
| holsters_crossdraw | 5 | 0 |
| satchel_straps | 5 | 0 |
| holsters_center | 3 | 1 |
| armor | 1 | 1 |
| gauntlets | 1 | 1 |
| holsters_quivers | 2 | 0 |
| jewelry_rings_left | 1 | 1 |
| jewelry_rings_right | 2 | 0 |
| spats | 2 | 0 |
| unionsuit_legs | 2 | 0 |
| gunbelt_accs | 1 | 0 |
:::
:::details All colors variations by categories (50,737)
| Category | Male | Female |
| --- | --- | --- |
| pants | 9,976 | 199 |
| coats | 7,929 | 636 |
| shirts_full | 3,539 | 1,728 |
| vests | 4,771 | 55 |
| hats | 461 | 3,816 |
| gunbelts | 3,077 | 85 |
| boots | 1,268 | 1,323 |
| neckerchiefs | 2,313 | 80 |
| skirts | 6 | 2,165 |
| gloves | 1,132 | 122 |
| neckties | 1,211 | 2 |
| overalls_full | 588 | 6 |
| belts | 242 | 91 |
| jewelry_necklaces | 98 | 195 |
| holsters_right | 266 | 6 |
| shirts_full_overpants | 270 | 0 |
| shawls | 0 | 245 |
| accessories | 198 | 29 |
| suspenders | 208 | 2 |
| masks | 207 | 1 |
| loadouts | 155 | 14 |
| unionsuits_full | 169 | 0 |
| boot_accessories | 124 | 10 |
| holsters_knife | 134 | 0 |
| satchels | 130 | 4 |
| eyewear | 128 | 4 |
| jewelry_bracelets | 73 | 57 |
| aprons | 80 | 24 |
| badges | 98 | 0 |
| dresses | 8 | 90 |
| cloaks | 42 | 52 |
| neckwear | 35 | 51 |
| chemises | 0 | 81 |
| corsets | 0 | 59 |
| headwear | 17 | 41 |
| jewelry_rings | 57 | 0 |
| vest_accessories | 56 | 0 |
| coat_accessories | 44 | 9 |
| chaps | 40 | 4 |
| overalls_modular_uppers | 40 | 0 |
| holsters_crossdraw | 37 | 0 |
| knickers | 0 | 31 |
| jewelry_earrings | 0 | 30 |
| overalls_modular_lowers | 26 | 0 |
| pants_accessories | 20 | 4 |
| outfits | 18 | 1 |
| holsters_left | 11 | 4 |
| gauntlets | 7 | 7 |
| wrist_bindings | 8 | 3 |
| hat_accessories | 3 | 7 |
| ankle_bindings | 5 | 2 |
| coats_heavy | 7 | 0 |
| holsters_center | 5 | 1 |
| satchel_straps | 6 | 0 |
| holsters_quivers | 4 | 0 |
| jewelry_rings_left | 2 | 2 |
| armor | 1 | 2 |
| jewelry_rings_right | 2 | 0 |
| spats | 2 | 0 |
| unionsuit_legs | 2 | 0 |
| gunbelt_accs | 1 | 0 |
:::

## 4. Configuration

The configuration files are located in the `config` folder within the resource. This folder contains two subfolders:

- **`_default.lock/`** - Contains the default configuration files. **Do not edit these files directly** as they may be overwritten during updates.
- **`custom/`** - This is where you place your custom configuration files to override the defaults.

### How to customize the configuration

1. Navigate to `jo_clothingstore_npc/config/_default.lock/`
2. Copy the file you want to modify (e.g., `prices.lua`)
3. Paste it into `jo_clothingstore_npc/config/custom/`
4. Edit the copied file in the `custom` folder

The script automatically loads files from `custom/` first, and only uses `_default.lock/` as a fallback. This system ensures your customizations are preserved when updating the script.

### Default configuration files

`jo_clothingstore_npc/config/_default.lock/items.lua`

```lua
Config.clothesItem = { --Inventory item names for each clothing category, only used if Config.clothesInItem = true in the main script
    aprons = "aprons",
    ankle_bindings = "ankle_bindings",
    coat_accessories = "coat_accessories",
    coats_heavy = "coats_heavy",
    hat_accessories = "hat_accessories",
    headwear = "headwear",
    holsters_center = "holsters",
    holsters_crossdraw = "holsters",
    holsters_knife = "holsters",
    holsters_quivers = "holsters",
    holsters_right = "holsters",
    jewelry_necklaces = "jewelry",
    jewelry_rings = "jewelry",
    neckerchiefs = "neckerchiefs",
    outfits = "outfits",
    overalls_full = "overalls",
    overalls_modular_lowers = "overalls",
    overalls_modular_uppers = "overalls",
    pants_accessories = "pants_accessories",
    satchel_straps = "satchel_straps",
    shirts_full_overpants = "shirts_full_overpants",
    unionsuit_legs = "unionsuit_legs",
    unionsuits_full = "unionsuits_full",
    vest_accessories = "vest_accessories",
    wrist_bindings = "wrist_bindings",
    masks_large = "mask_large",
    shawls = "shawls",
    knickers = "knickers",
    corsets = "corsets",
    chemises = "chemises",
    jewelry_earrings = "jewelry",
}
```

`jo_clothingstore_npc/config/_default.lock/lang.lua`

```lua
-- * ======================================
-- *  GENERAL
-- * ======================================
Lang.npcCategoryName = "Npc Clothes"

-- * ======================================
-- *  CLOTHES CATEGORIES
-- * ======================================
Lang.ankle_bindings = "Ankle Bindings"
Lang.aprons = "Aprons"
Lang.chemises = "Chemises"
Lang.coat_accessories = "Coat Accessories"
Lang.coats_heavy = "Heavy Coats"
Lang.corsets = "Corsets"
Lang.hat_accessories = "Hat Accessories"
Lang.headwear = "Headwear"
Lang.holsters_center = "Holsters Center"
Lang.holsters_crossdraw = "Holsters Crossdraw"
Lang.holsters_knife = "Knife Holsters"
Lang.holsters_quivers = "Quivers"
Lang.holsters_right = "Right Holsters"
Lang.jewelry_earrings = "Earrings"
Lang.jewelry_necklaces = "Necklaces"
Lang.jewelry_rings = "Rings"
Lang.knickers = "Knickers"
Lang.masks_large = "Large Masks"
Lang.neckerchiefs = "Neckerchiefs"
Lang.outfits = "Outfits"
Lang.overalls_full = "Full Overalls"
Lang.overalls_modular_lowers = "Modular Overalls (Lowers)"
Lang.overalls_modular_uppers = "Modular Overalls (Uppers)"
Lang.pants_accessories = "Pants Accessories"
Lang.satchel_straps = "Satchel Straps"
Lang.shawls = "Shawls"
Lang.shirts_full_overpants = "Shirts (Over Pants)"
Lang.unionsuit_legs = "Union Suit Legs"
Lang.unionsuits_full = "Full Union Suits"
Lang.vest_accessories = "Vest Accessories"
Lang.wrist_bindings = "Wrist Bindings"
```

`jo_clothingstore_npc/config/_default.lock/prices.lua`

```lua
-- ================================================================
-- PRICE CONFIGURATION GUIDE
-- ================================================================
-- Need to build or adjust a price table quickly?
-- Use the official Price Generator here:
--   https://docs.jumpon-studios.com/DeveloperResources/price-generator
--
-- The generator creates ready-to-paste Lua price tables for this config.
-- Copy the generated Lua code and paste it as the value of the relevant
-- price entry or model override.
-- ================================================================

Config.prices = { -- NPC clothes categories pricing
    npc_coats_closed = 5,
    npc_chaps = 4,
    npc_spats = 5,
    npc_ponchos = 4.25,
    npc_holsters_left = 3.12,
    npc_masks = 10,
    npc_neckwear = 2.15,
    npc_armor = 20,
    npc_jewelry_rings_left = 1.25,
    npc_jewelry_rings_right = 1.25,
    npc_boot_accessories = 3.55,
    npc_gloves = 4.25,
    npc_badges = 2,
    npc_gunbelts = 5,
    npc_loadouts = 6.7,
    npc_vests = 5,
    npc_shirts_full = 5,
    npc_pants = 5,
    npc_suspenders = 1.5,
    npc_gunbelt_accs = 1,
    npc_hats = 3.5,
    npc_cloaks = 5,
    npc_coats = 5,
    npc_belts = 2,
    npc_gauntlets = 3,
    npc_eyewear = 6,
    npc_boots = 5,
    npc_jewelry_bracelets = 2,
    npc_satchels = 10,
    npc_accessories = 2,
    npc_neckties = 2,
    npc_skirts = 5,
    npc_belt_buckles = 1,
    npc_dresses = 5,
    npc_aprons = 2,
    npc_ankle_bindings = 2,
    npc_coat_accessories = 2,
    npc_coats_heavy = 2,
    npc_hat_accessories = 2,
    npc_headwear = 2,
    npc_holsters_center = 2,
    npc_holsters_crossdraw = 2,
    npc_holsters_knife = 2,
    npc_holsters_quivers = 2,
    npc_holsters_right = 2,
    npc_jewelry_necklaces = 2,
    npc_jewelry_rings = 2,
    npc_neckerchiefs = 2,
    npc_outfits = 2,
    npc_overalls_full = 2,
    npc_overalls_modular_lowers = 2,
    npc_overalls_modular_uppers = 2,
    npc_pants_accessories = 2,
    npc_satchel_straps = 2,
    npc_shirts_full_overpants = 2,
    npc_unionsuit_legs = 2,
    npc_unionsuits_full = 2,
    npc_vest_accessories = 2,
    npc_wrist_bindings = 2,
    npc_masks_large = 2,
    npc_corsets = 2,
    npc_chemises = 2,
    npc_jewelry_earrings = 2,
    npc_knickers = 2,
    npc_shawls = 2,
}

Config.modelPrices = { --Override prices for specific clothing models
    male = {},
    female = {},
}

for category in pairs(Config.prices) do
    Config.modelPrices["male"][category] = {}
    Config.modelPrices["female"][category] = {}
end

Config.modelPrices["male"]["npc_outfits"][2] = { gold = 10 } -- Example: set the outfit male number 2 to 10 gold
Config.modelPrices.female.npc_aprons[1] = -1                 -- Example: remove the female aprons number 1
Config.modelPrices.female.npc_pants[1] = -1
Config.modelPrices.female.npc_pants[2] = 10

-- Known bugged clothes :
Config.modelPrices.male.npc_pants[55] = -1
```

### Language Configuration

The script supports full translation through the language system. To override any text:

1. Find the key you want to change in `config/_default.lock/lang.lua`
2. Copy `lang.lua` to `config/custom/` and add only the keys you want to override

Example:

```lua
Lang.npcCategoryName = "Одежда NPC"
Lang.bodyPartsMenuTitle = "Исправить части телa"
Lang.upperBody = "Верхняя часть тела"
```

Available translation categories include:
- General UI & Common Terms
- NPC clothes categories names

:::tip 💡Only change the key you need to translate
You only need to include the specific keys you want to change in `config/custom/lang.lua`. Don't copy the entire language file if you don't need to.
:::
