Forum rules - please read before posting.

2nd player problems!

GOAL: Have player with new outfit appear in new scene in place of old one.

PROBLEM 1: Ignoring OnStart action to change prefab of player, I put new player prefab in scene. But new prefab appears and moves around screen, but does not animate in left and right or up and down in idle pose or walk animation. IS the non animation due to it being tagged with player?

Also, new player is not affected by sorting map. It also says 'Cannot switch player - already controlling the desired prefab.' in the Console.

PROBLEM 2: Using original Player prefab and using On Start to switch player to new prefab has no effect on scene start.

SOLUTIONS ATTEMPTED: Tried using OnStart to change player, has no effect. Tried starting scene with new player prefab, new player does not animate and is not affected by Sorting Map.

What am I doing wrong?

Screenshots below

Comments

  • You have your components on the wrong object.  The BoxCollider is unnecessary, and the FollowSortingMap / SpriteRenderer should be on the sprite child - not the root.  You can try using the new Character Wizard to place the correct components on the correct objects.

    If you never need to switch player mid-scene, then you can simply have the new Player prefab present in the scene before running the game, and AC will use that Player for the duration of the scene, and switch back to the default everywhere else.  You should disable Player switching in the Settings Manager in this case.

    Otherwise, enable Player switching and ensure both prefabs are listed in the Settings Manager.
  • Thanks for that. However, my new player prefab will just not animate even after making those changes, any reason you can think of why?
  • I used the new character wizard like you suggested and it now works! thanks
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.