aboutsummaryrefslogtreecommitdiff
path: root/src/modules/settings.js
AgeCommit message (Collapse)Author
2024-02-04removed use of "vipertmp" folder0neGal
Previously we downloaded the Northstar archive and packages to a folder named "vipertmp" in the system's cache folder, now that's just moved into "Viper/Temp" (still inside the system's cache folder) With this, all Viper cache is stored in the same folder in the system's cache folder... Wait... Why wasn't it always like this? Oh right, my past stupidity and lack of foresight. Oh well. "vipertmp" still gets deleted when clearing install cache, along with the new folder, so doing so will by itself clean up the old folder.
2024-02-04merge src/modules/window.js into src/win.js0neGal
I intended to do this when creating src/win.js, but wanted it to be in a different commit, as that commit made pretty large changes as well. So no more `main_win`, `win_show` and confusion between what `win` is.
2024-02-04move IPC events into their respective modules0neGal
I've not been able to find anything that breaks from this, as I've gone through every IPC event that got moved, to ensure it still functions, and all the breakage I found has since been fixed. IPC events that dont fit in any particular module is also now in the new file named `src/app/modules/ipc.js` There's also another module `src/win.js`, which lets you get the `BrowserWindow` outside of `src/index.js` I also took the oppertunity to clean up some of the code when moving it around, and adding a couple comments, as some of it was quite horrid.
2024-02-03src/modules/settings.js now provides a function0neGal
This fixes a couple issues where the main process wouldn't actually get changes made to the settings, this fixes that. On top of this, changing settings is now done with `settings.set()` There shouldn't be any breakage from this change, but I suppose it is possible. Especially because the `settings()` function still does contain backup options set, meaning `settings.nsargs` is technically still valid, but dont expect it to actually be updated when that variable is changed, its merely here to avoid any problems.
2024-01-12deprecate ns_startup_args.txt0neGal
Ideally this has no side effects, however, I've not actually tested if the launching does properly use the launch arguments, due to not having a Windows device on hand. This will be tested later... We still attempt to load launch arguments from `ns_startup_args.txt` if none is set in the settings. However, this may be removed in the future.
2023-09-16made some lang keys far more logical0neGal
Most of these are from back when Viper was originally started, I also removed a few keys as they were no longer in use, but were forgotten about, most of these are from pre-v1.0.0 aka, the old smaller UI
2023-09-13fixed settings file refusing to save if invalid0neGal
This is quite counter intuitive, as, if it's invalid, how do we re-validate it, if we can't even save it again. This existed here because the idea was for the re-validation to occur somewhere else, and to make sure incorrectly formatted data wasn't being given to this function. Now the function simply resets the config, a restart may be required to add missing settings, in case the parsed `conf` doesn't have all keys.
2023-09-13synchronize changes to settings from main process0neGal
If the main process has changes to the settings, said settings will now also be sent to the renderer, making them synchronized.
2023-08-07fixed Northstar startup arguments not applying0neGal
2023-07-22colored console logging0neGal
Far prettier, and far more useful at a glance.
2023-03-09download Northstar to <cache_dir>/vipertmp0neGal
"cache_dir" being wherever your OS puts it's cache, it's the same place mods.js uses to download mods. This prevents cluttering up the gamepath with temporary files.
2023-03-05small cleanups and changes in comments0neGal
I've made some code return early instead of adding more nesting, on top of this I've added some more comments in some files, rephrased a few things, and so on...
2023-01-12added: src/modules/json.js0neGal
This module makes it easier to read JSON files, simply returning false on errors, and attempting to repair the JSON automatically.
2023-01-12modularize settings Object0neGal
The reasoning behind this is obvious, I overall would like to make utils.js far smaller, and if not get entirely rid of it.