Thanks for the reply, the above did not work. I deleted the project with the issue, but was able to recreate it again as I’ve done it a few times whilst trying to solve it myself.
I thought I give a more step by step of what I did to make it easier to replicate the issue.
-
Made new project, First Person → Blueprint → Create
-
Created a new game mode: Tools → New C++ class → Game Mode Base → Create Class
-
I get two pop ups, first one stating that the project includes sources and to close the editor and build from the IDE. The second one is the class has been made successfully but you need to recompile and asks if you want to edit the code now. I press yes, after couple of tests with no, this issue remains the same.
-
I close the editor and build from the VS.
-
Launch Editor → C++ Classes → (Project Name) → Right click the game mode → Create blueprint class based on gamemode → Rename BP_MyGameModeBase → selected destination to be in: First Person → BluePrints → Create My Game Mode bas…
-
Ctrl + Shift + S to save all
In the world settings, the BP will not appear in there, but you can drag or “Use Selected Asset from Content Browser” and the BP will be there.
NOTE: When trying to change the “GameMode Override” in the world setting, you will not find the BP in the list however you can drag the BP into it, but when you relaunch, I was presented with error messages:
CreateExport: Failed to load Outer for resource ‘DefaultSceneRoot_GEN_VARIABLE’: BlueprintGeneratedClass /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C
CreateExport: Failed to load Outer for resource ‘SimpleConstructionScript_0’: BlueprintGeneratedClass /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C
CreateExport: Failed to load Outer for resource ‘SCS_Node_0’: SimpleConstructionScript /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C:SimpleConstructionScript_0
- Reopen the Editor and hover over the BP:
Note: I have also close the editor and built, the issue is still the same. Another thing to keep in mind, when re-launching the editor and hovering over the BP, you will see the parent class filled, after some time it will go or if you try to open it, you will get prompted this error message:
“Blueprint could not be loaded because it derives from an invalid class…”
- Close both VS and Editor and tried your steps.
TLDR:
Created a new gamemode on a fresh project (First Person), issue remains still.
I’m able to create a BP from the C++ class and add it to the gamemode override by dragging or using the arrow.
Upon relaunching editor, I’m presented with errors:
CreateExport: Failed to load Outer for resource ‘DefaultSceneRoot_GEN_VARIABLE’: BlueprintGeneratedClass /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C
CreateExport: Failed to load Outer for resource ‘SimpleConstructionScript_0’: BlueprintGeneratedClass /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C
CreateExport: Failed to load Outer for resource ‘SCS_Node_0’: SimpleConstructionScript /Game/FirstPerson/Blueprints/BP_MyGameModeBasetest.BP_MyGameModeBasetest_C:SimpleConstructionScript_0
and when opening the BP, I get this message:
Blueprint could not be loaded because it derives from an invalid class…
and the game mode override (world setting) is set to none.
This could be an issue with my machine and possibly need to reinstall both VS and UE5 just to be on the safe side, however, I’ve replicated these steps on third person, and it works perfectly fine.
I hope this explains my issue.
Thanks.
Note: I had multiple screenshots, but I can only put in one currently.