TheLimeGlass/Skellett

When using with Citizens I cannot get the NPC in the on damage event

Opened this issue · 0 comments

I have the current code below:

# When the citizen is hurt by another entity
on citizen damage from an entity:

    set {_attacker} to event-entity
    set {_npc} to event-citizen # <------ ERROR HERE

    send "Damage Taken: %the citizen damage%"
    send "Attacker: %{_attacker}%" to all players

According to an update from a while ago (https://www.spigotmc.org/resources/skript-java-addon-skellett.34361/update?update=140054),
image

I should be able to get the npc object with the syntax: [the] [event(-| )](citizen|npc), but it gives me the following error:

[21:50:54 INFO]: Line 35: (test.sk)
[21:50:54 INFO]:     There's no types.citizen in an on (npc|citizen) damage (by|from) [a[n]] entity event
[21:50:54 INFO]:     Line: set {_npc} to event-citizen

(Works with other values, such as event-entity (attacker, in this case) and event-string)

Sorry if I'm using an old resource, I couldn't find any examples on skunity and didn't find anything on Google.
Thanks in advance!