BloodGauntlet
Member
- Joined
- Jul 27, 2016
- Messages
- 45
- Reaction score
- 18
The way I understand it this should run every time damage occurs? The script isn't running when damage is dealt and no errors are being thrown. I know it's just because of my general lack of understanding but if someone could explain, much thanks.
print_r is a custom function, valid code.
print_r is a custom function, valid code.
Code:
function onHealthChange(creature, attacker, primaryDamage, primaryType, secondaryDamage, secondaryType, origin)
local returnValues = {
["creature"] = creature,
["attacker"] = attacker,
["primaryDamage"] = primaryDamage,
["primaryType"] = primaryType,
["secondaryDamage"] = secondaryDamage,
["secondaryType"] = secondaryType,
["origin"] = origin
}
print_r(returnValues)
end
Code:
<event type="healthchange" name="damage" script="damage.lua"/>