/// <summary> /// Depending on the btn was clicked will do action /// </summary> /// <param name="action"></param> public void MouseListenAction(string action) { var sub = action.Substring(9); if (sub.Contains("New.")) { _newGameWindow.MouseListen(sub); } else if (sub.Contains("Tutorial")) { _newGameWindow.MouseListen(sub); } else if (sub.Contains("Save.")) { SaveLoadGameWindow.MouseListen(sub); } else if (sub == "Continue") { ContinueGameBtn(); } else if (sub == "Resume") { Program.InputMain.EscapeKey(); } else if (sub == "NewGame") { RedifineWindows(); HideMainMakeWindActive(_newGameWindow); } else if (sub == "Exit") { if (!wasOptionalFeedbackShown) { Dialog.InputFormDialog(H.OptionalFeedback); wasOptionalFeedbackShown = true; return; } Application.Quit(); } else if (sub == "SaveGame") { RedifineWindows(); SaveLoadGameWindow.Show("Save"); } else if (sub == "LoadGame") { RedifineWindows(); SaveLoadGameWindow.Show("Load"); } else if (sub.Contains("Options")) { RedifineWindows(); _optionsWindow.Listen(sub); } else if (sub.Contains("Achieve")) { //this is a call from Main if (sub == "Achieve") { RedifineWindows(); _achieveWindow.Show(""); } //the hit of the ok else { _achieveWindow.MouseListen(sub); } //Debug.Log("Achive"); } }