Arnn Powell Devlog - Character Select Implementation


PROBLEM:

Today I setup the character select screen. Since this is a temporary setup getting the correct mesh to load into the level it took a little while longer to accomplish. The first plan was to change the Default Pawn of the GameMode on the levels BeginPlay. After trying this many different ways it was obvious it was not going to work. I tried using the ChangeDefaultPawnClass in blueprints in Level BeginPlay and outside of it, creating a function to set it in the level blueprint, but neither worked.   The selection process also needs to be data driven instead of the way it is working now.

SOLUTION:

To change the mesh and make the process data driven I created a c++ data asset class that will hold all the CharacterData. Mesh, Name, Icon, Level, Stats, Animations, can all be set in this class and used anywhere it is needed. With this CharacterData, I was able to create a GameInstance and save the mesh in the character select menu, then load the mesh on level BeginPlay. The game instance allowed the mesh to be saved across level transitions. 

Get CrumBrawler

Leave a comment

Log in with itch.io to leave a comment.