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 havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. Don’t forget to sign up for the Hive Cup. There’s a 555 EUR prize pool. Sign up now!
    Dismiss Notice
  4. The Hive Workshop Cup contest results have been announced! See the maps that'll be featured in the Hive Workshop Cup tournament!
    Dismiss Notice
  5. The results are out! Check them out.
    Dismiss Notice
  6. The poll for Hive's 12th Concept Art Contest is up! Go cast your vote for your favourite genie!
    Dismiss Notice
  7. The raddest synthwave tracks were chosen - Check out our Music Contest #12 - Results and congratulate the winners!
    Dismiss Notice
  8. 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.

How do i make a unit's ability sync with its animation?

Discussion in 'World Editor Help Zone' started by Scippi, Feb 13, 2010.

  1. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    Hey guys i was wondering if anyone could tell me how to make a unit's animation sync with the ability it's casting as when a unit on my map casts an ability the projectile is fired before it could finish its animation, is there any way to make the projectile fire AFTER or when the unit has finished its animation?

    Thanks in advance
     
  2. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    You can go to the ability, and change the "stats-casting time", so that it takes longer to cast the ability (since the animation is cued when you start to cast the ability". If you time it properly, then it should turn out to:
    Ability cued-->Animation-->projectile is fired

    You can also go to the unit with the spell in object editor, then under "Art-Animation cast backswing" you can lower the value, so that his animation time takes less time. however, i think this might also affect the attacking backswing.
     
  3. Goolygot

    Goolygot

    Joined:
    Sep 1, 2008
    Messages:
    478
    Resources:
    0
    Resources:
    0
    If you make the ability in triggers or jass, you can just use wait x(how long the cast animation last) seconds, as the first action after he/she finishes casting the ability in events.
     
  4. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    Thanks for the responses guys :D but none of those 2 solutions seemed to work :(
     
  5. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Is it a triggered spell? can you describe it in more detail please?
     
  6. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    No it's not a trigger spell, it's basically storm bolt but with a greater range and a different projectile, i'm trying to turn it into a one hit sniping kill
     
  7. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    hmmm... if you changed the casting time, it should work...
     
  8. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    I have done but the only thing that does is make the delay before the skill can be casted longer, the projectile still shoots out earlier than the animation
     
  9. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    hmmm...

    Wait... What unit are you animating it for? Because if the unit doesnt have a Channeling animation, then the spell casting delay wont work (he'll just sit there looking dumb).

    But, you could trigger it so:

    • Event - Unit begins casting an ability
    • Condition - Ability is equal to (sniping bolt thing)
    • Actions
      • Animation - Play casting unit's (attack or spell animation; whichever one you want )

    With this one, if you add the delay, this should happen:

    Spell is cued --> Animation is played during the channeling/delay time ---> Bolt is fired out
     
  10. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    Thanks for putting the effort into this Vestri :D
    And as for the trigger thing, I'm having a few problems with the animations. The default casting animation of the model is called Spell Throw on the model preview on the left hand side, and the animation i want to use is called Attack Slam, this is the name that i entered on the animation action "Play casting unit's Attack Slam animation", when it casts the ability the default animation is played even when i put in "Remove the Spell Throw Animation Tag"
     
  11. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    lol.... xD

    Okay, go to the ability, and under "Art-Animation Names", it should be "spell,throw"; change this to "spell,slam".

    If you have problems with the delay and stuff, then the triggers + cast delay will fix that. But just changing the animation should cue the slam animation instead.

    Good luck with your map!
     
  12. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    Thank you, and what animation do i put on the trigger? Play spell,slam animation?
     
  13. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    You only need the trigger if you want it to delay to show the animation first, and yes, "play spell,slam" is the right one.
     
  14. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    So i've set the animation on the spell to spell,slam and set the play animation to play spell,slam but everytime the unit casts the ability it's still using the default Spell Throw animation :(
     
  15. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Oops, sorry i forgot one little thing. Remove the "Spell" part, and just leave the "slam" string. What happens is that if the unit has both, the animation before the others takes priority, and "spell" by default cues the unit's default spell casting animation. If you just leave "slam", then it will only cue the slam animation.

    The reason why there are two sometimes, is so that animations dont get glitchy when you have channeling spells, for instance.
     
  16. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    The unit only starts playing the animation after the Cast time delay (1.4s) and not when it starts casting the ability :(

    This is the trigger

    • Snipe start
      • Events
        • Unit - Marksman 0310 <gen> Begins casting an ability
      • Conditions
        • (Ability being cast) Equal to Snipe
      • Actions
        • Animation - Play Marksman 0310 <gen>'s slam animation
        • Animation - Change (Target unit of ability being cast)'s animation speed to 60.00% of its original speed
        • Animation - Change Marksman 0310 <gen>'s animation speed to 40.00% of its original speed
        • Special Effect - Create a special effect attached to the weapon of Marksman 0310 <gen> using Abilities\Spells\Orc\Bloodlust\BloodlustTarget.mdl
        • Special Effect - Destroy (Last created special effect)
        • Special Effect - Create a special effect attached to the weapon of Marksman 0310 <gen> using Abilities\Spells\Human\MarkOfChaos\MarkOfChaosTarget.mdl
        • Special Effect - Destroy (Last created special effect)
        • Special Effect - Create a special effect attached to the overhead of (Target unit of ability being cast) using Abilities\Spells\Other\TalkToMe\TalkToMe.mdl
     
  17. VestriDeus

    VestriDeus

    Joined:
    May 31, 2009
    Messages:
    120
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Change the "Begins casting an ability" to "begins channeling" an ability; i think that should work.

    One of the annoying things about WE is that if two animations are cued, they will interrupt, so you have to add a wait action, and reset the animation (i just learned this lol)

    • finally....
      • Events
        • Unit - Marksman 0310 <gen> Begins Channeling an ability
      • Conditions
        • (Ability being cast) Equal to Snipe
      • Actions
        • Wait (0.01) seconds
        • Animation - Reset Marksman 0310 <gen>'s animation
        • Animation - Play Marksman <310>'s slam animation
        • --- all that other stuff...
     
  18. Scippi

    Scippi

    Joined:
    Dec 29, 2009
    Messages:
    68
    Resources:
    0
    Resources:
    0
    The animation is still not syncing with the ability

    • Snipe start
      • Events
        • Unit - Marksman 0310 <gen> Begins channeling an ability
      • Conditions
        • (Ability being cast) Equal to Snipe
      • Actions
        • Wait 0.01 seconds
        • Animation - Reset Marksman 0310 <gen>'s animation
        • Animation - Change Marksman 0310 <gen>'s animation speed to 40.00% of its original speed
        • Animation - Play Marksman 0310 <gen>'s slam animation
        • Animation - Change (Target unit of ability being cast)'s animation speed to 60.00% of its original speed
        • Special Effect - Create a special effect attached to the weapon of Marksman 0310 <gen> using Abilities\Spells\Orc\Bloodlust\BloodlustTarget.mdl
        • Special Effect - Destroy (Last created special effect)
        • Special Effect - Create a special effect attached to the weapon of Marksman 0310 <gen> using Abilities\Spells\Human\MarkOfChaos\MarkOfChaosTarget.mdl
        • Special Effect - Destroy (Last created special effect)
        • Special Effect - Create a special effect attached to the overhead of (Target unit of ability being cast) using Abilities\Spells\Other\TalkToMe\TalkToMe.mdl


    You want me to send you the actual map to look at it? You can test it for me if you want ;D
     
  19. Maximilianx

    Maximilianx

    Joined:
    Oct 14, 2008
    Messages:
    334
    Resources:
    0
    Resources:
    0
    You really shouldn't have to fiddle around with triggers, just manipulate the two fields in the object editor
    Cast Backswing
    Cast Point