Пример #1
0
            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));
            }
Пример #2
0
        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);
        }
Пример #3
0
            public override bool ValidateEquipment(Item item)
            {
                var itemID = item.ItemID;

                return(!(item is BaseQuiver) && GargoyleOnlyIDs.Any(id => id == itemID));
            }