예제 #1
0
        public static string OpeningDisplayMessage(int wuso)
        {
            //int wuso = 0;
            global playernameprop = new global();

            Console.Write("請輸入你的名字:");
            playername = Console.ReadLine();
            Console.WriteLine("");

            while (wuso == 0)
            {
                Console.WriteLine("你真的確定嗎? 1 我很確定(我、很確定!) 2 我還是改一下好了...");
                wuso = Convert.ToInt32(Console.ReadLine()) - 1;
                if (wuso == 1)
                {
                    Console.WriteLine("哈哈騷年為時已晚啦 ~ 謎之拳五郎: 你,已經死了。(大誤)");
                    Console.WriteLine("__________________________________________________________");
                }
                else if (wuso == 0)
                {
                }
                else if (wuso != 0 && wuso != 1)
                {
                    Console.WriteLine("愛亂選那就不給你改囉!");
                    Console.WriteLine("__________________________________________________________");
                    break;
                }
                else
                {
                }
            }

            Console.WriteLine("");
            Console.WriteLine("於是.....故事開始了。");
            Console.ReadLine();
            Console.WriteLine("時值平安時代,沒錯,就在柏林圍牆倒下後不久,");
            Console.ReadLine();
            Console.WriteLine("我知道你在想甚麼,不要問,你會怕。");
            Console.ReadLine();
            Console.WriteLine("不會怕就算了。人家好難過喔~");
            Console.ReadLine();
            Console.WriteLine("少年--{0} 誕。生。了。 可喜可賀。可喜可賀。", playername);
            Console.ReadLine();
            Console.WriteLine("殊不知他的誕生,將會引起一陣滔天的風暴......");
            Console.ReadLine();
            Console.WriteLine("註記:不是家庭風暴。");
            Console.ReadLine();
            Console.WriteLine("");
            Console.WriteLine("~序章完~");
            Console.WriteLine("__________________________________________________________");
            Console.WriteLine("");
            //Console.ReadLine();

            return(playername);
        }
