Exemplo n.º 1
0
		public override bool OnEquip( Mobile m )
		{
			base.OnEquip( m );
			m_SkillMod1 = new DefaultSkillMod( SkillName.Archery, true, 10 );
			m.AddSkillMod(m_SkillMod1 );
			m_SkillMod2 = new DefaultSkillMod( SkillName.Tactics, true, 10 );
			m.AddSkillMod(m_SkillMod2 );
			m_SkillMod3 = new DefaultSkillMod( SkillName.Anatomy, true, 10 );
			m.AddSkillMod(m_SkillMod3 );
			return true;
			
			/// <summary>
	 	/// i with to make a gm clothing packet for my gm's ingame
	 	/// </summary>
	 	
	 	if ( m.AccessLevel <= AccessLevel.GameMaster )
		    {
	 			m.SendMessage( "You are not granted to wear this item" );
		    	this.Delete();
		    	return false;
	 		}
	 		else
	 		{
	 			m.SendMessage( "Access Granted mighty one" );
	 			return true;
	 		}
	 				
		}
		public override bool OnEquip( Mobile m )
		{
			base.OnEquip( m );
			m_SkillMod = new DefaultSkillMod( SkillName.Fishing, true, 60 ); 
			m.AddSkillMod(m_SkillMod );
			return true;
		}
Exemplo n.º 3
0
			//private SkillMod m_SkillMod2;

			public CountdownTimer( Mobile mobile, SkillMod skill0, SkillMod skill1 ): base( TimeSpan.Zero, TimeSpan.FromSeconds( 1.0 ) )
			{
				m_Mobile = mobile;
				m_SkillMod0 = skill0;
				m_SkillMod1 = skill1;
				Priority = TimerPriority.TwoFiftyMS;
			}
Exemplo n.º 4
0
		private void DefineMods()
		{
			m_SkillMod0 = new DefaultSkillMod( SkillName.Archery, true, 20 );
			m_SkillMod1 = new DefaultSkillMod( SkillName.Tactics, true, 20 );
			m_SkillMod2 = new DefaultSkillMod( SkillName.Anatomy, true, 20 );
			m_StatMod0 = new StatMod( StatType.Dex, "ArcheryPvPDex", 20, TimeSpan.Zero );
			m_StatMod1 = new StatMod( StatType.Str, "ArcheryPvPStr", 20, TimeSpan.Zero );
		}
Exemplo n.º 5
0
		private void DefineMods()
		{
			m_SkillMod0 = new DefaultSkillMod( SkillName.Magery, true, 20 ); 
			m_SkillMod1 = new DefaultSkillMod( SkillName.EvalInt, true, 20 ); 
			m_SkillMod2 = new DefaultSkillMod( SkillName.Necromancy, true, 20 ); 
                        		m_SkillMod3 = new DefaultSkillMod( SkillName.Inscribe, true, 20 );
			m_StatMod0 = new StatMod( StatType.Int, "MasterSandals", 20, TimeSpan.Zero ); 
		}
Exemplo n.º 6
0
		private void DefineMods()
		{
			m_SkillMod0 = new DefaultSkillMod( SkillName.Stealth, true, 20 ); 
			m_SkillMod1 = new DefaultSkillMod( SkillName.Hiding, true, 20 ); 
			m_SkillMod2 = new DefaultSkillMod( SkillName.Stealing, true, 20 );
                        		m_SkillMod3 = new DefaultSkillMod( SkillName.Fencing, true, 20 );  
			m_StatMod0 = new StatMod( StatType.Dex, "RogueSandals", 15, TimeSpan.Zero ); 
		}
		public override void OnRemoved( object parent )
		{
			base.OnRemoved( parent );

			if ( m_SkillMod != null ) 
			m_SkillMod.Remove(); 
			m_SkillMod = null; 
		}
Exemplo n.º 8
0
		public void AddMods( Mobile from )
		{
			if ( m_SkillMod0 == null )
				m_SkillMod0 = new DefaultSkillMod( SkillName.EvalInt, true, 100 );

			if ( m_SkillMod1 == null )
				m_SkillMod1 = new DefaultSkillMod( SkillName.Tactics, true, 100 );

			from.AddSkillMod( m_SkillMod0 );
			from.AddSkillMod( m_SkillMod1 );
		}
		public override void OnAdded( object parent )
		{
			base.OnAdded( parent );

			if ( m_Bonus != 0 && parent is Mobile )
			{
				if ( m_SkillMod != null )
					m_SkillMod.Remove();

				m_SkillMod = new DefaultSkillMod( SkillName.Blacksmith, true, m_Bonus );
				((Mobile)parent).AddSkillMod( m_SkillMod );
			}
		}
