Inheritance: BaseHat
コード例 #1
0
ファイル: BaseMobileHelper.cs プロジェクト: Ravenwolfe/xrunuo
        public static Item GetRandomHat()
        {
            Item hat = null;

            switch ( Utility.Random( 6 ) )
            {
                case 0:
                    hat = new SkullCap( GetRandomHue() );
                    break;
                case 1:
                    hat = new Bandana( GetRandomHue() );
                    break;
                case 2:
                    hat = new WideBrimHat();
                    break;
                case 3:
                    hat = new TallStrawHat( Utility.RandomNeutralHue() );
                    break;
                case 4:
                    hat = new StrawHat( Utility.RandomNeutralHue() );
                    break;
                case 5:
                    hat = new TricorneHat( Utility.RandomNeutralHue() );
                    break;
            }

            return hat;
        }
コード例 #2
0
        public Grandma () : base( AIType.AI_Mage, FightMode.Closest, 10, 1, 0.2, 0.4 )
        {
            
            Name = "Grandma";
            Body = 606;
            Hue = Utility.RandomSkinHue();

            Item hair = new Item(Utility.RandomList(0x2FC0, 0x2FC1, 0x2FCD, 0x2FD1));
            hair.Hue = 1109;
            hair.Layer = Layer.Hair;
            hair.Movable = false;
            AddItem(hair);

            SetStr(350, 400);//Adjust this to fit your shard.
            SetDex(100, 150);//Adjust this to fit your shard.
            SetInt(100, 150);//Adjust this to fit your shard.

            SetHits(800, 1000);//Adjust this to fit your shard.

            SetDamage(25, 30);//Adjust this to fit your shard.

            SetDamageType(ResistanceType.Physical, 45);//Adjust this to fit your shard.
            SetDamageType(ResistanceType.Energy, 75);//Adjust this to fit your shard.

            SetResistance(ResistanceType.Physical, 80, 85);//Adjust this to fit your shard.
            SetResistance(ResistanceType.Fire, 50, 70);//Adjust this to fit your shard.
            SetResistance(ResistanceType.Cold, 50);//Adjust this to fit your shard.
            SetResistance(ResistanceType.Poison, 90, 100);//Adjust this to fit your shard.
            SetResistance(ResistanceType.Energy, 40);//Adjust this to fit your shard.

            SetSkill(SkillName.Anatomy, 90.1, 100.0);//Adjust this to fit your shard.
            SetSkill(SkillName.EvalInt, 90.1, 100.0);//Adjust this to fit your shard.
            SetSkill(SkillName.Magery, 90.1, 100.0);//Adjust this to fit your shard.
            SetSkill(SkillName.Meditation, 90.1, 100.0);//Adjust this to fit your shard.
            SetSkill(SkillName.MagicResist, 100.0, 150.0);//Adjust this to fit your shard.
            SetSkill(SkillName.Tactics, 90.1, 100.0);//Adjust this to fit your shard.
            SetSkill(SkillName.Swords, 90.1, 100.0);//Adjust this to fit your shard.

            Fame = 8000;//Adjust this to fit your shard.
            Karma = -8000;//Adjust this to fit your shard.

            VirtualArmor = 35;//Adjust this to fit your shard. 

            Shoes Shoes = new Shoes();
            Shoes.Hue = 1150;
            AddItem(Shoes);

            PlainDress PlainDress = new PlainDress();
            PlainDress.Hue = 1150;
            AddItem(PlainDress);

            SkullCap SkullCap = new SkullCap();
            SkullCap.Hue = 1150;
            AddItem(SkullCap);
            
            m_Timer = new TeleportTimer(this);
            m_Timer.Start();
        }
コード例 #3
0
ファイル: Commoner5.cs プロジェクト: Telm/RunUO_EME
        public Commoner5()
            : base(AIType.AI_Melee, FightMode.None, 10, 1, 0.8, 3.0)
        {
            SetStr( 10, 30 );
            SetDex( 10, 30 );
            SetInt( 10, 30 );

            Fame = 50;
            Karma = 50;

            SetSkill( SkillName.Fishing, 60.0, 70.0 );
            SetSkill( SkillName.Cooking, 60.0, 70.0 );

            SpeechHue = Utility.RandomDyedHue();
            Title = string.Empty;//Commoner5.Titles[Utility.Random( 0, Titles.Length )];
            Hue = Utility.RandomSkinHue();
            if ( this.Female = Utility.RandomBool() )
            {
                this.Body = 0x191;
                this.Name = NameList.RandomName( "female" );
                Item hair = new Item( Utility.RandomList( 0x203B, 0x203C, 0x203D, 0x2045, 0x204A, 0x2046 , 0x2049 ) );
                hair.Hue = Utility.RandomHairHue();
                hair.Layer = Layer.Hair;
                hair.Movable = false;
                AddItem( hair );
                Item hat = null;
                switch ( Utility.Random( 5 ) )//4 hats, one empty, for no hat
                {
                    case 0: hat = new FloppyHat( Utility.RandomNeutralHue() );		break;
                    case 1: hat = new FeatheredHat( Utility.RandomNeutralHue() );	break;
                    case 2: hat = new Bonnet();			break;
                    case 3: hat = new Cap( Utility.RandomNeutralHue() );			break;
                }
                AddItem( hat );
                Item pants = null;
                switch ( Utility.Random( 3 ) )
                {
                    case 0: pants = new ShortPants( GetRandomHue() );	break;
                    case 1: pants = new LongPants( GetRandomHue() );	break;
                    case 2: pants = new Skirt( GetRandomHue() );		break;
                }
                AddItem( pants );
                Item shirt = null;
                switch ( Utility.Random( 7 ) )
                {
                    case 0: shirt = new Doublet( GetRandomHue() );		break;
                    case 1: shirt = new Surcoat( GetRandomHue() );		break;
                    case 2: shirt = new Tunic( GetRandomHue() );		break;
                    case 3: shirt = new FancyDress( GetRandomHue() );	break;
                    case 4: shirt = new PlainDress( GetRandomHue() );	break;
                    case 5: shirt = new FancyShirt( GetRandomHue() );	break;
                    case 6: shirt = new Shirt( GetRandomHue() );		break;
                }
                AddItem( shirt );
            }
            else
            {
                this.Body = 0x190;
                this.Name = NameList.RandomName( "male" );
                Item hair = new Item( Utility.RandomList( 0x203B, 0x203C, 0x203D, 0x2044, 0x2045, 0x2047, 0x2048 ) );
                hair.Hue = Utility.RandomHairHue();
                hair.Layer = Layer.Hair;
                hair.Movable = false;
                AddItem( hair );
                Item beard = new Item( Utility.RandomList( 0x0000, 0x203E, 0x203F, 0x2040, 0x2041, 0x2067, 0x2068, 0x2069 ) );
                beard.Hue = hair.Hue;
                beard.Layer = Layer.FacialHair;
                beard.Movable = false;
                AddItem( beard );
                Item hat = null;
                switch ( Utility.Random( 7 ) ) //6 hats, one empty, for no hat
                {
                    case 0: hat = new SkullCap( GetRandomHue() );					break;
                    case 1: hat = new Bandana( GetRandomHue() );					break;
                    case 2: hat = new WideBrimHat();								break;
                    case 3: hat = new TallStrawHat( Utility.RandomNeutralHue() );	break;
                    case 4: hat = new StrawHat( Utility.RandomNeutralHue() );		break;
                    case 5: hat = new TricorneHat( Utility.RandomNeutralHue() );	break;
                }
                AddItem( hat );
                Item pants = null;
                switch ( Utility.Random( 2 ) )
                {
                    case 0: pants = new ShortPants( GetRandomHue() );	break;
                    case 1: pants = new LongPants( GetRandomHue() );	break;
                }
                AddItem( pants );
                Item shirt = null;
                switch ( Utility.Random( 5 ) )
                {
                    case 0: shirt = new Doublet( GetRandomHue() );		break;
                    case 1: shirt = new Surcoat( GetRandomHue() );		break;
                    case 2: shirt = new Tunic( GetRandomHue() );		break;
                    case 3: shirt = new FancyShirt( GetRandomHue() );	break;
                    case 4: shirt = new Shirt( GetRandomHue() );		break;
                }
                AddItem( shirt );
            }

            Item feet = null;
            switch ( Utility.Random( 3 ) )
            {
                case 0: feet = new Boots( Utility.RandomNeutralHue() );	break;
                case 1: feet = new Shoes( Utility.RandomNeutralHue() );	break;
                case 2: feet = new Sandals( Utility.RandomNeutralHue() );		break;
            }
            AddItem( feet );
            Container pack = new Backpack();

            pack.DropItem( new Gold( 0, 50 ) );

            pack.Movable = false;

            AddItem( pack );
        }
コード例 #4
0
ファイル: Rackham.cs プロジェクト: FreeReign/imaginenation
		public Rackham() : base( AIType.AI_Melee, FightMode.Closest, 10, 1, 0.2, 0.4 )
		{
			Name = "Rackham";
                        Title = "the Bloody Pirate";
			Body = 0x190;
			Hue = Utility.RandomSkinHue();
			
			ThighBoots tb = new ThighBoots();
                        tb.Hue = 0;
                        AddItem( tb );

                        LongPants lp = new LongPants();
                        lp.Hue = 633;
                        AddItem( lp );

		        FancyShirt fs = new FancyShirt();
                        fs.Hue = 907;
                        AddItem( fs );

			SkullCap sk = new SkullCap();
                        sk.Hue = 413;
                        AddItem( sk );

			BodySash bs = new BodySash();
			bs.Hue = 633;
			AddItem( bs );

			Cloak cl = new Cloak();
			cl.Hue = 688;
			AddItem( cl );

	                Scimitar sc = new Scimitar();
			sc.Hue = 533;
                        AddItem( sc );

			GoldBeadNecklace gn = new GoldBeadNecklace();
			AddItem( gn );

			GoldBracelet gb = new GoldBracelet();
			AddItem( gb );

			GoldEarrings ge = new GoldEarrings();
			AddItem( ge );

			GoldRing gr = new GoldRing();
			AddItem( gr );			
                        
                        AddItem( new PonyTail(1149));
                     
			AddItem( new Vandyke(1149));
			
			SetStr( 120, 140 );
			SetDex( 90, 105 );
			SetInt( 25, 40 );

			SetHits( 450, 500 );
			SetMana( 0 );

			SetDamage( 20, 28 );

			SetDamageType( ResistanceType.Physical, 100 );

			SetResistance( ResistanceType.Physical, 56, 67 );
			SetResistance( ResistanceType.Fire, 40, 50 );
			SetResistance( ResistanceType.Poison, 40, 50 );
			SetResistance( ResistanceType.Cold, 40, 45 );
			SetResistance( ResistanceType.Energy, 40, 55 );

			SetSkill( SkillName.MagicResist, 55.1, 65.0 );
			SetSkill( SkillName.Tactics, 85.3, 105.0 );
			SetSkill( SkillName.Wrestling, 90.3, 105.0 );
			SetSkill( SkillName.Swords, 90.3, 105.0 );

			Fame = 9900;
			Karma = -9900;

			VirtualArmor = 25;
					
                        PackItem( new SeafaringBracelet() );
			PackItem( new TreasureMap( 1, Map.Felucca ) ); 
		}
コード例 #5
0
ファイル: Fishing.cs プロジェクト: Crome696/ServUO
        public override Item Construct(Type type, Mobile from, Item tool)
        {
            // Searing Weapon Support
            if (type == typeof(BaseWeapon))
                return null;

            if (type == typeof(TreasureMap))
            {
                int level;
                if (from is PlayerMobile && ((PlayerMobile)from).Young && from.Map == Map.Trammel && TreasureMap.IsInHavenIsland(from))
                    level = 0;
                else
                    level = 1;

                return new TreasureMap(level, from.Map == Map.Felucca ? Map.Felucca : Map.Trammel);
            }
            else if (type == typeof(MessageInABottle))
            {
                return new MessageInABottle(from.Map == Map.Felucca ? Map.Felucca : Map.Trammel);
            }
            else if (type == typeof(WhitePearl))
            {
                return new WhitePearl();
            }

            Container pack = from.Backpack;

            if (pack != null)
            {
                List<SOS> messages = pack.FindItemsByType<SOS>();

                for (int i = 0; i < messages.Count; ++i)
                {
                    SOS sos = messages[i];

                    if ((from.Map == Map.Felucca || from.Map == Map.Trammel) && from.InRange(sos.TargetLocation, 60))
                    {
                        Item preLoot = null;
                        bool dredge = HasTypeHook(tool, HookType.Dredging);

                        switch (Utility.Random(Core.HS ? 17 : 16))
                        {
                            case 0: // Body parts
                            case 1:
                                {
                                    int[] list = new int[]
                                    {
                                        0x1CDD, 0x1CE5, // arm
                                        0x1CE0, 0x1CE8, // torso
                                        0x1CE1, 0x1CE9, // head
                                        0x1CE2, 0x1CEC // leg
                                    };

                                    preLoot = new ShipwreckedItem(Utility.RandomList(list), dredge);
                                    break;
                                }
                            case 2: // Bone parts
                            case 3:
                                {
                                    int[] list = new int[]
                                    {
                                        0x1AE0, 0x1AE1, 0x1AE2, 0x1AE3, 0x1AE4, // skulls
                                        0x1B09, 0x1B0A, 0x1B0B, 0x1B0C, 0x1B0D, 0x1B0E, 0x1B0F, 0x1B10, // bone piles
                                        0x1B15, 0x1B16 // pelvis bones
                                    };

                                    preLoot = new ShipwreckedItem(Utility.RandomList(list), dredge);
                                    break;
                                }
                            case 4: // Paintings and portraits
                            case 5:
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0xE9F, 10), dredge);
                                    break;
                                }
                            case 6: // Pillows
                            case 7:
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0x13A4, 11), dredge);
                                    break;
                                }
                            case 8: // Shells
                            case 9:
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0xFC4, 9), dredge);
                                    break;
                                }
                            case 10: //Hats
                            case 11:
                                {
                                    if (Utility.RandomBool())
                                        preLoot = new SkullCap();
                                    else
                                        preLoot = new TricorneHat();

                                    break;
                                }
                            case 12: // Misc
                            case 13:
                                {
                                    int[] list = new int[]
                                    {
                                        0x1EB5, // unfinished barrel
                                        0xA2A, // stool
                                        0xC1F, // broken clock
                                        0x1047, 0x1048, // globe
                                        0x1EB1, 0x1EB2, 0x1EB3, 0x1EB4 // barrel staves
                                    };

                                    if (Utility.Random(list.Length + 1) == 0)
                                        preLoot = new Candelabra();
                                    else
                                        preLoot = new ShipwreckedItem(Utility.RandomList(list), dredge);

                                    break;
                                }
                            #region High Seas
                            case 14:
                                {
                                    int[] list = new int[]
                                    {
                                        0x1E19, 0x1E1A, 0x1E1B, //Fish heads
                                        0x1E2A, 0x1E2B,         //Ores
                                        0x1E71, 0x1E7A,         //Unfinished drawers
                                        0x1E75,                 //Unfinished legs
                                    };

                                    double ran = Utility.RandomDouble();

                                    if (ran < 0.05)
                                        preLoot = new YellowPolkaDotBikini();
                                    else if (ran < 0.25)
                                        preLoot = new ShipwreckedItem(list[Utility.RandomMinMax(3, 7)], dredge);
                                    else
                                        preLoot = new Item(list[Utility.Random(3)]);
                                    break;
                                }
                            #endregion
                        }

                        if (preLoot != null)
                        {
                            if (preLoot is IShipwreckedItem)
                                ((IShipwreckedItem)preLoot).IsShipwreckedItem = true;

                            return preLoot;
                        }

                        LockableContainer chest;
						
                        if (Utility.RandomBool())
                            chest = new MetalGoldenChest();
                        else
                            chest = new WoodenChest();

                        if (sos.IsAncient)
                            chest.Hue = 0x481;

                        TreasureMapChest.Fill(chest, from.Luck, Math.Max(1, Math.Min(4, sos.Level)), true, from.Map);

                        if (sos.IsAncient)
                            chest.DropItem(new FabledFishingNet());
                        else
                            chest.DropItem(new SpecialFishingNet());

                        chest.Movable = true;
                        chest.Locked = false;
                        chest.TrapType = TrapType.None;
                        chest.TrapPower = 0;
                        chest.TrapLevel = 0;

                        sos.Delete();

                        return chest;
                    }
                }
            }

            return base.Construct(type, from, tool);
        }
