L
L
Loper472021-10-19 23:32:59
Unity
Loper47, 2021-10-19 23:32:59

When falling from gravity, the player falls "ladder". How to make a smooth fall?

There is a player who is constantly moving along X. It hangs on the player Rigidbody2Dwith standard settings (non-standard ones don't help either). When the player is in free fall, i.e. he falls and at the same time moves along X, he does this with a "ladder" (pixel to the right - pixel down). Also, when a player jumps (like a bird in Flappy Bird), he also does it with a ladder. Player movement is implemented through transform.Translate. The camera is stationary.

PS The game is very similar to Don't touch the spikes for Android.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
Loper47, 2021-10-20
@Loper47

The answer is banal :) It was necessary to useFixedUpdate()

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question