Updating
An update replaces the script and keeps everything you set up. What you configured lives in two places the update never needs to touch: your config.lua and the saved/ folder. Your photos are in a separate resource.
What to keep
| Keep | Why |
|---|---|
zaiders_appearance/shared/config.lua | Your options. A new version's options work even if your file doesn't have them: they take their defaults, and the console names them on start. |
zaiders_appearance/saved/ | Everything you saved in the admin panel: shops, prices, stock, theme, peds, the photo framing. Also scan/ (what each photo's garment files had inside) and hairswatch/ (the swatches of the packs' hairs). |
zaiders_photos/ (the whole folder) | Your catalog photos. Don't replace it. |
| Your edited language files, if any | An update brings new language files. Put your changed lines back afterwards. |
zaiders_studio/ is the other way round: it holds no data, so replace it whole.
Steps
Download the new version
From portal.cfx.re → Granted assets, with the account that owns it.
Make a backup
Copy your current
zaiders_appearancefolder somewhere safe, or at leastshared/config.luaandsaved/.Replace the script
Stop the server, or at least the resource. Replace the
zaiders_appearancefolder with the new one, then put back yourshared/config.luaand yoursaved/folder.Leave
zaiders_photosaloneDon't replace that folder: it holds your photos. The package's
zaiders_photoshas no photo list, so copying it over wouldn't erase the list. Copy over it only the package'sfxmanifest.lua,writer.luaandupgrade.js.Replace
zaiders_studiowholeDelete the old
zaiders_studiofolder and copy the package's. It holds no data, and it still doesn't go inserver.cfg.Run the SQL file if it changed
Appearancez.sqlonly creates tables that don't exist yet, so running it again is safe. The resource also creates missing tables on its own.Start and read the console
The console lists the options your
config.luadoesn't have yet and the values it fixed. Copy the new options from the new version'sconfig.luaif you want to change them. An option a version removed (such asConfig.Barber.handsOnorConfig.Barber.colorCard.matchClothes) is named once,no longer exists in this version: it is ignored: delete that line. New features that need a decision come off: character height arrives withConfig.Height.enabled = false. See How the config is checked.
From 1.x to 2.0
Version 2.0 gives everything an English name. Nothing is lost: the resources move their own files the first time they start.
Rename
zaiders_fotostozaiders_photosThen copy into it the package's
fxmanifest.lua,writer.luaandupgrade.js. On start it moves its folders to the new names (fotos/→photos/,datos/→data/,tatuajes/→tattoos/).Replace
zaiders_appearance, keeping yourconfig.luaand itsdatos/folderOn start it moves
datos/tosaved/with English file names (tiendas.json→shops.json,tatuajes.json→tattoos.json…). The shops, tattoo prices and ped settings saved with Spanish names are read as before.Replace
zaiders_estudiowithzaiders_studioDelete the old folder and copy the new one. It doesn't go in
server.cfg.Change one line of
server.cfgensure zaiders_fotosbecomesensure zaiders_photos.
A config.lua of 1.x keeps working as it is. Its Config.Photos.resource = 'zaiders_fotos' becomes zaiders_photos by itself while there's no zaiders_fotos (the console says that resource is now called zaiders_photos, so zaiders_photos is used); change that line when you like. Config.PedByName = 'todos' / 'nadie' is read as 'everyone' / 'nobody', and the ped categories with their Spanish names as the English ones. The console commands now have English names: zappearance_clean_photos, zappearance_tattoo_images, zappearance_changes and zappearance_migrate.
Changing clothing packs
Adding, removing or repacking a clothing pack isn't an update of the script, but it changes the garment numbers:
- Restart the whole server, not a single pack. FiveM numbers the clothing in start order, so restarting one pack while the server runs gives the players who join afterwards different garment numbers.
- Join once with an admin afterwards. The admin's game tells the server which garment is behind each number again.
- A repacked pack keeps its photos: each photo follows its garment by what its files have inside. Clothing packs → Changes lists the garments whose model or texture changed, to take only those again. See Catalog photos.
