コード例 #1
0
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}

			PackItem( new RedBook( "a book", m.Name, 20, true ) );
			//PackItem( new Gold( 1000 ) ); // Starting gold can be customized here
			PackItem( new Dagger() );
			PackItem( new Candle() );
			PackItem( new Spellbook( UInt64.MaxValue ) );
			
			Account account = (Account)m.Account;
				if(account.GetTag("AlreadyGotTheirGold") == null)
			{
				PackItem( new StatBall() );
				PackItem( new SkillBall() );
				PackItem( new BankCheck( 100000 ) );
				account.SetTag("AlreadyGotTheirGold", "True");
			}
			
		}
コード例 #2
0
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}

			PackItem( new RedBook( "a book", m.Name, 20, true ) );
			PackItem( new Gold( 100 ) ); // Starting gold can be customized here
			PackItem( new Dagger() );
			PackItem( new Candle() );
			PackItem( new BankCheck (900) );
			PackItem( new Runebook(10) );
			PackItem( new TrashPack() );
			PackItem( new SkillBall() );
			PackItem( new CorpseWand() );
			PackItem( new SkillBall() );
			PackItem( new PetLeash() );
			PackItem( new ResourceStorageKeyBlackSmith() );
			PackItem( new ResourceStorageKeyScribersTome() );
			PackItem( new ResourceStorageKeySpellCasters() );
			PackItem( new ResourceStorageKeyTailor() );
			PackItem( new NewPlayerPackage() );
			PackItem( new StatSkillPurchaseCrystal() );
			PackItem( new NewPlayerWelcomeHandbook() );
			//PackItem( new ResourceStorageKeyWood() );


		}
コード例 #3
0
        private static void AddBackpack( Mobile m )
        {
            Container pack = m.Backpack;

            PlayerMobile pm = m as PlayerMobile;

            pm.RawStr = 10;
            pm.AvatarID = 1076;
            pm.RawDex = 10;
            pm.RawInt = 10;
            pm.MaxHits = 10;
            pm.MaxStam = 10;
            pm.MaxMana = 10;
            pm.Hits = 10;
            pm.Stam = 10;
            pm.Mana = 10;
            pm.Criminal = true;

            if ( pack == null )
            {
                pack = new ArmourBackpack();
                pack.Movable = false;

                m.AddItem( pack );
            }

            PackItem( new RedBook( "a book", m.Name, 20, true ) );
            PackItem( new Copper( Utility.Random( 75, 150 ) ) ); // Starting gold can be customized here
            PackItem( new Dagger() );
            PackItem( new Candle() );
        }
コード例 #4
0
		//private static void AddBankbox2( Mobile m )
		//{
		//	BankBox2 box = m.Bankbox2;
//
//			if ( box == null )
//			{
//				box = new Bankbox2();
//				box.Movable = false;
//
//				
//			}
//
//		}
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}
			Container cont;
			cont = new WoodenBox();
			cont.ItemID = 0xE7D;
			cont.Hue = 0x489;
			PlaceItemIn( cont, 16, 51, new NLeatherGorget() );
			PlaceItemIn( cont, 28, 51, new NLeatherArms() );
			PlaceItemIn( cont, 40, 51, new NLeatherGloves() );
			PlaceItemIn( cont, 52, 51, new NLeatherLegs() );
			
			PlaceItemIn( cont, 64, 115, new TokenLedger() );
			
 			PlaceItemIn( cont, 16, 115, new Candle() );
			PlaceItemIn( pack, 18, 169, cont );
			PlaceItemIn( pack, 16, 51, new SkillBall() );
			PlaceItemIn( pack, 56, 51, new SkillBall() );
			PlaceItemIn( pack, 66, 51, new SkillBall() );
			PlaceItemIn( pack, 80, 51, new StatBall() );
			PlaceItemIn( pack, 70, 169, new RuleBook1() );
			PlaceItemIn( pack, 164, 169, new BankCheck(  5000 ) );
			PlaceItemIn( pack, 164, 51, new CommandBook() );
		}
コード例 #5
0
ファイル: KinAwards.cs プロジェクト: zerodowned/angelisland
		public static void PackItem(Mobile m, Item item)
		{
			Container pack = m.Backpack;

			if (pack == null)
			{	// add a pack
				pack = new Backpack();
				pack.Movable = false;
				m.AddItem(pack);
			}

			if (!item.Stackable || !pack.TryDropItem(m, item, false)) // try stack
				pack.DropItem(item); // failed, drop it anyway
		}
