• 🏆 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!

stop casting as condition

Status
Not open for further replies.
Level 4
Joined
Dec 15, 2007
Messages
108
hi, how i can do a condition that says "a unit stops an spezific ability" coz i have
the ability tranquility in a trigger but when i interrupt the spell the healing is going on and that is not the sense of it

here the trigger:

tranqulity Kopieren
Ereignisse
Einheit - A unit Startet den Effekt einer Fähigkeit
Bedingungen
(Ability being cast) Gleich Tranquiliy
Aktionen
Wait 3.00 seconds
Einheitengruppe - Pick every unit in (Units in (Region centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Schleifen - Aktionen
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
'IF'-Bedingungen
(Ability being cast) Gleich Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Gleich True
((Picked unit) is alive) Gleich True
'THEN'-Aktionen
Einheit - Set life of (Picked unit) to ((Leben of (Picked unit)) + (Real((((Intelligenz of (Triggering unit) (Einschließen bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Schwebender Text - Create floating text that reads (String((((Intelligenz of (Triggering unit) (Einschließen bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Schwebender Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Schwebender Text - Change (Last created floating text): Deaktivieren permanence
Schwebender Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Schwebender Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
'ELSE'-Aktionen
Do nothing
the action x5
 
Level 6
Joined
Aug 15, 2007
Messages
209
English please ;-;.

What I will say is that if there is any loop in that blob of non-English, then make a condition asking if the distance between the initial point of the caster and its current position is greater than 10 or so. If it is, then skip to the end and finish things up. That's how I do my channeling spells, and it works out fine.
 
Level 4
Joined
Dec 15, 2007
Messages
108
you are casting tranquility then the spell is interrupt by a ability stun or ent or you move. for the first u didnt move but the spell is interrupt
 
Level 19
Joined
Aug 24, 2007
Messages
2,888
set a boolean for that
like Casting

set it to true on spell cast
make it false on spell stop

Every second check for it and do actions
 
Level 4
Joined
Dec 15, 2007
Messages
108
tranqulity Kopieren
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Tranquiliy
Actions
Wait 3.00 seconds
Unit Group - Pick every unit in (Units in (Rect centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Ability being cast) Equal to Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Equal to True
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + (Real((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Floating Text - Create floating text that reads (String((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Floating Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
Else - Actions
Do nothing
Wait 3.00 seconds
Unit Group - Pick every unit in (Units in (Rect centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Ability being cast) Equal to Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Equal to True
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + (Real((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Floating Text - Create floating text that reads (String((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Floating Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
Else - Actions
Do nothing
Wait 3.00 seconds
Unit Group - Pick every unit in (Units in (Rect centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Ability being cast) Equal to Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Equal to True
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + (Real((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Floating Text - Create floating text that reads (String((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Floating Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
Else - Actions
Do nothing
Wait 3.00 seconds
Unit Group - Pick every unit in (Units in (Rect centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Ability being cast) Equal to Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Equal to True
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + (Real((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Floating Text - Create floating text that reads (String((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Floating Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
Else - Actions
Do nothing
Wait 3.00 seconds
Unit Group - Pick every unit in (Units in (Rect centered at (Position of (Triggering unit)) with size (600.00, 600.00))) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Ability being cast) Equal to Tranquiliy
((Picked unit) belongs to an ally of (Owner of (Casting unit))) Equal to True
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + (Real((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))))
Floating Text - Create floating text that reads (String((((Intelligence of (Triggering unit) (Include bonuses)) x 2) + SpelldamageP[(Player number of Speller)]))) above (Picked unit) with Z offset 5.00, using font size 8.00, color (0.00%, 100.00%, 0.00%), and 0.00% transparency
Floating Text - Set the velocity of (Last created floating text) to 100.00 towards 95.00 degrees
-------- - --------
Floating Text - Change (Last created floating text): Disable permanence
Floating Text - Change the lifespan of (Last created floating text) to 1.40 seconds
Floating Text - Change the fading age of (Last created floating text) to 0.65 seconds
-------- - --------
Else - Actions
Do nothing

here u have it in english-.-
 
Status
Not open for further replies.
Top