Details
-
Type:
Bug
-
Status: Resolved
-
Resolution: Fixed
-
Affects Version/s: 20w14a, 20w15a
-
Fix Version/s: 20w16a
-
Labels:
-
Confirmation Status:Plausible
-
Category:Crash
-
Mojang Priority:Important
Description
The bug
If a set_attributes function contains an undefined attribute, the item stack will try to put null to tag.AttributeName and throws java.lang.NullPointerException.
How to reproduce
/loot give @s loot mc-177253:test
→
An unexpected error occurred trying to execute that command (java.lang.NullPointerException)
- data/mc-177253/loot_tables/test.json
{ "type": "minecraft:generic", "pools": [ { "rolls": 1, "entries": [ { "type": "minecraft:item", "name": "minecraft:stone", "functions": [ { "function": "minecraft:set_attributes", "modifiers": [ { "name": "mc-177253", "attribute": "mc-177253:undefined", "operation": "addition", "amount": 0.0, "slot": "mainhand" } ] } ] } ] } ] }
Attachments
Issue Links
- relates to
-
MC-177085 Missing UUID field in attributes crash the game
- Resolved