V
V
Vorokan2021-06-15 16:49:57
Unity
Vorokan, 2021-06-15 16:49:57

How to change the sprite of an object when it is rotated?

void Flip()
{
facingRight = !facingRight;
Vector3 Scaler = transform.localScale;
Scaler.x *= -1;
transform.localScale = Scaler;
What to add to change the sprite or animation? I tried to do it myself, but nothing really happened.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question