• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Server.ResistanceMod类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Server.ResistanceMod的典型用法代码示例。如果您正苦于以下问题:C# ResistanceMod类的具体用法?C# ResistanceMod怎么用?C# ResistanceMod使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ResistanceMod类属于Server命名空间,在下文中一共展示了ResistanceMod类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ResistanceModTimer

 public ResistanceModTimer(Mobile m, string name, ResistanceMod[] mods, TimeSpan duration)
     : base(duration)
 {
     this.m_Mobile = m;
     this.m_Name = name;
     this.m_Mods = mods;
 }
开发者ID:Crome696,项目名称:ServUO,代码行数:7,代码来源:TimedResistanceMod.cs


示例2: OnHit

		public override void OnHit( Mobile attacker, Mobile defender, int damage )
		{
			if( !Validate( attacker ) || !CheckMana( attacker, true ) )
				return;

			ClearCurrentAbility( attacker );

			attacker.SendLocalizedMessage( 1063353 ); // You perform a masterful defense!

			attacker.FixedParticles( 0x375A, 1, 17, 0x7F2, 0x3E8, 0x3, EffectLayer.Waist );

			int modifier = (int)(30.0 * ((Math.Max( attacker.Skills[SkillName.Bushido].Value, attacker.Skills[SkillName.Ninjitsu].Value ) - 50.0) / 70.0));

			DefenseMasteryInfo info = m_Table[attacker] as DefenseMasteryInfo;

			if( info != null )
				EndDefense( (object)info );

			ResistanceMod mod = new ResistanceMod( ResistanceType.Physical, 50 + modifier );
			attacker.AddResistanceMod( mod );

			info = new DefenseMasteryInfo( attacker, 80 - modifier, mod );
			info.m_Timer = Timer.DelayCall( TimeSpan.FromSeconds( 3.0 ), new TimerStateCallback( EndDefense ), info );

			m_Table[attacker] = info;

			attacker.Delta( MobileDelta.WeaponDamage );
		}
开发者ID:nick12344356,项目名称:The-Basement,代码行数:28,代码来源:DefenseMastery.cs


示例3: ExpireTimer

			public ExpireTimer( Mobile m, ResistanceMod mod )
				: base( TimeSpan.FromSeconds( 10 ) )
			{
				m_Mobile = m;
				m_Mod = mod;
				Priority = TimerPriority.TwoFiftyMS;
			}
开发者ID:jackuoll,项目名称:Pre-AOS-RunUO,代码行数:7,代码来源:LadyJennifyr.cs


示例4: OnCast

        public override void OnCast()
        {
            if( CheckSequence() )
            {
                ArrayList targets = new ArrayList();

                foreach ( Mobile m in Caster.GetMobilesInRange( 3 ) )
                {
                    if ( Caster.CanBeBeneficial( m, false, true ) && !(m is Golem) )
                        targets.Add( m );
                }

                for ( int i = 0; i < targets.Count; ++i )
                {
                    Mobile m = (Mobile)targets[i];

                    TimeSpan duration = TimeSpan.FromSeconds( Caster.Skills[SkillName.Musicianship].Value * 0.2 );
                    int amount = (int)( Caster.Skills[SkillName.Musicianship].Value * .125 );

                    m.SendMessage( "Your fire resistance has increased." );
                    ResistanceMod mod1 = new ResistanceMod( ResistanceType.Fire, + amount );

                    m.AddResistanceMod( mod1 );

                    m.FixedParticles( 0x373A, 10, 15, 5012, 0x21, 3, EffectLayer.Waist );

                    new ExpireTimer( m, mod1, duration ).Start();
                }
            }

            FinishSequence();
        }
开发者ID:evildude807,项目名称:kaltar,代码行数:32,代码来源:FireCarolSpell.cs


