예제 #1
0
 /// <summary>
 /// Checks if the mana pool has more than or has the specified percentage of mana
 /// </summary>
 /// <param name="percentAsDecimal">The percent of mana as a decimal ex: 45% would be .45</param>
 /// <returns>True if the mana pool has that percent of mana</returns>
 public bool HasManaPercent(float percentAsDecimal)
 {
     return(((playerMana.GetCurrentMana()) / playerMana.GetMaxMana()) >= percentAsDecimal && (((playerMana.GetCurrentMana() - (defaultManaCost * (playerMana.GetCurrentMana() / playerMana.GetMaxMana()))) / playerMana.GetMaxMana()) >= 0));
 }