- Joined
- Jul 19, 2007
- Messages
- 772
I've got problem with a spell in my map that works like Cronosphere. First I want the Cronosphere-spell to ONLY stop the time of enemies not allies too... and secondly the spell sometimes isn't even casted when using it, nothings happening... Pls help me with these problems
-
Spells Vars
-
Events
- Map initialization
- Conditions
-
Actions
- Set ChAbilityMain = Sphere Of Timelessness
- Set ChUnitEffect = Sphere Of Timelessness
-
Events
-
Sphere Of Timelessness
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to ChAbilityMain
-
Actions
- Wait 0.20 seconds
- Set Chronosphere_Caster = (Casting unit)
- Set Chronosphere_Point[0] = (Target point of ability being cast)
- Unit - Create 1 ChUnitEffect for (Owner of Chronosphere_Caster) at Chronosphere_Point[0] facing Default building facing degrees
- Unit Group - Add (Last created unit) to Chronosphere_Group[0]
- If ((Level of ChAbilityMain for (Triggering unit)) Equal to 1) then do (Unit - Add a 5.00 second Generic expiration timer to (Last created unit)) else do (Do nothing)
- If ((Level of ChAbilityMain for (Triggering unit)) Equal to 2) then do (Unit - Add a 7.00 second Generic expiration timer to (Last created unit)) else do (Do nothing)
- If ((Level of ChAbilityMain for (Triggering unit)) Equal to 3) then do (Unit - Add a 9.00 second Generic expiration timer to (Last created unit)) else do (Do nothing)
- Custom script: call RemoveLocation(udg_Chronosphere_Point[0])
- Trigger - Turn on Sphere Of Timelessness Loop <gen>
- Unit - Order Chronosphere_Caster to Stop
-
Events
-
Sphere Of Timelessness Loop
-
Events
- Time - Every 0.01 seconds of game time
- Conditions
-
Actions
-
Unit Group - Pick every unit in Chronosphere_Group[0] and do (Actions)
-
Loop - Actions
- Set Chronosphere_Point[1] = (Position of (Picked unit))
- Set Chronosphere_Group[1] = (Units within 400.00 of Chronosphere_Point[1] matching ((Matching unit) Not equal to Chronosphere_Caster))
-
Unit Group - Pick every unit in Chronosphere_Group[1] and do (Actions)
-
Loop - Actions
- Unit - Pause (Picked unit)
- Animation - Change (Picked unit)'s animation speed to 0.00% of its original speed
-
Loop - Actions
-
Loop - Actions
- Custom script: call RemoveLocation(udg_Chronosphere_Point[1])
-
Unit Group - Pick every unit in Chronosphere_Group[0] and do (Actions)
-
Events
-
Sphere Of Timelessness Resume
-
Events
- Unit - A unit Dies
-
Conditions
- (Unit-type of (Dying unit)) Equal to ChUnitEffect
-
Actions
- Unit - Remove (Dying unit) from the game
- Set Chronosphere_Point[2] = (Position of (Dying unit))
- Set Chronosphere_Group[2] = (Units within 400.00 of Chronosphere_Point[2] matching ((Matching unit) Not equal to Chronosphere_Caster))
-
Unit Group - Pick every unit in Chronosphere_Group[2] and do (Actions)
-
Loop - Actions
- Unit - Unpause (Picked unit)
- Animation - Change (Picked unit)'s animation speed to 100.00% of its original speed
-
Loop - Actions
- Custom script: call RemoveLocation(udg_Chronosphere_Point[2])
-
Events