marcelo-mason / PreciousStones

Self-service protection for Minecraft servers
http://dev.bukkit.org/server-mods/preciousstones/
56 stars 67 forks source link

Flags toggled off by default not being stored in database for new cuboids #1091

Closed PIE-yt closed 7 years ago

PIE-yt commented 7 years ago

Flags toggled off by default (such as "?prevent-mob-spawn") aren't having there disabled state applied to new cuboid fields after a server restart.

I've checked the MySQL database and the "flags" key in the "pstone_cuboids" table is being left blank, which I think could perhaps be the issue.

I'm using: PreciousStones version 10.5.4 Spigot 1.12

Thanks for your time.

marcelo-mason commented 7 years ago

Happenins always, or sometimes?

PIE-yt commented 7 years ago

Seems to be always so far.

Just noticed you've made a fix :)

marcelo-mason commented 7 years ago

Try turning on show-debug-info: true in settings to see when that SQL query writing flags shows up and if it has data there.

PIE-yt commented 7 years ago

Sorry for the delay. I've checked the debug (and attached it), it appears to be writing {} for the flags key. Debug Output.txt

I've also attached the field definition Field Config.txt Tested on PS version 10.6.0

Thanks for your help.

marcelo-mason commented 7 years ago

So is this whats happening?

PIE-yt commented 7 years ago

/ps toggle works OK and saves the flags as it should. The issue is with flags that are attached to a field, but disabled on placement with the "?" prefix, such as: ?prevent-mob-spawn.

I'm trying to allow my players to place fields with extra flags disabled by default, so I can then have them pay to use "/ps toggle" (which I can do using BoosCooldowns) to switch the flags back on (I've not set this up yet so it can't be interfering.)

Hope that makes sense. Thanks for your time.

marcelo-mason commented 7 years ago

I see, I see. ok thanks. Will look into that.

marcelo-mason commented 7 years ago

try now

PIE-yt commented 7 years ago

Confirmed fixed 👍 Thanks so much for your time :)