/*public void SetHP(int modifier) * { * lock (HpLock) * { * CurrentHp = modifier; * } * } * public int GetHP() * { * int hp; * lock (HpLock) * { * hp = CurrentHp; * } * return hp; * } */ public void UpdateHp(int modifier, NecServer server = null, bool verifyAgro = false, uint instanceId = 0) { hp.Modify(modifier); if (verifyAgro) { if (server == null) { _Logger.Error("NecServer is null!"); return; } if (!GetAgroCharacter(instanceId)) { monsterAgroList.Add(instanceId, modifier); Character character = (Character)server.instances.GetInstance(instanceId); SetCurrentTarget(character); SetAgro(true); MonsterHate(server, true, instanceId); SendBattlePoseStartNotify(server); if (id == 4) { SetGotoDistance(1000); } else { SetGotoDistance(200); } } } }