/// <summary> /// 对话框添加按钮 /// </summary> /// <param name="whichDialog">对话框</param> /// <param name="buttonText">按钮文本</param> /// <param name="hotkey">快捷键</param> /// <returns>返回添加的按钮</returns> public static button DialogAddButton(dialog whichDialog, @string buttonText, integer hotkey) { button btn = new button { text = buttonText, hotkey = hotkey }; whichDialog.items.Add(btn); return(btn); }
public static @event TriggerRegisterDialogEvent(trigger whichTrigger, dialog whichDialog) { @event triEvent = new @event() { sourceDialog = whichDialog }; whichTrigger.events.Add(triEvent); return(triEvent); }
public static boolean SaveDialogHandle(hashtable table, integer parentKey, integer childKey, dialog whichDialog) { table.Add(parentKey.ToString("x8") + childKey.ToString("x8"), whichDialog); return(true); }
public static void DialogDisplay(player whichPlayer, dialog whichDialog, boolean flag) { whichDialog.displayed[whichPlayer] = flag; }
public static button DialogAddQuitButton(dialog whichDialog, boolean doScoreScreen, @string buttonText, integer hotkey) { throw new NotImplementedException(); }
public static void DialogSetMessage(dialog whichDialog, @string messageText) { whichDialog.message = messageText; }
/// <summary> /// 清空对话框 /// </summary> /// <param name="whichDialog"></param> public static void DialogClear(dialog whichDialog) { whichDialog.items.Clear(); }
/// <summary> /// 摧毁对话框 /// </summary> /// <param name="whichDialog"></param> public static void DialogDestroy(dialog whichDialog) { RuntimeRecorder.Recorder.Dialogs.Remove(whichDialog); whichDialog.destroyed = true; }
/// <summary> /// 创建对话框 /// </summary> /// <returns>返回创建的对话框</returns> public static dialog DialogCreate() { dialog d = new dialog(); return(d); }