Playing walk animation while sliding a unit

yunusowic

New Member
Reaction score
7
Ok. I've looked to thousands of topics but couldnt find anything really useful. My problem : I want to play a units walk animation while its sliding.

Trigger:
  • Unit - Move Unit[(Integer A)] instantly to (Point[(Integer A)] offset by 15.00 towards Angle[(Integer A)] degrees)


I'm using this action to move the unit. I know that it cancels the walk animation and I know that moving the unit using 'Point with offset' action doesnt cancel it. But I can't figure out how Point with offset is used.

I also used this

Trigger:
  • Custom script: call SetUnitAnimationByIndex( udg_Unit[GetForLoopIndexA()], 1)


But didnt work at all. So if its possible to play walk animation with 'Point with offset' move, I want to know how I can do it.
 

Romek

Super Moderator
Reaction score
964
"Move Unit" becomes SetUnitPosition in Jass.
SetUnitPosition interrupts orders and animation.

Use SetUnitX/Y instead.

Trigger:
  • Actions:
    • Set SomeLoc = (The Location you want the unit to move to)
    • Set SomeUnit = (The unit you want to move)
    • Custom Script: call SetUnitX(udg_SomeUnit, GetLocationX(udg_SomeLoc))
    • Custom Script: call SetUnitY(udg_SomeUnit, GetLocationY(udg_SomeLoc))


SomeLoc is a location (Point) variable.
SomeUnit is a unit variable.
 

Dirac

22710180
Reaction score
147
awesome, i've been looking for this too! [del]However it's not working[/del] :(
Trigger:
  • Custom script: call SetUnitX(udg_MUITarget[udg_TempInteger]), GetLocationX(udg_TempPoint))

Why? all variables are correct

SOLVED IT:
Use Custom script: call SetUnitX((udg_MUITarget[udg_TempInteger]), GetLocationX(udg_TempPoint))
 

yunusowic

New Member
Reaction score
7
thank you Romek. It works perfectly but it seems my custom model has a problem with its walk animation :(
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top