public void tm_Tick(object sender, EventArgs e) { if (i == (ReactPb.Width - 20)) { tm.Stop(); } else { i = i + 10; } ReactPb.Invalidate(); }
private void ActBt_Click(object sender, EventArgs e) { bt_click++; if (bt_click == 1) { convert(); ReactPb.Invalidate();//客の反応処理 } if (bt_click == 2) { Timer tm = new Timer(); tm.Start(); tm.Tick += new EventHandler(tm_Tick); ReactPb.Paint += new PaintEventHandler(reactpb_Paint); ActBt.Text = "リザルトへ"; //攻撃ステータスで処理時の客のセリフと画像 if (btway == 0) { ReactPb.Image = BuzzCookingFinal.Properties.Resources.badbg; if (btem == 0) { bm3 = BuzzCookingFinal.Properties.Resources.free_bad; ReactTb.Text = "「う・・・く、苦s・・」"; } else if (btem == 1) { bm3 = BuzzCookingFinal.Properties.Resources.businessman_bad; ReactTb.Text = "「・・・!?\r\n疲れが味にも支障を・・??」"; } else if (btem == 2) { bm3 = BuzzCookingFinal.Properties.Resources.ol_bad; ReactTb.Text = "「ちょ・・!なんなのこr。。。」"; } else if (btem == 3) { bm3 = BuzzCookingFinal.Properties.Resources.family_bad; ReactTb.Text = "「パp・・・ああ、あなt・・\r\n・コンナトコロデ・・・」"; } else if (btem == 4) { bm3 = BuzzCookingFinal.Properties.Resources.kids_bad; ReactTb.Text = "「おえ・・・\r\n泥と蟻を食べてるみt・・i」"; } else if (btem == 5) { bm3 = BuzzCookingFinal.Properties.Resources.american_bad; ReactTb.Text = "「OH....MY...GOD.....」"; } else if (btem == 6) { bm3 = BuzzCookingFinal.Properties.Resources.china_bad; ReactTb.Text = "「..ワタシノレキシ..\r\nココデオワルアr...」"; } else if (btem == 7) { bm3 = BuzzCookingFinal.Properties.Resources.india_bad; ReactTb.Text = "「イセ ワパス レ ジャエn....」"; } else if (btem == 8) { bm3 = BuzzCookingFinal.Properties.Resources.bisyokuwoman_bad; ReactTb.Text = "「うぷ....口いっぱいに...\r\nゴm...」"; } else if (btem == 9) { bm3 = BuzzCookingFinal.Properties.Resources.bisyokuman_bad; ReactTb.Text = "「うぷ....口いっぱいに...\r\nゴm...」"; } else if (btem == 10) { bm3 = BuzzCookingFinal.Properties.Resources.kansaman_bad; ReactTb.Text = "「食品......衛生法....違反...\r\nというか.もはy」"; } else if (btem == 11) { bm3 = BuzzCookingFinal.Properties.Resources.kansawoman_bad; ReactTb.Text = "「こんな....許されな....」"; } else if (btem == 12) { bm3 = BuzzCookingFinal.Properties.Resources.police_bad; ReactTb.Text = "「すまない....逮捕より先に...\r\n殉職した仲間のもとへ....」"; } else if (btem == 13) { bm3 = BuzzCookingFinal.Properties.Resources.yakuza_bad; ReactTb.Text = "「毒デモ盛ったノカ!?\r\nテメエ....ヨクモ....」"; } else if (btem == 14) { bm3 = BuzzCookingFinal.Properties.Resources.boss_bad; ReactTb.Text = "「これは....終末の....」"; } else if (btem == 15) { bm3 = BuzzCookingFinal.Properties.Resources.boss_bad; ReactTb.Text = "「これは....終末の....」"; } } //回復ステータスで処理時の客のセリフと画像 if (btway == 1) { ReactPb.Image = BuzzCookingFinal.Properties.Resources.happy_bg; if (btem == 0) { bm3 = BuzzCookingFinal.Properties.Resources.free_good; ReactTb.Text = "「ヤバ!美味しいなこれ!」"; } else if (btem == 1) { bm3 = BuzzCookingFinal.Properties.Resources.businessman_good; ReactTb.Text = "「これは・・午後からの活力!!!」"; } else if (btem == 2) { bm3 = BuzzCookingFinal.Properties.Resources.ol_good; ReactTb.Text = "「ちょーやば!先輩誘わなきゃ!」"; } else if (btem == 3) { bm3 = BuzzCookingFinal.Properties.Resources.family_good; ReactTb.Text = "「ママの料理よりおいしい!!!」"; } else if (btem == 4) { bm3 = BuzzCookingFinal.Properties.Resources.kids_good; ReactTb.Text = "「生まれて初めてこんな美味しいの\r\n食べたよ!おとーさんにも教えなきゃ!」"; } else if (btem == 5) { bm3 = BuzzCookingFinal.Properties.Resources.american_good; ReactTb.Text = "「WAO!Delicious!!!」"; } else if (btem == 6) { bm3 = BuzzCookingFinal.Properties.Resources.china_good; ReactTb.Text = "「好吃 ハオチー!!!」"; } else if (btem == 7) { bm3 = BuzzCookingFinal.Properties.Resources.india_good; ReactTb.Text = "「 レケン ボハット アッチャ タ」"; } else if (btem == 8) { bm3 = BuzzCookingFinal.Properties.Resources.bisyokuwoman_good; ReactTb.Text = "「あら?いけるじゃない?\r\n不味いなんて嘘じゃない!」"; } else if (btem == 9) { bm3 = BuzzCookingFinal.Properties.Resources.bisyokuman_good; ReactTb.Text = "「噂通りだな!素晴らしい!」"; } else if (btem == 10) { bm3 = BuzzCookingFinal.Properties.Resources.kansaman_good; ReactTb.Text = "「聞いていた話と違うな・・」"; } else if (btem == 11) { bm3 = BuzzCookingFinal.Properties.Resources.kansawoman_good; ReactTb.Text = "「合法よ合法!!美味しすぎるわ!」"; } else if (btem == 12) { bm3 = BuzzCookingFinal.Properties.Resources.police_good; ReactTb.Text = "「事件性なしであります!!!\r\nむしろ美味しすぎて事件であります!」"; } else if (btem == 13) { bm3 = BuzzCookingFinal.Properties.Resources.yakuza_good; ReactTb.Text = "「うほ!うほほほ!!!\r\nうまーーーーーーーーい」"; } else if (btem == 14) { bm3 = BuzzCookingFinal.Properties.Resources.boss_good; ReactTb.Text = "「ふむ・・悪くないではないか。」"; } else if (btem == 15) { bm3 = BuzzCookingFinal.Properties.Resources.boss_good; ReactTb.Text = "「素晴らしい料理ではないか!」"; } } } if (bt_click == 3) { Result rtf = new Result(btem, btenemy, btway); rtf.Show(); Close(); } }