コード例 #6
0
ファイル: Loot.cs プロジェクト: zerodowned/angelisland
        public static Item RandomIOB()
        {
            switch (Utility.Random(7))
            {
                case 0: // Undead - GUL
                    {
                        if (Utility.RandomBool())
                            return new BloodDrenchedBandana();
                        else
                        {
                            BodySash sash = new BodySash();
                            sash.Hue = 0x66C;
                            sash.IOBAlignment = IOBAlignment.Council;
                            sash.Name = "blood drenched sash";
                            sash.Dyable = false;
							sash.Scissorable = false;
                            return sash;
                        }
                    }
                case 1: // Undead - UND
                {
                    Sandals sandals = new Sandals();
                    if (Utility.RandomBool())
                        sandals.Hue = 0x66C;
                    else
                        sandals.Hue = 0x1;
                    sandals.IOBAlignment = IOBAlignment.Undead;
                    sandals.Name = "sandals of the walking dead";
                    sandals.Dyable = false;
					sandals.Scissorable = false;
                    return sandals;


                }
                case 2: // Orcish
                {
                    if (Utility.RandomBool())
                    {	// green mask (brute color)
						if (Utility.RandomBool())
							return new OrcishKinMask();
						else
						{	// old style mask (orc colored)
							OrcishKinMask mask = new OrcishKinMask();
							mask.Hue = 0;
							return mask;
						}

                    }
                    else
                    {
                        return new OrcishKinHelm();

                    }
                }
                case 3: //Savage
                {
                    if (Utility.RandomBool())
                    {
                        if (Utility.RandomBool())
                            {
                                BearMask mask = new BearMask();
                                mask.IOBAlignment = IOBAlignment.Savage;
                                mask.Name = "bear mask of savage kin";
                                mask.Dyable = false;
                                return mask;
                            }
                        else
                            {
                                DeerMask mask = new DeerMask();
                                mask.IOBAlignment = IOBAlignment.Savage;
                                mask.Name = "deer mask of savage kin";
                                mask.Dyable = false;
                                return mask;
                            }
                    }
                    else
                        {
                            SavageMask mask = new SavageMask();
                            mask.IOBAlignment = IOBAlignment.Savage;
                            mask.Name = "tribal mask of savage kin";
                            mask.Dyable = false;
                            return mask;
                        }
                }
                case 4: // Pirates
                {
                        if (Utility.RandomBool())
                        {
                            if (Utility.RandomBool())
                            {
                                SkullCap skullcap = new SkullCap();
                                skullcap.IOBAlignment = IOBAlignment.Pirate;
                                skullcap.Name = "a pirate skullcap";
                                skullcap.Hue = 0x66C;
                                skullcap.Dyable = false;
								skullcap.Scissorable = false;
                                return skullcap;
                            }
                            else
                            {
                                Boots boots = new Boots();
                                boots.IOBAlignment = IOBAlignment.Pirate;
                                boots.Name = "pirate kin boots";
                                boots.Hue = 0x66c;
                                boots.Dyable = false;
								boots.Scissorable = false;
                                return boots;
                            }
                        }
                        else
                        {
                            return new PirateHat();
                        }

                }
                case 5: // Brigands
                {
                        if (Utility.RandomBool())
                        {
                            return new BrigandKinBandana();
                        }
                        else
                        {
                            return new BrigandKinBoots();
                        }
                }
				case 6: // Good
				{
					switch ( Utility.Random( 4 ))
					{
						case 0: 
							Boots boots = new Boots(0x5E4);
							boots.IOBAlignment = IOBAlignment.Good;
							boots.Name = "Britannian Militia";
							boots.Dyable = false;
							return boots;
						case 1: Cloak cloak = new Cloak(Utility.RandomSpecialVioletHue());
							cloak.IOBAlignment = IOBAlignment.Good;
							cloak.Name = "Britannian Militia";
							cloak.Dyable = false;
							cloak.Scissorable = false;
							return cloak;
						case 2: Surcoat surcoat = new Surcoat(Utility.RandomSpecialVioletHue());
							surcoat.IOBAlignment = IOBAlignment.Good;
							surcoat.Name = "Britannian Militia";
							surcoat.Dyable = false;
							surcoat.Scissorable = false;
							return surcoat;
						case 3: BodySash bodySash = new BodySash(Utility.RandomSpecialRedHue());
							bodySash.IOBAlignment = IOBAlignment.Good;
							bodySash.Name = "Britannian Militia";
							bodySash.Dyable = false;
							bodySash.Scissorable = false;
							return bodySash;
					}
					break;
				}
            }
            return null;

        }
コード例 #7
0
ファイル: Pirate.cs プロジェクト: FreeReign/Rebirth-Repack
        public Pirate()
            : base(AIType.AI_Melee, FightMode.Agressor, 10, 1, 0.45, 0.8)
        {
            Female = Utility.RandomBool();
            Body = Female ? 401 : 400;
            Title = "the pirate";
            Name = NameList.RandomName( Female ? "female" : "male" );
            Hue = Utility.RandomSkinHue();
            SetStr( 86, 100 );
            SetDex( 86, 100 );
            SetInt( 71, 85 );
            Karma = 2;

            SetSkill( SkillName.Tactics, 65, 87.5 );
            SetSkill( SkillName.MagicResist, 65, 87.5 );
            SetSkill( SkillName.Parry, 65, 87.5 );
            SetSkill( SkillName.Swords, 55, 77.5 );
            SetSkill( SkillName.Macing, 25, 47.5 );
            SetSkill( SkillName.Fencing, 25, 47.5 );
            SetSkill( SkillName.Wrestling, 45, 67.5 );

            Item item = null;
            if ( !Female )
            {
                item = AddRandomHair();
                item.Hue = Utility.RandomHairHue();
                item = AddRandomFacialHair( item.Hue );
                item = new Shirt();
                item.Hue = Utility.RandomNondyedHue();
                AddItem( item );
                item = new ShortPants();
                item.Hue = Utility.RandomNondyedHue();
                AddItem( item );
                item = new Cutlass();
                AddItem( item );
                if ( Utility.RandomBool() )
                {
                    item = new Bandana();
                }
                else
                {
                    item = new SkullCap();
                }
                item.Hue = Utility.RandomRedHue();
                AddItem( item );
                item = new ThighBoots();
                item.Hue = Utility.RandomNeutralHue();
                AddItem( item );
                PackGold( 15, 100 );
            } else {
                item = AddRandomHair();
                item.Hue = Utility.RandomHairHue();
                item = new Shirt();
                item.Hue = Utility.RandomNondyedHue();
                AddItem( item );
                item = new ShortPants();
                item.Hue = Utility.RandomNondyedHue();
                AddItem( item );
                item = new Cutlass();
                AddItem( item );
                if ( Utility.RandomBool() )
                {
                    item = new Bandana();
                }
                else
                {
                    item = new SkullCap();
                }
                item.Hue = Utility.RandomRedHue();
                AddItem( item );
                item = new ThighBoots();
                item.Hue = Utility.RandomNeutralHue();
                AddItem( item );
                PackGold( 15, 100 );
            }
        }
コード例 #8
0
		public DummyNox() : base(AIType.AI_Mage, FightMode.Closest, 15, 1, 0.2, 0.6)
		{

			// A Dummy Nox or Pure Mage
			int iHue = 20 + Team * 40;
			int jHue = 25 + Team * 40;

			// Skills and Stats
			this.InitStats( 90, 90, 125 );
			this.Skills[SkillName.Magery].Base = 120;
			this.Skills[SkillName.EvalInt].Base = 120;
			this.Skills[SkillName.Inscribe].Base = 100;
			this.Skills[SkillName.Wrestling].Base = 120;
			this.Skills[SkillName.Meditation].Base = 120;
			this.Skills[SkillName.Poisoning].Base = 100;


			// Name
			this.Name = "Nox Mage";

			// Equip
			Spellbook book = new Spellbook();
			book.Movable = false;
			book.LootType = LootType.Newbied;
			book.Content =0xFFFFFFFFFFFFFFFF;
			AddItem( book );

			Kilt kilt = new Kilt();
			kilt.Hue = jHue;
			AddItem( kilt );

			Sandals snd = new Sandals();
			snd.Hue = iHue;
			snd.LootType = LootType.Newbied;
			AddItem( snd );

			SkullCap skc = new SkullCap();
			skc.Hue = iHue;
			AddItem( skc );

			// Spells
			AddSpellAttack( typeof(Spells.First.MagicArrowSpell) );
			AddSpellAttack( typeof(Spells.First.WeakenSpell) );
			AddSpellAttack( typeof(Spells.Third.FireballSpell) );
			AddSpellDefense( typeof(Spells.Third.WallOfStoneSpell) );
			AddSpellDefense( typeof(Spells.First.HealSpell) );
		}
