How to disable Burrow Spawn?
DmitryErgen opened this issue · 3 comments
Describe the bug
There was such problem on the server. Previously, only the player who connected to the host took off. Through trial and error, it turned out that this is due to burrow. How to turn them off ?
Steps To Reproduce
Steps to reproduce the behavior: After some time has elapsed, or when a player enters the server.
Crash Log
---- Minecraft Crash Report ----
// Why did you do that?
Time: 02.09.2022, 16:32
Description: Exception ticking world
java.lang.IllegalArgumentException: bound must be positive
at java.util.Random.nextInt(Random.java:322) ~[?:?] {re:mixin}
at untamedwilds.block.blockentity.CritterBurrowBlockEntity.releaseOrCreateMob(CritterBurrowBlockEntity.java:83) ~[untamedwilds-1.18.2-2.2.0.jar%23154!/:1.18.2] {re:classloading}
at untamedwilds.block.CritterBurrowBlock.m_7455_(CritterBurrowBlock.java:98) ~[untamedwilds-1.18.2-2.2.0.jar%23154!/:1.18.2] {re:classloading}
at net.minecraft.world.level.block.state.BlockBehaviour$BlockStateBase.m_60735_(BlockBehaviour.java:681) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,re:classloading,pl:mixin:APP:ferritecore.blockstatecache.mixin.json:BlockStateBaseMixin,pl:mixin:APP:valhelsia_structures.mixins.json:BlockStateBaseMixin,pl:mixin:A}
at net.minecraft.server.level.ServerLevel.m_8714_(ServerLevel.java:440) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,re:classloading,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevellMixin,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevelSnowMixin,pl:mixin:APP:forge-mca.mixin.json:MixinServerWorld,pl:mixin:APP:supplementaries.mixins.json:ServerLevelMixin,pl:mixin:APP:betterdeserttemples.mixins.json:ServerLevelMixin,pl:mixin:APP:zombieawareness.mixins.json:MixinPlaySound,pl:mixin:APP:zombieawareness.mixins.json:MixinLevelEvent,pl:mixin:APP:assets/sound_physics_remastered/sound_physics_remastered.mixins.json:ServerWorldMixin,pl:mixin:APP:create.mixins.json:accessor.ServerLevelAccessor,pl:mixin:A}
at net.minecraft.server.level.ServerChunkCache.m_8490_(ServerChunkCache.java:359) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B}
at net.minecraft.server.level.ServerChunkCache.m_201698_(ServerChunkCache.java:309) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B}
at net.minecraft.server.level.ServerLevel.m_8793_(ServerLevel.java:281) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,re:classloading,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevellMixin,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevelSnowMixin,pl:mixin:APP:forge-mca.mixin.json:MixinServerWorld,pl:mixin:APP:supplementaries.mixins.json:ServerLevelMixin,pl:mixin:APP:betterdeserttemples.mixins.json:ServerLevelMixin,pl:mixin:APP:zombieawareness.mixins.json:MixinPlaySound,pl:mixin:APP:zombieawareness.mixins.json:MixinLevelEvent,pl:mixin:APP:assets/sound_physics_remastered/sound_physics_remastered.mixins.json:ServerWorldMixin,pl:mixin:APP:create.mixins.json:accessor.ServerLevelAccessor,pl:mixin:A}
at net.minecraft.server.MinecraftServer.m_5703_(MinecraftServer.java:902) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.server.MinecraftServer.m_5705_(MinecraftServer.java:842) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.client.server.IntegratedServer.m_5705_(IntegratedServer.java:118) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:classloading,xf:OptiFine:default}
at net.minecraft.server.MinecraftServer.m_130011_(MinecraftServer.java:685) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.server.MinecraftServer.m_177918_(MinecraftServer.java:261) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at java.lang.Thread.run(Thread.java:833) ~[?:?] {}
A detailed walkthrough of the error, its code path and all known details is as follows:
-- Head --
Thread: Render thread
Stacktrace:
at java.util.Random.nextInt(Random.java:322) ~[?:?] {re:mixin}
at untamedwilds.block.blockentity.CritterBurrowBlockEntity.releaseOrCreateMob(CritterBurrowBlockEntity.java:83) ~[untamedwilds-1.18.2-2.2.0.jar%23154!/:1.18.2] {re:classloading}
at untamedwilds.block.CritterBurrowBlock.m_7455_(CritterBurrowBlock.java:98) ~[untamedwilds-1.18.2-2.2.0.jar%23154!/:1.18.2] {re:classloading}
at net.minecraft.world.level.block.state.BlockBehaviour$BlockStateBase.m_60735_(BlockBehaviour.java:681) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,re:classloading,pl:mixin:APP:ferritecore.blockstatecache.mixin.json:BlockStateBaseMixin,pl:mixin:APP:valhelsia_structures.mixins.json:BlockStateBaseMixin,pl:mixin:A}
at net.minecraft.server.level.ServerLevel.m_8714_(ServerLevel.java:440) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,re:classloading,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevellMixin,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevelSnowMixin,pl:mixin:APP:forge-mca.mixin.json:MixinServerWorld,pl:mixin:APP:supplementaries.mixins.json:ServerLevelMixin,pl:mixin:APP:betterdeserttemples.mixins.json:ServerLevelMixin,pl:mixin:APP:zombieawareness.mixins.json:MixinPlaySound,pl:mixin:APP:zombieawareness.mixins.json:MixinLevelEvent,pl:mixin:APP:assets/sound_physics_remastered/sound_physics_remastered.mixins.json:ServerWorldMixin,pl:mixin:APP:create.mixins.json:accessor.ServerLevelAccessor,pl:mixin:A}
at net.minecraft.server.level.ServerChunkCache.m_8490_(ServerChunkCache.java:359) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B}
at net.minecraft.server.level.ServerChunkCache.m_201698_(ServerChunkCache.java:309) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B}
at net.minecraft.server.level.ServerLevel.m_8793_(ServerLevel.java:281) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,re:classloading,pl:accesstransformer:B,xf:fml:sereneseasons:temperature_transformer,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevellMixin,pl:mixin:APP:immersive_weathering.mixins.json:ServerLevelSnowMixin,pl:mixin:APP:forge-mca.mixin.json:MixinServerWorld,pl:mixin:APP:supplementaries.mixins.json:ServerLevelMixin,pl:mixin:APP:betterdeserttemples.mixins.json:ServerLevelMixin,pl:mixin:APP:zombieawareness.mixins.json:MixinPlaySound,pl:mixin:APP:zombieawareness.mixins.json:MixinLevelEvent,pl:mixin:APP:assets/sound_physics_remastered/sound_physics_remastered.mixins.json:ServerWorldMixin,pl:mixin:APP:create.mixins.json:accessor.ServerLevelAccessor,pl:mixin:A}
-- Affected level --
Details:
All players: 2 total; [ServerPlayer['Dmitry_Ergen'/189, l='ServerLevel[Новый мир]', x=658.52, y=115.00, z=-826.87], ServerPlayer['Boom-Barashkin'/547, l='ServerLevel[Новый мир]', x=663.21, y=120.06, z=-797.84]]
Chunk stats: 19265
Level dimension: minecraft:overworld
Level spawn location: World: (-32,62,-80), Section: (at 0,14,0 in -2,3,-5; chunk contains blocks -32,-64,-80 to -17,319,-65), Region: (-1,-1; contains chunks -32,-32 to -1,-1, blocks -512,-64,-512 to -1,319,-1)
Level time: 1312589 game time, 1129381 day time
Level name: Новый мир
Level game mode: Game mode: survival (ID 0). Hardcore: false. Cheats: true
Level weather: Rain time: 147671 (now: false), thunder time: 144788 (now: false)
Known server brands: forge
Level was modded: true
Level storage version: 0x04ABD - Anvil
Stacktrace:
at net.minecraft.server.MinecraftServer.m_5703_(MinecraftServer.java:902) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.server.MinecraftServer.m_5705_(MinecraftServer.java:842) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.client.server.IntegratedServer.m_5705_(IntegratedServer.java:118) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:classloading,xf:OptiFine:default}
at net.minecraft.server.MinecraftServer.m_130011_(MinecraftServer.java:685) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at net.minecraft.server.MinecraftServer.m_177918_(MinecraftServer.java:261) ~[client-1.18.2-20220404.173914-srg.jar%23172!/:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:balm.mixins.json:MinecraftServerMixin,pl:mixin:APP:notenoughcrashes.mixins.json:client.MixinMinecraftServerClientOnly,pl:mixin:APP:terrablender.mixins.json:MixinMinecraftServer,pl:mixin:A}
at java.lang.Thread.run(Thread.java:833) ~[?:?] {}
Version (please complete the following information):
- Minecraft version: 1.18.2
- Version of the mod: 2.2.0
No, I did not add anything new to the generation after the creation of the world. The main problem was that this was not done by one burrow, but by some random ones. Thanks for the advice.
Did you (or the server host) happen to change a datapack at some point after generating the world?
I'm afraid there's no way to retroactively disable burrows, there's a config option to turn them off (and have critters spawn directly in the world), but:
- This only works on newly generated chunks
- Existing burrows will still keep ticking, which causes the crash (if they try to spawn mobs with variant -1)
- Burrows exist because, otherwise, the amount of critters does hurt performance
If you are familiar with Minecraft world editors, it should be easy to find the burrow responsible and deleting it, or alternatively, you should also be able to run the server console without crashing, from where you can run a mass replace command (burrows only tick if they are closer than 50 blocks from a player)
/fill 600 0 -750 750 256 -900 minecraft:air replace untamedwilds:burrow
This command should replace all Burrows within a radius of 50 blocks from your player's coords with air. It comes without saying, but make a backup before running /fill commands that someone posted online
I will be adding a safeguard in the mod to prevent burrows that somehow generated with Variant -1 from ticking, but it will be a while until I have a new version ready