Invalid account data in client.json files causes unexpected behavior
AmmoniumX opened this issue ยท 3 comments
Describe the bug
Having a *_client.json file with an invalid default account can cause crashes and invalid accounts to be shown in shops
To Reproduce
Steps to reproduce the behavior:
- Go to
/config/adminshop/ - Replace the content in any of the
*_client.jsonfiles to an invalid account, such as one the player does not have access to. - This will make the client "think" it has access to this account, and can crash when placing buyers/sellers
Expected behavior
The client should recognize this as an invalid account and reset it to the player's personal account
Minecraft Version: 1.19.2/1.19.4
Mod Version: 1.16
I think you should save the *_client.json file in the World folder, it would prevent shipping the file with modpacks, because to do that you would have to expressely move it in the defaultconfigs folder (to be copied into the world folder). I hope I'm clear, feel free to tell me if you don't get my blabla ๐
as we discussed, a config/adminshop/client/world name_client.json could be a good solution. And also, the adminshop-common.toml lines:
#Display configurations. Options for changing client view
[display_config]
#Displays your current balance and gained balance per second in the top left corner
"Balance Display" = true
#If monetary values should be formatted as M/B/T/etc (Short) instead of Million/Billion/Trillion/etc (Full)
"Short mode " = trueshould be moved to a separate client config to allow pack developers removing it from the overrides folder