mojira.dev
MC-5477

Fireworks and given dye beyond id 15

What I expected to happen was...:
Uncertain, probably just white firework ball.

What actually happened was...:
Game crash.

Steps to Reproduce:
1.

/give @p dye 1 16

(16 or anything higher which is outside the normal range)

2. Put it in a crafting table with gun powder.
3. Game crashes

Linked issues

Attachments

Comments 9

Can reproduce, Though step one is incorrect, it should be /give username 351 1 16

Severe, can cause game crash & loss of data.

Doh! I always forget the 'count' parameter when adding damage parameters. But yes, that is the issue. Good intuiting my error'd instructions.

Description: Updating screen events

java.lang.ArrayIndexOutOfBoundsException: 16
	at zy.a(SourceFile:107)
	at aae.a(SourceFile:810)
	at vk.a(SourceFile:53)
	at vj.a(SourceFile:81)
	at wd.c(SourceFile:77)
	at ux.a(SourceFile:223)
	at bcz.a(SourceFile:295)
	at awv.a(SourceFile:582)
	at awv.b(SourceFile:555)
	at awb.d(SourceFile:132)
	at awb.m(SourceFile:107)
	at ats.k(SourceFile:1158)
	at ats.S(SourceFile:663)
	at ats.d(SourceFile:619)
	at net.minecraft.client.main.Main.main(SourceFile:101)

Fixed in 1.8 snapshots.

I'm still getting a crash in 1.8 snapshots including 14w28b. The instructions to reproduce were a little off.

In step 1 in the above instructions, one should include both the quantity and the damage-value after the player selector, so that the instructions are like this:

1. /give @p dye 1 <some number above 15>
2. Put it on a crafting table with gun powder.
3. game crashes

Confirmed that that still causes a crash.

Would someone be able to fix step 1 in the description? EDIT: <3 Thanks

Fixed, but dye items with a data value over 15 are technically not valid and you should not be using them.

darkjmknight

migrated

Confirmed

crash, dye, firework_charge

Minecraft 1.4.7, Minecraft 1.5, Snapshot 13w11a, Minecraft 1.5.1, Minecraft 1.5.2, Minecraft 1.6.1, Minecraft 1.6.2, Minecraft 14w28a, Minecraft 14w28b

Minecraft 1.8-pre1

Retrieved