# Moving Character within a moving ship or similar

Hi. I’m a newbie and want to make a moving spaceship where my character can walk around inside this moving (!) ship. I searched alot with google but I didnt find a solution or even better a tutorial. There was a proposal to set one char (ship) as a base for the player but this seems to need programming and I only use blueprints.

I’m willing to learn it but give me some hints where to search and which direction. This should be a common problem as I thing that every piloted ship or plane has this theme. Typically a ship on the water is the same.

The “trick” that he world is moving around the ship is not working for my idea

Thanks for helping a newbie

Welcome to unreal.

You trying to do quite ambitious thing. Let me explain.

For now all you want to do is move YOUR character inside moving object (Actor). Next you want shoot something, then you want moving enemy and finally that enemy to have AI script. Problem is that shooting and bot AI are made for static environment that do not move. You probably find some optimizations made in that code that assume level is static and not moving.

Then there are even more things that assume levels are not moving, like particle effects (you can set them to local space, but that makes some effects impossible/hard to do), and lights that can be static, dynamic or movable, cheapest and fastest are static (they are calculated in editor during level building), but since your spaceship is moving you cannot use static lights.

First thing you should realize is that you are making game, you need to FOOL player that your ship is moving, not make simulation of moving ship. Second is old truth that all movement is relative.

So it is much much easier to calculate position of all space bodies then make spaceship static and move everything around it. Ie. you calculate everything like spaceship was moving and sun is static, then just translate (substract spaceship location and rotation) everything to move relative to spaceship not star. This way you have some more vector math, but you avoid problems with lighting, shooting, AI movement, physics, particles, and probably some more things.

‘Dont-be-evil’ corp won’t help you learn game dev, not ever, not really.
This is a complex area tbh, more so for multiplayer if that’s the goal.
Instead search for posts by TheJamsh to get some hints / solutions.

Thanks for this very good and explaining answer - I understood and try to adapt.

I want to add one thing. If you plan on doing multiplayer, my solution with fooling people what is really moving will not work (when 2 players meet in 2 ships which one is moving?).
For multiplayer you need do everything the hard way. Or make inside ship as small separate (and not moving level), then transition from outside to inside.

Just make fun game, not simulation of how things really work.