How do I write the glue between my levels ?

Hello,

I’m a beginner to Unreal Engine 4 and I understood how to make levels and all the logic of its components. But I can’t find any information on how to make the game itself ? Where am I supposed to write (or blueprint, but I prefer C++) what we can see when we launch the standalone game ? From now, when we launch it we are throwed into a map without anything else.

I couldn’t find anywhere where is the game lifecycle. I mean, on games like Borderlands 2 there are intro movies, a splash screen, a main screen… The game has a lifecycle, it’s not just maps put ones after anothers.

So here is my question : where do I write all the glue between my levels ? Should I do it by creating new levels and then adding a “main menu” or “intro screen” component into them to make them act as if they were actually a menu ?

Thanks for your help !

The answer is Yes, to everything.

There are about 4 levels of understanding how UE4 works (depending on how you look at them) and actually come in no particular order. A great part of UE4 can be manipulated just using config files and not touching the code at all. You can change the splash screen and starting screen (level) using the config files. Generally you use a scene to build your main menu with a HUD. The only method for loading a level that I have found is to call from code the console command to load a level; To exit or close the game is done the same you call from code the console command “quit”. You can change the default splash screen and I think even the intro movie from the config files. To add more you would do as you described, create a new scene and play that movie or intro in it and move to the next one when completed. Your “main menu” would be it’s own screen or you could even probably put it all in one intro scene.

The second level consists of working with the editor itself and building the game and levels using the editor.

The third level consists of understanding blueprints (can probably be lumped in to level 2). Technically EVERYTHING can be built in blueprints and blueprints are actually VERY fast even when compared to C++ code (amazingly enough). They are visual based however and some times (to me) can get over cluttered and confusing… I guess code can to but I’m used to it. There is also a size limitation to blueprints.

And the fourth level consists of understanding the C++ as well as when to use C++ vs Blueprints. I know you prefer C++ but like I said everything you can do in C++ you can also do in Blueprints. I am a C++ programmer by trade and my philosophy is to use C++ to create the base objects of my game while I use Blueprints to build the specialized objects from the base objects. An example of this is a base Object called “ItemActor” is built in C++ but the concrete item of “Health Pickup” would be in Blueprints.

Thanks a lot :slight_smile: