Who is responsible for creating ACtorller class object

Hello everyone,I hava a trouble about the frame of gameplay programing.These days I want to find out the frame about UE4’s gameplay programing.I have seen the official’s documentation about this,but it’s too simple.
Now ,I know there are some core class about this frame, they are AGameMode,AGameState,ACtroller,APlayerState,Apawn. I also make a uml model for these classes, but I still have a question. Who is the first to be created when the game play?
and who is resposible for createing ACtorller class object?
I very much hope someone can tell me the creating order about these core class object . thanks!

Hello, qscool

Please note that GameMode is the base of the game framework. It sets the rules for the game and handles player spawning (for example, the way PlayerStart is chosen). The best illustration of GameMode and GameState classes interaction can be found in multiplayer games. GameMode instance only exists on the server. Login logic is handled here. On the other hand, GameState acts as a representation of world and gameplay elements to the clients.

PlayerController represents human players joining the game. It allows players to possess pawns in the game so they can have physical representations in the level.

PlayerState is a replicated extension of PlayerController. It is used to store player information like score, kills, deaths, character type etc.

A good example of GameState and PlayerState classes implementation can be found in Shooter Game project, which can be downloaded from the Launcher (Example Game Projects section in Learn tab).

In general, you can see gameplay class relationships on the following graph:

Please also not that you can set default Pawn and PlayerController class in the constructor of your GameMode class like this:

DefaultPawnClass = ACustomCharacter::StaticClass(); 
PlayerControllerClass = ACustomPlayerController::StaticClass();

If you like to learn more about Gameplay Programming in Unreal Engine 4, please go here:

Hope this helped!

Have a great day!

Hello Andrew Melnick
Thank you for your help,these days I put much attention to the frame of gameplay programming,the following is a simple graph about it

This graph is maked from the source code from ue4,because I want to find out the relationship about gamemode,gamestate pawn,controller ,playerstate etc.
Now,I konw the gamemode class has a few improtant attributes like DefaultPawnClass,GameStateClass,PlayerControllerClass,PlayerStateClass etc.These attributes designate the class type about object to be create in the game. So,I also know the interaction about this class from the graph.
From the graph,I know the UWord class is responsible for managing controller,level,pawn,gamemode,gamestate objects,and ULevel class is responsible for managing all the actors within this level. But I still don’t know clearly about the createing order. Which class object is created first,which is second,and third …
Before using ue4,I am a C++ programer,so,I have a little bigotry about the frame,I always want to understand the frame more clearly.