コード例 #6
0
        public static void AddBackpack( Mobile m )
        {
            Container pack = m.Backpack;

            if ( pack == null )
            {
                pack = new Backpack();
                pack.Movable = false;

                m.AddItem( pack );
            }

            PackItem( new Dagger() );
        }
コード例 #7
0
        private static void AddBackpack( Mobile m )
        {
            Container pack = m.Backpack;

            if ( pack == null )
            {
                pack = new Backpack();
                pack.Movable = false;

                m.AddItem( pack );
            }

            PackItem( new Gold( 1000 ) ); // Starting gold can be customized here
        }
コード例 #8
0
ファイル: CharacterCreation.cs プロジェクト: svvota/runuo
        private static void AddBackpack( Mobile m )
        {
            Container pack = m.Backpack;

            if ( pack == null )
            {
                pack = new Backpack();
                pack.Movable = false;

                m.AddItem( pack );
            }

            PackItem( new RedBook( "a book", m.Name, 20, true ) );
            PackItem( new Gold( 1000 ) ); // Starting gold can be customized here
            PackItem( new Dagger() );
            PackItem( new Candle() );
        }
コード例 #9
0
        private static void AddBackpack(Mobile m)
        {
            Container pack = m.Backpack;

            if (pack == null)
            {
                pack = new Backpack();
                pack.Movable = false;

                m.AddItem(pack);
            }

            PackItem(new Gold(2000)); // Starting gold can be customized here
            PackItem(MakeNewbie(new Dagger()));

            PackItem(new Spellbook((ulong)18446744073709551615)); //fullbook
            PackItem(new BagOfReagents(50));
        }
コード例 #10
0
		public override void OnAdded( object parent )
		{
			if (m_Hat != null)
			{
				m_Hat.Delete();
				m_Hat = null;
			}

			if (RootParent is Mobile)
			{
				m_Hat = new WizardsHat();
				m_Hat.Hue = 1153;
				m_Hat.Movable = false;
				m_Hat.Name = "a white magic hat";
				m_Owner = ((Mobile)RootParent);
				m_Owner.AddItem( m_Hat );
			}
		}
コード例 #11
0
        public static void AddHair( Mobile m, int itemID, int hue )
        {
            Item item;

            switch ( itemID & 0x3FFF )
            {
                case 0x2044: item = new Mohawk( hue ); break;
                case 0x2045: item = new PageboyHair( hue ); break;
                case 0x2046: item = new BunsHair( hue ); break;
                case 0x2047: item = new Afro( hue ); break;
                case 0x2048: item = new ReceedingHair( hue ); break;
                case 0x2049: item = new TwoPigTails( hue ); break;
                case 0x204A: item = new KrisnaHair( hue ); break;
                case 0x203B: item = new ShortHair( hue ); break;
                case 0x203C: item = new LongHair( hue ); break;
                case 0x203D: item = new PonyTail( hue ); break;
                default: return;
            }

            m.AddItem( item );
        }
コード例 #12
0
        private static void AddBeard( Mobile m, int itemID, int hue )
        {
            if ( m.Female )
                return;

            Item item;

            switch ( itemID & 0x3FFF )
            {
                case 0x203E: item = new LongBeard( hue ); break;
                case 0x203F: item = new ShortBeard( hue ); break;
                case 0x2040: item = new Goatee( hue ); break;
                case 0x2041: item = new Mustache( hue ); break;
                case 0x204B: item = new MediumShortBeard( hue ); break;
                case 0x204C: item = new MediumLongBeard( hue ); break;
                case 0x204D: item = new Vandyke( hue ); break;
                default: return;
            }

            m.AddItem( item );
        }
コード例 #13
0
        private static void AddBackpack( Mobile m )
        {
            Container pack = m.Backpack;

            if ( pack == null )
            {
                pack = new Backpack();
                pack.Movable = false;

                m.AddItem( pack );
            }

            PackItem( new RedBook( "a book", m.Name, 20, true ) );
            PackItem( new Gold( 2000 ) ); // Starting gold can be customized here
            PackItem( new Spellbook( (ulong)18446744073709551615 ) );
            PackItem( new Bandage(500) );
            PackItem( new Dagger() );
            PackItem( new Candle() );
            EquipItem( new HalfApron( Utility.RandomYellowHue() ) );
            EquipItem( new HalfApron( Utility.RandomYellowHue() ) );
        }
