mojira.dev
MCPE-172778

[ScriptAPI] setLore of undefined value will crash

Steps to reproduce crash

  • try to setLore with value as undefined

example:

new ItemStack("stick").setLore([undefined]);

Attachments

Comments 2

If you want an undefined lore value, you should be able set it like this:

new ItemStack("stick").setLore([""]);

 

Thank you, but i am not very begginer, Script API should handle this type as other ones for example it handle numbers and objects, and it throws as intended, b7t it should not crash whole MC 😉

ConMaster2112

(Unassigned)

1072371

Confirmed

Multiple

Windows 11

Script-API

1.20.20.20 Preview

Retrieved