Making a villager trade air gives a console error message
Whenever you change a villagers trade to air using NBT tag editing and open the trade the game crashes even if you don't trade. I used a mod to create the trade but the game will crash even without it on single player and multiplayer.
Steps to reproduce in 14w08a:
- Place command block with
summon Villager ~ ~-2 ~ {PersistenceRequired: 1,CustomName:Lever Game Champion,CustomNameVisible:1, Attributes:[{Name:generic.movementSpeed,Base:0}],Offers:{Recipes:[ {buy:{id:0},sell:{id:323,Count:1,tag:{display:{Name:”Local Lever Game Champion”,Lore:[“Some day I will beat, the legendry Teep!”]}}}}]}} - Pausing the game will yield an exception in the development console:
[19:49:40 INFO]: Client> [19:49:40] [Server thread/INFO]: Saving chunks for level 'New World222'/Overworld [19:49:40 INFO]: Client> s: Saving entity NBT [19:49:40 INFO]: Client> at sk.e(SourceFile:1123) [19:49:40 INFO]: Client> at sk.d(SourceFile:1090) [19:49:40 INFO]: Client> at atc.a(SourceFile:210) [19:49:40 INFO]: Client> at atc.a(SourceFile:99) [19:49:40 INFO]: Client> at oa.b(SourceFile:161) [19:49:40 INFO]: Client> at oa.a(SourceFile:192) [19:49:40 INFO]: Client> at ob.a(SourceFile:663) [19:49:40 INFO]: Client> at net.minecraft.server.MinecraftServer.a(SourceFile:305) [19:49:40 INFO]: Client> at cby.v(SourceFile:124) [19:49:40 INFO]: Client> at net.minecraft.server.MinecraftServer.run(SourceFile:387) [19:49:40 INFO]: Client> at mr.run(SourceFile:657) [19:49:40 INFO]: Client> Caused by: java.lang.NullPointerException [19:49:40 INFO]: Client> at aik.j(SourceFile:114) [19:49:40 INFO]: Client> at ail.a(SourceFile:125) [19:49:40 INFO]: Client> at aai.b(SourceFile:206) [19:49:40 INFO]: Client> at sk.e(SourceFile:1111) [19:49:40 INFO]: Client> ... 10 more [19:49:40 INFO]: Client> [19:49:40] [Server thread/INFO]: Saving chunks for level 'New World222'/Nether [19:49:40 INFO]: Client> [19:49:40] [Server thread/INFO]: Saving chunks for level 'New World222'/The End
Villagers apparently cannot buy air. Doesn't throw exceptions with
summon Villager ~ ~-2 ~ {PersistenceRequired: 1,CustomName:Lever Game Champion,CustomNameVisible:1, Attributes:[{Name:generic.movementSpeed,Base:0}],Offers:{Recipes:[ {buy:{id:1},sell:{id:323,Count:1,tag:{display:{Name:”Local Lever Game Champion”,Lore:[“Some day I will beat, the legendry Teep!”]}}}}]}}
Difference:
buy:{id:0}
-->
buy:{id:1}
2013-06-20, 01:43 AM
2017-03-17, 09:29 PM
2016-01-11, 12:25 PM
4
6
-