How to make Acid Bomb play "Attack - 2" animation?

MintJulep

New Member
Reaction score
4
I've been having a really hard time with this. Here's some stuff that hasn't worked:

1. Putting "attack 2", "attack,2", "attack - 2", etc. in Art - Animation Names. Apparently the object editor can't use a specific of a random animation like "attack".

2. Trigger, where Unit Starts the Effect of an ability, Animation - Play (triggering unit)'s attack,2 animation. Every animation was cancelled out by the animation of Acid Bomb.

3. Doing #2, but leaving the Art - Animation Names blank in Acid Bomb. Just defaulted to the unit's spell animation.

4. Modifying #2 with Finishes Casting an Ability, Starts Casting an Ability, and Reset Unit Animation.

5. Modifying #2 with Play unit animation (specify rarity), using attack and "only Rare animations".


Summary: It seems you can't set Attack - 2 in the object editor, and whatever you do with triggers is canceled out by what's in the object editor, even if the object editor's field is blank.

:mad:
 

saw792

Is known to say things. That is all.
Reaction score
280
You have to order it through a jass function, SetUnitAnimationByIndex(). The index for the attack 2 animation will be different for every model, so you will have to try every possible index (integer) until you have found the correct one.

Code:
Events - A unit starts the effect of an ability
Conditions - Ability being cast equal to ...
Actions - Custom Script: call SetUnitAnimationByIndex(GetTriggerUnit(), 0)

Change the 0 until you find the correct animation in game.
 

MintJulep

New Member
Reaction score
4
attack
2
?

or change the animation name with a model editor?

All animation FAQs I've read say that it's not possible to do an attack 2 through the object editor. I tried it and they seem to be right, it doesn't work. Changing the animation name won't change the attribute that prevents it from working (being a random animation instead of a specific one).


You have to order it through a jass function, SetUnitAnimationByIndex(). The index for the attack 2 animation will be different for every model, so you will have to try every possible index (integer) until you have found the correct one.

Code:
Events - A unit starts the effect of an ability
Conditions - Ability being cast equal to ...
Actions - Custom Script: call SetUnitAnimationByIndex(GetTriggerUnit(), 0)

Change the 0 until you find the correct animation in game.

I just tried this and it seems the effect is exactly the same as when I used "Play Unit Animation", ie. the animation is cancelled out by whatever animation is set for Acid Bomb. No difference for using "Finishes casting an ability".
 

Samael88

Evil always finds a way
Reaction score
181
Wich unit are we talking about? And wich animation? the name over the sidepanal animation window please:) Else we can be of no help to you:confused:

Edit: If you are talking about the chemist. The ogre carrying a goblin. Then his second attack is this: "attack, one, -1, NEW"
It has to be exactly those letters. If you type "Dissipate" he will play his dissipate animation when you cast the spell.

These are the names that shows up in the window I mentioned above. Every time there is a space you will need to make a new string in the object editor. Like the first attack animation is this: "attack, one, -, 2, NEW"
That and the fact that it is casesensitive is important to keep in mind:)
 

MintJulep

New Member
Reaction score
4
The unit is a custom model (it shouldn't affect anything for triggers, etc.), and the animation is Attack 2.
 

Samael88

Evil always finds a way
Reaction score
181
Check the spelling then, you said you tried these:
"attack 2", "attack,2", "attack - 2",

And now you say this:

Try it again, casesensitive and spaces:D

Edit: And btw, there is no random animation in warcraft 3, the game just picks them out from a list when attacking or anything else that has more than one animation.
 

MintJulep

New Member
Reaction score
4
Setting it as Attack 2 didn't work either. The unit just stands still, which I'm assuming is what it does if you enter some string it doesn't recognize. The animation:

animationxi5.png


By "random" animation, I'm talking about how certain animations are grouped together, and whenever the game orders an animation from that group it chooses a random one. For attack, it randomly chooses between "Attack 1" and "Attack 2" whenever you attack, or "Stand 1" or "Stand 2" whenever you're standing still. Tutorials I've read say you can't specify a random animation in the Object Editor, only a group like "Attack" or "Stand".
 

Samael88

Evil always finds a way
Reaction score
181
The animation for name for that one would be "Attack" "2" and that would be in two separate strings.
That model is based on the orc blademaster.

You do this in order:
1.Open the required animation names tab
2.Remove all strings
3. Press Add String, write "Attack" without the ""
4. Press Add String againm, Write "2" without the "" this time aswell.
5. Enjoy the unit playing the correct animation:thup:

Try it. It will work, if you follow the instructions correct:thup:
 

MintJulep

New Member
Reaction score
4
Sorry Sam, it's still not working. With those instructions, it still randomly chooses between the "Attack 1" and "Attack 2" animations, only doing "Attack 2" about a third of the time.
 

Samael88

Evil always finds a way
Reaction score
181
Ah, Now I see what you mean. I will try to see if I can fix it with the modelfile. I will try with the blademaster first, If I fix it you can send me the modelfile and I will fix it for you.

Of topic: Finally something that is a bit more difficult:D

Edit: I have managed to fix it with the blademaster by renaming the animation.
The result was this:
Pros: Worked as supposed:D
Cons: When attacking normal he only has one attack animation:(
Shall I PM you my email or will you attack the model here?
 

MintJulep

New Member
Reaction score
4
Eh, making this one spell look right probably isn't worth the loss of the alternate attack animation. The model though, is Kelen1, found here.

I can't believe that WorldEdit makes such simple tasks so difficult, or impossible. I mean, we have the animation, why can't we just play it...:(
 

Samael88

Evil always finds a way
Reaction score
181
I think it has with the string to do.
The first attack is this: "Attack"
The second is this: "Attack, 2"
I think the function cannot really handle numbers. Or it is a built in function. It could perhaps be possible to add another copy of that animation and rename it just for the abilities sake, but I don't think it would be worth it either tho due to the import size:thdown:
 

neckface

terrain contest winner! :) dance contest loser. :(
Reaction score
34
Art - Animation Names

Add String, and type: attack
Add a 2nd string, and type: second

It should then read attack,second
case closed! ;)
 

MintJulep

New Member
Reaction score
4
Art - Animation Names

Add String, and type: attack
Add a 2nd string, and type: second

It should then read attack,second
case closed! ;)

This hasn't worked, because for the default animations, the object editor just ignores the 2nd string and randomly chooses between the 1st and 2nd attacks.


Edit the animation name with a Model Editor (attack two if you want like Alchemist).

Unfortunately, Samuel tested this earlier in this topic and says that changing the attack 2 to a specific animation detectable in the object editor has the drawback of removing that animation from the character's regular attacks.
 

MintJulep

New Member
Reaction score
4
I figured out a workable solution guys, and I'll post it here for future reference in case anyone else has this problem:

1. Set the hero's "Cast Backswing" and "Cast Point" all the way down, to below .15 seconds.

2. Trigger:
Code:
Events:
A unit finishes casting an ability.

Conditions:
Ability being cast equal to Acid Bomb.

Actions:
Unit - Order (Hero) to stop
Unit - Pause (Hero)
Custom Script: call SetUnitByAnimationIndex(udg_Hero,animation#)
Wait x seconds.
Unit - Unpause (Hero).

Possibly it'll work without the wait. Basically, setting the cast backswing really low will allow the object editor animation to be interrupted by the animation you set in the trigger (before, the animation was uninterruptable even by triggers). Lowering the cast backswing basically lowers the "uninterruptable animation" time to an unnoticable level. The stop and pause are to prevent the hero from interrupting his own triggered animation with an aggro-ed attack.

Thanks for the help, everyone.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top