JomarTaaca
New Member
- Reaction score
- 0
Hey, Ive been trying to add this effect that when a unit dies in the map, it would make creat a "bomb-like" effect that causes every unit/destructable anywhere around it in an AOE to be damaged by 500 hit points. Ive created a trigger and tested it for about 50 times now and it isnt working, can anyone help me out? Im pretty sure its an easy trigger to any experienced people whos used world editor. Thanks!
Here is the GUI converted to JASS
And here is the GUI Picture (Edited)
Here is the GUI converted to JASS
Code:
function Trig_Inf_Dies_Copy_Func001C takes nothing returns boolean
if ( not ( GetUnitTypeId(GetDyingUnit()) == 'OC05' ) ) then
return false
endif
if ( not ( GetUnitTypeId(GetDyingUnit()) == 'O005' ) ) then
return false
endif
if ( not ( GetUnitTypeId(GetDyingUnit()) == 'OC00' ) ) then
return false
endif
return true
endfunction
function Trig_Inf_Dies_Copy_Conditions takes nothing returns boolean
if ( not Trig_Inf_Dies_Copy_Func001C() ) then
return false
endif
return true
endfunction
function Trig_Inf_Dies_Copy_Actions takes nothing returns nothing
call SetUnitScalePercent( GetDyingUnit(), 150.00, 150.00, 150.00 )
call UnitDamageTargetBJ( GetDyingUnit(), GetAttacker(), 500, ATTACK_TYPE_CHAOS, DAMAGE_TYPE_UNIVERSAL )
endfunction
//===========================================================================
function InitTrig_Inf_Dies_Copy takes nothing returns nothing
set gg_trg_Inf_Dies_Copy = CreateTrigger( )
call TriggerRegisterPlayerUnitEventSimple( gg_trg_Inf_Dies_Copy, Player(9), EVENT_PLAYER_UNIT_DEATH )
call TriggerRegisterPlayerUnitEventSimple( gg_trg_Inf_Dies_Copy, Player(10), EVENT_PLAYER_UNIT_DEATH )
call TriggerRegisterPlayerUnitEventSimple( gg_trg_Inf_Dies_Copy, Player(11), EVENT_PLAYER_UNIT_DEATH )
call TriggerAddCondition( gg_trg_Inf_Dies_Copy, Condition( function Trig_Inf_Dies_Copy_Conditions ) )
call TriggerAddAction( gg_trg_Inf_Dies_Copy, function Trig_Inf_Dies_Copy_Actions )
endfunction
And here is the GUI Picture (Edited)
Trigger:
- Inf Dies
- Events
- Unit - A unit owned by Player 10 (Light Blue) Dies
- Unit - A unit owned by Player 11 (Dark Green) Dies
- Unit - A unit owned by Player 12 (Brown) Dies
- Conditions
- Or - Any (Conditions) are true
- Conditions
- (Unit-type of (Dying unit)) Equal to Infernal Fire Caster
- (Unit-type of (Dying unit)) Equal to Infernal Ent Killer(Fury)
- (Unit-type of (Dying unit)) Equal to Infernal Ent Killer
- Conditions
- Or - Any (Conditions) are true
- Actions
- Animation - Change (Dying unit)'s size to (150.00%, 150.00%, 150.00%) of its original size
- Unit - Cause (Dying unit) to damage (Killing unit), dealing 500.00 damage of attack type Chaos and damage type Universal
- Unit - Cause (Dying unit) to damage circular area after 0.00 seconds of radius 500.00 at (Position of (Triggering unit)), dealing 100.00 damage of attack type Chaos and damage type Normal
- Unit - Explode (Dying unit)
- Events