コード例 #14
0
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}

            PackItem(new SkillBall());
            PackItem(new StatBall());
            PackItem(new Gold(10000));
            PackItem(new Dagger());
            PackItem(new SkillBall());
            PackItem(new SkillBall());
            PackItem(new SkillBall());
            //PackItem(new NewCharSandals());
            PackItem(new TrashBackpack());
            PackItem(new TokenBox());
			
		}
コード例 #15
0
 // copy what the possessee has equipped and wear it
  static void CopyLayer( Mobile possessed, Mobile from, Layer layer )
  {
   Item anItem = possessed.FindItemOnLayer( layer );
   if ( anItem != null )
   {
  Item myitem = new Item();
  myitem.ItemID = anItem.ItemID;
  myitem.Hue = anItem.Hue;
  myitem.Layer = layer;
     from.AddItem(myitem);
   }
  }
コード例 #16
0
ファイル: Soldier.cs プロジェクト: justdanofficial/khaeros
        public static void EquipFreeSoldier(Armament a, Mobile m)
        {
            if (a == Armament.LightCavalry)
                a = (Armament)1;
            else if (a == Armament.HeavyCavalry)
                a = (Armament)3;

            int chance = Utility.RandomMinMax(1, 6);
            Nation nation = Nation.Vhalurian;

            switch (chance)
            {
                case 1: nation = Nation.Alyrian; break;
                case 2: nation = Nation.Azhuran; break;
                case 3: nation = Nation.Khemetar; break;
                case 4: nation = Nation.Mhordul; break;
                case 5: nation = Nation.Tyrean; break;
                case 6: nation = Nation.Vhalurian; break;
            }

            m.Language = "Common";
            m.Female = Utility.RandomBool();

            if (m.Female)
            {
                m.Body = 0x191;
                (m as Soldier).BaseName = RandomName(nation, true) + RandomSurname(nation, true);
            }

            else
            {
                m.Body = 0x190;
                (m as Soldier).BaseName = BaseKhaerosMobile.RandomName(nation, false) + RandomSurname(nation, false);
            }

            m.Hue = BaseKhaerosMobile.AssignRacialHue(nation);
            m.HairItemID = BaseKhaerosMobile.AssignRacialHair(nation, m.Female);
            int hairhue = BaseKhaerosMobile.AssignRacialHairHue(nation);
            m.HairHue = hairhue;

            if (!m.Female)
            {
                m.FacialHairItemID = BaseKhaerosMobile.AssignRacialFacialHair(nation);
                m.FacialHairHue = hairhue;
            }
            else
                m.FacialHairItemID = 0;

            if (m.Backpack == null)
                m.AddItem(new Backpack());

            m.Name = ((m as Soldier).BaseName + " the Free Soldier");

            ChainChest cc = new ChainChest();
            m.EquipItem(cc);
            PlateArms pa = new PlateArms();
            m.EquipItem(pa);
            TyreanHalfPlateGloves thpg = new TyreanHalfPlateGloves();
            m.EquipItem(thpg);
            PlateGorget pg = new PlateGorget();
            m.EquipItem(pg);
            PlateLegs pl = new PlateLegs();
            m.EquipItem(pl);
            m.EquipItem(new Cloak(Utility.RandomMinMax(1873, 1908)));
            m.EquipItem(new Tunic(Utility.RandomMinMax(1873, 1908)));

            int RandomWeapons = Utility.Random(3);

            switch (RandomWeapons)
            {
                case 0: Broadsword sword = new Broadsword(); m.EquipItem(sword); MetalShield shield = new MetalShield(); m.EquipItem(shield); break;
                case 1: WarHammer wh = new WarHammer(); m.EquipItem(wh); break;
                case 2: Bow b = new Bow(); m.EquipItem(b); m.AddToBackpack(new Arrow(Utility.Random(20))); (m as BaseCreature).AI = AIType.AI_Archer; break;
            }
        }
コード例 #17
0
ファイル: SecureTrade.cs プロジェクト: Ravenwolfe/xrunuo
        public SecureTradeInfo( SecureTrade owner, Mobile m, SecureTradeContainer c )
        {
            m_Owner = owner;
            m_Mobile = m;
            m_Container = c;

            m_Mobile.AddItem( m_Container );
        }
コード例 #18
0
ファイル: BaseBoat.cs プロジェクト: Crome696/ServUO
        public void LockPilot(Mobile pilot)
        {
            m_Pilot = pilot;
            pilot.Direction = m_Facing;
            pilot.AddItem(m_VirtualMount);

            pilot.SendLocalizedMessage(1116727); //You are now piloting this vessel.

            if (IsMoving)
                StopMove(false);
        }