示例5: ExpireTimer

		public ExpireTimer( Mobile m, ResistanceMod[] mod, TimeSpan delay, Hashtable hashtbl ) : base( delay )
		{
			m_Mobile = m;

			m_Mod = mod;

			m_Hashtbl = hashtbl;
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:8,代码来源:BaseTimersSE.cs


示例6: AddMod

		public static void AddMod( Mobile m, string name, ResistanceMod[] mods, TimeSpan duration )
		{
			string fullname = name + ":" + m.Serial.ToString();

			if ( m_Table.ContainsKey( fullname ) )
			{
				ResistanceModTimer timer = m_Table[fullname];
				timer.Stop();
				m_Table.Remove( fullname );
			}

			ResistanceModTimer timertostart = new ResistanceModTimer( m, name, mods, duration );
			timertostart.Start();
			m_Table.Add( fullname, timertostart );
		}
开发者ID:romeov007,项目名称:imagine-uo,代码行数:15,代码来源:TimedResistanceMod.cs


示例7: OnGaveMeleeAttack

		public override void OnGaveMeleeAttack( Mobile defender )
		{
			base.OnGaveMeleeAttack( defender );
			
			if ( m_Table == null )
				m_Table = new Hashtable();
		
			if ( Combatant != null && m_Table[ Combatant ] == null )
			{
				ResistanceMod mod = new ResistanceMod( ResistanceType.Fire, -10 );
				Combatant.AddResistanceMod( mod );
				m_Table[ Combatant ] = mod;
				Timer.DelayCall( TimeSpan.FromSeconds( 30 ), new TimerStateCallback( EndMod_Callback ), Combatant );
			}
		}
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:15,代码来源:LadyJennifyr.cs


示例8: OnHit

		public override void OnHit( Mobile attacker, Mobile defender, double damageBonus )
		{
			base.OnHit( attacker, defender, damageBonus );

			if ( attacker != null && defender != null )
			{
				ResistanceMod[] mods = new ResistanceMod[]{ new ResistanceMod( ResistanceType.Fire, -15 ) };

				for ( int i = 0; i < mods.Length; ++i )
					attacker.AddResistanceMod( mods[i] );

				TimedResistanceMod.AddMod( 
					defender, 
					"BistroFork", 
					mods, 
					TimeSpan.FromSeconds( 10 )
				);
			}
		}
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:19,代码来源:BistroFork.cs


示例9: CorruptArmorAttack

        public static void CorruptArmorAttack( Mobile from, ref ExpireTimer timer, Mobile target )
        {
            ResistanceMod[] mod = new ResistanceMod[5]
            {
                new ResistanceMod( ResistanceType.Fire, -target.FireResistance / 2 ),
                new ResistanceMod( ResistanceType.Poison, -target.PoisonResistance / 2 ),
                new ResistanceMod( ResistanceType.Cold, -target.ColdResistance / 2 ),
                new ResistanceMod( ResistanceType.Energy, -target.EnergyResistance / 2 ),
                new ResistanceMod( ResistanceType.Physical, -target.PhysicalResistance / 2 )
            };

            target.SendLocalizedMessage( 1070846 ); // The creature magically corrupts your armor!

            TimeSpan duration = TimeSpan.FromSeconds( 2 + Utility.Random( 3 ) );

            LowerResistanceAttack( from, ref timer, duration, target, mod, m_RuneBeetleRMT );

            return;
        }
开发者ID:Ravenwolfe,项目名称:xrunuo,代码行数:19,代码来源:BaseAttackHelperSE.cs


示例10: OnGaveMeleeAttack

		public override void OnGaveMeleeAttack( Mobile defender )
		{
			base.OnGaveMeleeAttack( defender );

			if ( Utility.RandomDouble() < 0.1 )
			{
				ExpireTimer timer;

				if ( m_Table.TryGetValue( defender, out timer ) )
					timer.DoExpire();

				defender.FixedParticles( 0x3709, 10, 30, 5052, EffectLayer.LeftFoot );
				defender.PlaySound( 0x208 );
				defender.SendLocalizedMessage( 1070833 ); // The creature fans you with fire, reducing your resistance to fire attacks.

				ResistanceMod mod = new ResistanceMod( ResistanceType.Fire, -10 );
				defender.AddResistanceMod( mod );

				m_Table[defender] = timer = new ExpireTimer( defender, mod );
				timer.Start();
			}
		}
开发者ID:jackuoll,项目名称:Pre-AOS-RunUO,代码行数:22,代码来源:LadyJennifyr.cs


示例11: LowerResistanceAttack

		public static void LowerResistanceAttack( Mobile from, ref ExpireTimer timer, TimeSpan duration, Mobile target, ResistanceMod[] mod, Hashtable hashtbl )
		{
			target.PlaySound( 0x1E9 );
			target.FixedParticles( 0x376A, 9, 32, 5008, EffectLayer.Waist );

			timer = new ExpireTimer( target, mod, duration, hashtbl );
			timer.Start();

			hashtbl[target] = timer;

			for (int i=0;i<mod.Length;i++)
				target.AddResistanceMod( mod[i] );		

			if ( hashtbl == m_RuneBeetleRMT )
				target.SendLocalizedMessage( 1070845 ); // The creature continues to corrupt your armor!

			if ( hashtbl == m_FanDancerRMT )
				target.SendLocalizedMessage( 1070835 ); // The creature surrounds you with fire, reducing your resistance to fire attacks.

			from.DoHarmful( target );

			return;
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:23,代码来源:BaseAttackHelperSE.cs


示例12: OnGaveMeleeAttack

		public override void OnGaveMeleeAttack( Mobile defender )
		{
			base.OnGaveMeleeAttack( defender );

			if( 0.1 > Utility.RandomDouble() )
			{
				/* Grasping Claw
				 * Start cliloc: 1070836
				 * Effect: Physical resistance -15% for 5 seconds
				 * End cliloc: 1070838
				 * Effect: Type: "3" - From: "0x57D4F5B" (player) - To: "0x0" - ItemId: "0x37B9" - ItemIdName: "glow" - FromLocation: "(1149 808, 32)" - ToLocation: "(1149 808, 32)" - Speed: "10" - Duration: "5" - FixedDirection: "True" - Explode: "False"
				 */

				ExpireTimer timer = (ExpireTimer)m_Table[defender];

				if( timer != null )
				{
					timer.DoExpire();
					defender.SendLocalizedMessage( 1070837 ); // The creature lands another blow in your weakened state.
				}
				else
					defender.SendLocalizedMessage( 1070836 ); // The blow from the creature's claws has made you more susceptible to physical attacks.

				int effect = -(defender.PhysicalResistance * 15 / 100);

				ResistanceMod mod = new ResistanceMod( ResistanceType.Physical, effect );

				defender.FixedEffect( 0x37B9, 10, 5 );
				defender.AddResistanceMod( mod );

				timer = new ExpireTimer( defender, mod, TimeSpan.FromSeconds( 5.0 ) );
				timer.Start();
				m_Table[defender] = timer;
			}
		}
开发者ID:nathanvy,项目名称:runuo,代码行数:35,代码来源:Hiryu.cs


示例13: DefenseMasteryInfo

			public DefenseMasteryInfo( Mobile from, int damageMalus, ResistanceMod mod )
			{
				m_From = from;
				m_DamageMalus = damageMalus;
				m_Mod = mod;
			}
开发者ID:nick12344356,项目名称:The-Basement,代码行数:6,代码来源:DefenseMastery.cs


示例14: FinalEffect

        public static void FinalEffect( Mobile target, int protection, int duration )
        {
            if( target == null || target.Deleted || !(target is IKhaerosMobile) )
                return;

            if( target.ResistanceMods != null )
                target.ResistanceMods.Clear();

            if( ((IKhaerosMobile)target).AuraOfProtection != null )
                ((IKhaerosMobile)target).AuraOfProtection.Stop();

            target.PlaySound( 0x1E9 );
            target.FixedParticles( 0x375A, 9, 20, 5016, EffectLayer.Waist );

            ResistanceMod blunt = new ResistanceMod( ResistanceType.Blunt, protection );
            ResistanceMod slash = new ResistanceMod( ResistanceType.Slashing, protection );
            ResistanceMod pierce = new ResistanceMod( ResistanceType.Piercing, protection );
            target.AddResistanceMod( blunt );
            target.AddResistanceMod( slash );
            target.AddResistanceMod( pierce );

            ((IKhaerosMobile)target).AuraOfProtection = new AuraOfProtectionTimer( target, duration );
            ((IKhaerosMobile)target).AuraOfProtection.Start();

            if( target is PlayerMobile && ((PlayerMobile)target).HasGump( typeof( CharInfoGump ) ) )
                ((PlayerMobile)target).SendGump( new CharInfoGump( (PlayerMobile)target ) );
        }
开发者ID:justdanofficial,项目名称:khaeros,代码行数:27,代码来源:AuraOfProtection.cs


示例15: OnTick

            protected override void OnTick()
            {
                if( m_target == null )
                    return;

                if( m_animsleft > 0 )
                {
                    m_animsleft--;
                    m_target.FixedParticles( 0x375A, 9, 20, 5016, EffectLayer.Waist );
                    ( (IKhaerosMobile)m_target ).AuraOfProtection = new AuraOfProtectionTimer( m_target, m_animsleft );
                    ( (IKhaerosMobile)m_target ).AuraOfProtection.Start();
                }

                else
                {
                    if( m_target.ResistanceMods != null )
                        m_target.ResistanceMods.Clear();

                    ResistanceMod blunt = new ResistanceMod( ResistanceType.Blunt, 0 );
                    ResistanceMod slash = new ResistanceMod( ResistanceType.Slashing, 0 );
                    ResistanceMod pierce = new ResistanceMod( ResistanceType.Piercing, 0 );
                    m_target.AddResistanceMod( blunt );
                    m_target.AddResistanceMod( slash );
                    m_target.AddResistanceMod( pierce );

                    if( m_target is PlayerMobile && ( (PlayerMobile)m_target ).HasGump( typeof( CharInfoGump ) ) && ( (PlayerMobile)m_target ).m_CharInfoTimer == null )
                    {
                        ( (PlayerMobile)m_target ).m_CharInfoTimer = new CharInfoGump.CharInfoTimer( ( (PlayerMobile)m_target ) );
                        ( (PlayerMobile)m_target ).m_CharInfoTimer.Start();
                    }

                    if( ( (IKhaerosMobile)m_target ).AuraOfProtection != null )
                    {
                        ( (IKhaerosMobile)m_target ).AuraOfProtection.Stop();
                        ( (IKhaerosMobile)m_target ).AuraOfProtection = null;
                    }
                }
            }
开发者ID:justdanofficial,项目名称:khaeros,代码行数:38,代码来源:AuraOfProtection.cs


示例16: ApplyFortune

        public void ApplyFortune(int fortune, int power)
        {
            if (m_FortuneType1 == 0)
            {
                AnnounceFortune(fortune);

                switch (fortune)
                {
                    default:
                    case 1: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Physical, power)); break;
                    case 2: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Fire, power)); break;
                    case 3: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Cold, power)); break;
                    case 4: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Poison, power)); break;
                    case 5: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Energy, power)); break;
                    case 11: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Physical, -power)); break;
                    case 12: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Fire, -power)); break;
                    case 13: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Cold, -power)); break;
                    case 14: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Poison, -power)); break;
                    case 15: AddResistanceMod(m_FortuneMod1 = new ResistanceMod(ResistanceType.Energy, -power)); break;
                }

                m_FortuneType1 = fortune;
                m_FortunePower1 = power;
            }
            else if (fortune != m_FortuneType1)
            {
                AnnounceFortune(fortune);

                switch (fortune)
                {
                    default:
                    case 1: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Physical, power)); break;
                    case 2: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Fire, power)); break;
                    case 3: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Cold, power)); break;
                    case 4: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Poison, power)); break;
                    case 5: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Energy, power)); break;
                    case 11: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Physical, -power)); break;
                    case 12: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Fire, -power)); break;
                    case 13: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Cold, -power)); break;
                    case 14: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Poison, -power)); break;
                    case 15: AddResistanceMod(m_FortuneMod2 = new ResistanceMod(ResistanceType.Energy, -power)); break;
                }

                m_FortuneType2 = fortune;
                m_FortunePower2 = power;
            }
            else
            {
                // pick another fortune
            }
        }
