public static bool CheckDamage(Mobile from, Server.DamageType type) { if (from is BaseCreature) { if (KhaldunTastyTreat.UnderInfluence((BaseCreature)from)) { return(true); } return(false); } else if (from.Player) { Item damager = from.FindItemOnLayer(Layer.OneHanded); if (damager == null) { damager = from.FindItemOnLayer(Layer.TwoHanded); } if (damager != null && damager.HasSocket <Caddellite>()) { switch (type) { case Server.DamageType.Melee: case Server.DamageType.Ranged: return(damager is BaseWeapon); default: return(damager is Spellbook); } } } return(false); }