Пример #1
0
    public void SetWeaponInfo(WeaponInfo weaponInfo)
    {
        this.weaponInfo = weaponInfo;
        image.sprite    = weaponInfo.sprite;
        title.text      = weaponInfo.displayName;
        damageText.SetWith(weaponInfo.damage);
        delayText.SetWith(weaponInfo.repeatDelay);
        bool canBuy = playerScoreInfo.CanBuyWeapon(weaponInfo);

        priceText.SetWith(canBuy ? buyText : cannotBuyText, weaponInfo.scoreWorth);
        button.interactable = canBuy;
    }
Пример #2
0
 public void PurchaseWeaponItem(WeaponInfo weaponInfo)
 {
     Debug.Assert(playerScoreInfo.CanBuyWeapon(weaponInfo));
     weaponBeingPurchased = weaponInfo;
     ShowSelectSlot();
 }