[Bug]: placing a segment incorrectly and then (or whilst) running the drill leads to a hard crash and world corruption
notandvm opened this issue ยท 3 comments
Mod Version
8.0.1
What mod loader(s) are you seeing the problem on?
Fabric
Mod Loader Version
0.14.22
Problem Description
when assembling a drill, if done incorrectly, it can lead to a hard crash via. ticking block entity once the drill either starts or is already running
furthermore, once crashed, the world becomes permanently corrupted, and any further attempts at rejoining said world simply crashes to desktop for the same reason
Steps To Reproduce
- create a world, place a drill head segment
- place another segment but incorrectly (most easily done with item collector)
- run the drill; game will freeze before crashing due to ticking block entity.
Crash Report or Error Logs
---- Minecraft Crash Report ----
// I let you down. Sorry :(
Time: 2023-08-25 01:06:08
Description: Ticking block entity
java.lang.NullPointerException: Cannot invoke "dev.the_fireplace.caterpillar.block.entity.DrillBaseBlockEntity.method_11016()" because "lastBlockEntity" is null
at dev.the_fireplace.caterpillar.block.entity.DrillHeadBlockEntity.tick(DrillHeadBlockEntity.java:98)
at net.minecraft.class_2818$class_5563.method_31703(class_2818.java:662)
at net.minecraft.class_2818$class_5564.method_31703(class_2818.java:716)
at net.minecraft.class_1937.method_18471(class_1937.java:470)
at net.minecraft.class_3218.method_18765(class_3218.java:390)
at net.minecraft.server.MinecraftServer.method_3813(MinecraftServer.java:897)
at net.minecraft.server.MinecraftServer.method_3748(MinecraftServer.java:824)
at net.minecraft.class_1132.method_3748(class_1132.java:105)
at net.minecraft.server.MinecraftServer.method_29741(MinecraftServer.java:671)
at net.minecraft.server.MinecraftServer.method_29739(MinecraftServer.java:265)
at java.base/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: Server thread
Stacktrace:
at dev.the_fireplace.caterpillar.block.entity.DrillHeadBlockEntity.tick(DrillHeadBlockEntity.java:98)
at net.minecraft.class_2818$class_5563.method_31703(class_2818.java:662)
at net.minecraft.class_2818$class_5564.method_31703(class_2818.java:716)
at net.minecraft.class_1937.method_18471(class_1937.java:470)
at net.minecraft.class_3218.method_18765(class_3218.java:390)
-- Block entity being ticked --
Details:
Name: simplycaterpillar:drill_head // dev.the_fireplace.caterpillar.block.entity.DrillHeadBlockEntity
Block: Block{simplycaterpillar:drill_head}[drilling=false,facing=south,part=base,waterlogged=false]
Block location: World: (-1,-59,10), Section: (at 15,5,10 in -1,-4,0; chunk contains blocks -16,-64,0 to -1,319,15), Region: (-1,0; contains chunks -32,0 to -1,31, blocks -512,-64,0 to -1,319,511)
Block: Block{simplycaterpillar:drill_head}[drilling=false,facing=south,part=base,waterlogged=false]
Block location: World: (-1,-59,10), Section: (at 15,5,10 in -1,-4,0; chunk contains blocks -16,-64,0 to -1,319,15), Region: (-1,0; contains chunks -32,0 to -1,31, blocks -512,-64,0 to -1,319,511)
Stacktrace:
at net.minecraft.class_2818$class_5563.method_31703(class_2818.java:662)
at net.minecraft.class_2818$class_5564.method_31703(class_2818.java:716)
at net.minecraft.class_1937.method_18471(class_1937.java:470)
at net.minecraft.class_3218.method_18765(class_3218.java:390)
at net.minecraft.server.MinecraftServer.method_3813(MinecraftServer.java:897)
at net.minecraft.server.MinecraftServer.method_3748(MinecraftServer.java:824)
at net.minecraft.class_1132.method_3748(class_1132.java:105)
at net.minecraft.server.MinecraftServer.method_29741(MinecraftServer.java:671)
at net.minecraft.server.MinecraftServer.method_29739(MinecraftServer.java:265)
at java.base/java.lang.Thread.run(Thread.java:833)
-- Affected level --
Details:
All players: 1 total; [class_3222['notandvm'/1, l='ServerLevel[New World]', x=1.44, y=-60.00, z=8.19]]
Chunk stats: 2809
Level dimension: minecraft:overworld
Level spawn location: World: (0,-60,0), Section: (at 0,4,0 in 0,-4,0; chunk contains blocks 0,-64,0 to 15,319,15), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,-64,0 to 511,319,511)
Level time: 359 game time, 359 day time
Level name: New World
Level game mode: Game mode: creative (ID 1). Hardcore: false. Cheats: true
Level weather: Rain time: 84104 (now: false), thunder time: 138757 (now: false)
Known server brands: fabric
Removed feature flags:
Level was modded: true
Level storage version: 0x04ABD - Anvil
Stacktrace:
at net.minecraft.server.MinecraftServer.method_3813(MinecraftServer.java:897)
at net.minecraft.server.MinecraftServer.method_3748(MinecraftServer.java:824)
at net.minecraft.class_1132.method_3748(class_1132.java:105)
at net.minecraft.server.MinecraftServer.method_29741(MinecraftServer.java:671)
at net.minecraft.server.MinecraftServer.method_29739(MinecraftServer.java:265)
at java.base/java.lang.Thread.run(Thread.java:833)
-- System Details --
Details:
Minecraft Version: 1.20.1
Minecraft Version ID: 1.20.1
Operating System: Linux (amd64) version 5.13.0-valve36-1-neptune
Java Version: 17.0.7, Flathub
Java VM Version: OpenJDK 64-Bit Server VM (mixed mode, sharing), Flathub
Memory: 543262720 bytes (518 MiB) / 1610612736 bytes (1536 MiB) up to 4294967296 bytes (4096 MiB)
CPUs: 8
Processor Vendor: AuthenticAMD
Processor Name: AMD Custom APU 0405
Identifier: AuthenticAMD Family 23 Model 144 Stepping 2
Microarchitecture: unknown
Frequency (GHz): -0.00
Number of physical packages: 1
Number of physical CPUs: 4
Number of logical CPUs: 8
Graphics card #0 name: VanGogh [AMD Custom GPU 0405]
Graphics card #0 vendor: Advanced Micro Devices, Inc. [AMD/ATI] (0x1002)
Graphics card #0 VRAM (MB): 258.00
Graphics card #0 deviceId: 0x163f
Graphics card #0 versionInfo: unknown
Virtual memory max (MB): 22281.30
Virtual memory used (MB): 6746.78
Swap memory total (MB): 16384.00
Swap memory used (MB): 7.50
JVM Flags: 2 total; -Xms512m -Xmx4096m
Fabric Mods:
cloth-config: Cloth Config v11 11.1.106
cloth-basic-math: cloth-basic-math 0.6.1
fabric-api: Fabric API 0.87.0+1.20.1
fabric-api-base: Fabric API Base 0.4.30+7abfd51577
fabric-api-lookup-api-v1: Fabric API Lookup API (v1) 1.6.35+4d8536c977
fabric-biome-api-v1: Fabric Biome API (v1) 13.0.10+b3afc78b77
fabric-block-api-v1: Fabric Block API (v1) 1.0.9+e022e5d177
fabric-blockrenderlayer-v1: Fabric BlockRenderLayer Registration (v1) 1.1.40+b3afc78b77
fabric-client-tags-api-v1: Fabric Client Tags 1.1.1+97bb207577
fabric-command-api-v1: Fabric Command API (v1) 1.2.33+f71b366f77
fabric-command-api-v2: Fabric Command API (v2) 2.2.12+b3afc78b77
fabric-commands-v0: Fabric Commands (v0) 0.2.50+df3654b377
fabric-containers-v0: Fabric Containers (v0) 0.1.63+df3654b377
fabric-content-registries-v0: Fabric Content Registries (v0) 4.0.9+b3afc78b77
fabric-convention-tags-v1: Fabric Convention Tags 1.5.4+a1a980da77
fabric-crash-report-info-v1: Fabric Crash Report Info (v1) 0.2.18+aeb40ebe77
fabric-data-generation-api-v1: Fabric Data Generation API (v1) 12.2.2+1e61dba177
fabric-dimensions-v1: Fabric Dimensions API (v1) 2.1.53+8536527b77
fabric-entity-events-v1: Fabric Entity Events (v1) 1.5.22+b3afc78b77
fabric-events-interaction-v0: Fabric Events Interaction (v0) 0.6.1+e91849a877
fabric-events-lifecycle-v0: Fabric Events Lifecycle (v0) 0.2.62+df3654b377
fabric-game-rule-api-v1: Fabric Game Rule API (v1) 1.0.38+b04edc7a77
fabric-item-api-v1: Fabric Item API (v1) 2.1.27+b3afc78b77
fabric-item-group-api-v1: Fabric Item Group API (v1) 4.0.10+23d9108177
fabric-key-binding-api-v1: Fabric Key Binding API (v1) 1.0.36+fb8d95da77
fabric-keybindings-v0: Fabric Key Bindings (v0) 0.2.34+df3654b377
fabric-lifecycle-events-v1: Fabric Lifecycle Events (v1) 2.2.21+b3afc78b77
fabric-loot-api-v2: Fabric Loot API (v2) 1.1.39+b3afc78b77
fabric-loot-tables-v1: Fabric Loot Tables (v1) 1.1.43+9e7660c677
fabric-message-api-v1: Fabric Message API (v1) 5.1.7+3265161977
fabric-mining-level-api-v1: Fabric Mining Level API (v1) 2.1.49+b3afc78b77
fabric-model-loading-api-v1: Fabric Model Loading API (v1) 1.0.2+709a987177
fabric-models-v0: Fabric Models (v0) 0.4.1+9386d8a777
fabric-networking-api-v1: Fabric Networking API (v1) 1.3.10+eeb8eb3677
fabric-networking-v0: Fabric Networking (v0) 0.3.50+df3654b377
fabric-object-builder-api-v1: Fabric Object Builder API (v1) 11.1.1+6beca84877
fabric-particles-v1: Fabric Particles (v1) 1.1.1+201a23a077
fabric-recipe-api-v1: Fabric Recipe API (v1) 1.0.20+b3afc78b77
fabric-registry-sync-v0: Fabric Registry Sync (v0) 2.3.2+4df89eb277
fabric-renderer-api-v1: Fabric Renderer API (v1) 3.1.2+6bdb2ed077
fabric-renderer-indigo: Fabric Renderer - Indigo 1.4.2+6bdb2ed077
fabric-renderer-registries-v1: Fabric Renderer Registries (v1) 3.2.45+df3654b377
fabric-rendering-data-attachment-v1: Fabric Rendering Data Attachment (v1) 0.3.34+b3afc78b77
fabric-rendering-fluids-v1: Fabric Rendering Fluids (v1) 3.0.27+b3afc78b77
fabric-rendering-v0: Fabric Rendering (v0) 1.1.48+df3654b377
fabric-rendering-v1: Fabric Rendering (v1) 3.0.7+b3afc78b77
fabric-resource-conditions-api-v1: Fabric Resource Conditions API (v1) 2.3.5+ea08f9d877
fabric-resource-loader-v0: Fabric Resource Loader (v0) 0.11.9+132c48c177
fabric-screen-api-v1: Fabric Screen API (v1) 2.0.7+b3afc78b77
fabric-screen-handler-api-v1: Fabric Screen Handler API (v1) 1.3.29+b3afc78b77
fabric-sound-api-v1: Fabric Sound API (v1) 1.0.12+b3afc78b77
fabric-transfer-api-v1: Fabric Transfer API (v1) 3.3.0+cdf060b277
fabric-transitive-access-wideners-v1: Fabric Transitive Access Wideners (v1) 4.3.0+6c31357e77
fabricloader: Fabric Loader 0.14.22
java: OpenJDK 64-Bit Server VM 17
minecraft: Minecraft 1.20.1
simplycaterpillar: Simply Caterpillar 8.0.1
Server Running: true
Player Count: 1 / 8; [class_3222['notandvm'/1, l='ServerLevel[New World]', x=1.44, y=-60.00, z=8.19]]
Data Packs: vanilla, fabric
Enabled Feature Flags: minecraft:vanilla
World Generation: Stable
Type: Integrated Server (map_client.txt)
Is Modded: Definitely; Client brand changed to 'fabric'; Server brand changed to 'fabric'
Launched Version: 1.20.1
Additional Information
also, whilst unrelated to this crash, it should be noted that (at least on fabric) SC requires cloth config api, or else the game crashes on start-up; this dependency isn't listed on the mod page nor is it tied to the mod's file versions on either modrinth/curseforge, which could cause issues for people looking to download the mod manually
Hello, thanks for your bug report !
I will update the code so when you right click on the middle of the block on front of you and not the ground, it will automatically place the block in the right place.
Should prevent this bug for collector and reinforcement blocks,
Fixed in #22 with release 8.0.2 of fabric and forge