コード例 #9
0
ファイル: LockeCole.cs プロジェクト: greeduomacro/UO-Forever
        public LockeCole()
            : base(AIType.AI_Arcade, FightMode.Closest, 10, 1, 0.2, 0.4)
        {
            Name = "Locke Cole";
            Body = 400;
            Hue = 1162;
            SpecialTitle = "Undead Treasure Hunter";
            TitleHue = 1174;

            BaseSoundID = 362;

            SetStr(500);
            SetDex(400);
            SetInt(100);

            SetHits(400000);

            SetDamage(2, 4);

            foreach (SkillName skill in _Skills)
            {
                SetSkill(skill, 80.0, 140.0);
            }

            SpeechHue = YellHue = 34;

            VirtualArmor = 90;

            PackGold(3000, 3500);
            PackMagicItems(5, 5, 0.95, 0.95);
            PackMagicItems(5, 5, 0.80, 0.65);
            PackMagicItems(5, 5, 0.80, 0.65);
            PackMagicItems(6, 6, 0.80, 0.65);

            Damagers = new Dictionary<PlayerMobile, int>();

            var helm = new SkullCap();
            helm.Name = "Locke's Bandana";
            helm.Hue = 4;
            helm.Identified = true;
            AddItem(Immovable(helm));

            var arms = new JinBaori();
            arms.Name = "Locke's Jacket";
            arms.Hue = 4;
            arms.Identified = true;
            AddItem(Immovable(arms));

            var gloves = new LeatherGloves();
            gloves.Name = "Locke's Gloves";
            gloves.Hue = 4;
            gloves.Identified = true;
            AddItem(Immovable(gloves));

            var tunic = new Shirt();
            tunic.Name = "Locke's Shirt";
            tunic.Hue = 0;
            tunic.Identified = true;
            AddItem(Immovable(tunic));

            var legs = new LeatherNinjaPants();
            legs.Name = "Locke's Pants";
            legs.Hue = 4;
            legs.Identified = true;
            AddItem(Immovable(legs));

            var boots = new ElvenBoots();
            boots.Name = "Locke's Boots";
            boots.Hue = 1175;
            boots.Identified = true;
            AddItem(Immovable(boots));

            var spellbook = new Dagger();
            spellbook.Name = "Thief Dagger";
            spellbook.Hue = 0;
            spellbook.Movable = false;
            AddItem(Immovable(spellbook));
        }
コード例 #10
0
        public LockeColeMirrorImagePortal()
            : base(AIType.AI_Arcade, FightMode.Closest, 10, 1, 0.2, 0.4)
        {
            Name = "Locke Cole";
            Body = 400;
            Hue = 1162;
            SpecialTitle = "Mirror Image";
            TitleHue = 1174;

            BaseSoundID = 362;

            SetStr(10, 10);
            SetDex(200);
            SetInt(706, 726);

            SetHits(2000);

            SetDamage(1, 1);

            foreach (SkillName skill in _Skills)
            {
                SetSkill(skill, 65.0, 70.0);
            }

            SpeechHue = YellHue = 34;

            VirtualArmor = 90;

            PackGold(500, 1000);
            PackMagicItems(5, 5, 0.95, 0.95);

            var helm = new SkullCap();
            helm.Name = "Locke's Bandana";
            helm.Hue = 4;
            helm.Identified = true;
            AddItem(Immovable(helm));

            var arms = new JinBaori();
            arms.Name = "Locke's Jacket";
            arms.Hue = 4;
            arms.Identified = true;
            AddItem(Immovable(arms));

            var gloves = new LeatherGloves();
            gloves.Name = "Locke's Gloves";
            gloves.Hue = 4;
            gloves.Identified = true;
            AddItem(Immovable(gloves));

            var tunic = new Shirt();
            tunic.Name = "Locke's Shirt";
            tunic.Hue = 0;
            tunic.Identified = true;
            AddItem(Immovable(tunic));

            var legs = new LeatherNinjaPants();
            legs.Name = "Locke's Pants";
            legs.Hue = 4;
            legs.Identified = true;
            AddItem(Immovable(legs));

            var boots = new ElvenBoots();
            boots.Name = "Locke's Boots";
            boots.Hue = 1175;
            boots.Identified = true;
            AddItem(Immovable(boots));

            var spellbook = new Dagger();
            spellbook.Name = "Thief Dagger";
            spellbook.Hue = 0;
            spellbook.Movable = false;
            AddItem(Immovable(spellbook));
        }
コード例 #11
0
		public override void OnResponse( NetState state, RelayInfo info )
		{
			Mobile from = state.Mobile;
			PlayerMobile player = from as PlayerMobile;

			switch( info.ButtonID )
			{
				case 0:
				{
                                        player.Profession = 3;
                                        player.Level = 1;
                                        player.Exp = 0;
                                        player.KillExp = 0;
                                        player.LevelAt = 200;

                                        from.BankBox.DropItem( new BankCheck( 500 ) );

                                        from.Str += 25;
                                        from.Dex += 20;
                                        from.Int += 5;

                                        from.Skills.ArmsLore.Base = 10;
                                        from.Skills.Blacksmith.Base = 50;
                                        from.Skills.Carpentry.Base = 25;
                                        from.Skills.Cooking.Base = 25;
                                        from.Skills.Fletching.Base = 25;
                                        from.Skills.Mining.Base = 50;
                                        from.Skills.Tailoring.Base = 25;
                                        from.Skills.Tinkering.Base = 25;

			                SkullCap hat = new SkullCap();
			                hat.Hue = 0;
			                hat.Identified = true;
			                from.AddToBackpack( hat );

			                FormalShirt shirt = new FormalShirt();
			                shirt.Hue = 0;
			                shirt.Identified = true;
			                from.AddToBackpack( shirt );

			                ShortPants pants = new ShortPants();
			                pants.Hue = 0;
			                pants.Identified = true;
			                from.AddToBackpack( pants );

			                HeavyBoots boots = new HeavyBoots();
			                boots.Hue = 0;
			                boots.Identified = true;
			                from.AddToBackpack( boots );

			                HalfApron apron = new HalfApron();
			                apron.Hue = 0;
			                apron.Identified = true;
			                from.AddToBackpack( apron );

			                FurCape cloak = new FurCape();
			                cloak.Hue = 0;
			                cloak.Identified = true;
			                from.AddToBackpack( cloak );

                                        from.AddToBackpack( new CrafterSkillGuide() );
                                        from.BankBox.DropItem( new BagOfComponents() );
                                        from.BankBox.DropItem( new BagOfTools() );
                                        from.BankBox.DropItem( new IronIngot( 200 ) );
                                        from.BankBox.DropItem( new MinersIngotPouch() );

		                        from.Map = Map.Malas;
                                        from.Location = new Point3D( 1670, 2008, 1 );
		                        from.PlaySound( 0x214 );
		                        from.FixedEffect( 0x376A, 10, 16 );

                                        World.Broadcast( 0x35, true, "Another has chosen thy path of the Crafter!" );
					from.CloseGump( typeof( CrafterClassGump ) );

					break;
				}
				case 1:
				{
					from.SendMessage( "You decide that the way of the Crafter is not in your best interests." );
					from.CloseGump( typeof( CrafterClassGump ) );

					break;
				}
			}
		}
