I have a custom weapon which on creation should call a function in the custom
game state to “register itself”, so the game state has it in a variable for quick
reference. After setting this up everything compiles fine. When starting a PIE
session, the editor crashes. From then on if anything attempts to touch any of
the assets involved, the editor crashes:
- Opening a map with the custom game state referenced.
- Opening the weapon class to edit.
- Opening any blueprint interface used in either of them.
Other things to note:
-
I’m on 4.1.1 because even a working version crashes 4.2 on startup (seems to be an unrelated problem).
-
Everything in the project is made with Blueprints.
-
What matters is making the call. The class it’s called from or the data passed seems to be irrelevant.
-
The log is useless:
LogCrashTracker:
LogWindows: === Critical error: ===
LogWindows: Fatal error!
LogExit: Executing StaticShutdownAfterError
EDIT: More clues:
- The GetGameState seems to return a valid object. The PlayerArray is 1 as expected but the GetElapsedTime is always 0 regardless when I query it.
- The GameState’s function can be called from the player controller and the game mode. Tried from several actor derived classes, crashed every time.
- I forgot to mention this because it’s been happening since forever: PIE (along with the editor) crashes every time after I edit and successfully compile the default pawn, controller or game mode. Nothing permanently broken, after restart I carry on where I left off. The log ends the same way as above.
EDIT 2: Even when the editor crashes (like opening a map which refers to any of the now radioactive assets or starting PIE) a standalone, uncooked game works. Unusually low frame rates but everything functions as expected.