mojira.dev
MC-118612

Mob spawners with a Weight tag crash the game.

When I create a mob spawner with a "Weight" tag in SpawnPotentials, the game crashes and I can no longer reload the world without it crashing again. Here is an example command which would crash the game:

/setblock ~ ~ ~ minecraft:mob_spawner 0 replace {SpawnData:{id:sheep},SpawnPotentials:[{Entity:{id:sheep},Weight:0.6},{Entity:{id:cow},Weight:0.4}]}

Linked issues

Comments 3

Thank you for your report!
However, this issue has been temporarily resolved as Awaiting Response.

We do not have enough information to find the cause of this issue.
Please attach the crash report ([minecraft/crash-reports/crash-<DATE>-client.txt|http://hopper.minecraft.net/help/guides/finding-minecraft-data-folder/]) here.

Once attached, the report will be reopened automatically.

Quick Links:
📓 Issue Guidelines – 💬 Community Support – 📧 Customer Support – 📖 Game Wiki

Weight must be >= 1.

Thanks Neko! That would make sense. 🙂
Here's the crash report.


Minecraft Crash Report ----
// Why did you do that?

Time: 6/11/17 4:10 PM
Description: Ticking block entity

java.lang.IllegalArgumentException
at rq.a(SourceFile:18)
at rq.a(SourceFile:37)
at ami.i(SourceFile:141)
at ami.c(SourceFile:128)
at avw.e(SourceFile:91)
at ams.k(SourceFile:1417)
at om.k(SourceFile:547)
at net.minecraft.server.MinecraftServer.D(SourceFile:632)
at net.minecraft.server.MinecraftServer.C(SourceFile:560)
at chb.C(SourceFile:154)
at net.minecraft.server.MinecraftServer.run(SourceFile:464)
at java.lang.Thread.run(Thread.java:745)

A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

– Head –
Thread: Server thread
Stacktrace:
at rq.a(SourceFile:18)
at rq.a(SourceFile:37)
at ami.i(SourceFile:141)
at ami.c(SourceFile:128)
at avw.e(SourceFile:91)

– Block entity being ticked –
Details:
Name: minecraft:mob_spawner // avw
Block type: ID #52 (tile.mobSpawner // arx)
Block data value: 0 / 0x0 / 0b0000
Block location: World: (186,73,245), Chunk: (at 10,4,5 in 11,15; contains blocks 176,0,240 to 191,255,255), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,0,0 to 511,255,511)
Actual block type: ID #52 (tile.mobSpawner // arx)
Actual block data value: 0 / 0x0 / 0b0000
Stacktrace:
at ams.k(SourceFile:1417)
at om.k(SourceFile:547)

– Affected level –
Details:
Level name: bug?
All players: 1 total; [oo['Zerdguyyy'/558, l='bug?', x=187.24, y=74.53, z=243.57]]
Chunk stats: ServerChunkCache: 272 Drop: 0
Level seed: -1558627067970984661
Level generator: ID 00 - default, ver 1. Features enabled: true
Level generator options:
Level spawn location: World: (176,64,248), Chunk: (at 0,4,8 in 11,15; contains blocks 176,0,240 to 191,255,255), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,0,0 to 511,255,511)
Level time: 967 game time, 967 day time
Level dimension: 0
Level storage version: 0x04ABD - Anvil
Level weather: Rain time: 145624 (now: false), thunder time: 109290 (now: false)
Level game mode: Game mode: creative (ID 1). Hardcore: false. Cheats: true
Stacktrace:
at net.minecraft.server.MinecraftServer.D(SourceFile:632)
at net.minecraft.server.MinecraftServer.C(SourceFile:560)
at chb.C(SourceFile:154)
at net.minecraft.server.MinecraftServer.run(SourceFile:464)
at java.lang.Thread.run(Thread.java:745)

– System Details –
Details:
Minecraft Version: 1.12
Operating System: Windows 10 (amd64) version 10.0
Java Version: 1.8.0_25, Oracle Corporation
Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 170916360 bytes (162 MB) / 472649728 bytes (450 MB) up to 1060372480 bytes (1011 MB)
JVM Flags: 6 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx1G -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode -XX:-UseAdaptiveSizePolicy -Xmn128M
IntCache: cache: 6, tcache: 0, allocated: 13, tallocated: 95
Profiler Position: N/A (disabled)
Player Count: 1 / 8; [oo['Zerdguyyy'/558, l='bug?', x=187.24, y=74.53, z=243.57]]
Type: Integrated Server (map_client.txt)
Is Modded: Probably not. Jar signature remains and both client + server brands are untouched.

zerdguyyy

(Unassigned)

Unconfirmed

Minecraft 1.12

Retrieved