예제 #2
0
        public static void GameTextingPattern()
        {
            global Textroadline = new global();

            //openingending playernameprop = new openingending();
            //物件

            Console.WriteLine("");
            Console.WriteLine("故事......要從騷年的誕生說起....");
            Console.ReadLine();
            Console.WriteLine("很久很久以前.....有一對老夫婦,他們多年來膝下無子...");
            Console.ReadLine();
            Console.WriteLine("因為老先生嚴重不舉....(笑)");
            Console.ReadLine();
            Console.WriteLine("但是,神明再次給他們一次機會....");
            Console.ReadLine();
            Console.WriteLine("...");
            Console.ReadLine();
            Console.WriteLine("有一天,老夫婦們家前的小河飄來了一個異物");
            Console.ReadLine();
            Console.WriteLine("那竟然是........長得像桃子一樣的屁股!");
            Console.ReadLine();
            Console.WriteLine("咬到舌頭了......是長得像屁股一樣的桃子");
            Console.ReadLine();
            Console.WriteLine("老夫婦們便不疑有他,從褲檔抄出一把藍波刀就這樣劈了下去!!!");
            Console.ReadLine();
            Console.WriteLine("只聞刀聲霍霍,老先生一招\"流星墜月\"就這樣夾著淒厲的風勢下刀!!");
            Console.ReadLine();
            Console.WriteLine("只見那屁股...不對是桃子,竟然緩緩抖了兩下,竟噴出了大樣的鮮血!!");
            Console.ReadLine();
            Console.WriteLine("那血噴得可真快,霎那間老夫婦兩人被那血流捲進河流之中,從此失去下落...");
            Console.ReadLine();
            Console.WriteLine("說時遲那時快,屁股竟伴隨著一聲慘叫 \"要...裂開了!!!\" 從中裂開了");
            Console.ReadLine();
            Console.WriteLine("還伴隨著雙眼上翻比\"耶\"的表情呢。");
            Console.ReadLine();
            Console.WriteLine("從中,滾出了一名少年。");
            Console.ReadLine();
            Console.WriteLine("沒錯那就是......");
            Console.ReadLine();
            Console.WriteLine("屁太郎--{0}", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("");
            Console.WriteLine("~前章完~");
            Console.WriteLine("__________________________________________________________");


            Console.WriteLine("");
            Console.WriteLine("於是十八年過去了......");
            Console.ReadLine();
            Console.WriteLine("由於出生時就是少年的樣子,少年現在的樣子根本就是魔法師嘛(笑)");
            Console.ReadLine();
            Console.WriteLine("不不不,{0} 真的是一位魔法師,而且快變成黑魔法師了(爆笑)", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("言歸正傳,少年踏上了旅程。");
            Console.ReadLine();
            Console.WriteLine("我知道你在想甚麼,不要問,你會ㄆㄚ..(毆打聲)....總而言之少年踏上了旅程。");
            Console.ReadLine();
            Console.WriteLine("少年第一個到達的地方,是個飽受魔王侵擾的小村子。");
            Console.ReadLine();
            Console.WriteLine("\"真是慘啊...\"魔法師(笑){0}說道。", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("此時,突然一股像怪物般細瘦的手抓住了{0}!!", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("\"求求你,幫幫我...\" 原來是一位倒在路邊的老太太");
            Console.ReadLine();
            Console.WriteLine("\"勇者,幫幫我...我的女兒被魔王抓走了!!請你救救她!!\" 倒在路邊的老太太央求著");
            Console.ReadLine();

a:
            Console.Write("怎麼辦? 1 推開她,乾我屁事! 2 好吧,我喜歡幫助別人,尤其是倒在路邊的老太太!  ");
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            Console.WriteLine("");
            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2)
            {
                Console.WriteLine("輸入錯誤!");
                Console.Write("怎麼辦? 1 推開她不理她,乾我屁事! 2 好吧,我喜歡幫助別人,尤其是倒在路邊的老太太!  ");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }  // 當input的是123以外的數字時,重做

            if (Textroadline.textroadline1 == 1)
            {
                Console.WriteLine("\"滾開!干我屁屁事!\"你朝倒在路邊的老太太踹了一腳");
                Console.ReadLine();
                Console.WriteLine("結果老太太爆炸了。");
                Console.ReadLine();
                Console.WriteLine("你被炸死了。");
                Console.ReadLine();

b:
                Console.WriteLine("Game Over...");
                Console.ReadLine();
                Console.WriteLine("你失敗了!要再試一次嗎?");
                Console.WriteLine("選1代表繼續,選2代表關閉程式");
                int a = Convert.ToInt32(Console.ReadLine());
                if (a == 1)
                {
                    goto a;
                }
                else if (a == 2)
                {
                    System.Environment.Exit(System.Environment.ExitCode);
                }
                else
                {
                    Console.WriteLine("輸入錯誤");
                    goto b;
                }
            }
            else if (Textroadline.textroadline1 == 2)
            {
                goto c;
            }
            else
            {
            }
c:
            Console.WriteLine("{0}選擇接受老太太的委託。", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("老太太瞬間爬起來交給你一張地圖,然後跑走了。");
            Console.ReadLine();
            Console.WriteLine("......究竟是命運的操弄呢?還是一切都只是必然呢?讓我們看下去...");
            Console.ReadLine();
            Console.WriteLine("說時遲,那時快。{0}到達魔王城了。", openingending.playername);
            Console.ReadLine();
            Console.WriteLine("只見大門深鎖。門似乎很硬(廢話)");
            Console.ReadLine();


d:
            Console.Write("怎麼辦? 1 用力撞開 2 走側門 ");
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            Console.WriteLine("");
            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2)
            {
                Console.WriteLine("輸入錯誤!");
                Console.Write("怎麼辦? 1 用力撞開 2 走側門 ");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }  // 當input的是12以外的數字時,重做

            if (Textroadline.textroadline1 == 2)
            {
                Console.WriteLine("你走向側門。");
                Console.ReadLine();
                Console.WriteLine("結果遇到魔王成的守衛---貞子!!!。");
                Console.ReadLine();
                Console.WriteLine("進入戰鬥!!!");
                Console.WriteLine("");
                Console.WriteLine("__________________________________________________________");
                battle2.Battle2display();
                Console.WriteLine("你打敗了貞子後,推開側門。");
                Console.ReadLine();
                Console.WriteLine("結果門後只有著,倒插著許多尖刺的巨大洞穴......");
                Console.ReadLine();
                Console.WriteLine("當{0}打算說\"WTF?\"時,他背後突然被人推了一把...!", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("騷年無力的下墜,臨死前只看到剛才交給他地圖的老婆婆站在他本來的位子的後方...");
                Console.ReadLine();
                Console.WriteLine("\"這是為了我剛才被你殺掉女兒!\"老婆婆淒厲的吼叫著。");
                Console.ReadLine();
                Console.WriteLine("{0}只感受到腹部遭到刺穿的感覺,及喉嚨有股灼熱感不斷湧升。然後,失去了意識。", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("你死了。 Game Over......");
                Console.ReadLine();
e:
                Console.WriteLine("你失敗了!要再試一次嗎?");
                Console.WriteLine("選1代表繼續,選2代表關閉程式");
                int a = Convert.ToInt32(Console.ReadLine());
                if (a == 1)
                {
                    goto d;
                }
                else if (a == 2)
                {
                    System.Environment.Exit(System.Environment.ExitCode);
                }
                else
                {
                    Console.WriteLine("輸入錯誤");
                    goto e;
                }
            }
            else if (Textroadline.textroadline1 == 1)
            {
                Console.WriteLine("在撞了第三次後,門終於被撞開。於是{0}走進了魔王城。", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("魔王城內部卻是一片空城。前方隱約傳來啪啪聲。");
                Console.ReadLine();
                Console.WriteLine("究竟要不要前去探查呢?");
                Console.ReadLine();
                Console.WriteLine("你以為可以選選項? 是男人當然要前去偷看,不,是察看啦!");
                Console.ReadLine();
                Console.WriteLine("只見你離傳出啪啪聲的房間越來越近......");
                Console.ReadLine();
                Console.WriteLine("究竟會看到甚麼呢?");
                Console.ReadLine();
                Console.WriteLine("我們下回分曉。");
                Console.ReadLine();
                Console.WriteLine("等等,等等啦!剛剛是開玩笑的!不要按下關閉鍵啊!!");
                Console.ReadLine();
                Console.WriteLine("那麼,究竟會看到甚麼呢?");
                Console.ReadLine();
                Console.WriteLine("{0}用力推開那扇房間的門!卻發現超乎意料之外的事實!", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("老先生竟然在跟阿部啪啪啪!!");
                Console.ReadLine();
                Console.WriteLine("不過雖著震驚而來的,馬上就是悲傷了。");
                Console.ReadLine();
                Console.WriteLine("老先生暴斃了。");
                Console.ReadLine();
                Console.WriteLine("似乎是因為玩法太激烈了(?)");
                Console.ReadLine();
                Console.WriteLine("管他的,反正就是死了。");
                Console.ReadLine();
                Console.WriteLine("阿部停下動作,緩緩地轉過來面對你。開口了。");
                Console.ReadLine();
                Console.WriteLine("\"我就是人稱六肛魔王的阿部,你是來成為我的下一個687的嗎?\"");
                Console.ReadLine();
                Console.WriteLine("阿部上下打良著你的腰部,淫蕩極的笑了。");
                Console.ReadLine();
                Console.WriteLine("\"人家....人家才不是呢!\"{0}嬌羞地反駁了,不愧是神受啊。", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("\"我!我是來打倒你的!!納屁來!\"{0}大吼一聲,像魔王阿部衝刺!", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("\"哼哼,真是愛搗蛋的孩子呢,看來需要調教一下?\"魔王阿部如此說了。");
                Console.ReadLine();
                Console.WriteLine("\"來吧!好男人,不來嗎!\"");
                Console.ReadLine();
                Console.WriteLine("強者之間無須對話,唯有一戰!");
                Console.ReadLine();
                Console.WriteLine("註記:那剛講那麼多是要死喔。");
                Console.ReadLine();
                Console.WriteLine("");
                Console.WriteLine("進入戰鬥!!");
                Console.WriteLine("__________________________________________________________");
                battle1.Battle1display();

                Console.WriteLine("\"想不到...我也有這麼一天...\"阿部痛苦的喘著氣說道。");
                Console.ReadLine();
                Console.WriteLine("{0}:........", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("\"看來我...輸了呢...\"阿部的身體不停的搖晃。");
                Console.ReadLine();
                Console.WriteLine("\"拿去吧......這是我們道館的徽章...\"阿部斷斷續續的說道。");
                Console.ReadLine();
                Console.WriteLine("\"不對...我在說甚麼...可惡...終於連話都說錯了嗎...\"阿部咋舌了一下。");
                Console.ReadLine();
                Console.WriteLine("\"那些我從別人身上奪走的...你都拿去吧...\"");
                Console.ReadLine();
                Console.WriteLine("\"全部都...接受吧...\"語畢,魔王便倒下了。");
                Console.ReadLine();
                Console.WriteLine("你陡然繳一軟,重重的坐下了。");
                Console.ReadLine();
                Console.WriteLine("一場偉大的戰役背後,總是伴隨著難以衡量的辛苦及代價。");
                Console.ReadLine();
                Console.WriteLine("現在的{0},深深的體驗這句話了。", openingending.playername);
                Console.ReadLine();
                Console.WriteLine("突然,倒下去的阿部那邊傳來了阿部的聲音。");
                Console.ReadLine();
                Console.WriteLine("\"全部都接受吧...當然....還~有~我~ 啾~\"");
                Console.ReadLine();
                Console.WriteLine("......");
                Console.ReadLine();
                Console.WriteLine("........");
                Console.ReadLine();
                Console.WriteLine("..........");
                Console.ReadLine();
                Console.WriteLine("蛤?!");
                Console.ReadLine();
                Console.WriteLine("~後章完~");
                Console.WriteLine("__________________________________________________________");
                Console.WriteLine("");
                Console.ReadLine();
            }
            else
            {
            }
        }
예제 #3
0
        public static void Battle2display()
        {
            global Battlesentaku = new global();

a:

            while (Battlesentaku.monsterhp1 > 0 || Battlesentaku.playerhp > 0)
            {
c:

                Console.WriteLine("");
                Console.WriteLine("目前訊息");
                Console.WriteLine("貞子生命 {0}", Battlesentaku.monsterhp1);
                Console.WriteLine("玩家生命 {0}", Battlesentaku.playerhp);
                Console.WriteLine("玩家魔力 {0}", Battlesentaku.playermana);
                Console.WriteLine("__________________________________________________________");
                Console.WriteLine("");

                if (Battlesentaku.turn % 2 == 1)
                {
                    Console.WriteLine("輪到玩家攻擊!");
                    Console.Write("請選擇動作: 1 攻擊 2 魔法 3 逃跑 你選擇: ");
                    Battlesentaku.battlesentaku = Console.ReadLine();

                    if (Battlesentaku.battlesentaku == "1" && Battlesentaku.monsterhp1 - 8 > 0)
                    {
                        Console.WriteLine("");
                        Console.WriteLine("你的攻擊產生了{0}的物理傷害!", Battlesentaku.playerdamage);
                        Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playerdamage;
                        Battlesentaku.turn       = Battlesentaku.turn + 1;
                    }

                    else if (Battlesentaku.battlesentaku == "2" && Battlesentaku.monsterhp1 - 15 > 0)
                    {
                        if (Battlesentaku.playermana >= 20)
                        {
                            Console.WriteLine("");
                            Console.WriteLine("消耗20瑪那,產生了15點的魔法傷害!");
                            Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playermanadamage;
                            Battlesentaku.playermana = Battlesentaku.playermana - Battlesentaku.playermanacost;
                            Console.WriteLine("");
                            Battlesentaku.turn = Battlesentaku.turn + 1;
                        }
                        else
                        {
                            Console.WriteLine("");
                            Console.WriteLine("瑪那不夠!");
                            Console.WriteLine("");
                        }
                    }
                    else if (Battlesentaku.battlesentaku == "3")
                    {
                        double runrate = Randomglobal.Attackcriticalrate(1);
                        if (runrate == 1.10)
                        {
                            Console.WriteLine("");
                            Console.WriteLine("恭喜!逃跑成功!");
                            Console.WriteLine("");
                            Battlesentaku.controlrunsucbreak = 1;
                            goto d;
                        }
                        else
                        {
                            Console.WriteLine("");
                            Console.WriteLine("恭喜!逃跑失敗!");
                            Console.WriteLine("");
                            Battlesentaku.turn++;
                        }
                    }

                    else if (Battlesentaku.battlesentaku != "1" && Battlesentaku.battlesentaku != "2" && Battlesentaku.battlesentaku != "3")
                    {
                        Console.WriteLine("");
                        Console.WriteLine("輸入錯誤");
                        Console.WriteLine("");
                        goto c;
                    }
                    // else { }

                    else if (Battlesentaku.battlesentaku == "1" && Battlesentaku.monsterhp1 - 8 < 0)
                    {
                        Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - 500;
                        break;
                    }

                    else if (Battlesentaku.battlesentaku == "2" && Battlesentaku.monsterhp1 - 15 < 0)
                    {
                        Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - 500;
                        break;
                    }
                    else
                    {
                    }
                }
                else
                {
                }


                if (Battlesentaku.turn % 2 == 0)//貞子攻擊回合
                {
                    Console.WriteLine("");
                    if (Battlesentaku.turn % 5 > 0)
                    {
                        Console.WriteLine("輪到貞子攻擊!");
                        Battlesentaku.playerhp = Battlesentaku.playerhp - Battlesentaku.monsterdamage;
                        Console.WriteLine("貞子使出了頭髮纏繞!");
                        Console.WriteLine("你受到了{0}傷害!", Battlesentaku.monsterdamage);
                        Battlesentaku.turn = Battlesentaku.turn + 1;
                    }
                    else if (Battlesentaku.turn % 5 == 0)
                    {
                        double atlcrtrate2 = Randomglobal.Attackcriticalrate(1);
                        Console.WriteLine("輪到貞子攻擊!");
                        int monsterctrhit = Convert.ToInt32(Battlesentaku.monsterdamage * atlcrtrate2);
                        Battlesentaku.playerhp = Battlesentaku.playerhp - monsterctrhit;
                        Console.WriteLine("貞子發飆了!她舉電視丟向你!");
                        Console.WriteLine("貞子暴擊!你受到了{0}傷害!", monsterctrhit);
                        Console.WriteLine("");
                        Battlesentaku.turn = Battlesentaku.turn + 1;
                    }
                    else
                    {
                    }
                }
                else
                {
                }
            }

            if (Battlesentaku.monsterhp1 <= 0)
            {
                Console.WriteLine("恭喜擊敗!");
                Console.WriteLine("");
                Console.WriteLine("__________________________________________________________");
            }
            else if (Battlesentaku.playerhp <= 0)
            {
                Console.WriteLine("你失敗了!要再試一次嗎?");
                Console.WriteLine("選1代表繼續,選2代表關閉程式");
                Console.Write("你選擇? ");
                Battlesentaku.battlesentaku = Console.ReadLine();
                if (Battlesentaku.battlesentaku == "1")
                {
                    Battlesentaku.playerhp   = 100;
                    Battlesentaku.monsterhp1 = 100;
                    Battlesentaku.playermana = 100;
                    goto a;
                }
                else if (Battlesentaku.battlesentaku == "2")
                {
                    System.Environment.Exit(System.Environment.ExitCode);
                }
            }
            else
            {
            }
d:
            if (Battlesentaku.controlrunsucbreak == 1)
            {
                Console.WriteLine("");
                Console.WriteLine("__________________________________________________________");
                Console.WriteLine("");
                //  break;
            }
        }
예제 #4
0
        public static void Battledisplay()

        {
            global Battlesentaku = new global();

            //Randomglobal random = new Randomglobal();
            //  Battlesentaku.turn =Battlesentaku.turn+1;

a:

            while (Battlesentaku.monsterhp1 * Battlesentaku.playerhp > 0)
            {
c:
                Console.WriteLine("{0}", Battlesentaku.turn);
                // Console.WriteLine("{0}", Battlesentaku.turn);
                Console.WriteLine("");
                Console.WriteLine("目前訊息.................................");
                Console.WriteLine("monsterhp1 {0}", Battlesentaku.monsterhp1);
                Console.WriteLine("playermana {0}", Battlesentaku.playermana);
                Console.WriteLine("playerhp {0}", Battlesentaku.playerhp);
                Console.WriteLine("........................................");
                Console.WriteLine("");

                if (Battlesentaku.turn % 2 == 1) //普通攻擊
                {
                    // Battlesentaku.playerhp = Battlesentaku.playerhp - 1000;

                    //Console.ReadLine();


                    Console.Write("請選擇動作: ");
                    //  Console.WriteLine("");
                    Battlesentaku.battlesentaku = Convert.ToInt32(Console.ReadLine());
                    Console.WriteLine("你選擇:  {0}", Battlesentaku.battlesentaku);
                    if (Battlesentaku.battlesentaku == 1)
                    {
                        Console.WriteLine("minus 5hp");
                        Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playerdamage;
                        Console.WriteLine("current monster hp  {0}", Battlesentaku.monsterhp1);
                        Battlesentaku.turn = Battlesentaku.turn + 1;
                        // Console.WriteLine("{0}", Battlesentaku.turn);
                        // Console.ReadLine();
                    }

                    else if (Battlesentaku.battlesentaku == 2) //魔力攻擊
                    {
                        if (Battlesentaku.playermana >= 30)
                        {
                            Console.WriteLine("-20hp,mana-30");
                            Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playermanadamage;
                            Battlesentaku.playermana = Battlesentaku.playermana - Battlesentaku.playermanacost;
                            Console.WriteLine("");
                            Battlesentaku.turn = Battlesentaku.turn + 1;

                            //  Console.ReadLine();
                        }
                        else if (Battlesentaku.battlesentaku == 3)
                        {
                            if (Randomglobal.attackcriticalrate >= 1.3)
                            {
                                Console.WriteLine("逃走失敗!");
                                Battlesentaku.turn++;
                            }
                            else
                            {
                                Console.WriteLine("逃走成功!");
                            }
                        }
                        else
                        {
                            Console.WriteLine("mana not enough!");
                            Console.WriteLine("");
                            //Console.ReadLine();
                        }
                    }
                    else if (Battlesentaku.battlesentaku != 1 && Battlesentaku.battlesentaku != 2 && Battlesentaku.battlesentaku != 3) //&& Battlesentaku.battlesentaku != 4)
                    {
                        Console.WriteLine("輸入錯誤");
                        Console.WriteLine("");
                        goto c;
                        //  Console.ReadLine();
                    }
                    else
                    {
                    }
                }
                else
                {
                }

                if (Battlesentaku.turn % 2 == 0)//怪獸攻擊回合
                {
                    Console.WriteLine("");
                    if (Battlesentaku.turn % 5 > 0)
                    {
                        Console.WriteLine("輪到怪獸攻擊!");
                        Battlesentaku.playerhp = Battlesentaku.playerhp - Battlesentaku.monsterdamage;
                        Console.WriteLine("你受到了{0}傷害!", Battlesentaku.monsterdamage);
                        // Console.WriteLine("請按任一鍵繼續...");
                        //Console.ReadLine();
                        Battlesentaku.turn = Battlesentaku.turn + 1;

                        // goto d;
                    }
                    else if (Battlesentaku.turn % 5 == 0)
                    {
                        Console.WriteLine("輪到怪獸攻擊!");
                        int monsterctrhit = Convert.ToInt32(Battlesentaku.monsterdamage * Randomglobal.attackcriticalrate);
                        Battlesentaku.playerhp = Battlesentaku.playerhp - monsterctrhit;
                        Console.WriteLine("暴擊率{0}!你受到了{1}傷害!", Randomglobal.attackcriticalrate, monsterctrhit);
                        // Console.WriteLine("請按任一鍵繼續...");
                        // Console.ReadLine();
                        Battlesentaku.turn = Battlesentaku.turn + 1;

                        // goto d;
                        //  Console.ReadLine();
                    }
                    else
                    {
                    }
                }
                else
                {
                }

                if (Battlesentaku.monsterhp1 < 0)
                {
                    Console.WriteLine("恭喜擊敗!");
                }
                else if (Battlesentaku.playerhp < 0)
                {
                    Console.WriteLine("你失敗了!要再試一次嗎?");
                    Console.WriteLine("選1代表繼續,選2代表關閉程式");
                    Battlesentaku.battlesentaku = Convert.ToInt32(Console.ReadLine());
                    if (Battlesentaku.battlesentaku == 1)
                    {
                        Battlesentaku.playerhp = Battlesentaku.playerhp + 100;
                        goto a;
                    }
                    else if (Battlesentaku.battlesentaku == 2)
                    {
                        System.Environment.Exit(System.Environment.ExitCode);
                    }
                }
                else
                {
                }
                // Battlesentaku.turn = Battlesentaku.turn + 1;
            }
        }
예제 #5
0
        public static void Battle1display()
        {
            int    failedcount   = 0;
            global Battlesentaku = new global();

            Battlesentaku.monsterhp1 = 130;
            //  Console.WriteLine("阿部生命 {0}", Battlesentaku.monsterhp1);
a:

            #region
            while (Battlesentaku.monsterhp1 * Battlesentaku.playerhp > 0)
            {
c:

                Console.WriteLine("");
                Console.WriteLine("目前訊息");
                Console.WriteLine("阿部生命 {0}", Battlesentaku.monsterhp1);
                Console.WriteLine("玩家生命 {0}", Battlesentaku.playerhp);
                Console.WriteLine("玩家魔力 {0}", Battlesentaku.playermana);

                Console.WriteLine("_________________________________________");
                Console.WriteLine("");


                #region
                #region
                #region
                if (Battlesentaku.turn % 2 == 1)
                {
                    Console.WriteLine("輪到玩家攻擊!");

                    Console.Write("請選擇動作: 1 攻擊 2 魔法 3 逃跑 你選擇: ");
                    Battlesentaku.battlesentaku = Console.ReadLine();
                    Console.WriteLine("你選擇:  {0}", Battlesentaku.battlesentaku);
                    #region
                    if (Battlesentaku.battlesentaku == "1")
                    {
                        Console.WriteLine("你的攻擊產生了{0}的物理傷害!", Battlesentaku.playerdamage);
                        Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playerdamage;
                        Battlesentaku.turn       = Battlesentaku.turn + 1;
                    }

                    else if (Battlesentaku.battlesentaku == "2")
                    {
                        if (Battlesentaku.playermana >= 20)
                        {
                            Console.WriteLine("消耗20瑪那,產生了15點的魔法傷害!");
                            Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - Battlesentaku.playermanadamage;
                            Battlesentaku.playermana = Battlesentaku.playermana - Battlesentaku.playermanacost;
                            Console.WriteLine("");
                            Battlesentaku.turn = Battlesentaku.turn + 1;
                        }
                        else
                        {
                            Console.WriteLine("瑪那不夠!");
                            Console.WriteLine("");
                        }
                        #endregion
                    }


                    else if (Battlesentaku.battlesentaku != "1" && Battlesentaku.battlesentaku != "2" && Battlesentaku.battlesentaku != "3")
                    {
                        Console.WriteLine("輸入錯誤");
                        Console.WriteLine("");
                        goto c;
                    }

                    else if (Battlesentaku.battlesentaku == Battlesentaku.magicword)
                    {
                        Console.WriteLine("突然一陣強光襲來,眼前出現了謎樣的文字......");
                        Console.ReadLine();
                        Console.Write("請輸入隱含世界真理之密語:");
                        string keycheck = Console.ReadLine();
                        #region
                        if (keycheck == Battlesentaku.keyword)
                        {
                            Console.WriteLine("");
                            Console.WriteLine("騷年,想不到你竟然答對了...");
                            Console.ReadLine();
                            Console.WriteLine("我就成全你! 讓你成為真正的 真。好。男。人 吧!");
                            Console.ReadLine();
                            Console.WriteLine("\"碰\"一聲。一股力量就這樣從你的屁股注入!");
                            Console.ReadLine();
                            Console.WriteLine("職業轉職! 進化成混沌魔導S師(笑)!");
                            Console.ReadLine();
                            Console.WriteLine("生命加成9999! 物攻加成9999! 魔攻加成9999!");
                            Console.ReadLine();
                            Console.WriteLine("去吧.....騷年,去反征服魔王吧...讓他了解誰才是真正的\"攻\"!");
                            Console.ReadLine();
                            Console.WriteLine("一陣強光襲來,你回到戰鬥之中。");
                            Console.ReadLine();
                            Battlesentaku.playerdamage     = 9999;
                            Battlesentaku.playerhp         = 9999;
                            Battlesentaku.playermana       = 9999;
                            Battlesentaku.playermanadamage = 9999;
                        }
                        else
                        {
                        }
                        #endregion
                    }

                    else if (Battlesentaku.battlesentaku1 == "3")
                    {
                        Console.WriteLine("");
                        Console.WriteLine("恭喜!逃跑失敗!");
                        Console.WriteLine("");
                        Battlesentaku.turn++;
                    }

                    else
                    {
                        Console.WriteLine("輸入錯誤!");
                        Console.WriteLine("用掉一回合。");
                        Console.ReadLine();
                    }
                    #endregion
                    #endregion
                }



                else if (Battlesentaku.battlesentaku1 == "1" && Battlesentaku.monsterhp1 - 8 < 0)
                {
                    Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - 500;
                    break;
                }

                else if (Battlesentaku.battlesentaku1 == "2" && Battlesentaku.monsterhp1 - 15 < 0)
                {
                    Battlesentaku.monsterhp1 = Battlesentaku.monsterhp1 - 500;
                    break;
                }

                else
                {
                }


                #endregion
                #region



                if (Battlesentaku.turn % 2 == 0)//怪物攻擊回合
                {
                    Console.WriteLine("");
                    if (Battlesentaku.turn % 6 > 0)
                    {
                        Console.WriteLine("輪到阿部攻擊!");
                        //  Console.ReadLine();
                        Battlesentaku.playerhp = Battlesentaku.playerhp - Battlesentaku.monsterdamage;
                        Console.WriteLine("你被肛了!受到了{0}傷害!", Battlesentaku.monsterdamage);
                        Console.WriteLine("阿部露出了相當興奮的笑容!");
                        Console.ReadLine();
                        Battlesentaku.turn = Battlesentaku.turn + 1;
                    }
                    else if (Battlesentaku.turn % 6 == 0)
                    {
                        Console.WriteLine("輪到阿部攻擊!");
                        Console.ReadLine();
                        double atlcrtrate2 = Randomglobal.Attackcriticalrate(1);
                        // Console.WriteLine("{0}",atlcrtrate2);
                        int monsterctrhit = Convert.ToInt32(Battlesentaku.monsterdamage * atlcrtrate2);
                        Battlesentaku.playerhp = Battlesentaku.playerhp - monsterctrhit;
                        Console.WriteLine("阿部突然有feel了!他更奮力地動起他的腰!你受到了{0}傷害!", monsterctrhit);
                        Console.WriteLine("阿部露出了相當興奮的笑容!");
                        Console.ReadLine();
                        Battlesentaku.turn = Battlesentaku.turn + 1;
                    }

                    else
                    {
                    }
                }
                else
                {
                }

                #endregion
                #region
                if (Battlesentaku.monsterhp1 <= 0)
                {
                    Console.WriteLine("恭喜擊敗!");
                    Console.WriteLine("");
                    Console.WriteLine("_______________________________________________________________");
                }
                else if (Battlesentaku.playerhp <= 0)
                {
                    Console.WriteLine("你失敗了!要再試一次嗎?");
                    Console.Write("選1代表繼續,選2代表關閉程式  ");
                    Battlesentaku.battlesentaku1 = Console.ReadLine();
                    if (Battlesentaku.battlesentaku1 == "1")
                    {
                        Battlesentaku.playerhp   = 100;
                        Battlesentaku.monsterhp1 = 130;
                        Battlesentaku.playermana = 100;
                        failedcount++;
                        switch (failedcount)
                        {
                        case 1:
                            Console.WriteLine("");
                            Console.WriteLine("提示一:不可硬上,只可智取。");
                            Console.WriteLine("");
                            break;

                        case 2:
                            Console.WriteLine("");
                            Console.WriteLine("提示二:採取行動:行動代號:今日之內不變之常數。8碼");
                            Console.WriteLine("");
                            break;

                        case 3:
                            Console.WriteLine("");
                            Console.WriteLine("提示三:智慧之語:密語代號一:賦予你智慧的月份。2碼");
                            Console.WriteLine("");
                            break;

                        case 4:
                            Console.WriteLine("");
                            Console.WriteLine("提示四:智慧之語:密語代號二:陽之相反。非陰。1碼");
                            Console.WriteLine("");
                            break;

                        case 5:
                            Console.WriteLine("");
                            Console.WriteLine("提示五:智慧之語:密語代號三:賦予你生命的日子。2碼");
                            Console.WriteLine("");
                            break;

                        case 6:
                            Console.WriteLine("");
                            Console.WriteLine("提示六:智慧之語:密語代號四:密語代碼與行動代號中重複一次高的字。1碼");
                            Console.WriteLine("");
                            break;

                        default:
                            Console.WriteLine("");
                            Console.WriteLine("總提示:");
                            Console.WriteLine("提示一:不可硬上,只可智取。");
                            Console.WriteLine("提示二:採取行動:行動代號:今日之內不變之常數。8碼");
                            Console.WriteLine("提示三:智慧之語:密語代號一:賦予你智慧的月份。2碼");
                            Console.WriteLine("提示四:智慧之語:密語代號二:陽之相反。非陰。1碼");
                            Console.WriteLine("提示五:智慧之語:密語代號三:賦予你生命的日子。2碼");
                            Console.WriteLine("提示六:智慧之語:密語代號四:密語代碼與行動代號中重複為一次頻率最高的字。1碼");
                            Console.WriteLine("");
                            break;
                        }

                        goto a;
                    }
                }

                else if (Battlesentaku.battlesentaku1 == "2")
                {
                    System.Environment.Exit(System.Environment.ExitCode);
                }


                else
                {
                }
                #endregion
            }

            #endregion
        }
예제 #6
0
        public static void GameTextingPattern()
        {
            global Textroadline = new global();

            //物件
            Console.Write("key serifu:");
            //選擇肢
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            //量化選擇之選擇肢


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }
            // 當input的是123以外的數字時,重做

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢2開始
            Console.Write("key serifu2:"); //選擇肢2
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu2:"); //選擇肢2
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢3開始
            Console.Write("key serifu3:"); //選擇肢3
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu3:"); //選擇肢3
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢4開始
            Console.Write("key serifu4:"); //選擇肢4
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu4:"); //選擇肢4
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢5開始
            Console.Write("key serifu5:"); //選擇肢5
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu5:"); //選擇肢5
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢6開始
            Console.Write("key serifu6:"); //選擇肢6
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu6:"); //選擇肢6
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢7開始
            Console.Write("key serifu7:"); //選擇肢7
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu7:"); //選擇肢7
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________

            //選擇肢8開始
            Console.Write("key serifu8:"); //選擇肢8
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3)
            {
                Console.WriteLine("again!");
                Console.Write("key serifu8:"); //選擇肢8
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;

                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +1 暫定
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +2 暫定
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
                Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", Textroadline.textroadlineeffect1);  //輸出,測示用
                // +3 暫定
            }
            else
            {
            }
            //判斷路線分歧(暫定 不考慮因選擇影響劇情)
            Console.WriteLine();
            //________________________________________________________________________________________________________________
        }
예제 #7
0
        public static void GameTextingPattern()
        {
            global Textroadline = new global();

            Console.WriteLine("一 早上起床之後 通常吃什麼當早點?");
            Console.WriteLine("1. 蛋和吐司");
            Console.WriteLine("2. 麥片");
            Console.WriteLine("3. 汽水");
            Console.WriteLine("4. 什麼都不吃");
            Console.WriteLine("");
            Console.Write("你的選擇:");
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());



            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("一 早上起床之後 通常吃什麼當早點?");
                Console.WriteLine("1. 蛋和吐司");
                Console.WriteLine("2. 麥片");
                Console.WriteLine("3. 汽水");
                Console.WriteLine("4. 什麼都不吃");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }
            // 當input的是1234以外的數字時,重做


            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 6;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");

            Console.WriteLine("二 如果你可以選任何一樣你想吃的東西當早點你會選擇什麼?");
            Console.WriteLine("1. 蛋和吐司");
            Console.WriteLine("2. 其它別種東西");
            Console.WriteLine("3. 汽水");
            Console.WriteLine("4. 蛋糕");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("二 如果你可以選任何一樣你想吃的東西當早點你會選擇什麼?");
                Console.WriteLine("1. 蛋和吐司");
                Console.WriteLine("2. 其它別種東西");
                Console.WriteLine("3. 汽水");
                Console.WriteLine("4. 蛋糕");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            //Console.WriteLine("textroadline1 = {0}", Textroadline.textroadline1);  //輸出,測示用

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");

            Console.WriteLine("三 午餐時?你會...");
            Console.WriteLine("1. 不吃東西 因為太忙或擔心體重");
            Console.WriteLine("2. 吃你想了一個早上想吃的東西");
            Console.WriteLine("3. 吃自己帶來的食物");
            Console.WriteLine("4. 問朋友要吃什麼 再一起去吃");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());

            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("三 午餐時?你會...");
                Console.WriteLine("1. 不吃東西 因為太忙或擔心體重");
                Console.WriteLine("2. 吃你想了一個早上想吃的東西");
                Console.WriteLine("3. 吃自己帶來的食物");
                Console.WriteLine("4. 問朋友要吃什麼 再一起去吃");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("四 一位朋友請你吃一些她/他帶來的食物 你會...");
            Console.WriteLine("1. 吃一小口 因為實在太餓了");
            Console.WriteLine("2. 為了保持禮貌 只吃一小口");
            Console.WriteLine("3. 拒絕他/她的好意 因為你正在減肥");
            Console.WriteLine("4. 吃兩口");
            Console.WriteLine("");
            Console.Write("你的選擇:");
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine(" 輸入錯誤!請再試一次!");
                Console.WriteLine("四 一位朋友請你吃一些她/他帶來的食物 你會...");
                Console.WriteLine("1. 吃一小口 因為實在太餓了");
                Console.WriteLine("2. 為了保持禮貌 只吃一小口");
                Console.WriteLine("3. 拒絕他/她的好意 因為你正在減肥");
                Console.WriteLine("4. 吃兩口");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }


            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 6;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("五 你未來的男/女朋友請你吃一樣 東西 你想那會是什麼?");
            Console.WriteLine("1. 一塊蛋糕");
            Console.WriteLine("2. 一顆蘋果");
            Console.WriteLine("3. 一片批薩");
            Console.WriteLine("4. 一個胡蘿蔔");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());

            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("五 你未來的男/女朋友請你吃一樣 東西 你想那會是什麼?");
                Console.WriteLine("1. 一塊蛋糕");
                Console.WriteLine("2. 一顆蘋果");
                Console.WriteLine("3. 一片批薩");
                Console.WriteLine("4. 一個胡蘿蔔");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }


            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 5;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("六 你的狗對你奮力搖尾巴 企圖引起你的注意 你會給他...");
            Console.WriteLine("1. 給他一塊狗餅乾");
            Console.WriteLine("2. 一些蛋糕");
            Console.WriteLine("3. 什麼都不給 拍拍他就好");
            Console.WriteLine("4. 什麼都不給 還把他趕開 因為你認為不能讓你的狗養成要什麼有什麼的壞習慣");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("六 你的狗對你奮力搖尾巴 企圖引起你的注意 你會給他...");
                Console.WriteLine("1. 給他一塊狗餅乾");
                Console.WriteLine("2. 一些蛋糕");
                Console.WriteLine("3. 什麼都不給 拍拍他就好");
                Console.WriteLine("4. 什麼都不給 還把他趕開 因為你認為不能讓你的狗養成要什麼有什麼的壞習慣");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("七 夢中 你正在一家全世界最棒的餐廳裡 你想你會點...");
            Console.WriteLine("1. 菜單上列的每道菜 反正是做夢嘛!!");
            Console.WriteLine("2. 一個大盤 裡面什麼東西都有的沙拉");
            Console.WriteLine("3. 牛排");
            Console.WriteLine("4. 一個會讓你多長很多肥油的點心");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("七 夢中 你正在一家全世界最棒的餐廳裡 你想你會點...");
                Console.WriteLine("1. 菜單上列的每道菜 反正是做夢嘛!!");
                Console.WriteLine("2. 一個大盤 裡面什麼東西都有的沙拉");
                Console.WriteLine("3. 牛排");
                Console.WriteLine("4. 一個會讓你多長很多肥油的點心");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }
            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("八 在一個熱帶島上 你覺得什麼食物是你一定要吃到的?");
            Console.WriteLine("1. 水果和蔬蔡");
            Console.WriteLine("2. 肉和馬玲薯");
            Console.WriteLine("3. 冰淇淋 巧克力和蛋糕?");
            Console.WriteLine("4. 中國菜");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("八 在一個熱帶島上 你覺得什麼食物是你一定要吃到的?");
                Console.WriteLine("1. 水果和蔬蔡");
                Console.WriteLine("2. 肉和馬玲薯");
                Console.WriteLine("3. 冰淇淋 巧克力和蛋糕?");
                Console.WriteLine("4. 中國菜");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 5;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine("九 你現在是一個嬰兒 你媽媽正在餵你吃...");
            Console.WriteLine("1. 嬰兒麥片或嬰兒食物");
            Console.WriteLine("2. 肉和馬鈴薯");
            Console.WriteLine("3. 綠色花椰菜");
            Console.WriteLine("4. 什麼都沒有 你媽正在做別的事");
            Console.WriteLine("");
            Console.Write("你的選擇:");

            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());


            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("九 你現在是一個嬰兒 你媽媽正在餵你吃...");
                Console.WriteLine("1. 嬰兒麥片或嬰兒食物");
                Console.WriteLine("2. 肉和馬鈴薯");
                Console.WriteLine("3. 綠色花椰菜");
                Console.WriteLine("4. 什麼都沒有 你媽正在做別的事");
                Console.WriteLine("");
                Console.Write("你的選擇:");
                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 6;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 4;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 8;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 2;
            }
            else
            {
            }
            Console.WriteLine("____________________________________________________________________");
            Console.WriteLine(" 十 你現在是六歲的小孩 你爸爸正在餵你吃...");
            Console.WriteLine("1. 批薩");
            Console.WriteLine("2. 義大利麵");
            Console.WriteLine("3. 泡泡糖");
            Console.WriteLine("4. 胡蘿蔔");
            Console.WriteLine("");
            Console.Write("你的選擇:");
            Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());

            while (Textroadline.textroadline1 != 1 && Textroadline.textroadline1 != 2 && Textroadline.textroadline1 != 3 && Textroadline.textroadline1 != 4)
            {
                Console.WriteLine("____________________________________________________________________");
                Console.WriteLine("輸入錯誤!請再試一次!");
                Console.WriteLine("十 你現在是六歲的小孩 你爸爸正在餵你吃...");
                Console.WriteLine("1. 批薩");
                Console.WriteLine("2. 義大利麵");
                Console.WriteLine("3. 泡泡糖");
                Console.WriteLine("4. 胡蘿蔔");
                Console.WriteLine("");
                Console.Write("你的選擇:");

                Textroadline.textroadline1 = Convert.ToInt32(Console.ReadLine());
            }

            if (Textroadline.textroadline1 == 1)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 7;
            }
            else if (Textroadline.textroadline1 == 2)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 5;
            }
            else if (Textroadline.textroadline1 == 3)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 1;
            }
            else if (Textroadline.textroadline1 == 4)
            {
                Textroadline.textroadlineeffect1 = Textroadline.textroadlineeffect1 + 3;
            }
            else
            {
            }
            a = Textroadline.textroadlineeffect1;
            Console.WriteLine("Textroadline.textroadlineeffect1 = {0}", a);      //輸出,測示用
        }