Forum rules - please read before posting.

Player alpha

Hi there! I wonder if it's possible to change the transparency or alpha for the player sprite (player character) i can't find how to make it semi transparent...
any help?
Thank you so much!!

Comments

  • edited March 2016
    You can write a custom Action that controls the transparency of the player sprite.  While this is really more of a Unity thing than AC, the code you'll want to place in the Run() function will be something like:

    AC.KickStarter.player.GetComponentInChildren <SpriteRenderer>().color = new Color (1f, 1f, 1f, 0.5f);

    Where 0.5f means half-transparent - so you can change this to suit.  Then just call this Action when appropriate.
  • Fantastic, it worked at the first try!! thank you once again Chris!!
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.