A
A
Alex Blinov2019-06-13 11:17:55
Game development
Alex Blinov, 2019-06-13 11:17:55

how to do physics in unity 2d

How to make unity2d objects pushable? There is an object that we control, as well as another object that does not move, but just stands still. When we move to the side of this object and push it, we need it to move (a game with a 2d top view). Used various properties collider, rigidbody. Help!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Denis Gaydak, 2019-06-13
@CEPII

you would show what you tried...
and so, on the player who moves - Rigidbody (and the collider of course) with the Kinematic checkbox, most likely, although it depends on the game.
on the subject, too, Rigidbody and without any freezing positions and static (the same Kinematic),
both of them walk on the floor, some kind of hefty collider.
all. this is enough when the player tries to "enter" the object - the object will be pushed out. physics)
what exactly is wrong with you.
just put a square on the floor in the editor and push it with another square (by moving it in the editor with the arrows / dragging it into the Scene View, do you get it?))

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question