Answer the question
In order to leave comments, you need to log in
Does a platformer player fly instead of falling?
private void FixedUpdate()
{
posPlayer = new Vector2(playerObject.transform.position.x, transform.position.y);
Vector2 posObj = new Vector2(transform.position.x, transform.position.y);
Vector2 newPosition = Vector2.MoveTowards(posObj, posPlayer, Time.deltaTime * speed);
if (isPlayerEntered)
rigidbody2D.MovePosition(newPosition);
}
isPlayerEntered == false
true
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question