Spigot : 1.12.2
Skript : last stable version - dev37c
When writing this code
function test(p: player):
message "" to {_p}
make console execute command "/give %{_p}% enchanted_book 1 0 {StoredEnchantments:[{id:49,lvl:2}]}"
make console execute command "/give %{_p}% enchanted_book 1 0 {StoredEnchantments:[{id:48,lvl:2}]}"
give 64 arrow to {_p}
message "Hello" to {_p}
It says that the line that sends "Hello" to {_p} is not valid because "{_p} is an itemstack" but it is a player
And when sending all messages first, and then giving items to {_p}, like this
function test(p: player):
message "" to {_p}
message "Hello" to {_p}
make console execute command "/give %{_p}% enchanted_book 1 0 {StoredEnchantments:[{id:49,lvl:2}]}"
make console execute command "/give %{_p}% enchanted_book 1 0 {StoredEnchantments:[{id:48,lvl:2}]}"
give 64 arrow to {_p}
It works.
Don't have more info on this bug
This is really weird. @Blueyescat confirmed it for me. Some devs are looking into it now but it's a pretty edge case. Thanks for the detailed info as well, we were able to reproduce it pretty immediately.
This seems to have disappeared since 1.13 dev builds.
Most helpful comment
This is really weird. @Blueyescat confirmed it for me. Some devs are looking into it now but it's a pretty edge case. Thanks for the detailed info as well, we were able to reproduce it pretty immediately.