Esempio n. 1
0
 /// <summary>
 /// Casters the has resources.
 /// </summary>
 /// <param name="caster">The caster.</param>
 /// <returns></returns>
 public bool CasterHasResources(Characters.Stats caster)
 {
     foreach (KeyValuePair <StatType, int> stat in Costs)
     {
         if (caster.GetStatCount(Characters.Stats.Get.MOD, stat.Key) < stat.Value)
         {
             return(false);
         }
     }
     return(true);
 }
Esempio n. 2
0
 /// <summary>
 /// Casters the has resource.
 /// </summary>
 /// <param name="stat">The stat.</param>
 /// <param name="caster">The caster.</param>
 /// <returns></returns>
 public bool CasterHasResource(StatType stat, Characters.Stats caster)
 {
     return(caster.GetStatCount(Characters.Stats.Get.MOD, stat) >= Costs[stat]);
 }
Esempio n. 3
0
 public static int GetDifference(StatType type, Characters.Stats a, Characters.Stats b)
 {
     return(a.GetStatCount(Characters.Stats.Get.TOTAL, type) - b.GetStatCount(Characters.Stats.Get.TOTAL, type));
 }