Login screen?

Hello. I spent like 5 minutes on the topic name because its really hard to compress all i need into the topic name :slight_smile: But there is it. Rigth now when i press the “Play” button i start directly in my level, but I want to the game to start not at my map, but have some login screen first where u can put nickname, then maybe some selection screen and then player would enter the world, load map and set everything up. How can i do it on client side?

You can create an empty map in which you create a UMG blueprint that you put on the view port for UI of the main menu. As far as nickname since you would need data persistent across maps your best approach would likely be to use an instance of GameInstance to hold the name and other persistent data. 's guide is a good starting point to understanding Gameinstance.

Is it possible to do all in c++ ? So i have to make separate level and HUD which would have the input fields, and after user puts login and presses key load the map and ingame HUD, smth like that? By the way, where can i see the whole map load process and character creation? Right now the engine just sets things up for me at start, but i would like to have more “control” over that stuff

Take a look at this thread, think it’s what you want.

What exactly do you mean with “while map load process and character creation”?

I think a good start is AGameMode as many things are handled there: AGameMode | Unreal Engine Documentation
But I agree with you that it is pretty hard to find kind of a starting point there, it’s probably the best to look for specific things, at least that is what helped me much, to look for “What exactly do I want to do right now” and search for how to achieve that. Slowly and bit by bit, but as soon as you have a good understanding of how Unreal handles things it’s not that hard anymore.

So what i need is to create new game modes, like LoginScreen, Ingame, and start with blank map and simple HUD to put the login/password and then switch the gamemode to Ingame which would place me in the world, right?

Agentleo actually already described what you need to do, I think that you don’t know how all the classes in Unreal work together, therefore I’d suggest reading this Gameplay Framework | Unreal Engine Documentation. It gives a pretty good overview about how the most important classes (inculding GameMode) are tied to each other.

Basically you need to different maps, one map for the login screen and one for the gameplay. Each map has a different GameMode where, besides the basic rules, also the standard classes e.g. PlayerController and HUD can be set. One possible way to make the login screen would be to create a new PlayerController and let him handle the UI stuff (UMG, WidgetBlueprints) and set that PC as the standard PC in your login screen gamemode. When the player logs in you just transition to a different map where all the gameplay happens. There you have a different GameMode, different PC etc. If desired that GameMode can also handle custom spawning of Players.

Yes i agree - im pretty new to UE but i know c++ well. Using basic classes i can do a lot of fun stuff, but there are so many things that it takes a lot of time :slight_smile:

Im plannin to (dont laugh) make MMORPG :smiley: