Mob changes
This commit is contained in:
@@ -156,9 +156,16 @@ public class MobInstance
|
||||
|
||||
// Carried loot from player kills
|
||||
public List<CarriedLoot> CarriedPlayerLoot { get; set; } = new();
|
||||
|
||||
|
||||
/// <summary>Check if this mob is carrying loot from player kills</summary>
|
||||
public bool HasCarriedLoot => CarriedPlayerLoot.Count > 0;
|
||||
|
||||
// Death loot - generated when mob dies, lootable by players
|
||||
public List<LootDrop>? DeathLoot { get; set; }
|
||||
public long DeathLootGold { get; set; }
|
||||
|
||||
/// <summary>Check if this mob has loot available</summary>
|
||||
public bool HasDeathLoot => DeathLoot != null && (DeathLoot.Count > 0 || DeathLootGold > 0);
|
||||
|
||||
/// <summary>Current HP as percentage (0-1)</summary>
|
||||
public float HpPercent => MaxHealth > 0 ? (float)Health / MaxHealth : 0f;
|
||||
|
||||
Reference in New Issue
Block a user