Mana.GetMana C# (CSharp) Method

GetMana() public method

public GetMana ( ) : float
return float
    public float GetMana()
    {
        return mana;
    }

Usage Example

Ejemplo n.º 1
0
        public override bool Use(GameObject user)
        {
            Mana mana = user.GetComponent <Mana>();

            if (mana.GetMana() < manaCost)
            {
                return(false);
            }

            CooldownStore cooldownStore = user.GetComponent <CooldownStore>();

            if (cooldownStore.GetTimeRemaining(this) > 0)
            {
                return(false);
            }

            AbilityData data = new AbilityData(user);

            ActionScheduler actionScheduler = user.GetComponent <ActionScheduler>();

            actionScheduler.StartAction(data);

            targetingStrategy.StartTargeting(data,
                                             () => {
                TargetAquired(data);
            });

            return(true);
        }
All Usage Examples Of Mana::GetMana