public void OnTakeDamage(Object.Living obj) { byte shade = 0; var hp = ((((float)obj.HPCur / (float)obj.HP) * 100) * 1); shade = Convert.ToByte(hp); gameLink.Send(new GameOutMessage.HitAnimation(obj.objId, shade).Compile()); }
public void OnTakeDamage(Object.Living obj) { if (_takeDamage != null) { _takeDamage(obj); } if (obj is Player.Player) { (obj as Player.Player).gameLink.Send(new Network.GameOutMessage.SetHP(obj as Player.Player).Compile()); } }
public static void CastHeal(Player.LeafSpell spell, Object.Living target) { double amt = 0.6f + (spell.Level * 0.02); target.HPCur += (int)(target.HP * amt); }