Cokemonkey11
New Member
- Reaction score
- 18
I have this function:
I need to replace "heal" with whatever the ID is for healing salve (item - converted to a unit ability)
my other problem is, how do I, in a trigger, call this function?
Edit - I figured out the spell ID by viewing object editor as Raw data, but how do I call the function in a trigger now?
JASS:
function paladinCharm takes nothing returns nothing
local unit targetUnit = GetSpellTargetUnit()
local unit castingUnit = GetSpellAbilityUnit()
local unit healDummy
call PauseUnitBJ( true, targetUnit )
call SetUnitLifeBJ( targetUnit, 1.00 )
call SetUnitPositionLoc( targetUnit, PolarProjectionBJ(GetUnitLoc(castingUnit), 100.00, ( GetUnitFacing(castingUnit) - 180.00 )) )
call SetUnitPositionLoc( targetUnit, PolarProjectionBJ(GetUnitLoc(targetUnit), 100.00, ( GetUnitFacing(castingUnit) - 180.00 )) )
call SetUnitPositionLoc( targetUnit, PolarProjectionBJ(GetUnitLoc(targetUnit), 100.00, ( GetUnitFacing(castingUnit) - 180.00 )) )
call SetUnitPositionLoc( targetUnit, PolarProjectionBJ(GetUnitLoc(targetUnit), 100.00, ( GetUnitFacing(castingUnit) - 180.00 )) )
call CreateNUnitsAtLoc( 1, 039;h000039;, GetOwningPlayer(castingUnit), GetUnitLoc(targetUnit), bj_UNIT_FACING )
set healDummy = GetLastCreatedUnit()
call IssueTargetOrderBJ( healDummy, "heal", targetUnit )
call TriggerSleepAction( 1.00 )
call RemoveUnit( healDummy )
call PauseUnitBJ( false, targetUnit )
endfunction
I need to replace "heal" with whatever the ID is for healing salve (item - converted to a unit ability)
my other problem is, how do I, in a trigger, call this function?
Edit - I figured out the spell ID by viewing object editor as Raw data, but how do I call the function in a trigger now?