Unhelpful error message when an invalid entity name is given
josephcsible opened this issue ยท 3 comments
Issue Description:
When an invalid entity name is given to game.getEntity
, the error message is very unhelpful in figuring out what the problem is.
What happens:
The message ERROR: Error executing test.zs: null
is printed, and a NullPointerException stack trace is written to the log.
What you expected to happen:
I expected to get a message like this: ERROR: test.zs:1: Could not resolve "EnderDrgaon"
, like you do now if you give an invalid item name.
Script used (Please Pastebin or gist your script, posting an unpasted or ungist'd script will automatically close this issue):
Minetweaker.log file (Please Pastebin or gist your file, posting an unpasted or ungist'd file will automatically close this issue):
Affected Versions (Do not use "latest"):
- Minecraft: 1.11.2
- Forge: 13.20.1.2414
- Crafttweaker: 1.11.2-3.0.26
Your most recent log file where the issue was present:
Ah, forgot to add the bracket handler way...
<entity:sheep>.addDrop(<minecraft:dirt>, 1, 5);
<entity:sheep>.addPlayerOnlyDrop(<minecraft:stick>, 1, 5);
<entity:sheep>.addDrop(<minecraft:diamond>);
<entity:sheep>.removeDrop(<minecraft:wool:*>);
is what I have in my test script
Thanks, I didn't know about that syntax. There doesn't seem to be documentation for mob drops anywhere, so I just took what I was using from your last comment in #37.