// Fill out your copyright notice in the Description page of Project Settings. #include "DialogueGraphPanelNodeFactory.h" #include "Node//DialogueGraphNode_NPC.h" #include "Node/DialogueGraphNode_Player.h" #include "Node/DialogueGraphNode_Root.h" #include "Widget/DialogueGraphNode.h" #include "Widget/GraphNodeWidget_Root.h" TSharedPtr FDialogueGraphPanelNodeFactory::CreateNode(class UEdGraphNode* InNode) const { if (UDialogueGraphNode_NPC* NPCNode = Cast(InNode)) return SNew(SDialogueGraphNode, NPCNode); if (UDialogueGraphNode_Player* PlayerNode = Cast(InNode)) return SNew(SDialogueGraphNode, PlayerNode); if (UDialogueGraphNode_Root* RootNode = Cast(InNode)) return SNew(SGraphNodeWidget_Root, RootNode); return nullptr; }