Minecraft’s built in game rules can be set via the <gamerules>
module. Not all gamerules are supported, the table below lists which are supported.
When stopping the daylight cycle, you should either use the <doDaylightCycle>
gamerule, or the timelock element. One will overwrite the other, so be consistent.
Element | Description |
---|---|
<gamerules> </gamerules>
|
Node containing the defined game rules. |
Element | Description | Values |
---|---|---|
<doFireTick>
|
Toggles whether firespread occurs. | true / false |
<doTileDrops>
|
Toggles whether tile entities drop. | true / false |
<doMobLoot>
|
Toggles whether mobs drop loot on death. | true / false |
<mobGriefing>
|
Toggles whether mobs such as Creepers and Endermen cause enviromental damage. | true / false |
<naturalRegeneration>
|
Toggles whether or not players naturally regain heath. | true / false |
<doDaylightCycle>
|
Toggles whether or not the time tick occurs. | true / false |
Example
<gamerules>
<doDaylightCycle>false</doDaylightCycle>
<naturalRegeneration>false</naturalRegeneration>
</gamerules>
Rule | Reason |
---|---|
doMobSpawning
|
Not supported in favor of the mobs module. |
keepInventory
|
Not supported since PGM already solves this with kits. |
commandBlockOutput
|
Command blocks are disabled in PGM. |
logAdminCommands
|
Not useful in custom maps. |
randomTickSpeed
|
Not useful in custom maps. |
reducedDebugInfo
|
Not useful in custom maps. |
sendCommandFeedback
|
Not useful in custom maps. |
showDeathMessages
|
Not useful in custom maps. |