Exemple #1
0
        public override void Runing()
        {
            DeBugRun();
            PrintHelper.PrintStoryText(new StringBuilder().Append(GameMainRecycle.InfoText), GameRoom.LineLength);
            QuestInfoRoomScript questRoom = (QuestInfoRoomScript)GameMainRecycle.RoomScripts.Group[typeof(QuestInfoRoomScript).Name];

            SelectText.Clear();
            SelectQuest.Clear();
            foreach (var item in Quests)
            {
                SelectQuest.Add(questRoom.Quests.Group[item]);
                SelectText.Add(questRoom.Quests.Group[item].Name);
            }
            OutRoom = LastRoom;
            if (RetureRoom == false)
            {
                SelectIndex = 999;
            }

            SelectIndex = PrintHelper.PrintSelectText(SelectText, SelectIndex);
            if (SelectIndex <= SelectText.Count)
            {
                GameMainRecycle.PlayerInfo.PlayerQuest = (GameQuest)SelectQuest[SelectIndex].Clone();
            }
        }
Exemple #2
0
 public override void Runing()
 {
     GiveLast = false;
     OutRoom  = LastRoom;
     KeyString.Clear();
     KeyNames.Clear();
     foreach (var item in Controller.ControllerKeys)
     {
         KeyString.Add(string.Format("<{0}>:   <{1}>", item.Key, item.Value));
         KeyNames.Add(item.Key);
     }
     SelectIndex = 0;
     DeBugRun();
     SelectIndex = PrintHelper.PrintSelectText(KeyString, SelectIndex);
     if (SelectIndex > KeyString.Count - 1)
     {
         string KeySave = Newtonsoft.Json.JsonConvert.SerializeObject(Controller.ControllerKeys);
         JsonHelper.SaveMyJson(Directory.GetCurrentDirectory(), KeySave, "KeySetting");
         return;
     }
     else
     {
         Console.Clear();
         Console.WriteLine("请按下你想要使用的按键");
         Controller.ControllerKeys[KeyNames[SelectIndex]] = Console.ReadKey().Key;
         OutRoom = this;
     }
 }
Exemple #3
0
        public override void Runing()
        {
            if (RetureRoom == false)
            {
                SelectIndex = 999;
            }
            SetRoom();
            OutRoom = LastRoom;
            DeBugRun();
            Console.WriteLine("选项:");
            UnitInfoRoom Pinfo = (UnitInfoRoom)GameMainRecycle.RoomScripts.Group   [SelectRoom[0]];

            Pinfo.Unit  = GameMainRecycle.PlayerInfo.PlayerUnit;
            SelectIndex = PrintHelper.PrintSelectText(SelectText, SelectIndex);
            if (SelectIndex <= SelectText.Count)
            {
                OutRoom          = GameMainRecycle.RoomScripts.Group[SelectRoom[SelectIndex]];
                OutRoom.LastRoom = this;
            }
        }