| 01-09-2006, 02:40 AM | #1 | ||
I have a little question. *First of all I have two triggers to make things clear *I hid them in order to not confuse poeple, hope that does not bother you
What happens is that I order all units (in this case knights) from a unitgroup to slide over the landscape, but the slide off course looks unnatural so I added a walk animation to the horses, but the thing is, it is just not being animated. (side note: I made this cause the normal knight movement, gets messup up and they don't run in a clear line) (side note: With other animations it is possible, seems like only the walk animation is bugging.) So is there anything advisable or is there something that I am missing or doing wrong. |
| 01-09-2006, 02:43 AM | #2 |
Use the trigger tags for triggers. |
| 01-09-2006, 02:45 AM | #3 |
You mean unit animation tags ?? else can you explain what trigger tags are.... |
| 01-09-2006, 02:50 AM | #4 |
Instead of wrapping your GUI triggers in [ hidden ], wrap them in [ trigger ] tags. Makes them look VERY pretty. I wuv it. Anyway, I could be wrong, but I think moving a unit with the GUI line "Unit - Move Unit" interrupts animations. What you need to be using is the JASS lines SetUnitX and SetUnitY. Regardless of this thing, JASS is a handy thing to know, and is worth learning if you don't know it already. Only takes a couple hours to learn too, thanks to all the awesome tutorials that are floating around the internet. |
| 01-09-2006, 02:55 AM | #5 |
well I found it already in GUI, but thank for the replies. as simple trigger like this was needed Trigger2 Events Time - Every 0.01 seconds of game time Conditions HorsesWalk Equal to True Actions Unit Group - Pick every unit in HorseArmy1 and do (Actions) Loop - Actions Animation - Play (Picked unit)'s Walk animation |
| 01-09-2006, 03:09 AM | #6 |
If you're going to be running that every .01 seconds, (which you could probably increase to .03 or more, since almost nobody is running wc3 at 100 frames/second) I suggest you get rid of the unit group leak. Trigger2 Trigger: ![]() Events
![]() Time - Every 0.01 seconds of game time
![]() Conditions
![]() HorsesWalk Equal to True
![]() Actions
![]() Set MyUnitGroupVariable = (Every unit in HorseArmy1)
![]() Unit Group - Pick every unit in (MyUnitGroupVariable) and do (Actions)
![]() Loop - Actions
![]() Animation - Play (Picked unit)'s Walk animation
![]() Custom Script: call RemoveGroup( udg_MyUnitGroupVariable)
![]() Custom Script: set udg_MyUnitGroupVariable = nullShould fix it, but I'm not all that great at memory leaks myself, so that might not cover all leaks/handle the leak correctly. |
| 01-09-2006, 03:24 AM | #7 |
don't get the point here, I removed the loop if that is what you are refering at |
| 01-09-2006, 10:53 AM | #8 |
There is no leak Pharaoh, it's a group variable. |
