Forum rules - please read before posting.

Player don't stop in walking animation 2D

Hello! Sorry for put this question, but i can't find a solution to this.
I have a 2D game  with a single player character.
The problem is that the player's walk_L or walk_R animations keeps continuous playing after reaching destination no matter what.
I have also two iddle animations but they don't do anything.

Must be an error from my part but I can't solve it. Any ideas?
tnx guys!

Comments

  • I've been having this same issue. The player starts in idle, but as soon as he walks he then won't transition out of the walk animation. Meaning, he continues to walk in place. However, it seems like as soon as I interact with something that plays a new animation (like picking up an object) or causes dialog (even with "don't animate" checked) that the player animations resume acting normal. By normal I mean he walks while moving, idles while stationary, etc. 

    I've gone over the manual and video tutorials multiple times, can't seem to figure this one out. 
  • Thank you for your answer WhiteredCrow, i'll check if the situation changes after picking an object...and trying to figure out what's going on... 
  • Check your Console to see if it's trying to play animations that it cannot find.  If you're using the standard Sprites Unity animation engine, you'll need to supply 4 or 8 directions for idle and walk animations - so even if you're only working with Left and Right animations, you'll still need to supply Up and Down ones as well (these could even be duplicated from your L/R clips if need be).

    If you want to work solely in Left/Right, consider switching to the Sprites Unity Complex animation engine, which gives you far greater control over how your 2D characters are animated, by letting you control animations using Mecanim parameters.  This is covered in Section 3.9 of the Manual.
  • Ahhh OK Chris! That must be the reason, i'm not using 8 directions...I'd like to let you know that i bought AC looong time ago (almost when it started), but i never have the the time to develop my game. It's amazing how much improve did you make during this time, and most important, you're still doing a fan-tas-tic job!! AC shines where others engines don't (specially for the documentation and features) kudos man!
  • edited February 2016
    I'm not getting any errors in the console and I do have the multiple directions (as duplicates of my L anims) however, I did notice a warning in the Animator component that says "Not initialized" when viewing the prefab in the project folder. When viewing it in the Hierarchy that same notice reads differently. Here are some screen caps of the parent (Sal) and child object (salSprite) of my player prefab, along with the Animator (playerAnimations) and the alternate notice within the Hierarchy. Any help is greatly appreciated!

    image
    image
    image
  • What versions of Unity and AC are you working with?  Do any relevant messages appear in the Console during gameplay?
  • I have the basic version of Unity, version is 5.3.2f1 (64-bit) and AC 1.48b, though I've been having this issue for a few months now.  

    This is the only thing that appears in the console during gameplay: 

    PlayerPrefs Key 'AC_Sally_Face_Game_0' loaded
    UnityEngine.Debug:Log(Object)
    AC.Options:LoadPrefsFromID(Int32, Boolean, Boolean) (at Assets/AdventureCreator/Scripts/Options/Options.cs:179)
    AC.Options:LoadPrefs() (at Assets/AdventureCreator/Scripts/Options/Options.cs:134)
    AC.Options:Start() (at Assets/AdventureCreator/Scripts/Options/Options.cs:35)
  • I just updated to AC version 1.50i to see if that would fix anything, no luck. 
  • Anything different in the Console after updating?
  • Slightly different: 

    PlayerPrefs Key 'AC_Sally_Face_Game_0' loaded

    -----------------------------
    UnityEngine.Debug:Log(Object)
    AC.ACDebug:Log(Object) (at Assets/AdventureCreator/Scripts/Static/ACDebug.cs:17)
    AC.Options:LoadPrefsFromID(Int32, Boolean, Boolean) (at Assets/AdventureCreator/Scripts/Options/Options.cs:166)
    AC.Options:LoadPrefs() (at Assets/AdventureCreator/Scripts/Options/Options.cs:124)
    AC.Options:OnStart() (at Assets/AdventureCreator/Scripts/Options/Options.cs:35)
    AC.StateHandler:InitPersistentEngine() (at Assets/AdventureCreator/Scripts/Game engine/StateHandler.cs:76)
    AC.StateHandler:OnAwake() (at Assets/AdventureCreator/Scripts/Game engine/StateHandler.cs:65)
    AC.KickStarter:SetPersistentEngine() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:101)
    AC.KickStarter:AssignLocalPlayer() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:1074)
    AC.KickStarter:OnAwake() (at Assets/AdventureCreator/Scripts/Game engine/KickStarter.cs:838)
    AC.MultiSceneChecker:Awake() (at Assets/AdventureCreator/Scripts/Game engine/MultiSceneChecker.cs:27)

  • Hello guys. Chris you were right, i put the complete set of animations for the player (8 for walk and 8 for idle) and now everything works just fine. Thank you for your help!
  • Dont you need more idle animations?

    I know you got it set to flipped, but wont you still need an idel_UL and idle_DL ?
  • edited February 2016
    @patoland: 8 directions are only necessary if you have Diagonal sprites? checked - if you only need 4 directions, you can uncheck that box.

    @witheredCrow: Can't see what's wrong it.  Package up your player prefab, plus the animations + graphics, and PM it to me in private.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.