Ejemplo n.º 1
0
        public Card(string _name, ElementalType.ElementType _type, int _initiative, List <CardEffect> _effects)
        {
            //Each card needs a unique ID, up counter and assign the new ID
            //TODO: Add a check to ensure no ID duplication
            //TODO: Add a failsafe
            ID_COUNTER++;
            id = ID_COUNTER;

            //Card data
            name        = _name;
            initative   = _initiative;
            myType      = _type;
            cardEffects = _effects;

            //Display all card effect descriptions on the card text.
            for (int i = 0; i < cardEffects.Count; i++)
            {
                cardText += cardEffects[i].GetDescription();
                cardText += "\n"; //line break for each effect
            }
        }
Ejemplo n.º 2
0
 public DealDamage(int baseAmount, ElementalType.ElementType type)
 {
     baseDamage  = baseAmount;
     damageType  = type;
     description = $"Deal {baseAmount} {damageType.ToString()} damage";
 }
Ejemplo n.º 3
0
 //TODO: Damage calculation including type
 public void TakeDamage(int amount, ElementalType.ElementType type)
 {
 }