コード例 #19
0
         protected override void OnTarget( Mobile from, object targeted )
         {
            if ( targeted is Mobile )
            {
               Mobile targ = (Mobile)targeted;

               // if ( !targ.Player ) // use to limit to Non-Players
               if ( from != targ && from.AccessLevel > targ.AccessLevel )
               {
                  CommandLogging.WriteLine( from, "{0} {1} is cloning {2}", from.AccessLevel, CommandLogging.Format( from ), CommandLogging.Format( targ ) );

                  from.Hidden = true;

                  from.Dex = targ.Dex;
                  from.Int = targ.Int;
                  from.Str = targ.Str;
                  from.Fame = targ.Fame;
                  from.Karma = targ.Karma;
                  from.NameHue = targ.NameHue;
                  from.SpeechHue = targ.SpeechHue;
                  //from.Criminal = !targ.Criminal;

                  from.Name = targ.Name;
                  from.Title = targ.Title;
                  from.Female = targ.Female;
                  from.Body = targ.Body;
                  from.Hue = targ.Hue;

                  from.Hits = from.HitsMax;
                  from.Mana = from.ManaMax;
                  from.Stam = from.StamMax;

                  from.Location = targ.Location;
                  from.Direction = targ.Direction;

                  if( !targ.Player )
                     from.BodyMod = targ.Body;
                  else
                     from.BodyMod = 0;

                  for (int i=0; i<from.Skills.Length; i++)
                     from.Skills[i].Base = targ.Skills[i].Base;

                  // This code block deletes everything GM has equiped.
                  ArrayList m_items = new ArrayList( from.Items );
                  for (int i=0; i<m_items.Count; i++)
                  {
                     Item item = (Item)m_items[i];
                     if((( item.Parent == from ) && ( item != from.Backpack )))
                        item.Delete();
                        // Alternate Option: from.PlaceInBackpack( item );
                  }

                  // This code block deletes everything in GM's pack if
                  // subject is a Player. (This block is optional.)
                  if( targ.Player )
                  {
                     Container m_pack = from.Backpack;
                     if( m_pack != null)
                     {
                        ArrayList p_items = new ArrayList( m_pack.Items );
                        for (int i=0; i<p_items.Count; i++)
                        {
                           ((Item)p_items[i]).Delete();
                        }
                     }
                  }

                  // This code block duplicates all equiped items
                  ArrayList items = new ArrayList( targ.Items );
                  for (int i=0; i<items.Count; i++)
                  {
                     Item item = (Item)items[i]; //my favorite line of code, ever.
                     if((( item != null ) && ( item.Parent == targ ) && ( item != targ.Backpack )))
                     {
                        Type type = item.GetType();
                        Item newitem = Loot.Construct( type );
                        CopyProperties( newitem, item );
                        from.AddItem( newitem );
                     }
                  }

                  // This code block duplicates all pack items if subject is a Player
                  if( targ.Player )
                  {
                     Container pack = targ.Backpack;
                     if( pack != null )
                     {
                        ArrayList t_items = new ArrayList( pack.Items );
                        for (int i=0; i<t_items.Count; i++)
                        {
                           Item item = (Item)t_items[i];
                           if(( item != null ) && ( item.IsChildOf( pack )))
                           {
                              Type type = item.GetType();
                              Item newitem = Loot.Construct( type );
                              CopyProperties( newitem, item );
                              from.PlaceInBackpack( newitem );
                           }
                        }
                     }
                  }
               }
            }
         }
