static public new void SelectCom(GKToyNode node) { switch (node.doubleClickType) { // Dialogue. case 2: GKToyMakerDialogueCom.PopupTaskWindow(); GKToyMakerDialogueCom.InitSubData((GKToyDialogue)node); break; // Dialogue condition. case 4: GKToyMakerDialogueConditionCom.PopupTaskWindow(); GKToyMakerDialogueConditionCom.InitSubData((GKToyDialogueCondition)node); break; // Dialogue exit. case 5: GKToyMakerDialogueExitCom.PopupTaskWindow(); GKToyMakerDialogueExitCom.InitSubData((GKToyDialogueExit)node); break; // Dialogue action. case 6: GKToyMakerDialogueActionCom.PopupTaskWindow(); GKToyMakerDialogueActionCom.InitSubData((GKToyDialogueAction)node); break; default: break; } }
public static void PopupTaskWindow() { instance = GetWindow <GKToyMakerDialogueConditionCom>(GKToyDialogueMaker._GetDialogueLocalization("Dialogue condition"), true); _styleCenrer.alignment = TextAnchor.MiddleCenter; _styleRight.alignment = TextAnchor.MiddleRight; instance.minSize = new Vector2(300, 100); instance.maxSize = new Vector2(300, 100); instance._data = null; }
void OnEnable() { if (null == instance) { instance = GetWindow <GKToyMakerDialogueConditionCom>("", true); wantsMouseMove = true; minSize = new Vector2(200, 100); maxSize = new Vector2(200, 100); } }
void OnDestroy() { instance = null; }