Hi, thanks for the great plugin!
I’ve started to integrate it into my project and faced some issues with order of loading game modules. Hope your insight will help 
In general, I have 2 game modules (the 1st is something like core library and the 2nd is game itself) and GCFSM plugin enabled.
In core module I define parent class for blueprints containing state machine, smth like UStateMachine. In game module I create blueprint (let’s say BP_StateMachine) derived from the UStateMachine and define state machine inside.
Issue 1: to make sure that BP_StateMachine asset is loaded correctly we need to load modules in order GCFSM (PreDefault) -> Core (Default) -> Game (PostDefault) otherwise all FSM nodes disappear from BP_StateMachine. So this issue is solved by setting loading phases as mentioned.
Then in core module I define state class (let’s say UState) with exposed member variable TSubclassOf<UExample> ExampleClass (so it will appear as pin in FSM state node in BP_StateMachine). This UExample class is also defined in core module.
Issue 2: There’s “ensure” crash during BP_StateMachine loading (BlueprintCompilationManager.cpp line 1312):
UBlueprint* BP = Cast<UBlueprint>(ForClass->ClassGeneratedBy);
if(ensure(BP)) ...
call from GCFSMStateNode.cpp (line 493):
// Add pins for state arguments
auto execPin = spawnNode->GetThenPin();
if (auto implementationClass = GetImplementationClass())
{
execPin = FKismetCompilerUtilities::GenerateAssignmentNodes(compilerContext, sourceGraph, spawnNode, this, spawnNode->GetReturnValuePin(), implementationClass);
}
As far as I understand the problem is that no CDO is presented (BlueprintCompilationManager.cpp line 1306) for UState class because core module is not loaded yet.
If I change loading order to Core -> GCFSM -> Game crash disappears but Issue 1 is here again.
For now the only solution I see is to merge core and game modules, but I would prefer not to do that as I’d like to reuse core module in several projects.
Thanks in advance!








