Distance Based Skill

Kangaxx

New Member
Reaction score
1
Another plea for help, i want my hero to get his aura disabled if he hasn't moved at least 20 range in the last 1 second and every 500 units travelled to emit a thunderclap, the thunderclap should also make enemies miss. Though something is wrong, here are my triggers:

Trigger:
  • Unstable Ground Begins
    • Events
      • Unit - A unit Learns a skill
    • Conditions
      • (Learned Hero Skill) Equal to Unstable Ground
    • Actions
      • Set Owner_of_Unit = (Owner of (Triggering unit))
      • Set Distance_Travelled = 0.00
      • Set Trig_Unit = (Triggering unit)
      • Set Position_of_Shike = (Position of (Triggering unit))
      • Unit - Create 1 Dummy for Owner_of_Unit at (Position of (Triggering unit)) facing Default building facing degrees
      • Set Dummy = (Last created unit)
      • Unit - Order Dummy to Follow Trig_Unit
      • Trigger - Turn on Unstable Ground Distance <gen>
      • Trigger - Turn on Unstable Ground Moving <gen>
      • Trigger - Turn on Unstable Ground Stomp <gen>

Trigger:
  • Unstable Ground Distance
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
    • Actions
      • Set Distance_Travelled = (Distance_Travelled + (Distance between Position_of_Shike and (Position of Trig_Unit)))
      • Set Dummy_Loc = (Position of Dummy)

Trigger:
  • Unstable Ground Stomp
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
      • Distance_Travelled Greater than or equal to 500.00
    • Actions
      • Unit - Add Unstable Ground Clap to Dummy
      • Unit - Set level of Unstable Ground Clap for Dummy to (Level of Unstable Ground for Trig_Unit)
      • Unit - Order Dummy to Human Mountain King - Thunder Clap
      • Wait 1.00 seconds
      • Unit - Order Dummy to Follow Trig_Unit

Trigger:
  • Unstable Ground Moving
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • Set Distance_Travelled = 0.00
      • Set Dummy_Loc = (Position of Dummy)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Distance between Position_of_Shike and (Position of Trig_Unit)) Greater than or equal to 20.00
        • Then - Actions
          • Unit - Add Unstable Ground Unit to Dummy
          • Unit - Set level of Unstable Ground Unit for Dummy to (Level of Unstable Ground for Trig_Unit)
          • Player - Enable Unstable Ground for Owner_of_Unit
        • Else - Actions
          • Player - Disable Unstable Ground for Owner_of_Unit
          • Unit - Remove Unstable Ground Unit from Dummy
 

canons200

New Member
Reaction score
50
try this?
Trigger:
  • abc
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
    • Actions
      • Set P_DummyMove = (Position of yourdummy)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • (Distance between Position_of_yourcaster and (Position_of_P_DummyMove)) Greater than or equal to 21.00
        • Then - Actions
 

Kangaxx

New Member
Reaction score
1
try this?
Trigger:
  • abc
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
    • Actions
      • Set P_DummyMove = (Position of yourdummy)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • (Distance between Position_of_yourcaster and (Position_of_P_DummyMove)) Greater than or equal to 21.00
        • Then - Actions

How can a point variable be an unit variable?
 

HydraRancher

Truth begins in lies
Reaction score
197
Trigger:
  • Unstable Ground Stomp
    • Events
      • Time - Every 0.01 seconds of game time
    • Conditions
      • Distance_Travelled Greater than or equal to 500.00
    • Actions
      • Unit - Add Unstable Ground Clap to Dummy
      • Unit - Set level of Unstable Ground Clap for Dummy to 4
      • Unit - Order Dummy to Human Mountain King - Thunder Clap
      • Unit - Order Dummy to Follow (Triggering unit)


1.Theres no triggering Unit

2.Your ordering him to thunder clap then immediately follow.
 

Kangaxx

