internal Enmity(EnmityObj obj, int totalEnmity) { Object = obj.ObjectId == Core.Me.ObjectId ? Core.Me : GameObjectManager.GetObjectByObjectId(obj.ObjectId); CurrentEnmity = obj.Enmity; if (totalEnmity == 0) { CurrentEnmityPercent = 0; return; } CurrentEnmityPercent = (int)((CurrentEnmity * 200 + totalEnmity) / (totalEnmity * 2)); }
internal Enmity(EnmityObj obj) { Object = obj.ObjectId == Core.Me.ObjectId ? Core.Me : GameObjectManager.GetObjectByObjectId(obj.ObjectId); CurrentEnmity = obj.Enmity; }