コード例 #1
0
 public void buyDefence()
 {
     if (Player_Info.Money >= ShopInfo.DefencePrice)
     {
         Player_Info.BuyDefence();
         print(Player_Info.defence);
         Player_Info.reduceMoney(ShopInfo.DefencePrice);
         ShopInfo.incrementDefence();
         updateDefencePrice();
         updatePlayerMoney();
         playCoinAudio();
         save();
     }
     else
     {
         errorDefencePrice();
         Invoke("updateDefencePrice", 3f);
     }
 }