コード例 #1
0
 public void DoUpgrade1()
 {
     playerHandler.AddMoney(-currentCell.upgrade1Cost);
     currentCell.Upgrade1();
     currentCell.RemoveCircle();
     currentCell.CreateCircle();
 }
コード例 #2
0
    // Public Methods

    public void InflammationUpgrade()
    {
        playerHandler.AddMoney(-inflammationUpgradeCost);
        foreach (Pathogen p in attackerHandler.attackers)
        {
            p.Slow(40, 10);
        }
    }
コード例 #3
0
    // Public Methods

    public void BuyCell()
    {
        GameObject g          = Instantiate(cell, transform.position, transform.rotation);
        Cell       boughtCell = g.GetComponent <Cell>();

        boughtCell.placing   = true;
        boughtCell.placeable = true;
        boughtCell.CreateCircle();
        playerHandler.AddMoney(-cost);
        placing = true;
    }
コード例 #4
0
 public void SellTower()
 {
     player.AddMoney(cost / 2);
     player.RemoveCell(this);
     Destroy(gameObject);
 }
コード例 #5
0
    // Private Methods

    private void Reward()
    {
        playerHandler.AddMoney(waveReward + currentWave * 10);
    }
コード例 #6
0
 public void GiveReward(int r)
 {
     player.AddMoney(r);
 }