• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

"Two actions spell" help plz

Status
Not open for further replies.
Level 1
Joined
Jan 16, 2007
Messages
3
I´m trying to do a spell but i can´t figure it out, can you nice guys help me?
It´s a passive skill that when HP drops under 300 it activates and takes the unit to the position it was 10sec before with the same HP/MP and if i click it(the Spell) and target an enemy unit it does Cyclone that lasts for 5/8/12sec.
I´m still a Noob, I´d realy apreciate help.
-Thx
 
Last edited:
Level 19
Joined
Nov 16, 2006
Messages
2,165
Well this requires two triggers (passive spell):
A trigger thats has the event : Every 0.01 seconds
With action -> (Create a variable)set CasterPosition(point variable) is position of your unit.
Set LifeInteger = Life of your unit bleh ..
Another Trigger with event : Every 0.01 seconds
that would have a condition with if life of your unit lesser then 300
-> action :
Move your unit to Casterposition.

Ah bah I have to eat, I'll create it for u if u wait a bit.
 
Level 6
Joined
Oct 23, 2006
Messages
223
10 seconds ago? so you'd have to store the integer on like 10 variables/arrays and then find the one 9 variables previously? hmm kinda complicated, but do able or you can store its status every 10 seconds...but that would be very inaccurate but might save you some lag time....
 
Level 19
Joined
Nov 16, 2006
Messages
2,165
I think 1 sec update would be enough.
Oh wait we are both wrong lol, it has to be 10 seconds :)

Well now the trigger.
Create a new spell of the basic Cyclone, make it a hero ability and fill the descriptions. Add the amount of time u want them to be cycloned.
Create a trigger just like this :

Code:
Save R
    Events
        Time - Every 10.00 seconds of game time
    Conditions
    Actions
        Set CasterLoc = (Position of Caster)
        Set CasterReal[1] = (Life of Caster)
        Set CasterReal[2] = (Mana of Caster)

Code:
Save T
    Events
        Time - Every 0.10 seconds of game time
    Conditions
        (Life of Caster) Less than 300.00
        Level of Spell  for Caster Greater than 0

    Actions
        Trigger - Turn off Save R <gen>
        Unit - Move Caster instantly to CasterLoc
        Unit - Set life of Caster to CasterReal[1]
        Unit - Set mana of Caster to CasterReal[2]
        Trigger - Turn on Save R <gen>

Variables :
CasterLoc = Point
Caster = Unit
CasterReal[1] & CasterReal[2] = Real with array.

Make sure that you created a trigger where Caster is set to your unit.
 
Level 12
Joined
Apr 29, 2005
Messages
999
Oh wait we are both wrong lol, it has to be 10 seconds :)

Well now the trigger.
Create a new spell of the basic Cyclone, make it a hero ability and fill the descriptions. Add the amount of time u want them to be cycloned.
Create a trigger just like this :

Code:
Save R
    Events
        Time - Every 10.00 seconds of game time
    Conditions
    Actions
        Set CasterLoc = (Position of Caster)
        Set CasterReal[1] = (Life of Caster)
        Set CasterReal[2] = (Mana of Caster)

Code:
Save T
    Events
        Time - Every 0.10 seconds of game time
    Conditions
        (Life of Caster) Less than 300.00
        Level of Spell  for Caster Greater than 0

    Actions
        Trigger - Turn off Save R <gen>
        Unit - Move Caster instantly to CasterLoc
        Unit - Set life of Caster to CasterReal[1]
        Unit - Set mana of Caster to CasterReal[2]
        Trigger - Turn on Save R <gen>

Variables :
CasterLoc = Point
Caster = Unit
CasterReal[1] & CasterReal[2] = Real with array.

Make sure that you created a trigger where Caster is set to your unit.
Hm ass I thought in the first place without thinking clearly but your post convinced my that I was wrong. :eek:
 
Status
Not open for further replies.
Top