コード例 #20
0
ファイル: GMbody.cs プロジェクト: PepeBiondi/runsa
			protected override void OnTarget( Mobile from, object targeted )
			{
				if ( targeted is Mobile )
				{
					Mobile targ = (Mobile)targeted;
					if ( from != targ ) 
						from.SendMessage( "You may only set your own body to GM style." );

					else 
					{
						m_Mobile = from;

						CommandLogging.WriteLine( from, "{0} {1} is assuming a GM body", from.AccessLevel, CommandLogging.Format( from ) );

						Container pack = from.Backpack;

						if ( pack == null )
						{
							pack = new Backpack();
							pack.Movable = false;

							from.AddItem( pack );
						}

						from.Hunger = 20;
						from.Thirst = 20;
						from.Fame = 0;
						from.Karma = 0;
						from.Kills = 0;
						from.Hidden = true;
						from.Blessed = true;
						from.Hits = from.HitsMax;
						from.Mana = from.ManaMax;
						from.Stam = from.StamMax;

						if(from.AccessLevel >= AccessLevel.Counselor)
						{
							EquipItem( new StaffRing() );
							Spellbook book1 = new Spellbook( (ulong)18446744073709551615 );
							Spellbook book2 = new NecromancerSpellbook( (ulong)0xffff );
							Spellbook book3 = new BookOfChivalry();
							Spellbook book4 = new BookOfBushido();
                            Spellbook book5 = new BookOfNinjitsu();

                            PackItem(new GMHidingStone());

							PackItem( book1 );
							PackItem( book2 );
							PackItem( book3 );
							PackItem( book4 );
							PackItem( book5 );
							from.RawStr = 100;
							from.RawDex = 100;
							from.RawInt = 100;
							from.Hits = from.HitsMax;
							from.Mana = from.ManaMax;
							from.Stam = from.StamMax;

							for ( int i = 0; i < targ.Skills.Length; ++i )
								targ.Skills[i].Base = 120;
						}

						if(from.AccessLevel == AccessLevel.Counselor)
						{
							EquipItem( new CounselorRobe() );
							EquipItem( new ThighBoots( 3 ) );
							from.Title = "[Counselor]";
						}

						if(from.AccessLevel == AccessLevel.GameMaster)
						{
							EquipItem( new GMRobe() );
							EquipItem( new ThighBoots( 39 ) );
							from.Title = "[GM]";
						}

						if(from.AccessLevel == AccessLevel.Seer)
						{
							EquipItem( new SeerRobe() );
							EquipItem( new ThighBoots( 467 ) );
							from.Title = "[Seer]";
						}

						if(from.AccessLevel == AccessLevel.Administrator)
						{
							EquipItem( new AdminRobe() );
							EquipItem( new ThighBoots( 1001 ) );
							from.Title = "[Admin]";
						}

						if(from.AccessLevel == AccessLevel.Developer)
						{
							EquipItem( new AdminRobe() );
							EquipItem( new ThighBoots( 1001 ) );
							from.Title = "[Developer]";
						}

						if(from.AccessLevel == AccessLevel.Owner)
						{
							EquipItem( new AdminRobe() );
							EquipItem( new ThighBoots( 1001 ) );
							from.Title = "[Owner]";
						}
					}
				}
			}
コード例 #21
0
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}

			PackItem( new RedBook( "a book", m.Name, 20, true ) );
			PackItem(new Gold(204));	// Adam: add the magic starting gold of 204
			PackItem( new Dagger() );
			PackItem( new Candle() );
			PackItem(new Spyglass());	// Adam: The spyglass is how you opperate a moongate. seems like a reasonable starting item

			// [NEW] Tower
			//RecallRune ocRune = new RecallRune();
			//ocRune.Target =	new Point3D( 1688, 1422, 0 ); 
			//ocRune.TargetMap = Map.Felucca;
			//ocRune.Description = "[NEW] Tower";
			//ocRune.Marked = true;
			//PackItem( ocRune );

			// add a book describing new
			//PackItem(NewBook());

			// wea: added newbie tent
			TentBag newbtent = new TentBag();
			PackItem( newbtent );
                        
		}
コード例 #22
0
ファイル: Spawner.cs プロジェクト: zerodowned/angelisland
		//wipe layers of src mobile, copy identical layers 
		public static void CopyLayers ( Mobile dest, Mobile src ) 
		{ 
			try
			{
				dest.WipeLayers();
				Item[] items = new Item[21];
				items[0] = src.FindItemOnLayer( Layer.Shoes );
				items[1] = src.FindItemOnLayer( Layer.Pants );
				items[2] = src.FindItemOnLayer( Layer.Shirt );
				items[3] = src.FindItemOnLayer( Layer.Helm );
				items[4] = src.FindItemOnLayer( Layer.Gloves );
				items[5] = src.FindItemOnLayer( Layer.Neck );
				items[6] = src.FindItemOnLayer( Layer.Waist );
				items[7] = src.FindItemOnLayer( Layer.InnerTorso );
				items[8] = src.FindItemOnLayer( Layer.MiddleTorso );
				items[9] = src.FindItemOnLayer( Layer.Arms );
				items[10] = src.FindItemOnLayer( Layer.Cloak );
				items[11] = src.FindItemOnLayer( Layer.OuterTorso );
				items[12] = src.FindItemOnLayer( Layer.OuterLegs );
				items[13] = src.FindItemOnLayer( Layer.InnerLegs );
				items[14] = src.FindItemOnLayer( Layer.Bracelet );
				items[15] = src.FindItemOnLayer( Layer.Ring );
				items[16] = src.FindItemOnLayer( Layer.Earrings );
				items[17] = src.FindItemOnLayer( Layer.OneHanded);
				items[18] = src.FindItemOnLayer( Layer.TwoHanded);
				items[19] = src.FindItemOnLayer( Layer.Hair);
				items[20] = src.FindItemOnLayer( Layer.FacialHair);
				for( int i=0; i < items.Length; i++ )
				{
					if( items[i] != null )
					{
						Type temp = items[i].GetType();
						object o = Activator.CreateInstance( temp );
						if(o != null && o is Item)
						{
							Item item = (Item)o;
							CopyProperties(item, items[i]);
							dest.AddItem(item);
						}
						
					}
				}
			}
			catch(Exception exc)
			{
				LogHelper.LogException(exc);
				System.Console.WriteLine("Send to Zen please: ");
				System.Console.WriteLine("Exception caught in Spawner.CopyLayers: " + exc.Message);
				System.Console.WriteLine(exc.StackTrace);
			}

		}
