Updating
Move to a new version without losing settings or data.
- Back up your
config.lua,server/config.lua,locales/,custom/and anypresets/you made (and your database, as with any update). - Read the Changelog for every version between yours and the new one. A major version (2.x -> 3.0) renames or removes config keys; a minor adds features; a patch fixes.
- Replace the folder with the new download.
- Put your files back, then compare each config with the new one: new keys have defaults in the new file; renamed keys are listed in the changelog.
- Restart. The database migrates itself (
[cc_powerwash] database migrated to schema N); the console prints oneconfig:line for anything that no longer matches.
Never edit a file in sql/migrations/: the resource records which ones ran.
2.x -> 3.0.0
| Was | Now |
|---|---|
Config.Vans | Config.Vehicle.rental.vans (rows { label, model, livery }) |
ServerConfig.Van.models | ServerConfig.Vehicle.rentalModels |
hcburrito / hcspeedo in the main resource | the optional cc_powerwash_vans resource |
Config.UI.accent | Config.UI.theme.accent |
install/ox_inventory/items.lua | install/items/ox_inventory.lua |
sql/cc_powerwash.sql | sql/install.sql + sql/migrations/ |
Your 2.x database upgrades in place (schema 1 = the 2.x tables; cc_powerwash_meta is added).