开发者ID:greeduomacro,项目名称:cov-shard-svn-1,代码行数:51,代码来源:PlayerMobile.cs


示例17: OnTarget

           protected override void OnTarget(Mobile from, object targeted)
           {
                PlayerMobile pm = from as PlayerMobile;

                if (m_Tasty.Deleted)
                    return;

                if ( targeted is BaseCreature )
                {
                    BaseCreature creature = (BaseCreature)targeted;

                    if ( (creature.Controlled || creature.Summoned ) && (from == creature.ControlMaster) && !(creature.Sleep) )
                    {
                        creature.FixedParticles( 0x373A, 10, 15, 5018, EffectLayer.Waist );
	                creature.PlaySound( 0x1EA );

                        ResistanceMod mod = new ResistanceMod( ResistanceType.Physical, +15 );
                        ResistanceMod mod1 = new ResistanceMod( ResistanceType.Fire, +10 );
                        ResistanceMod mod2 = new ResistanceMod( ResistanceType.Cold, +10 );
                        ResistanceMod mod3 = new ResistanceMod( ResistanceType.Poison, +10 );
                        ResistanceMod mod4 = new ResistanceMod( ResistanceType.Energy, +10 );
			creature.AddResistanceMod( mod );
                        creature.AddResistanceMod( mod1 ); 
                        creature.AddResistanceMod( mod2 );
                        creature.AddResistanceMod( mod3 );
                        creature.AddResistanceMod( mod4 ); 

                        from.SendMessage("You have increased the Damage Absorption of your pet by 10% for 10 Minutes !!");  
                        m_Tasty.m_Used = true;
                        creature.Sleep = true; 

                       
                        Timer.DelayCall(TimeSpan.FromMinutes(10.0), delegate()
                        {
                        
                        ResistanceMod mod5 = new ResistanceMod( ResistanceType.Physical, -15 );
                        ResistanceMod mod6 = new ResistanceMod( ResistanceType.Fire, -10 );
                        ResistanceMod mod7 = new ResistanceMod( ResistanceType.Cold, -10 );
                        ResistanceMod mod8 = new ResistanceMod( ResistanceType.Poison, -10 );
                        ResistanceMod mod9 = new ResistanceMod( ResistanceType.Energy, -10 );
			creature.AddResistanceMod( mod5 );
                        creature.AddResistanceMod( mod6 ); 
                        creature.AddResistanceMod( mod7 );
                        creature.AddResistanceMod( mod8 );
                        creature.AddResistanceMod( mod9 ); 
                        creature.PlaySound( 0x1EB );
                       
                        m_Tasty.m_Used = true; 
                        creature.Sleep = false;
                        from.SendMessage("The effect of Vial of Armor Essence is finish !");   

                           Timer.DelayCall(TimeSpan.FromMinutes(120.0), delegate()
                           {
                           m_Tasty.m_Used = false;                                                
                           });
                                               
                        });
                                             
                    }
                    else if ( (creature.Controlled || creature.Summoned ) && (from == creature.ControlMaster) && (creature.Sleep) )
                    {
                         from.SendMessage("Pet already under the influence of Vial of Armor Essence !");     
                    }                     
                    else 
                    {
                          from.SendLocalizedMessage(1113049);    
                    }
                }
                else
                {
                   from.SendLocalizedMessage(500329);        
                }                      
            }  