コード例 #12
0
ファイル: Fishing.cs プロジェクト: greeduomacro/UO-Forever
		public override Item Construct(Type type, Mobile from)
		{
			if (type == typeof(TreasureMap))
			{
				int level;
				//if ( from is PlayerMobile && ((PlayerMobile)from).Young && from.Map == Map.Trammel && TreasureMap.IsInHavenIsland( from ) )
				//	level = 0;
				//else
				level = 1;

				return new TreasureMap(level, Map.Felucca);
			}
			else if (type == typeof(MessageInABottle))
			{
				return new MessageInABottle( /*from.Map == Map.Felucca ?*/ Map.Felucca /* : Map.Trammel*/);
			}

			Container pack = from.Backpack;

			if (pack != null)
			{
				List<SOS> messages = pack.FindItemsByType<SOS>();

				for (int i = 0; i < messages.Count; ++i)
				{
					SOS sos = messages[i];

					if (from.Map == sos.TargetMap &&
						from.InRange(sos.TargetLocation, (int)(from.Skills[SkillName.Fishing].Value - 75.0)))
					{
						Item preLoot = null;

						switch (Utility.Random(8))
						{
							case 0: // Body parts
								{
									var list = new[]
									{
										0x1CDD, 0x1CE5, // arm
										0x1CE0, 0x1CE8, // torso
										0x1CE1, 0x1CE9, // head
										0x1CE2, 0x1CEC // leg
									};

									preLoot = new ShipwreckedItem(Utility.RandomList(list));
									break;
								}
							case 1: // Bone parts
								{
									var list = new[]
									{
										0x1AE0, 0x1AE1, 0x1AE2, 0x1AE3, 0x1AE4, // skulls
										0x1B09, 0x1B0A, 0x1B0B, 0x1B0C, 0x1B0D, 0x1B0E, 0x1B0F, 0x1B10, // bone piles
										0x1B15, 0x1B16 // pelvis bones
									};

									preLoot = new ShipwreckedItem(Utility.RandomList(list));
									break;
								}
							case 2: // Paintings and portraits
								{
									preLoot = new ShipwreckedItem(Utility.Random(0xE9F, 10));
									break;
								}
							case 3: // Pillows
								{
									preLoot = new ShipwreckedItem(Utility.Random(0x13A4, 11));
									break;
								}
							case 4: // Shells
								{
									preLoot = new ShipwreckedItem(Utility.Random(0xFC4, 9));
									break;
								}
							case 5: //Hats
								{
									if (Utility.RandomBool())
									{
										preLoot = new SkullCap();
									}
									else
									{
										preLoot = new TricorneHat();
									}

									break;
								}
							case 6: // Misc
								{
									var list = new[]
									{
										0x1EB5, // unfinished barrel
										0xA2A, // stool
										0xC1F, // broken clock
										0x1047, 0x1048, // globe
										0x1EB1, 0x1EB2, 0x1EB3, 0x1EB4 // barrel staves
									};

									if (Utility.Random(list.Length + 1) == 0)
									{
										preLoot = new Candelabra();
									}
									else
									{
										preLoot = new ShipwreckedItem(Utility.RandomList(list));
									}

									break;
								}
						}

						if (preLoot != null)
						{
							if (preLoot is IShipwreckedItem)
							{
								((IShipwreckedItem)preLoot).IsShipwreckedItem = true;
							}

							return preLoot;
						}

						LockableContainer chest = null;

						switch (Utility.Random(3))
						{
							case 0:
								chest = new MetalGoldenChest();
								break;
							case 1:
								chest = new MetalChest();
								break;
							default:
							case 2:
								chest = new WoodenChest();
								break;
						}
						chest.Breakable = false;
						chest.Locked = false;

						if (sos.IsAncient)
						{
							int hue = 1150;

							if (0.20 > Utility.RandomDouble())
							{
								switch (Utility.Random((chest is WoodenChest) ? 6 : 14))
								{
									case 0:
										hue = 1193;
										break;
									case 1:
										hue = 1281;
										break;
									case 2:
										hue = 1190;
										break;
									case 3:
										hue = 1165;
										break;
									case 4:
										hue = 1160;
										break;
									case 5:
										hue = 1126;
										break;
									case 6:
										hue = CraftResources.GetInfo(CraftResource.Valorite).Hue;
										break;
									case 7:
										hue = CraftResources.GetInfo(CraftResource.Verite).Hue;
										break;
									case 8:
										hue = CraftResources.GetInfo(CraftResource.Agapite).Hue;
										break;
									case 9:
										hue = CraftResources.GetInfo(CraftResource.Gold).Hue;
										break;
									case 10:
										hue = CraftResources.GetInfo(CraftResource.Bronze).Hue;
										break;
									case 11:
										hue = CraftResources.GetInfo(CraftResource.Copper).Hue;
										break;
									case 12:
										hue = CraftResources.GetInfo(CraftResource.ShadowIron).Hue;
										break;
									case 13:
										hue = CraftResources.GetInfo(CraftResource.DullCopper).Hue;
										break;
								}
							}

							chest.Hue = hue;
						}
						else if ((chest is MetalChest || chest is MetalGoldenChest) && (0.5 * sos.Level) >= Utility.RandomDouble())
						{
							int randhue = Utility.Random(120);
							var resource = CraftResource.None;

							if (randhue >= 118)
							{
								resource = CraftResource.Valorite;
							}
							else if (randhue >= 115)
							{
								resource = CraftResource.Verite;
							}
							else if (randhue >= 110)
							{
								resource = CraftResource.Agapite;
							}
							else if (randhue >= 100)
							{
								resource = CraftResource.Gold;
							}
							else if (randhue >= 90)
							{
								resource = CraftResource.Bronze;
							}
							else if (randhue >= 70)
							{
								resource = CraftResource.Copper;
							}
							else if (randhue >= 40)
							{
								resource = CraftResource.ShadowIron;
							}
							else
							{
								resource = CraftResource.DullCopper;
							}

							chest.Hue = CraftResources.GetInfo(resource).Hue;
						}

						int soslevel = sos.Level;

						TreasureMapChest.Fill(chest, soslevel, from.Expansion);

						if (!sos.IsAncient)
						{
							chest.Locked = false;
						}

						double chance = Utility.RandomDouble();
						BaseCreature mibmonster1;
						BaseCreature mibmonster2;
						mibmonster1 = new DeepWaterElemental();
						if (chance <= 0.02 && from.Skills[SkillName.Fishing].Base >= 115)
						{
							mibmonster2 = new Osiredon();
							int choice = Utility.Random(5);
							switch (choice)
							{
								case 4:
									mibmonster2.PackItem(new SmallFishingNetDeed());
									break;
								case 3:
									mibmonster2.PackItem(new LargeFishingNetDeed());
									break;
								case 2:
									mibmonster2.PackItem(new Shell());
									break;
								case 1:
									mibmonster2.PackItem(new Anchor());
									break;
								case 0:
									mibmonster2.PackItem(new Hook());
									break;
							}
						}
						else if (soslevel < 5)
						{
							mibmonster2 = new WaterElemental();
						}
						else
						{
							mibmonster2 = new DeepWaterElemental();
						}
						int x = from.X, y = from.Y;

						Map map = from.Map;

						mibmonster1.MoveToWorld(new Point3D(x, y, -5), map);
						mibmonster2.MoveToWorld(new Point3D(x, y, -5), map);

						mibmonster1.Home = mibmonster1.Location;
						mibmonster1.HomeMap = mibmonster1.Map;
						mibmonster1.RangeHome = 10;

						mibmonster2.Home = mibmonster2.Location;
						mibmonster2.HomeMap = mibmonster2.Map;
						mibmonster2.RangeHome = 10;

						if (sos.IsAncient)
						{
							chest.DropItem(new FabledFishingNet());
						}
						else
						{
							chest.DropItem(new SpecialFishingNet());
						}

						chest.Movable = true;
						chest.Name = "treasure chest";
						chest.IsShipwreckedItem = true;

						if (sos.Level > 0)
						{
							chest.TrapType = TrapType.ExplosionTrap;
							chest.TrapPower = soslevel * Utility.RandomMinMax(9, 19);
							chest.TrapLevel = 0;
						}
						else
						{
							chest.TrapType = TrapType.None;
							chest.TrapPower = 1;
							chest.TrapLevel = 1;
						}

						sos.Delete();

						return chest;
					}
				}
			}

			return base.Construct(type, from);
		}
コード例 #13
0
        public FamousPiratesNox()
            : base(AIType.AI_Mage, FightMode.Closest, 15, 1, 0.2, 0.6)
        {
            // A FamousPirates Nox or Pure Mage
            int Hue = 2075;

            // Skills and Stats
            this.InitStats(210, 210, 250);
            this.Skills[SkillName.Magery].Base = 150;
            this.Skills[SkillName.EvalInt].Base = 150;
            this.Skills[SkillName.Inscribe].Base = 100;
            this.Skills[SkillName.Wrestling].Base = 150;
            this.Skills[SkillName.Meditation].Base = 150;
            this.Skills[SkillName.Poisoning].Base = 100;


            // Name
            this.Name = "Davy Jones";

            // Equip
            Spellbook book = FullSpellbook();
            AddItem(book);

            Kilt kilt = new Kilt();
			kilt.Movable = false;
            kilt.Hue = Hue;
            AddItem(kilt);

            Boots snd = new Boots();
			snd.Movable = false;
            snd.Hue = Hue;
            snd.LootType = LootType.Regular;
            AddItem(snd);

            SkullCap skc = new SkullCap();
			skc.Movable = false;
            skc.Hue = Hue;
            AddItem(skc);

            // Spells
            AddSpellAttack(typeof(Spells.First.MagicArrowSpell));
            AddSpellAttack(typeof(Spells.First.WeakenSpell));
            AddSpellAttack(typeof(Spells.Sixth.ExplosionSpell));
            AddSpellDefense(typeof(Spells.Third.WallOfStoneSpell));
            AddSpellDefense(typeof(Spells.Fourth.GreaterHealSpell));
        }
