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

Disable Animations

Status
Not open for further replies.
Level 3
Joined
Nov 18, 2015
Messages
41
I want to disable the alternate stand animations for a few select units.
(i.e. Stand - 2, Stand - 4, etc.; the ones that auto-play when a unit is idle)

The purpose of this is to remove the idle animations from a captain and his swordsman, as I have some special effects and animations on a timer to essentially emulate a training camp.
I just need them to stand there in-between swings.

Any thoughts or ideas would be appreciated.
 
Level 11
Joined
May 16, 2016
Messages
730
I want to disable the alternate stand animations for a few select units.
(i.e. Stand - 2, Stand - 4, etc.; the ones that auto-play when a unit is idle)

The purpose of this is to remove the idle animations from a captain and his swordsman, as I have some special effects and animations on a timer to essentially emulate a training camp.
I just need them to stand there in-between swings.

Any thoughts or ideas would be appreciated.
Do you want to make the captain to do periodical animation instead of standing?
If yes, then what animation do you want to do?
 
Level 3
Joined
Nov 18, 2015
Messages
41
Do you want to make the captain to do periodical animation instead of standing?
If yes, then what animation do you want to do?
I want to disable the alternate stand animations for a few select units.
(i.e. Stand - 2, Stand - 4, etc.; the ones that auto-play when a unit is idle)

All I want is for the guy to stand there in his basic stand animation with zero alterations.
 
Level 3
Joined
Nov 18, 2015
Messages
41
There is:
You can change timer of looping or/and animation index.
In that map you have a lot of useless junk in your triggers, and all you're doing is resetting the unit's animation every second.
This will also blatantly interrupt any custom animations I have triggered that last longer than 1 second (pretty much all animations are over a second long)
 
Level 11
Joined
May 16, 2016
Messages
730
In that map you have a lot of useless junk in your triggers, and all you're doing is resetting the unit's animation every second.
This will also blatantly interrupt any custom animations I have triggered that last longer than 1 second (pretty much all animations are over a second long)
You asked the captain to do stand-1 anmation, then there is my variant. :D
EDIT: You can save real, wait 1 sec., then save 0 (trigger wouldn't do animation if you save 0), then do your animation, then again save real, wait 1 sec etc etc
 
Level 3
Joined
Nov 18, 2015
Messages
41
You asked the captain to do stand-1 anmation, then there is my variant. :D
EDIT: You can save real, wait 1 sec., then save 0 (trigger wouldn't do animation if you save 0), then do your animation, then again save real, wait 1 sec etc etc
All that would do is wait 1 second after a unit started the animation? Animations have uneven, unfriendly timers, which is probably why Blizzard added the option to "Queue" animations, however unless there would be an easy way to detect when an animation is done, then there wouldn't be a way to tell whether or not the captain is doing his animations or if he's there idle.

All of this is a poor workaround regardless, whenever a unit is in the stand animation it will cycle through it's other extra stand animations. Worst case scenario I need to edit the models and remove the extra idle animations, however I would really prefer to not have to do that.
 
Level 11
Joined
May 16, 2016
Messages
730
Worst case scenario I need to edit the models and remove the extra idle animations, however I would really prefer to not have to do that.
Yeah, no way.
however unless there would be an easy way to detect when an animation
If you want detect, then change periodic event from 1 sec to 0.01, and find action "Set real = real + 1" and change it by "Set real=real + 0.01"
Then determine animation time (Stand-1 takes 1.5 sec.) and go to ORDER trigger
Change "Set real = <Animation Time you want>". Done
 
Level 3
Joined
Nov 18, 2015
Messages
41
If you want detect, then change periodic event from 1 sec to 0.01, and find action "Set real = real + 1" and change it by "Set real=real + 0.01"
Then determine animation time (Stand-1 takes 1.5 sec.) and go to ORDER trigger
Change "Set real = <Animation Time you want>". Done

That doesn't detect when the animation is over, it simply sets it to run after a set time equal to the animation, which doesn't help when animations are already queued from outside events.
 
Level 13
Joined
May 10, 2009
Messages
868
If your units won't move at all, you could simply use the function
JASS:
call SetUnitAnimationByIndex(Captain, 0)
and insert the correct animation value.

Now, if your units move all the time, and you don't want to use that function. Then, edit the model with Magos' Model Editor and just rename such animations.

Open your model with the Warcraft 3 Model Editor.
Go to:
1) Windows
2) Sequence Manager

Right click an animation that you don't want to see when the unit is idle -> Click Edit -> Rename it to: stand alternate
Do the same for other animations, but just modify a little bit the name of the animation, by adding, for example, "- 2" after the "stand alternate"

The good thing is that you still have the animations with your units, and they will be displayed if you add alternate tag to the units.

NOTE: Of course, I've used the term "alternate" as an example, you could give any other name if you're already using the "alternate" tag.
 
Last edited:
Level 3
Joined
Nov 18, 2015
Messages
41
If your units won't move at all, you could simply use the function
JASS:
call SetUnitAnimationByIndex(Captain, 0)
and insert the correct animation value.

Now, if your units move all the time, and you don't want to use that function. Then, edit the model with Magos' Model Editor and just rename such animations.

Open your model with the Warcraft 3 Model Editor.
Go to:
1) Windows
2) Sequence Manager

Right click an animation that you don't want to see when the unit is idle -> Click Edit -> Rename it to: stand alternate
Do the same for other animations, but just modify a little bit the name of the animation, by adding, for example, "- 2" after the "stand alternate"

The good thing is that you still have the animations with your units, and they will be displayed if you add alternate tag to the units.

NOTE: Of course, I've used the term "alternate" as an example, you could give any other name if you're already using the "alternate" tag.

Thank ya kindly!
 
Status
Not open for further replies.
Top