开发者ID:suiy187,项目名称:runuocustom,代码行数:73,代码来源:VialofArmorEssence.cs


示例18: RemoveResistanceMod

        public virtual void RemoveResistanceMod( ResistanceMod toRemove )
        {
            if ( m_ResistMods != null )
            {
                m_ResistMods.Remove( toRemove );

                if ( m_ResistMods.Count == 0 )
                    m_ResistMods = null;
            }

            UpdateResistances();
        }
开发者ID:BackupTheBerlios,项目名称:sunuo-svn,代码行数:12,代码来源:Mobile.cs


示例19: HiryuAbilitiesAttack

		public static void HiryuAbilitiesAttack( Mobile from, ref ExpireTimer timer )
		{
			Mobile target = GetRandomAttacker( from, 1 );

			if (target == null) return;

			if (Utility.RandomBool())
			{
				if (IsUnderEffect( target, BaseAttackHelperSE.m_HiryuRMT )) return;

				TimeSpan duration = TimeSpan.FromSeconds( 121 - (int)(target.Skills[SkillName.MagicResist].Value) );

				ResistanceMod[] mod = new ResistanceMod[1]
				{
					new ResistanceMod( ResistanceType.Physical, -25 )
				};

				LowerResistanceAttack( from, ref timer, duration, target, mod, m_HiryuRMT );
			}
			else
			{
				if (!target.Mounted) return;

				DismountAttack( from, target );
			}
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:26,代码来源:BaseAttackHelperSE.cs


示例20: OnGaveMeleeAttack

        public override void OnGaveMeleeAttack( Mobile defender )
        {
            base.OnGaveMeleeAttack( defender );

            if( 0.1 > Utility.RandomDouble() )
            {
                /* Flurry of Twigs
                 * Start cliloc: 1070850
                 * Effect: Physical resistance -15% for 5 seconds
                 * End cliloc: 1070852
                 * Effect: Type: "3" From: "0x57D4F5B" To: "0x0" ItemId: "0x37B9" ItemIdName: "glow" FromLocation: "(1048 779, 6)" ToLocation: "(1048 779, 6)" Speed: "10" Duration: "5" FixedDirection: "True" Explode: "False"
                 */

                ExpireTimer timer = (ExpireTimer)m_FlurryOfTwigsTable[defender];

                if( timer != null )
                {
                    timer.DoExpire();
                    defender.SendLocalizedMessage( 1070851 ); // The creature lands another blow in your weakened state.
                }
                else
                    defender.SendLocalizedMessage( 1070850 ); // The creature's flurry of twigs has made you more susceptible to physical attacks!

                int effect = -(defender.PhysicalResistance * 15 / 100);

                ResistanceMod mod = new ResistanceMod( ResistanceType.Physical, effect );

                defender.FixedEffect( 0x37B9, 10, 5 );
                defender.AddResistanceMod( mod );

                timer = new ExpireTimer( defender, mod, m_FlurryOfTwigsTable, TimeSpan.FromSeconds( 5.0 ) );
                timer.Start();
                m_FlurryOfTwigsTable[defender] = timer;
            }
            else if( 0.05 > Utility.RandomDouble() )
            {
                /* Chlorophyl Blast
                 * Start cliloc: 1070827
                 * Effect: Energy resistance -50% for 10 seconds
                 * End cliloc: 1070829
                 * Effect: Type: "3" From: "0x57D4F5B" To: "0x0" ItemId: "0x37B9" ItemIdName: "glow" FromLocation: "(1048 779, 6)" ToLocation: "(1048 779, 6)" Speed: "10" Duration: "5" FixedDirection: "True" Explode: "False"
                 */

                ExpireTimer timer = (ExpireTimer)m_ChlorophylBlastTable[defender];

                if( timer != null )
                {
                    timer.DoExpire();
                    defender.SendLocalizedMessage( 1070828 ); // The creature continues to hinder your energy resistance!
                }
                else
                    defender.SendLocalizedMessage( 1070827 ); // The creature's attack has made you more susceptible to energy attacks!

                int effect = -(defender.EnergyResistance / 2);

                ResistanceMod mod = new ResistanceMod( ResistanceType.Energy, effect );

                defender.FixedEffect( 0x37B9, 10, 5 );
                defender.AddResistanceMod( mod );

                timer = new ExpireTimer( defender, mod, m_ChlorophylBlastTable, TimeSpan.FromSeconds( 10.0 ) );
                timer.Start();
                m_ChlorophylBlastTable[defender] = timer;
            }
        }
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:65,代码来源:KazeKemono.cs



注:本文中的Server.ResistanceMod类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Server.SaveMetrics类代码示例发布时间:2022-05-26
下一篇:
C# Server.Region类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap