/// <summary>
        /// トップページへ
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void Top_Click(object sender, EventArgs e)
        {
            Top top = new Top();

            contents.Format format = new contents.Format();
            format.SeceneChange(this, top);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 購入
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void PurchaseButton_Click(object sender, EventArgs e)
        {
            if (sum >= contents.TicketPrice.MoneyPrice)
            {
                //使用した各金種の数を代入
                contents.MoneyNum.UseTenThousand  = int.Parse(TenThousand.Text);
                contents.MoneyNum.UseFiveThousand = int.Parse(FiveThousand.Text);
                contents.MoneyNum.UseOneThousand  = int.Parse(OneThousand.Text);
                contents.MoneyNum.UseFiveHundred  = int.Parse(FiveHundred.Text);
                contents.MoneyNum.UseOneHundred   = int.Parse(OneHundred.Text);
                contents.MoneyNum.UseFifty        = int.Parse(Fifty.Text);
                contents.MoneyNum.UseTen          = int.Parse(Ten.Text);

                //持っている各金種から数減らす
                contents.MoneyNum.TenNum          -= contents.MoneyNum.UseTen;
                contents.MoneyNum.FiftyNum        -= contents.MoneyNum.UseFifty;
                contents.MoneyNum.OneHundredNum   -= contents.MoneyNum.UseOneHundred;
                contents.MoneyNum.FiveHundredNum  -= contents.MoneyNum.UseFiveHundred;
                contents.MoneyNum.OneThousandNum  -= contents.MoneyNum.UseOneThousand;
                contents.MoneyNum.FiveThousandNum -= contents.MoneyNum.UseFiveThousand;;
                contents.MoneyNum.TenThousandNum  -= contents.MoneyNum.UseTenThousand;

                AfterPurchase_Money afterPurchase = new AfterPurchase_Money();
                contents.Format     format        = new contents.Format();
                format.SeceneChange(this, afterPurchase);
            }
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 購入
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void PurchaseButton_Click(object sender, EventArgs e)
        {
            if (isClick == true && contents.ElectronicMoneyNum.ElectronicalMoneyNum >= contents.TicketPrice.EleMoneyPrise)
            {
                //電子マネー代金からチケット代を引く
                contents.ElectronicMoneyNum.ElectronicalMoneyNum -= contents.TicketPrice.EleMoneyPrise;

                AfterPurchase_EleMoney afterPurchase = new AfterPurchase_EleMoney();
                contents.Format        format        = new contents.Format();
                format.SeceneChange(this, afterPurchase);
            }
        }