HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

SetUnitAnimationByIndex: Wierd problem...

12-30-2006, 12:19 PM#1
zeroXD
I'm making a spell for a map, but somehow the animation just dont want to work.

I'm using
Collapse JASS:
    call SetUnitAnimationByIndex( caster, 2 )
on the raider model, which is supposed to be the "walk" animation.
But all it does, is just repeating the "spell" animation.

Some explenation why this is happening?
BTW I am pausing the caster.
12-30-2006, 12:47 PM#2
Vexorian
Why do you think animation 2 is the walk animation?

And animation indexes begin with 0, so the first animation is 0, the second is 1, and so and so
12-30-2006, 01:45 PM#3
zeroXD
Yes, I know.
0: Stand
1: Stand - 2
2: Walk
... And so on.
"Spell" is n. 8.
12-30-2006, 01:50 PM#4
iNfraNe
perhaps some other trigger/spell is telling him to use the spell animation. Try using a 0.00 timer or changing the animation on the spell.
12-30-2006, 01:50 PM#5
Vexorian
Just tested, unit was paused, playing animation 2 does play walk.

So there must be something else involved there
12-30-2006, 01:55 PM#6
zeroXD
I dont have anything else using that unit.
Only that spell. Its a test map.
For some reason he just DONT want to do as I tell him...
Is it possible he could keep repeating the animation whenever he casts the spell, and I pause him? (spell animation)
12-30-2006, 03:44 PM#7
iNfraNe
You sometimes cant make the unit play its animation when casting a spell (at least, so I've noticed in my maps, I didnt do much testing to what is exactly causing it)

you can fix it by having a 0.00 timer.
12-30-2006, 06:27 PM#8
zeroXD
Yup, it does work. Thanks.