In my scene the camera is viewing from top to bottom, and the player moves along the x and z axis, and the y axis is facing towards the cam(no depth). I need this setup for rigidbody collisions. For movement I use Physics.Raycast to get the mouse pos and move the player to it.
However in 2D, z axis has no depth, but my player moves along it. I am not making a platformer here. I guess I can make the plane facing the cam and make the player move along x and y instead, but when I apply rigidbody the player just falls right off, and I need rigidbody for the player to collide with obstacles.
to summarize:
- unless I can calculate collisions without rigidbody, I can’t use the 2D setup as the player falls along the y axis. I don’t want a platformer style. My cam is viewing from top to bottom.
- in 3D mode it (barely) works if I use 3D colliders and rigidbodies but I don’t want to because it’s a 2D game.
In the end I’d prefer not to use any 3D objects if that’s possible. I’d like to keep everything 2D and just use sprites for grounds and walls, etc.
How do I incorporate my system into 2D correctly? It may sound confusing but help is much appreciated.
Thanks