Hi
An Item is lying on the ground
A Hero picks it up
as long as its carried every 0.2 sec a random enemy in Range (512) of the Hero gets 50 dmg and small effect is created at the enemy to show who is hit.
But i dont get this working :-(
my problem is the event, i can either choose -a unit picks up item- which would be great cause i would have a "triggering unit" but now i can no longer choose -every 0.2 sec of the game- which i need to continue damaging enemys...
The best i managed is to damage ONE enemy right after picking it up -.-
Is there a way to trigger something every X secs not as event but as action (or maybe condition? sounds unrealistic) ?
this is my trigger so far
wtf ?
sorry somehow my trigger wasnt converted back :->
its totaly gui
To post a trigger i have to:
convert trigger to text
copy paste text here
set [wc3 ] and [/wc3 ] at end and beginning.
did i do something wrong ? -.-
not my day
An Item is lying on the ground
A Hero picks it up
as long as its carried every 0.2 sec a random enemy in Range (512) of the Hero gets 50 dmg and small effect is created at the enemy to show who is hit.
But i dont get this working :-(
my problem is the event, i can either choose -a unit picks up item- which would be great cause i would have a "triggering unit" but now i can no longer choose -every 0.2 sec of the game- which i need to continue damaging enemys...
The best i managed is to damage ONE enemy right after picking it up -.-
Is there a way to trigger something every X secs not as event but as action (or maybe condition? sounds unrealistic) ?
this is my trigger so far
Trigger:
- function Trig_Dmgaura_Conditions takes nothing returns boolean
- if ( not ( IsItemOwned(gg_item_I006_0263) == true ) ) then
- return false
- endif
- return true
- endfunction
- function Trig_Dmgaura_Func003Func002A takes nothing returns nothing
- call AddSpecialEffectTargetUnitBJ( "overhead", GetEnumUnit(), "Abilities\\Spells\\Orc\\Disenchant\\DisenchantSpecialArt.mdl" )
- call UnitDamageTargetBJ( GetManipulatingUnit(), GetEnumUnit(), 50.00, ATTACK_TYPE_CHAOS, DAMAGE_TYPE_DEATH )
- endfunction
- function Trig_Dmgaura_Func003C takes nothing returns boolean
- return true
- endfunction
- function Trig_Dmgaura_Actions takes nothing returns nothing
- if ( Trig_Dmgaura_Func003C() ) then
- call ForGroupBJ( GetRandomSubGroup(1, GetUnitsInRangeOfLocAll(512, GetUnitLoc(GetManipulatingUnit()))), function Trig_Dmgaura_Func003Func002A )
- else
- call DoNothing( )
- endif
- if ( Trig_Dmgaura_Func003C() ) then
- endfunction
- //===========================================================================
- function InitTrig_Dmgaura takes nothing returns nothing
- set gg_trg_Dmgaura = CreateTrigger( )
- call TriggerRegisterTimerEventPeriodic( gg_trg_Dmgaura, 0.20 )
- call TriggerAddCondition( gg_trg_Dmgaura, Condition( function Trig_Dmgaura_Conditions ) )
- call TriggerAddAction( gg_trg_Dmgaura, function Trig_Dmgaura_Actions )
- endfunction
- if ( not ( IsItemOwned(gg_item_I006_0263) == true ) ) then
wtf ?
sorry somehow my trigger wasnt converted back :->
its totaly gui
To post a trigger i have to:
convert trigger to text
copy paste text here
set [wc3 ] and [/wc3 ] at end and beginning.
did i do something wrong ? -.-
not my day