View Single Post
Old 08-07-2008, 06:12 AM   #1 (permalink)
Zaihur
Forum Novice
 
Join Date: Feb 2004
Posts: 108
Default Double skill check trouble

Hi! I want to do a double skill check to give to a player an item but when I use the operator OR it give me the item only if i have both the two skill above that certain value. That's the code part...


Code:
        public override void OnSpeech(SpeechEventArgs e)
        {
            if (!e.Handled && e.Mobile.InRange(this.Location,3))
            {
                if (e.Speech == "...")
                {
                    if (((PlayerMobile)e.Mobile).Skills[SkillName.Stealth].Base < 49 | ((PlayerMobile)e.Mobile).Skills[SkillName.Lockpicking].Base < 49 | ((PlayerMobile)e.Mobile).Skills[SkillName.Hiding].Base < 99)
                    {
                        this.Say("...");
                    }
                    else
                    {
                        e.Mobile.AddToBackpack(new CustomItem());
                        this.Say("...");
                    }
                }

            }
Zaihur is offline   Reply With Quote