コード例 #14
0
        public UndeadSwordPirateSTR()
            : base(AIType.AI_Melee, FightMode.Closest, 10, 1, 0.175, 0.2)
        {
            Title = "the unrested pirate";
            Body = 400;
            Team = 1;
            Kills = 10;
            Hue = Utility.RandomSkinHue();
            SpeechHue=1153;
            this.Body = 0x190;
            this.Name = NameList.RandomName( "male" );
                    SetStr( 90, 100 );
            SetDex( 85, 100 );
            SetInt( 10, 20 );

            SetSkill( SkillName.Archery, 95.0, 100.0 );
            SetSkill( SkillName.MagicResist, 75.0, 100.0 );
            SetSkill( SkillName.Tactics, 90.0, 100.0 );
            SetSkill( SkillName.Healing, 75.0, 100.0 );
            SetSkill( SkillName.Anatomy, 90.0, 100.0 );
            SetSkill(SkillName.Swords, 95.0, 100.0);
            SetSkill(SkillName.Stealth, 120.0, 180.0);
            SetSkill(SkillName.Hiding, 120.0, 180.0);

            Fame = 4500;
            Karma = -4500;

            VirtualArmor = 0;

            Item hair = new Item( Utility.RandomList( 0x203B, 0x2049, 0x2048, 0x204A ) );
            hair.Hue = Utility.RandomHairHue();
            hair.Layer = Layer.Hair;
            hair.Movable = false;

            Item beard = new Item( Utility.RandomList( 0x2040, 0x203E , 0x204C, 0x204B, 0x203F ) );
            beard.Hue = hair.Hue;
            beard.Layer = Layer.FacialHair;
            beard.Movable = false;
            AddItem( beard );

            AddItem( hair );
            PackGold( 70, 95 );
            PackItem( new Bandage( 20 ) );

            switch ( Utility.Random( 2 ) )
            {
                case 0:
                {
                Item scimitar = new Scimitar();
                EquipItem( scimitar );
                break;
                }
                case 1:
                {
                Item cutlass = new Cutlass();
                EquipItem( cutlass );
                break;
                }
            }

            switch ( Utility.Random( 3 ) )
            {
                case 0:
                {
                Item fancyshirt = new FancyShirt();
                fancyshirt.Hue = Utility.RandomNeutralHue();
                EquipItem( fancyshirt );
                break;
                }
                case 1:
                {
                Item doublet = new Doublet();
                doublet.Hue = Utility.RandomNeutralHue();
                EquipItem( doublet );
                break;
                }
                case 2:
                {
                break;
                }
            }

            switch ( Utility.Random( 2 ) )
            {
                case 0:
                {
                Item longpants = new LongPants();
                longpants.Hue = Utility.RandomNeutralHue();
                EquipItem( longpants );
                break;
                }
                case 1:
                {
                Item shortpants = new ShortPants();
                shortpants.Hue = Utility.RandomNeutralHue();
                EquipItem( shortpants );
                break;
                }
            }

                    switch ( Utility.Random( 4 ) )
            {
               			case 0:
                {
                Item boots = new Boots();
                boots.Hue = 0;
                EquipItem( boots );
                break;
                }
                case 1:
                {
                Item shoes = new Shoes();
                shoes.Hue = 1713;
                EquipItem( shoes );
                break;
                }
                case 3:
                {
                Item thighboots = new ThighBoots();
                thighboots.Hue = 0;
                EquipItem( thighboots );
                break;
                }
                case 4:
                {
                break;
                }
                 }

                    switch ( Utility.Random( 3 ) )
                 {
               			case 0:
                {
                Item Bandana = new Bandana();
                Bandana.Hue = Utility.RandomBirdHue();
                EquipItem( Bandana );
                break;
                }
                case 1:
                {
                Item skullcap = new SkullCap();
                skullcap.Hue = Utility.RandomBirdHue();
                EquipItem( skullcap );
                break;
                }
                case 3:
                {
                break;
                }
                 }
        }
コード例 #15
0
        /// <summary>
        /// This is the function gives weaponry to players.
        /// </summary>
        private static void ArmPlayer(CTFPlayerGameData pgd)
        {
            Mobile m = pgd.Mob;

            if (!m.Alive)
                m.Resurrect();

            for (int i = m.Items.Count - 1; i >= 0; --i)
            {
                Item item = (Item)m.Items[i];
                if (item.Layer == Layer.OuterTorso)
                {
                    item.Delete();
                    break;
                }
            }

            List<Item> armthis = new List<Item>();

            if(GiveRobe)
                armthis.Add(new CTFRobe(pgd.Team));

            Item rankedCloth = null;
            CTFTeam team = pgd.Team;

            // 21 Ranks
            switch (CTFData.GetRank(m))
            {
                default:
                case 0: rankedCloth = new JesterHat(team.Hue); break;
                case 1: rankedCloth = new TallStrawHat(team.Hue); break;
                case 2: rankedCloth = new FloppyHat(team.Hue); break;
                case 3: rankedCloth = new WideBrimHat(team.Hue); break;
                case 4: rankedCloth = new Cap(team.Hue); break;
                case 5: rankedCloth = new SkullCap(team.Hue); break;
                case 6: rankedCloth = new FlowerGarland(team.Hue); break;
                case 7: rankedCloth = new StrawHat(team.Hue); break;
                case 8: rankedCloth = new FeatheredHat(team.Hue); break;
                case 9: rankedCloth = new TricorneHat(team.Hue); break;
                case 10: rankedCloth = new TribalMask(team.Hue); break;
                case 11: rankedCloth = new HornedTribalMask(team.Hue); break;
                case 12: rankedCloth = new BearMask(team.Hue); break;
                case 13: rankedCloth = new DeerMask(team.Hue); break;
                case 14: rankedCloth = new OrcishKinMask(team.Hue); break;
                case 15: rankedCloth = new SavageMask(team.Hue); break;
                case 16: rankedCloth = new WizardsHat(team.Hue); break;
                case 17: rankedCloth = new Bandana(team.Hue); break;
                case 18: rankedCloth = new ClothNinjaHood(team.Hue); break;
                case 19: rankedCloth = new Kasa(team.Hue); break;
                case 20:
                    rankedCloth = new BoneHelm();
                    rankedCloth.Hue = team.Hue;
                    ((BaseArmor)rankedCloth).ArmorAttributes.MageArmor = 1;
                    break;
            }
            if (rankedCloth != null)
            {
                rankedCloth.Movable = false;
                armthis.Add(rankedCloth);
            }

            //Alchemy removed by Blady
            /* 			if (m.Skills[SkillName.Alchemy].Value >= (m_MinSupplySkill + 15)) //80 Alchemy req - by Blady
            {
                for (int i = 0; i < 6; i++) //Amount reduced to 6 by Blady - used to be 10
                {
                    armthis.Add(new ExplosionPotion());
                    armthis.Add(new GreaterHealPotion());
                    armthis.Add(new GreaterCurePotion());
                    armthis.Add(new GreaterAgilityPotion());
                    armthis.Add(new RefreshPotion());
                    armthis.Add(new GreaterStrengthPotion());
                }
            } */

            if (m.Skills[SkillName.Chivalry].Value >= m_MinSupplySkill)
            {
                BookOfChivalry book = new BookOfChivalry();
                book.Content = 1023;//all spells
                armthis.Add(book);
            }

            if (m.Skills[SkillName.Necromancy].Value >= m_MinSupplySkill)
            {
                NecromancerSpellbook book = new NecromancerSpellbook();
                book.Content = 0x1FFFF;
                armthis.Add(book);
            }

            if (m.Skills[SkillName.Magery].Value >= m_MinSupplySkill)
            {
                GnarledStaff gs = new GnarledStaff();
                gs.Attributes.SpellChanneling = 1;
                gs.WeaponAttributes.MageWeapon = 20;
                armthis.Add(gs);

                Spellbook book = new Spellbook();
                book.Content = ulong.MaxValue;
                armthis.Add(book);
            }

            if (m.Skills[SkillName.Healing].Value >= m_MinSupplySkill)
                armthis.Add(new Bandage(1000));

            if (m.Skills[SkillName.Fencing].Value >= m_MinSupplySkill)
            {
                Spear sp = new Spear();
                sp.Attributes.SpellChanneling = 1;
                armthis.Add(sp);

                ShortSpear ssp = new ShortSpear();
                ssp.Attributes.SpellChanneling = 1;
                armthis.Add(ssp);

                WarFork wf = new WarFork();
                wf.Attributes.SpellChanneling = 1;
                armthis.Add(wf);

                Kryss k = new Kryss();
                k.Attributes.SpellChanneling = 1;
                armthis.Add(k);
            }

            if (m.Skills[SkillName.Swords].Value >= m_MinSupplySkill)
            {
                if (m.Skills[SkillName.Lumberjacking].Value >= m_MinSupplySkill)
                {
                    ExecutionersAxe ea = new ExecutionersAxe();
                    ea.Attributes.SpellChanneling = 1;
                    armthis.Add(ea);
                }

                Katana k = new Katana();
                k.Attributes.SpellChanneling = 1;
                armthis.Add(k);

                Longsword ls = new Longsword();
                ls.Attributes.SpellChanneling = 1;
                armthis.Add(ls);

                Cleaver c = new Cleaver();
                c.Attributes.SpellChanneling = 1;
                armthis.Add(c);

                BoneHarvester bh = new BoneHarvester();
                bh.Attributes.SpellChanneling = 1;
                armthis.Add(bh);
            }

            if (m.Skills[SkillName.Macing].Value >= m_MinSupplySkill)
            {
                WarAxe wa = new WarAxe();
                wa.Attributes.SpellChanneling = 1;
                armthis.Add(wa);

                HammerPick hp = new HammerPick();
                hp.Attributes.SpellChanneling = 1;
                armthis.Add(hp);

                QuarterStaff qs = new QuarterStaff();
                qs.Attributes.SpellChanneling = 1;
                armthis.Add(qs);
            }

            if (m.Skills[SkillName.Archery].Value >= m_MinSupplySkill)
            {
                Bow b = new Bow();
                b.Attributes.SpellChanneling = 1;
                armthis.Add(b);

                Crossbow xb = new Crossbow();
                xb.Attributes.SpellChanneling = 1;
                armthis.Add(xb);

                CompositeBow cb = new CompositeBow();
                cb.Attributes.SpellChanneling = 1;
                armthis.Add(cb);

                armthis.Add(new Arrow(150));
                armthis.Add(new Bolt(150));
            }

            if (m.Skills[SkillName.Poisoning].Value >= m_MinSupplySkill)
            {
                for (int i = 0; i < 2; i++)
                    armthis.Add(new GreaterPoisonPotion());
            }

            if (m.Skills[SkillName.Parry].Value >= m_MinSupplySkill)
            {
                MetalKiteShield ks = new MetalKiteShield();
                ks.Attributes.SpellChanneling = 1;
                armthis.Add(ks);
            }

            SunnySystem.ArmPlayer(m, armthis);
        }
コード例 #16
0
        public UndeadArcherPirate()
            : base(AIType.AI_Archer, FightMode.Closest, 10, 1, 0.175, 0.2)
        {
            Title = "the unrested pirate";
            Body = Utility.RandomList(400, 50, 3);
            Team = 1;
            Kills = 10;
            Hue = 0;
            SpeechHue=1153;
            this.Body = 0x190;
            this.Name = NameList.RandomName( "male" );
            SetStr( 60, 85 );
            SetDex( 50, 70 );
            SetInt( 10, 20 );
            SetDamage( 5, 7 );

            SetSkill( SkillName.Archery, 35.0, 50.0 );
            SetSkill( SkillName.MagicResist, 23.0, 27.5 );
            SetSkill( SkillName.Tactics, 40.0, 45.5 );
            SetSkill( SkillName.Healing, 30.2, 35.9 );
            SetSkill( SkillName.Anatomy, 45.2, 50.9 );
            SetSkill( SkillName.Swords, 50.0, 60.0);
            SetSkill(SkillName.Stealth, 120.0, 180.0);
            SetSkill(SkillName.Hiding, 120.0, 180.0);

            Fame = 2500;
            Karma = -2500;

            VirtualArmor = 0;

            Item hair = new Item( Utility.RandomList( 0x203B, 0x2049, 0x2048, 0x204A ) );
            hair.Hue = Utility.RandomHairHue();
            hair.Layer = Layer.Hair;
            hair.Movable = false;
            AddItem( hair );

            Item beard = new Item( Utility.RandomList( 0x2040, 0x203E , 0x204C, 0x204B, 0x203F ) );
            beard.Hue = hair.Hue;
            beard.Layer = Layer.FacialHair;
            beard.Movable = false;
            AddItem( beard );

            PackGold( 70, 95 );
            PackItem( new Bandage( 10 ) );

                Item crossbow = new Crossbow();
                EquipItem( crossbow );

            switch ( Utility.Random( 3 ) )
            {
                case 0:
                {
                Item fancyshirt = new FancyShirt();
                fancyshirt.Hue = Utility.RandomNeutralHue();
                EquipItem( fancyshirt );
                break;
                }
                case 1:
                {
                Item doublet = new Doublet();
                doublet.Hue = Utility.RandomNeutralHue();
                EquipItem( doublet );
                break;
                }
                case 2:
                {
                break;
                }
            }

            switch ( Utility.Random( 2 ) )
            {
                case 0:
                {
                Item longpants = new LongPants();
                longpants.Hue = Utility.RandomNeutralHue();
                EquipItem( longpants );
                break;
                }
                case 1:
                {
                Item shortpants = new ShortPants();
                shortpants.Hue = Utility.RandomNeutralHue();
                EquipItem( shortpants );
                break;
                }
            }

                    switch ( Utility.Random( 4 ) )
            {
               			case 0:
                {
                Item boots = new Boots();
                boots.Hue = 0;
                EquipItem( boots );
                break;
                }
                case 1:
                {
                Item shoes = new Shoes();
                shoes.Hue = 1713;
                EquipItem( shoes );
                break;
                }
                case 3:
                {
                Item thighboots = new ThighBoots();
                thighboots.Hue = 0;
                EquipItem( thighboots );
                break;
                }
                case 4:
                {
                break;
                }
                 }

                    switch ( Utility.Random( 3 ) )
                 {
               			case 0:
                {
                Item Bandana = new Bandana();
                Bandana.Hue = Utility.RandomBirdHue();
                EquipItem( Bandana );
                break;
                }
                case 1:
                {
                Item skullcap = new SkullCap();
                skullcap.Hue = Utility.RandomBirdHue();
                EquipItem( skullcap );
                break;
                }
                case 3:
                {
                break;
                }
                 }
        }
コード例 #17
0
        public Gambler() : base( AIType.AI_Melee, FightMode.None, 10, 1, 0.8, 3.0 ) 
        {
            SetStr( 10, 30 );
            SetDex( 10, 30 );
            SetInt( 10, 30 );
            Fame = 50;
            Karma = 50;
            SpeechHue = Utility.RandomDyedHue();
            Title = "the gambler";
            Hue = Utility.RandomSkinHue();
            Blessed = true;
            NameHue = 0x35;

            if ( this.Female = Utility.RandomBool() )
            {
                this.Body = 0x191;
                this.Name = NameList.RandomName( "female" );
                Item hair = new Item( Utility.RandomList( 0x203B, 0x203C, 0x203D, 0x2045, 0x204A, 0x2046 , 0x2049 ) );
                hair.Hue = Utility.RandomHairHue();
                hair.Layer = Layer.Hair;
                hair.Movable = false;
                AddItem( hair );
                Item hat = null;
                switch ( Utility.Random( 5 ) )
                {
                    case 0: hat = new FloppyHat( Utility.RandomNeutralHue() );		break;
                    case 1: hat = new FeatheredHat( Utility.RandomNeutralHue() );	break;
                    case 2: hat = new Bonnet();						break;
                    case 3: hat = new Cap( Utility.RandomNeutralHue() );		break;
                }
	    	AddItem( hat );
            }
            else
            {
                this.Body = 0x190;
                this.Name = NameList.RandomName( "male" );
                Item hair = new Item( Utility.RandomList( 0x203B, 0x203C, 0x203D, 0x2044, 0x2045, 0x2047, 0x2048 ) );
                hair.Hue = Utility.RandomHairHue();
                hair.Layer = Layer.Hair;
                hair.Movable = false;
                AddItem( hair );
                Item beard = new Item( Utility.RandomList( 0x0000, 0x203E, 0x203F, 0x2040, 0x2041, 0x2067, 0x2068, 0x2069 ) );
                beard.Hue = hair.Hue;
                beard.Layer = Layer.FacialHair;
                beard.Movable = false;
                AddItem( beard );
                Item hat = null;
                switch ( Utility.Random( 7 ) )
                {
                    case 0: hat = new SkullCap( GetRandomHue() );			break;
                    case 1: hat = new Bandana( GetRandomHue() );			break;
                    case 2: hat = new WideBrimHat();					break;
                    case 3: hat = new TallStrawHat( Utility.RandomNeutralHue() );	break;
                    case 4: hat = new StrawHat( Utility.RandomNeutralHue() );		break;
                    case 5: hat = new TricorneHat( Utility.RandomNeutralHue() );	break;
                }
	    	AddItem( hat );
	    }
            AddItem( new LongPants( GetRandomHue() ) );
            AddItem( new FancyShirt( GetRandomHue() ) );
            AddItem( new Boots( Utility.RandomNeutralHue() ) );
            AddItem( new Cloak( GetRandomHue() ) );
            AddItem( new BodySash( GetRandomHue() ) );

            Container pack = new Backpack();

            pack.DropItem( new Gold( 5, 500 ) );

            pack.Movable = false;
	    pack.Visible = false;

            AddItem( pack );

	    //reset stats
	    for ( int i = 0; i <= 5; ++i )
		gamestats[i]=0;
        }
