No categories assigned

LUA:AddHate

Revision as of 10:24, 28 February 2020 by Neatz09 (talk | contribs) (LUA Functions: AddHate(): added 4th param)

LUA Functions: AddHate()

Adds hate to param2 from param1


Syntax

AddHate(param1, param2, param3, param4)


Parameters

Required - param1 (Spawn), param2 (Spawn), param3 (sint32)
param1 is the spawn that is adding hate
param2 is the spawn recieving the hate
param3 is the amount of hate to add
param4 is a bool to send the packet

Usage

function cast(Caster, Target)
    -- Add 50 hate to the target
    AddHate(Caster, Target, 50, 1)
end

This is a simple taunt spell that adds 50 hate to the target.

Notes

If this is called from a spell script then the target/targets will be determined by the spell data(encounter AE, true AE, single target, etc...), the param is still required though.