New Member
Reaction score
1
That's not really the problem, though thanks for pointing the clap out. The skill either gets permanentely disabled OR is on all the time.
EDIT: Distance travelled never reaches 500 :(.
 

Moridin

Snow Leopard
Reaction score
144
First trigger -
Trigger:
  • Set Owner_of_Unit = (Owner of Caster)


Shouldn't that be Triggering unit? I don't think it would register the Triggering unit as the Casting unit.

--

Also I realise that except for Trigger 2, you don't ever alter the variable Distance Travelled.
So what's going to happen is:
-Unit gets the ability
-Trigger is switched on
-"(Distance between Position_of_Shike and (Position_of_Shike offset by Distance_Travelled towards (Facing of Trig_Unit) degrees)) Greater than or equal to 21.00" = Distance between point A and point A offset by Distance travelled (which is set to 0 in the beginning) which is NOT GREATER than 21 = NOT TRUE
-Goes to else.
-Does nothing.

I can't see the distance travelled ever increasing.
Edit: I really think that's your problem there.
 

Moridin

Snow Leopard
Reaction score
144
Try this. Edit the second trigger to be something like:

Event: Every 0.01 seconds.
Condition:
Action: Set Distance_Travelled = Distance_Travelled + (Distance between Position_of_Shike and Position of Trig_unit)

That might work.
 

Kangaxx

New Member
Reaction score
1
Okay, it's working now, but the dummy is clapping the earth like every 0.1 second. Um, i guess i need to reset the distance travelled to 0?
 

Kangaxx

New Member
Reaction score
1
Still clapping every 0.1 :(.

Trigger:
  • Unstable Ground Distance
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
    • Actions
      • Set Distance_Travelled = (Distance_Travelled + (Distance between Position_of_Shike and (Position of Trig_Unit)))
      • Set Dummy_Loc = (Position of Dummy)


Trigger:
  • Unstable Ground Stomp
    • Events
      • Time - Every 0.10 seconds of game time
    • Conditions
      • Distance_Travelled Greater than or equal to 500.00
    • Actions
      • Set Distance_Travelled = 0.00
      • Unit - Add Unstable Ground Clap to Dummy
      • Unit - Set level of Unstable Ground Clap for Dummy to (Level of Unstable Ground for Trig_Unit)
      • Unit - Order Dummy to Human Mountain King - Thunder Clap
      • Wait 1.00 seconds
      • Unit - Order Dummy to Follow Trig_Unit


^ Edited triggers. It should also stop clapping when i'm not moving.
My aura gets instantly removed. Another fix needed.
 

Moridin

Snow Leopard
Reaction score
144
Ok. You made a simple mistake.

Edit 2: For the above trigger (the one with the Order Dummy to Human Mountain King - Thunder Clap in it) set the Periodic Event to Every 1.0 second NOT GAME TIME.
Edit: Delete the Distance_travelled = 0 line in the trigger you've posted above.

Add this line:
Trigger:
  • Set Distance_Travelled = 0.00


to this trigger:
Trigger:
  • * Unstable Ground Moving
    • o Events
      • + Time - Every 1.00 seconds of game time
    • o Conditions
    • o Actions
      • + If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • # If - Conditions
          • * (Distance between Position_of_Shike and (Position of Trig_Unit)) Greater than or equal to 20.00
        • # Then - Actions
          • * Unit - Add Unstable Ground Unit to Dummy
          • * Unit - Set level of Unstable Ground Unit for Dummy to (Level of Unstable Ground for Trig_Unit)
        • # Else - Actions
          • * Player - Disable Unstable Ground for Owner_of_Unit
          • * Unit - Remove Unstable Ground Unit from Dummy


...BEFORE THE IF CONDITION. It should be something like this now:
Trigger:
  • * Unstable Ground Moving
    • o Events
      • + Time - Every 1.00 seconds of game time
    • o Conditions
    • o Actions
      • + Set Distance_Travelled = 0.00
      • + If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • # If - Conditions
          • * (Distance between Position_of_Shike and (Position of Trig_Unit)) Greater than or equal to 20.00
        • # Then - Actions
          • * Unit - Add Unstable Ground Unit to Dummy
          • * Unit - Set level of Unstable Ground Unit for Dummy to (Level of Unstable Ground for Trig_Unit)
        • # Else - Actions
          • * Player - Disable Unstable Ground for Owner_of_Unit
          • * Unit - Remove Unstable Ground Unit from Dummy
 

Kangaxx

New Member
Reaction score
1
The dummy is still clapping like a madman (with 1 hand!) and if my skill gets removed, it never returns :(.
EDIT: Now the skill is disabled untill i move from my initial (starting) spot.
 

canons200

New Member
Reaction score
50
in your case, mind you re-edit your first post and give out more information? because i don't know what you want to do with your skill and your ability.

i can give you full trigger provided i know what you really want
EDIT
this is not offence because sometime we use this method to set trigger but then another person use another method, and have a hard time to get to know how it work and yet return the same outcome with those different trigger
 

Moridin

Snow Leopard
Reaction score
144
Yeah I made a mistake. Give me a minute. I need to finish somthing and then I'll help you solve your problem. I think your solution is an easy one though...no worries.
 

Kangaxx

New Member
Reaction score
1
Edited my first post, changed the triggers to new ones.
Code:
Changelog:
No offense taken.
 

canons200

New Member
Reaction score
50
Edited my first post, changed the triggers to new ones.
Code:
Changelog:
No offense taken.

no, what i meant is that just tell us what you want your spell to do, how your spell look like, and what effect you want to have in your spell.

no need to show me your trigger, because i will make a trigger and post it here
 

Kangaxx

New Member
Reaction score
1
Lvl 1: -5% MS for enemies/+3% MS for Hero. Every 500 units travelled he stomps the ground for 30 Dmg in 300 AoE, causing the enemys to miss for 8% for 3 secs.
Lvl 2: -8% MS for enemies/ +5% MS for Hero. 500 units travelled he stomps the ground for 45 Dmg in 325 AoE, causing the enemys to miss for 12% for 3 secs.
Lvl 3: -11% MS for enemies/ +7% MS for Hero. 500 units travelled he stomps the ground for 60 Dmg in 350 AoE, causing the enemys to miss for 16% for 3 secs.
Lvl 4: -14% MS for enemies/+9% MS for Hero. 500 units travelled he stomps the ground for 75 Dmg in 375 AoE, causing the enemys to miss for 20% for 3 secs.

Note: this Aura do only occur while Hero is Moving/Attacking/Casting spells. If he stands still/is stunned/hexed for 1sec the ground whil stop vibrating. If he starts again the Aura will occur after 1 seconds.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top