• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] Serpent Ward Ability & AoE damage trigger help.

Status
Not open for further replies.

SpasMaster

Hosted Project: SC
Level 24
Joined
Jan 29, 2010
Messages
1,986
Hello, Hive! I am in need of help for an ability I am making.

It's called Magma Totem and it summons a Totem (Tweaked Serpent Ward). After that via trigger I want to cause the totem to damage all nearby enemy units. Sadly it doesn't happen. Here are the triggers. Any ideas? The ability being used is basically Serpent Ward.

[trigger=Magma Totem]Magma Totem
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Magma Totem
Actions
Set Magma_Caster = (Triggering unit)
Set Magma_Point = (Target point of ability being cast)
Trigger - Turn on Magma Totem Loop <gen>
Wait 14.00 seconds **Thats the duration of the Totem**
Trigger - Turn off Magma Totem Loop <gen>[/trigger]

[trigger=Magma Totem Loop (Initially Off)]Magma Totem Loop (Initially Off)
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Set Magma_Value = (10.00 + (5.00 x (Real((Hero level of Magma_Caster)))))
Set Magma_Group = (Units within 225.00 of Magma_Point matching (((Owner of (Matching unit)) Not equal to Player 1 (Red)) and (((Owner of (Matching unit)) Not equal to Player 2 (Blue)) and (((Owner of (Matching unit)) Not equal to Player 3 (Teal)) and ((Owner of (Matching unit)
Special Effect - Create a special effect at Magma_Point using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl
Set Magma_SFX = (Last created special effect)
Special Effect - Destroy (Last created special effect)
Unit Group - Pick every unit in Magma_Group and do (Actions)
Loop - Actions
Unit - Cause Magma_Caster to damage (Picked unit), dealing Magma_Value damage of attack type Spells and damage type Normal
Custom script: call RemoveLocation(udg_Magma_Point)
Custom script: call DestroyGroup(udg_Magma_Group)[/trigger]
 

SpasMaster

Hosted Project: SC
Level 24
Joined
Jan 29, 2010
Messages
1,986
Thanks for your response, but I am 100% sure it isn't because of the conditions because I use the same conditions for all my AoE triggered spells and they all work.

Player 1, Player 2 and Player 3 are the players who are allies. Player 4 is the Computer who is also allied with the Players.

So the condition I place should allow the spell to damage everyone apart from those four.
 
Have you declared the Magma_Value damage? Real variables by default have a value of 0.
You don't have to store the special effect in a variable, just keep the action "Special Effect - Destroy (Last created Special Effect)"; in fact, you don't even use that variable.
For the conditions, just use "((Matching unit) belongs to an enemy of (Owner of Magma_Caster)) Equal to True". Also, make sure the spell is indeed targeting and not some instant spell, like Howl of Terror (which would require (Position of Magma_Caster)) instead.
 

SpasMaster

Hosted Project: SC
Level 24
Joined
Jan 29, 2010
Messages
1,986
Have you declared the Magma_Value damage? Real variables by default have a value of 0.

I don't understand what you mean by "declared". Anyways I did what you said. I ended up having the Loop trigger happen once. It should happen once every second for 14 seconds. It exploded just once. Here are the modified triggers:

[trigger=Magma Totem]Magma Totem
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Magma Totem
Actions
Set Magma_Caster = (Triggering unit)
Set Magma_Point = (Target point of ability being cast)
Trigger - Turn on Magma Totem Loop <gen>
Wait 14.00 seconds
Trigger - Turn off Magma Totem Loop <gen>[/trigger]

[trigger=Magma Totem Loop]Magma Totem Loop
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Set Magma_Group = (Units within 225.00 of Magma_Point matching (((Matching unit) belongs to an enemy of (Owner of Magma_Caster)) Equal to True))
Special Effect - Create a special effect at Magma_Point using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl
Special Effect - Destroy (Last created special effect)
Unit Group - Pick every unit in Magma_Group and do (Actions)
Loop - Actions
Unit - Cause Magma_Caster to damage (Picked unit), dealing (10.00 + (5.00 x (Real((Hero level of Magma_Caster))))) damage of attack type Spells and damage type Normal
Custom script: call RemoveLocation(udg_Magma_Point)
Custom script: call DestroyGroup(udg_Magma_Group)[/trigger]


Note: Ability being used as base is Serpent Ward. That selects a point, right?
 
Status
Not open for further replies.
Top