Change Animation When Actor Changes Direction
I've been looking at other posts and cannot find quite what im looking for. I know how to change the animation if say the actor was moving left or right with controls.
However, the game im currently working on has a joystick at the bottom corner which moves the actor.
I have animations for the character moving NE, E, SE (The only direction they will be moving in)
The question is, how would I be able to change the animation of the actor when it is moving NE to when its moving E and again for SE.
I've thought about maybe when the joystick goes to a certain angle the animation will change using say an integer.
Thanks for the Help
Developer For BLUNTentertainment - Feel Free To Message Me! - Free Beginner Templates!
Best Answer
-
Braydon_SFX Posts: 9,273
You could probably constrain the joystick angle to a game attribute. Then create a few rules that have a few conditions that may say something like this:
Rule:
When game.joystick angle is faster than 100, but less than 150
Animation.My GameSalad Academy Courses! ◦ Check out my quality templates! ◦ Add me on Skype: braydon_sfx
Answers
I'll give it a go. Thanks!
Developer For BLUNTentertainment - Feel Free To Message Me! - Free Beginner Templates!
Really can't figure this out, im kinda new so trying to work around constraining the angle, would it be easier to say if self.y increases x amount from actor spawn and if self.y decreases x ammount from actor spawn?
Developer For BLUNTentertainment - Feel Free To Message Me! - Free Beginner Templates!
I have the same problem, is there any solution yet ?
This might help.