Skip to content

Make Configs editable from in-game - #45

Merged
cubefury merged 4 commits into
masterfrom
improve-configs
Nov 25, 2025
Merged

Make Configs editable from in-game#45
cubefury merged 4 commits into
masterfrom
improve-configs

Conversation

@cubefury

Copy link
Copy Markdown
Collaborator

Supersedes #43

Changes:

  1. Convert configs to GTNHLib system
  2. Make settings editable from ingame
  3. Write back settings to config when a player changes the display type and sort mode from within the vending machine gui

Tested on daily 214 in both SP and MP:

  1. Validation of display type and sort mode when it is changed
  2. Change configs from Mod Options in main menu
  3. Change configs from Mod Options while in-game
  4. Changing display type and sort mode from within vending machine gui

Breaking Changes

  1. This change will override any existing vendingmachine.cfg file and reset the config settings for existing instances when the mod is loaded. Trade database and character trade states/coin data are not affected.

Dev notes:

  1. DisplayType and SortMode classes should really be refactored out into their own files, but I will do that in a separate PR.
  2. I dont really know what to do with that lone unsaved world_dir config that's only populated at runtime, there's no other real "session" class where it would logically belong, so I just left it in there

@cubefury
cubefury requested a review from a team November 25, 2025 13:24
@Caedis

Caedis commented Nov 25, 2025

Copy link
Copy Markdown
Member

The config guis are automatically generated if you do not provide one btw

@Caedis

Caedis commented Nov 25, 2025

Copy link
Copy Markdown
Member

@cubefury

cubefury commented Nov 25, 2025

Copy link
Copy Markdown
Collaborator Author

yee i just listed that breaking change cuz it'll override any existing config file with the new format, in case someone loads this up and wonders why their settings got reset

@cubefury
cubefury merged commit 029abf7 into master Nov 25, 2025
1 check passed
@cubefury
cubefury deleted the improve-configs branch November 25, 2025 16:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants