TransWikia.com

Changing gamerule from server console has no effect

Arqade Asked on May 25, 2021

I implemented a datapack, that changes certain gamerules like mobGriefing or doInsomnia based on the preferences of the players that are currently playing on the server. The datapack works in a test world realiable, but when I put it on the server the gamerule changes have no effect.

If I check the current state of the gamerule with the server console, the gamerules change if I change my preferences ingame. But if check the same thing with the server chat and an OP-Account, nothing changes. And the output from the chat seems to be the correct one.

Tests

I tested this with mobGriefing. I am the only player online, so if I change my preferences with the datapack they instantly take effect.

  • I started with no preference set. So mobGriefing was set to the default, which is true, both in console and in the chat.
  • If I now set my preference to false, the gamerule should switch to false.
  • But it did that only on the console. (Ignore the server restart, it didn’t change anything)

Server console on the left, Game on the right

  • And it had no effect ingame. I tested it with a creeper.

The server runs on spigot in Java 1.16.4. I have not much experience with spigot, but I know commands and functions pretty well.

Do you have any idea, what causes this or how it could be fixed?

One Answer

You said you changed the value to "False"

The value must be lowercase, as in "false" same with "true".

Was just a typo, not actually the problem

Answered by jitter on May 25, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP