1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still haven't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. Ride into the sunset with the 32nd Modeling Contest. The contest is optionally paired. Best of luck, people!
    Dismiss Notice
  4. This adventure has come to an end. Congratulate our heroes in the 16th Mini Mapping Contest Results.
    Dismiss Notice
  5. From the gates of hell, the 5th Special Effect Contest Results have emerged.
    Dismiss Notice
  6. Race against the odds and Reforge, Don't Refund. The 14th Techtree Contest has begun!
    Dismiss Notice
  7. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

[Trigger] Cooldown not triggering for triggered ability?

Discussion in 'Triggers & Scripts' started by hobbles, Feb 23, 2009.

  1. hobbles

    hobbles

    Joined:
    Jan 26, 2009
    Messages:
    13
    Resources:
    0
    Resources:
    0
    Hey, I'm making an omnislash trigger but the cooldown isn't starting after I use the ability. I've checked Object Editor and the cooldown is definitely there, so I came to the conclusion that the problem's trigger-based.
    I'm not sure if it's because of how I start my trigger:

    • Events
      • Unit - A unit Starts the effect of an ability


    or if it's because I use

    • Actions
      • Move OmnislashBlademaster instantly to OmnislashTargetPosition
      • ---this is later in my trigger but not after a Wait ## seconds.... ---


    if anyone's experienced the same problem before, can you tell me how you fixed it?

    Thanks :3
     
  2. Freyleyes

    Freyleyes

    Joined:
    Jun 28, 2008
    Messages:
    766
    Resources:
    1
    Spells:
    1
    Resources:
    1
    It is because when you start the ability the unit is instantly moved right?
    To overcome this just ad a wait 0.1 sec delay to the spell :

    • Actions
      • Wait 0.10 seconds
      • Unit - Move Unit_Caster[1] instantly to (Position of Unit_Caster[2])


    Remember to set the units to variables as you are using a wait.

    where unit_caster[1] is the caster and unit_caster[2] is the target.

    Hope it helps.
     
  3. Justify

    Justify

    Joined:
    Mar 16, 2008
    Messages:
    935
    Resources:
    5
    Models:
    1
    Icons:
    1
    Spells:
    3
    Resources:
    5
    This cant be, the event "effect of an ability" fires after manacosts and cd, so it has to be another trigger or the ability itself.
     
  4. Need_O2

    Need_O2

    Joined:
    Aug 24, 2007
    Messages:
    2,880
    Resources:
    0
    Resources:
    0
    nope :/
    Even if you move in Effect of ability no cooldown - no manacost
    Ya I know sux
     
  5. Justify

    Justify

    Joined:
    Mar 16, 2008
    Messages:
    935
    Resources:
    5
    Models:
    1
    Icons:
    1
    Spells:
    3
    Resources:
    5
    Are you sure? I never tested it since the order "stop" doesn't work anymore (stopping the cast per trigger, so I needed starts casting an ability)... that would be... Blizzard, what else :/
     
  6. Need_O2

    Need_O2

    Joined:
    Aug 24, 2007
    Messages:
    2,880
    Resources:
    0
    Resources:
    0
    ya sure (I encountered same problem with some spells and saw problems about this on posts of ones try to make blink strike)
     
  7. Saishy

    Saishy

    Joined:
    Mar 23, 2008
    Messages:
    947
    Resources:
    0
    Resources:
    0
    Starts the effect of ability trigger before cooldown and after manacost.
     
  8. hobbles

    hobbles

    Joined:
    Jan 26, 2009
    Messages:
    13
    Resources:
    0
    Resources:
    0
    Yeah Saishy's right; the mana cost works - my hero loses 200 mana but the cooldown doesn't go off

    I haven't tried that .1 sec wait thing but i'll see if it works

    EDIT: It worked! Thanks, +rep :eek:
     
  9. Lord_BoNes

    Lord_BoNes

    Joined:
    Sep 5, 2007
    Messages:
    264
    Resources:
    0
    Resources:
    0
    The order is:
    Begins casting ability = No mana cost (if stopped)
    Starts effect of ability = No Cooldown (if stopped)
    Finishes casting ability = Mana cost + cooldown

    Instead of adding in a wait, just use "unit finishes casting ability". :thumbs_up:
     
  10. Zack1996

    Zack1996

    Joined:
    Dec 18, 2007
    Messages:
    1,088
    Resources:
    3
    Models:
    1
    Spells:
    1
    Tutorials:
    1
    Resources:
    3
    No, thats not the best way. It is actually like this:
    Begins casting: The Unit close enough to cast the spell
    Starts the effect: The Spell's Mana Cost and/or Cooldown is applied
    Finishes casting: The unit is not interrupted until the spell's icon is no longer greenish. Meaning that the unit must actually stand there until the spell's icon becomes not greenish.

    Overall, I would reccommend a short wait, as short as possible or about the same as the interval between each slash. I know mypost is quite irrelevant but I just wanted to clear some misconceptions.
     
  11. Need_O2

    Need_O2

    Joined:
    Aug 24, 2007
    Messages:
    2,880
    Resources:
    0
    Resources:
    0
    And finishes casting ability may forget its target location (Ive encountered with that many times)
     
  12. Dynasti

    Dynasti

    Joined:
    Oct 18, 2007
    Messages:
    877
    Resources:
    4
    Maps:
    2
    Spells:
    1
    Tutorials:
    1
    Resources:
    4
    Just use the "Unit is ordered to your spell"
     
  13. Saishy

    Saishy

    Joined:
    Mar 23, 2008
    Messages:
    947
    Resources:
    0
    Resources:
    0
    LOL?

    I don't think so...
     
  14. Rmx

    Rmx

    Joined:
    Aug 27, 2007
    Messages:
    1,088
    Resources:
    18
    Icons:
    3
    Spells:
    15
    Resources:
    18
    OMG i have an omnislash abiltie but it doesn't do this ???? why /?? i used start the effect of an abilitie and it's MUI and don't use waits !!!!!!
    Maybe u based of a bad abilitie try to base it of storm bolt or fire bold this should work :)
     
  15. Urwaldbewohner

    Urwaldbewohner

    Joined:
    May 5, 2008
    Messages:
    99
    Resources:
    0
    Resources:
    0
    Mith 2 triggers it works probaly it isnĀ“t the best possibilityy, but it works.

    Omnislash 1
    Event
    Unit - A unit Starts casting an ability
    Condition
    (Ability being cast) Gleich Omnislash
    Action
    Unit - Order (Casting unit) to Stoppen

    Omnislash 2
    Event
    Unit - A unit Stops casting an ability
    Condition
    (Ability being cast) Gleich Omnislash
    Action
    -Move .....
     
  16. Dr Super Good

    Dr Super Good

    Spell Reviewer

    Joined:
    Jan 18, 2005
    Messages:
    25,930
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    Simply move the unit via SetUnitX/Y, as that does not inturupt current orders.
     
  17. Saishy

    Saishy

    Joined:
    Mar 23, 2008
    Messages:
    947
    Resources:
    0
    Resources:
    0
    I would like to know how Dota made blink strike, since it does not trigger "Spell Blocking" runes because it moves the unit before the spell effect but after cooldown o.o
     
  18. Element of Water

    Element of Water

    Joined:
    Aug 3, 2008
    Messages:
    2,298
    Resources:
    5
    Spells:
    3
    Tutorials:
    1
    JASS:
    1
    Resources:
    5
    Instead of waiting 0.1 seconds, which will wait about 0.3 seconds afaik, you should wait 0 seconds, which waits for about 0.03 seconds afaik.
     
  19. Dr Super Good

    Dr Super Good

    Spell Reviewer

    Joined:
    Jan 18, 2005
    Messages:
    25,930
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    Element of Water, even if it is set to 0 it still is delayed like 0.1 seconds single player and 0.3+ multiplayer.

    SetUnitX/Y does not interupt the units current orders however can have a few other problems. Generally it workes ok im my experience unless you use it on unmovable units like buildings. It also allows the unit to keep moving while you move it so I am suprized people do not use it to make a sliding trigger.
     
  20. Element of Water

    Element of Water

    Joined:
    Aug 3, 2008
    Messages:
    2,298
    Resources:
    5
    Spells:
    3
    Tutorials:
    1
    JASS:
    1
    Resources:
    5
    I'm sure I heard somewhere that TSA for "0 seconds" only delays a very short time.

    Yeah well there is the problem with pathability... that and the fact most GUIers don't know it exists...