DamageEvent:Special variables:attacker -> Player who attackedvictim -> Entity that got damagedcause -> DamageCause of the eventevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)damage -> The amount of damage dealt item -> Item used to damageitem -> Item used to attackUsage:item.setDamageEvent(core.createRunnable("<code>"))
DamageEvent:Special variables:attacker -> Player who attackedvictim -> Entity that got damagedcause -> DamageCause of the eventevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)damage -> The amount of damage dealt item -> Item used to damageitem -> Item used to attackUsage:item.setDamageEvent(core.createRunnable("<code>"))ProjectileHitEntityEvent (Called when the projectile from core.shootProjectile() hits an entity):Special variables:shooter -> Player that shot the projectilevictim -> Entity that got hitlastLocation -> Last location of the projectile (Entity location for this event)event -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)item -> Item used to shootUsage:item.setParticleHitEvent(core.createRunnable("<code>"))ProjectileHitBlockEvent (Called when the projectile from core.shootProjectile() hits a block):Special variables:shooter -> Player that shot the projectilelastLocation -> The last location of the projectile before he got destroyedevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)item -> Item used to shootUsage:item.setParticleHitEvent(core.createRunnable("<code>"))ArmorEquipEvent (Called when the player equips an armor piece)Special variables:player -> Player who equipped the armoritem -> Equipped itemevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)Usage:item.setArmorEquipEvent(core.createRunnable("<code>"))ArmorUnEquipEvent (Called when the player un-equips an armor piece)Special variables:player -> Player who un-equipped the armoritem -> Un-Equipped itemevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)Usage:item.setArmorUnEquipEvent(core.createRunnable("<code>"))PlayerMoveEvent (Called when the player moves while holding the item or when equipped as his armor)Special Variables:player -> The player who moveditem -> Held item / Equipped itemevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)Usage:item.setPlayerMoveEvent(core.createRunnable("<code>"))PlayerDamageEvent (Called when the player gets damaged, called for the item the player holds and for each armor piece he has equipped)Special Variables:player-> The player that got damageditem -> The item the player has (held item & armor pieces)cause -> The damage causecauseName -> The name of the damage cause (just cause.getName() used for the ingame editor)damage -> The amount of damage takenevent -> The event itself (you can do core.cancelEvent(event) to cancel it like it never happened)Usage:item.setPlayerDamageEvent(core.createRunnable("<code>"))