* it works?
* does it work? who knows
* some cleanup
* format cmake
* update for new filesystem stuff
---------
Co-authored-by: Rémy Raes <contact@remyraes.com>
* Untemplate g_pSquirrel so intellisense and stuff actually works with it
* Remove unnecessary bitwise operations
* Don't use ScriptContext_COUNT and treat INVALID as a valid flag
* move compiled files to their own storage
* clear compiled files on mod reload
* allow functions to specify the sources that they wish to look for files in
* formatting
* fix: FetchModsListFromAPI sets mod state as done when... done
Previously, the state was set to DOWNLOADING, which conveniently
allowed DownloadMod to run; however, the DOWNLOADING state was
not assigned by DownloadMod, leading to nasty issues when calling
DownloadMod several times in a row.
* Use "Version" field to determine manifesto format version
* Remove old manifesto file if needed
* Export manifesto version to enabledmods.json on reload
* extract logic into functions
* dont stop loading all mods???
* refactor dependency constant logic
* some generic cleanup
* guard clauses
* stuff
* early out of mod load stuff
* github is being weird
* formatting
* Update primedev/mods/modmanager.cpp
* If a mod is installed several times, all mod versions are disabled to prevent crashing
Co-authored-by: Jack <66967891+ASpoonPlaysGames@users.noreply.github.com>
* feat: NSSetModEnabled now takes mod version as argument
* feat: move enabledmods.json to enabledmods.json.old if old manifesto format is used
* feat: add manifest version field to JSON file
Mods are no longer marked as successfully installed when the process failed.
When mod downloading/extraction fails, the mod directory is removed again.
Moves the logic that goes through all the paths where mods can be installed to its own function as part of improving code maintainability and future refactoring.
Instead of just RequiredOnClient mods and mods that have pdiff
The idea here is that it gives clients a better overview of what mods are enabled on the server they are joining.
Updates the launcher code to deal with adjusted verified mods JSON structure from the default manifest source
The idea here is to allow installing mods from other sources than Thunderstore.
This reworks how rpaks are loaded, unloaded and tracked.
It allows for rpak reloading between map loads, meaning that skins and map overhauls could be enabled and disabled on the fly.
Previous methods of loading rpaks still work.
Refactor logic to move Squirrel types to their own respective files and extend existing layouts in the process where applicable.
Contains additional smaller fixes.
Missing `rpak.json` would previously crash the game due to faulty boolean logic in the `if` statement. This change ensures that a missing `rpak.json` is handled gracefully.
Previously, the verified mods manifesto was fetched on game start without checking if the verified mod feature is enabled Squirrel-side; with this, the manifesto is only fetched when the user wants to download a mod (meaning they enabled the feature beforehand).
This basically prevents audio files from being loaded into memory if matching audio event has already been overriden by a previous mod, preventing a crash from occurring.
This means that audio mods now respect the load priority, i.e. mods with higher priority (= lower int value) will have priority over other mods on audio overrides.