2 2D Physics Rooms/Worlds

Hi,
i want to make a Top-Down Space Game with a Player in a Spaceship. The Player can walk in the ship and for example controll it by using a monitoring desk.
So i want 1 physics Room/world for the inner Ship and 1 physics Room/world for the universe so that the Players or the Enemys IN the ship have nothing to do with the Ships movements.

Is that possible?

Yes, by using layers, you can change effectively create two or more separate physics areas.

You would have layers for the “ship space”.

And separate layers for the “universe space”.

Then, in the physics options, you would set which layers interact.

The only thing that you can’t separate is gravity. I’m assuming you won’t have any gravity while on the ship, so you can set the local gravity for rigidbodies in “ship space” to 0. Then, setting the gravity will effect only things in “Universe Space”.

The problem is that the ship has a BoxCollider2D with Rigidbody2D and the player too, now if the ship moves the player collider stays where it has started… does anyone know why or a work around?

PS: the player and ship are on different uncolliding layers.