Y
Y
Yugg02020-12-09 18:55:28
Unity
Yugg0, 2020-12-09 18:55:28

What are the ways to add a rotation constraint to Unity3D?

After searching the entire Internet, reading the Unity manual, I was not able to make an object rotation constraint.

It is necessary that the player can turn as much as possible to the right by 90 degrees and also to the left by 90 degrees.

How can you limit rotation?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
freeExec, 2020-12-09
@YugGO

поворот = Mathf.Max(-90, Mathf.Min(90, поворот))

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question