示例#1
0
 public static void heal(StatusModel status, int hp_to_heal)
 {
     status.HitPointsLeft += hp_to_heal;
     status.HealthLeft    += (int)Math.Round(((double)hp_to_heal / (double)status.TotalHitPoints) * 100);
 }
示例#2
0
 public static void reset_status(StatusModel status)
 {
     status.HitPointsLeft = status.TotalHitPoints;
     status.HealthLeft    = 100;
 }
示例#3
0
        //Status functions

        public static void takeDmage(StatusModel status, int dmage)
        {
            status.HitPointsLeft -= dmage;
            status.HealthLeft    -= (int)Math.Round(((double)dmage / (double)status.TotalHitPoints) * 100);
        }