public override bool ValidateEquipment(Item item) { var elfOrHuman = item as ICanBeElfOrHuman; if (elfOrHuman != null && elfOrHuman.ElfOnly) { return(true); } var itemID = item.ItemID; return(!GargoyleOnlyIDs.Any(id => id == itemID)); }
public static Race GetRequiredRace(Item item) { var itemID = item.ItemID; if (GargoyleOnlyIDs.Any(id => id == itemID)) { return(Race.Gargoyle); } var elfOrHuman = item as ICanBeElfOrHuman; if (elfOrHuman != null) { return(elfOrHuman.ElfOnly ? Race.Elf : Race.Human); } if (ElfOnlyIDs.Any(id => id == itemID)) { return(Race.Elf); } return(Race.Human); }
public override bool ValidateEquipment(Item item) { var itemID = item.ItemID; return(!(item is BaseQuiver) && GargoyleOnlyIDs.Any(id => id == itemID)); }