How to create a horizontal scrolling level with some depth?

I’ve just started to learn Unreal Engine 4.26.2 and now I’m trying to understand landscapes.

While learning, I have thought about the levels of the games that I know and I’m not sure if these levels were made using one map, and if that is, how big the landscape was be.

I have an idea for a game and I don’t know who big a landscape could be (because in the Unreal documentation suggest the sizes with the best performance. My game will be a 3D horizontal scrolling game with some depth in the background but the character will move only in a 2D plane.

How can I do it?

Without using landscapes.

The world size is not “infinite” unless you use world origin rebasing.
When you do, then the world can pretty much be any size, and also generated procedurally.

For a game where the character has no access to the area of the background, its likely best to use a pre-rendered image background or a small portion made with meshes.

For instance, you could assemble any world you want, take a high-res screenshot in engine that spans whatever pixel width you wish, and use slices of the image as the background for the actual level.
You could even take several shots or assemble the graphics from footage of a panning camera render.

The point is, loading and handing landscapes is a mess to begin with. When there’s no actual need for it, do all you can to avoid it.
A 2.5d game is the perfect use case to use imagery instead of actual components, since with a bit of parallax you’d essentially never be able to tell.

Rayman Legends comes to mind as an example that does this with procedural/tiled backgrounds.

If you want seamless scrolling always, break the levels into logical chunks and stream them in / out.

Hi, have you ever managed to find a solution?

I know it has been a while, but I want to do the same thing, just with vertical scrolling. I know it’s really oldschool. What I want to do is I want the level to automatically scroll up with a fixed camera and the player (heli) should be free to move around in the viewport. This is what I already did:

Created a separate blueprint to represent the bounding box. This actor encapsulates the player character and defines the boundaries of their movement and added 4 box collision components, aka a wall in every direction.

I have no idea how to achieve it, maybe a script or blueprint logic to the bounding box actor to handle the movement and upwards scrolling behavior? But what about the camera?

I know it is a lot to ask but I hope someone can help.