コード例 #18
0
        public override Item Construct(Type type, Mobile from)
        {
            if (type == typeof(TreasureMap))
            {
                int level;
                if (from is PlayerMobile && ((PlayerMobile)from).Young && from.Map == Map.Trammel && TreasureMap.IsInHavenIsland(from))
                    level = 0;
                else
                    level = 1;

                return new TreasureMap(level, from.Map == Map.Felucca ? Map.Felucca : Map.Trammel);
            }
            else if (type == typeof(MessageInABottle))
            {
                return new MessageInABottle(from.Map == Map.Felucca ? Map.Felucca : Map.Trammel);
            }

            Container pack = from.Backpack;

            if (pack != null)
            {
                List<SOS> messages = pack.FindItemsByType<SOS>();

                for (int i = 0; i < messages.Count; ++i)
                {
                    SOS sos = messages[i];

                    if ((from.Map == Map.Felucca || from.Map == Map.Trammel) && from.InRange(sos.TargetLocation, 60))
                    {
                        Item preLoot = null;

                        switch ( Utility.Random(8) )
                        {
                            case 0: // Body parts
                                {
                                    int[] list = new int[]
                                    {
                                        0x1CDD, 0x1CE5, // arm
                                        0x1CE0, 0x1CE8, // torso
                                        0x1CE1, 0x1CE9, // head
                                        0x1CE2, 0x1CEC // leg
                                    };

                                    preLoot = new ShipwreckedItem(Utility.RandomList(list));
                                    break;
                                }
                            case 1: // Bone parts
                                {
                                    int[] list = new int[]
                                    {
                                        0x1AE0, 0x1AE1, 0x1AE2, 0x1AE3, 0x1AE4, // skulls
                                        0x1B09, 0x1B0A, 0x1B0B, 0x1B0C, 0x1B0D, 0x1B0E, 0x1B0F, 0x1B10, // bone piles
                                        0x1B15, 0x1B16 // pelvis bones
                                    };

                                    preLoot = new ShipwreckedItem(Utility.RandomList(list));
                                    break;
                                }
                            case 2: // Paintings and portraits
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0xE9F, 10));
                                    break;
                                }
                            case 3: // Pillows
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0x13A4, 11));
                                    break;
                                }
                            case 4: // Shells
                                {
                                    preLoot = new ShipwreckedItem(Utility.Random(0xFC4, 9));
                                    break;
                                }
                            case 5:	//Hats
                                {
                                    if (Utility.RandomBool())
                                        preLoot = new SkullCap();
                                    else
                                        preLoot = new TricorneHat();

                                    break;
                                }
                            case 6: // Misc
                                {
                                    int[] list = new int[]
                                    {
                                        0x1EB5, // unfinished barrel
                                        0xA2A, // stool
                                        0xC1F, // broken clock
                                        0x1047, 0x1048, // globe
                                        0x1EB1, 0x1EB2, 0x1EB3, 0x1EB4 // barrel staves
                                    };

                                    if (Utility.Random(list.Length + 1) == 0)
                                        preLoot = new Candelabra();
                                    else
                                        preLoot = new ShipwreckedItem(Utility.RandomList(list));

                                    break;
                                }
                        }

                        if (preLoot != null)
                        {
                            if (preLoot is IShipwreckedItem)
                                ((IShipwreckedItem)preLoot).IsShipwreckedItem = true;

                            return preLoot;
                        }

                        LockableContainer chest;
						
                        if (Utility.RandomBool())
                            chest = new MetalGoldenChest();
                        else
                            chest = new WoodenChest();

                        if (sos.IsAncient)
                            chest.Hue = 0x481;

                        TreasureMapChest.Fill(chest, Math.Max(1, Math.Min(4, sos.Level)));

                        if (sos.IsAncient)
                            chest.DropItem(new FabledFishingNet());
                        else
                            chest.DropItem(new SpecialFishingNet());

                        chest.Movable = true;
                        chest.Locked = false;
                        chest.TrapType = TrapType.None;
                        chest.TrapPower = 0;
                        chest.TrapLevel = 0;

                        sos.Delete();

                        return chest;
                    }
                }
            }

            return base.Construct(type, from);
        }
コード例 #19
0
ファイル: Fishing.cs プロジェクト: ITLongwell/aedilis2server
		public override Item Construct( Type type, Mobile from )
		{
			if ( type == typeof( TreasureMap ) )
			{
				int level;
				if ( from is PlayerMobile && ((PlayerMobile)from).Young && from.Map == Map.Felucca && TreasureMap.IsInHavenIsland( from ) )
					level = 0;
				else
					level = 1;

				return new TreasureMap( level, from.Map == Map.Felucca ? Map.Felucca : Map.Felucca );
			}
			else if ( type == typeof( MessageInABottle ) )
			{
				return new MessageInABottle( from.Map == Map.Felucca ? Map.Felucca : Map.Felucca );
			}

			Container pack = from.Backpack;

			if ( pack != null )
			{
				List<SOS> messages = pack.FindItemsByType<SOS>();

				for ( int i = 0; i < messages.Count; ++i )
				{
					SOS sos = messages[i];

					if ( from.Map == sos.TargetMap && from.InRange( sos.TargetLocation, 60 ) )
					{
						Item preLoot = null;

						switch ( Utility.Random( 7 ) )
						{
							case 0: // Bone parts
							{
								int[] list = new int[]
									{
										0x1AE0, 0x1AE1, 0x1AE2, 0x1AE3, 0x1AE4, // skulls
										0x1B09, 0x1B0A, 0x1B0B, 0x1B0C, 0x1B0D, 0x1B0E, 0x1B0F, 0x1B10, // bone piles
										0x1B15, 0x1B16, // pelvis bones
										0xECA, 0xECB, 0xECC, 0xECD, 0xECE, 0xECF, 0xED0, 0xED1, 0xED2 // skeletons
									};

								preLoot = new ShipwreckedItem( Utility.RandomList( list ) );
								break;
							}
							case 1: // Shells
							{
								preLoot = new ShipwreckedItem( Utility.Random( 0xFC4, 9 ) );
								break;
							}
							case 2: // Misc
							{
								int[] list = new int[]
									{
										0xE9F, 0xEA0, 0xEA1, 0xEA2, 0xEA3, 0xEA4, 0xEA5, 0xEA6, 0xEA7, 0xEA8, // paintings
										0x13A4, 0x13A5, 0x13A6, 0x13A7, 0x13A8, 0x13A9, 0x13AA, 0x13AB, 0x13AC, 0x13AD, 0x13AE, // pillows
										0x1EB5, // unfinished barrel
										0xA2A, // stool
										0xC1F, // broken clock
										0x1047, 0x1048, // globe
										0x1EB1, 0x1EB2, 0x1EB3, 0x1EB4, // barrel staves
										0xE25, 0xE26, 0xE27, 0xE28, 0xE29, 0xE2A, 0xE2B, 0xE2C, // bottles
										0xC19, 0xC1A, 0xC1B, 0xC1C, 0xC1D, 0xC1E, // broken chairs
										0xC2C, 0xC2D, 0xC2E, 0xC2F, 0xC30, // ruined painting, debris
										0x13E5, 0x13E6, 0x13E7, 0x13E8, 0x13E9, 0x13EA // hanging armor
									};

								preLoot = new ShipwreckedItem( Utility.RandomList( list ) );
								break;
							}
							case 3: // Ship Items
							{
								int[] list = new int[]
									{
										0x14F8, 0x14FA, // ropes
										0x14F7, 0x14F9, // anchors
										0x14EB, 0x14EC, // maps
										0x1057, 0x1058, // sextants
										0x171A // feathered hat
									};

								preLoot = new ShipwreckedItem( Utility.RandomList( list ) );
								break;
							}
							case 4: // Shells
							{
								preLoot = new ShipwreckedItem( Utility.Random( 0xFC4, 9 ) );
								break;
							}
							case 5:	//Hats
							{
								if ( Utility.RandomBool() )
									preLoot = new SkullCap();
								else
									preLoot = new TricorneHat();

								break;
							}
							case 6: // Misc
							{
								int[] list = new int[]
									{
										0x1EB5, // unfinished barrel
										0xA2A, // stool
										0xC1F, // broken clock
										0x1047, 0x1048, // globe
										0x1EB1, 0x1EB2, 0x1EB3, 0x1EB4 // barrel staves
									};

								if ( Utility.Random( list.Length + 1 ) == 0 )
									preLoot = new Candelabra();
								else
									preLoot = new ShipwreckedItem( Utility.RandomList( list ) );

								break;
							}
						}

						if ( preLoot != null )
						{
							if ( preLoot is IShipwreckedItem )
								( (IShipwreckedItem)preLoot ).IsShipwreckedItem = true;

							return preLoot;
						}

						LockableContainer chest;
						
						if ( Utility.RandomBool() )
							chest = new MetalGoldenChest();
						else
							chest = new WoodenChest();

						if ( sos.IsAncient )
							chest.Hue = 0x481;

						TreasureMapChest.Fill( chest, Math.Max( 1, Math.Max( 4, sos.Level ) ) );

						if ( sos.IsAncient )
							chest.DropItem( new FabledFishingNet() );
						else
							chest.DropItem( new SpecialFishingNet() );

						chest.Movable = true;
						chest.Locked = false;
						chest.TrapType = TrapType.None;
						chest.TrapPower = 0;
						chest.TrapLevel = 0;
// label chest with fisherman's name
						chest.Name = "Treasure chest fished up by " + from.Name;

						sos.Delete();

						return chest;
					}
				}
			}

			return base.Construct( type, from );
		}