コード例 #23
0
		private static void AddBackpack( Mobile m )
		{
			Container pack = m.Backpack;

			if ( pack == null )
			{
				pack = new Backpack();
				pack.Movable = false;

				m.AddItem( pack );
			}

						
			PackItem( new RedBook( "a book", m.Name, 20, true ) );
			PackItem( new Gold( 1000 ) ); // Starting gold can be customized here
			PackItem( new Dagger() );
			PackItem( new AedilisLantern() );
			PackItem( new TrashPack() );
                        PackItem( new BankToken() );
			//PackItem( new WelcomeBook() );
			
			WristWatch SWW = new WristWatch();
			SWW.Name = "Time Keeper's Watch";
			SWW.Hue = 46;
			SWW.LootType = LootType.Blessed;
                        PackItem( SWW );

			//IDWand SID = new IDWand();
                        //SID.Charges = 10;
			//SID.Name = "Starter ID Wand";
			//SID.Identified = true;
                        //PackItem( SID );

			if (m.AccessLevel > AccessLevel.Player)
			PackItem( new StaffLantern() );

			if (m.AccessLevel > AccessLevel.Player)
			PackItem( new GMEthereal() );

			if (m.AccessLevel > AccessLevel.Player)
			PackItem( new GMHidingStone() );

			if (m.AccessLevel == AccessLevel.Counselor)
			PackItem( new CounselorRobe() );

			if (m.AccessLevel == AccessLevel.GameMaster)
			PackItem( new GMRobe() );

			if (m.AccessLevel == AccessLevel.Administrator)
			PackItem( new GMRobe() );

			if (m.AccessLevel == AccessLevel.Developer)
			PackItem( new DeveloperRobe() );

			if (m.AccessLevel == AccessLevel.Owner)
			PackItem( new OwnerRobe() );

			PlayerMobile pm = (PlayerMobile)m;
			pm.PopUpToggle = true;

		}
コード例 #24
0
ファイル: SecureTrade.cs プロジェクト: rokann/JustUO
		public SecureTradeInfo(SecureTrade owner, Mobile m, SecureTradeContainer c)
		{
			Owner = owner;
			Mobile = m;
			Container = c;

			Mobile.AddItem(Container);

			VirtualCheck = new VirtualCheck(0, 0);
			Container.DropItem(VirtualCheck);
		}
コード例 #25
0
ファイル: Charm.cs プロジェクト: evildude807/kaltar
        private void CopyFromLayer(Mobile from, Mobile mimic, Layer layer)
        {
            Item newItem;
            Item oldItem = from.FindItemOnLayer(layer);
            if (oldItem != null)
            {
                Type t = oldItem.GetType();
                ConstructorInfo c = t.GetConstructor(Type.EmptyTypes);
                if (c != null)
                {
                    try
                    {
                        object o = c.Invoke(null);

                        if (o != null && o is Item)
                        {
                            newItem = (Item)o;
                            Dupe.CopyProperties(newItem, oldItem);//copy.Dupe( item, copy.Amount );
                            mimic.AddItem(newItem);
                            newItem.LootType = LootType.Newbied;
                        }
                    }
                    catch
                    {
                        from.SendMessage("Error!  Please check Charm.cs!");
                        return;
                    }
                }
            }
        }