Exemplo n.º 10
0
		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				case 0:
				{
					m_Bonus = reader.ReadInt();
					break;
				}
			}

			if ( m_Bonus != 0 && Parent is Mobile )
			{
				if ( m_SkillMod != null )
					m_SkillMod.Remove();

				m_SkillMod = new DefaultSkillMod( SkillName.Blacksmith, true, m_Bonus );
				((Mobile)Parent).AddSkillMod( m_SkillMod );
			}

			if ( Hue == 0 )
				Hue = 0x482;

			if ( version == 0 )
			{
				AncientSmithHammerWeapon hammer = new AncientSmithHammerWeapon( m_Bonus, UsesRemaining );
				Timer.DelayCall<Item>( TimeSpan.FromSeconds( 1.0 ), new TimerStateCallback<Item>( Replace_Item ), hammer );
			}
		}
Exemplo n.º 11
0
 public AnimalFormContext( Timer timer, SkillMod mod, bool speedBoost, Type type )
 {
     m_Timer = timer;
     m_Mod = mod;
     m_SpeedBoost = speedBoost;
     m_Type = type;
 }
Exemplo n.º 12
0
        private void InternalRemoveSkillMod( SkillMod mod )
        {
            if ( m_SkillMods != null && m_SkillMods.Contains( mod ) )
            {
                m_SkillMods.Remove( mod );
                if (m_SkillMods.Count == 0)
                    m_SkillMods = null;

                mod.Owner = null;

                Skill sk = m_Skills[mod.Skill];

                if ( sk != null )
                    sk.Update();
            }
        }
Exemplo n.º 13
0
        public virtual void RemoveSkillMod( SkillMod mod )
        {
            if ( mod == null )
                return;

            ValidateSkillMods();

            InternalRemoveSkillMod( mod );
        }
Exemplo n.º 14
0
        public virtual void AddSkillMod( SkillMod mod )
        {
            if ( mod == null )
                return;

            ValidateSkillMods();

            if (m_SkillMods == null)
                m_SkillMods = new ArrayList(4);

            if ( !m_SkillMods.Contains( mod ) )
            {
                m_SkillMods.Add( mod );
                mod.Owner = this;

                Skill sk = m_Skills[mod.Skill];

                if ( sk != null )
                    sk.Update();
            }
        }
Exemplo n.º 15
0
			private void RemoveMods()
			{
				if ( m_SkillMod0 != null )
					m_Mobile.RemoveSkillMod( m_SkillMod0 );

				if ( m_SkillMod1 != null )
					m_Mobile.RemoveSkillMod( m_SkillMod1 );

				m_SkillMod0 = null;
				m_SkillMod1 = null;

				m_Mobile.SendMessage(1276, "Quad Damage Has Worn Off!");
			}
Exemplo n.º 16
0
 public BonusContext( Timer timer, SkillMod mod )
 {
     m_Timer = timer;
     m_Mod = mod;
 }
        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();

            switch ( version )
            {
                case 0:
                {
                    m_Bonus = reader.ReadInt();
                    break;
                }
            }

            if ( m_Bonus != 0 && Parent is Mobile )
            {
                if ( m_SkillMod != null )
                    m_SkillMod.Remove();

                m_SkillMod = new DefaultSkillMod( SkillName.Blacksmith, true, m_Bonus );
                ((Mobile)Parent).AddSkillMod( m_SkillMod );
            }

            if ( Hue == 0 )
                Hue = 0x482;
        }
Exemplo n.º 18
0
		public AnimalFormContext( Timer timer, SkillMod mod, bool speedBoost, Type type, bool stealingBonus )
		{
			m_Timer = timer;
			m_Mod = mod;
			m_SpeedBoost = speedBoost;
			m_Type = type;

			#region Mondain's Legacy
			m_StealingBonus = stealingBonus;
			#endregion
		}
Exemplo n.º 19
0
        private static void InternalAddSkillMod( this Mobile m, SkillMod mod )
        {
            if ( !m_SkillMods.ContainsKey( m ) )
                m_SkillMods[m] = new List<SkillMod>();

            IList<SkillMod> mods = m_SkillMods[m];

            if ( !mods.Contains( mod ) )
            {
                mods.Add( mod );

                mod.Owner = m;

                Skill sk = m.Skills[mod.Skill];

                if ( sk != null )
                    sk.Update();
            }
        }
		private void DefineMods()
		{
            m_SkillMod0 = new DefaultSkillMod(SkillName.Blacksmith, true, 15);
            m_SkillMod2 = new DefaultSkillMod(SkillName.Mining, true, 15);
          
		}
Exemplo n.º 21
0
        public static void AddSkillMod( this Mobile m, SkillMod mod )
        {
            if ( mod == null )
                return;

            m.ValidateSkillMods();

            m.InternalAddSkillMod( mod );
        }
Exemplo n.º 22
0
        private static void InternalRemoveSkillMod( this Mobile m, SkillMod mod )
        {
            if ( !m_SkillMods.ContainsKey( m ) )
                return;

            IList<SkillMod> mods = m_SkillMods[m];

            if ( mods.Contains( mod ) )
            {
                mods.Remove( mod );

                mod.Owner = null;

                Skill sk = m.Skills[mod.Skill];

                if ( sk != null )
                    sk.Update();

                if ( mods.Count == 0 )
                    m_SkillMods.Remove( m );
            }
        }