Salaramon
New Member
- Reaction score
- 0
I have started learning JASS , and the best way to learn it for me is making what i want to make. So i am totally nub in JASS
So i just wonder how do i make a JASS trigger that add damage to unit:
Converted and copied this, so what next, just missing the action function?
So i just wonder how do i make a JASS trigger that add damage to unit:
JASS:
function Trig_Add_Damage_Conditions takes nothing returns boolean
if ( not ( GetItemTypeId(GetManipulatedItem()) == 039;I003039; ) ) then
return false
endif
return true
endfunction
function Trig_Add_Damage_Actions takes nothing returns nothing
endfunction
//===========================================================================
function InitTrig_Add_Damage takes nothing returns nothing
set gg_trg_Add_Damage = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Add_Damage, EVENT_PLAYER_UNIT_PICKUP_ITEM )
call TriggerAddCondition( gg_trg_Add_Damage, Condition( function Trig_Add_Damage_Conditions ) )
call TriggerAddAction( gg_trg_Add_Damage, function Trig_Add_Damage_Actions )
endfunction
Converted and copied this, so what next, just missing the action function?