示例#1
0
    public void UpArrowDamage()
    {
        if (coin >= upCostArrowDamage)
        {
            lm.SetCoin(lm.GetCoin() - upCostArrowDamage);
            coin          = lm.GetCoin();
            coinText.text = coin.ToString();

            lm.SetDamage(lm.GetDamage() + 2);
            arrowDamageText.text = lm.GetDamage().ToString();
        }
    }
示例#2
0
    // Start is called before the first frame update
    void Start()
    {
        lm = new LegacyManager();

        maxArrow    = lm.GetMaxArrow();
        arrowDamage = lm.GetDamage();
        attackSpeed = lm.GetAttackSpeed();

        maxHealth = lm.GetMaxHealth();
        potion    = lm.GetPotion();
        coin      = lm.GetCoin();

        maxArrowText.text    = maxArrow.ToString();
        arrowDamageText.text = arrowDamage.ToString();
        attackSpeedText.text = attackSpeed.ToString();
        maxHealthText.text   = maxHealth.ToString();
        potionText.text      = potion.ToString();
        coinText.text        = coin.ToString();
    }