Forum rules - please read before posting.

Player Sprite Randomly Disappears

I was going through a few cutscenes and fixing some mistakes I had made. When I tried loading the scene, the player wasn't there, and I couldn't move it. I took a while trying to find what was wrong when I saw that the player sprite in the player's prefab was gone. The object of the sprite was still in the prefab, but you couldn't see it. I didn't interact with the prefab at all, and it had been working fine earlier today. I have player switching enabled and was changing some player switch nodes in some cutscenes before I noticed what happened, but I don't see how that could have affected it. I later tried to load other scenes with this player, and the player could move around, but it was still invisible. Any ideas?

Comments

  • What are your AC and Unity versions?

    From your screenshot, it looks like the prefab itself has its Sprite Renderer component disabled. Make sure it's enabled, and then check to see if/when it somehow becomes disabled again.

    The only times AC should disable a Sprite Renderer itself is if you're using the Object: Visibility Action, a Limit Visibility component, or a Sprite Fader component. Are any of these a possibility? Otherwise, check that it's not animation related - i.e. your Animator doesn't control the enabled state of the Sprite Renderer.

  • I can't believe I didn't notice that the sprite renderer was disabled. I don't think I used an Object: Visibility action on the player at any time in the cutscene, but maybe it was just some weird one-time thing. Thank you so much.

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.