本文整理汇总了C#中Server.Mobile.FixedParticles方法的典型用法代码示例。如果您正苦于以下问题:C# Mobile.FixedParticles方法的具体用法?C# Mobile.FixedParticles怎么用?C# Mobile.FixedParticles使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server.Mobile
的用法示例。
在下文中一共展示了Mobile.FixedParticles方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Drink
public override void Drink( Mobile from )
{
if ( from.BeginAction( typeof( BaseMaskOfDeathPotion ) ) )
{
if ( !UnderEffect( from ) )
{
Timer t = (Timer)m_Table[from];
if ( t != null )
t.Stop();
m_Table[from] = t = Timer.DelayCall( Duration, new TimerStateCallback( Expire_Callback ), from );
//Effects.SendPacket( from, from.Map, new GraphicalEffect( EffectType.FixedFrom, from.Serial, Serial.Zero, 0x375A, from.Location, from.Location, 10, 15, true, false ) );//Default
from.FixedParticles( 0x3779, 10, 15, 5002, EffectLayer.Head );
from.FixedParticles( 0x376A, 9, 32, 5008, EffectLayer.Waist );
from.FixedParticles( 0x3778, 10, 30, 5010, EffectLayer.Head );
from.SendLocalizedMessage( 503326 ); // You are now ignored by monsters.
Delete();
}
Timer.DelayCall( TimeSpan.FromMinutes( Delay ),new TimerStateCallback( Release ), from );
}
else
{
from.SendMessage("You must wait 30 minutes to use this potion" );
}
}
示例2: OnDeath
public override void OnDeath( Mobile m )
{
bool toreturn = true;
if ( m != null && !m.Deleted)
{
if (m is PlayerMobile && m_Controller.NoPlayerItemDrop)
{
if (m.Female)
{
m.FixedParticles(0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist);
m.Body = 403;
m.Hidden = true;
}
else
{
m.FixedParticles(0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist);
m.Body = 402;
m.Hidden = true;
}
m.Hidden = false;
toreturn = false;
}
else if ( !(m is PlayerMobile) && m_Controller.NoNPCItemDrop)
{
if (m.Female)
{
m.FixedParticles(0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist);
m.Body = 403;
m.Hidden = true;
}
else
{
m.FixedParticles(0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist);
m.Body = 402;
m.Hidden = true;
}
m.Hidden = false;
toreturn = false;
}
else
toreturn = true;
// Start a 1 second timer
// The Timer will check if they need moving, corpse deleting etc.
m_Timer = new MovePlayerTimer(m, m_Controller);
m_Timer.Start();
// return base.OnDeath(m);
}
base.OnDeath(m);
}
示例3: FinalEffect
public static void FinalEffect( Mobile caster, Mobile target, int duration, double protection )
{
target.PlaySound( 0x202 );
target.FixedParticles( 0x376A, 1, 62, 9923, 3, 3, EffectLayer.Waist );
target.FixedParticles( 0x3779, 1, 46, 9502, 5, 3, EffectLayer.Waist );
( (IKhaerosMobile)target ).ShieldingMobile = caster;
( (IKhaerosMobile)target ).ShieldValue = protection;
( (IKhaerosMobile)caster ).ShieldedMobile = target;
Timer.DelayCall( TimeSpan.FromMinutes( duration ), new TimerCallback( ( (IKhaerosMobile)target ).RemoveShieldOfSacrifice ) );
Timer.DelayCall( TimeSpan.FromMinutes( duration ), new TimerCallback( ( (IKhaerosMobile)caster ).RemoveShieldOfSacrifice ) );
}
示例4: FinalEffect
public static void FinalEffect(Mobile caster, Mobile target, int hold)
{
target.PlaySound(0x204);
target.FixedParticles(0x37C4, 1, 8, 9916, 39, 3, EffectLayer.Head);
target.FixedParticles(0x37C4, 1, 8, 9502, 39, 4, EffectLayer.Head);
target.Emote("*is rooted to the ground, unmoving*");
target.SendMessage("You are overwhelmed by guilt over your sins.");
if (((IKhaerosMobile)target).StunnedTimer != null)
((IKhaerosMobile)target).StunnedTimer.Stop();
((IKhaerosMobile)target).StunnedTimer = new JusticePrisonTimer(target, hold);
((IKhaerosMobile)target).StunnedTimer.Start();
}
示例5: Drink
public override void Drink( Mobile m )
{
TimeSpan duration = TimeSpan.FromMinutes( 1 );
if (m.Hidden == false)
{
m.FixedParticles( 0x376A, 9, 32, 5007, EffectLayer.Waist );
m.PlaySound( 0x3C4 );
BuffInfo.RemoveBuff( m, BuffIcon.HidingAndOrStealth );
BuffInfo.AddBuff( m, new BuffInfo( BuffIcon.Invisibility, 1075825 ) ); //Invisibility/Invisible
BasePotion.PlayDrinkEffect( m );
this.Consume();
m.Hidden = true;
RemoveTimer( m );
Timer t = new InternalTimer( m, duration );
m_Table[m] = t;
t.Start();
}
else
{
m.SendMessage( "An invisibility potion is already taking effect on your person." ); //An invisibility potion is already taking effect on your person.
}
}
示例6: OnHit
public override void OnHit( Mobile attacker, Mobile defender, int damage )
{
if ( !IsBladeweaveAttack )
{
if ( !Validate( attacker ) )
return;
if ( !CheckMana( attacker, true ) )
return;
}
ClearCurrentAbility( attacker );
Timer t = (Timer) m_Table[attacker];
if ( t != null )
t.Stop();
Skill ninjitsu = attacker.Skills[SkillName.Ninjitsu];
int delay = (int) ( ninjitsu.Value / 12.0 );
attacker.SendLocalizedMessage( 1063345 ); // You block an attack!
defender.SendLocalizedMessage( 1063346 ); // Your attack was blocked!
attacker.FixedParticles( 0x37C4, 1, 16, 0x251D, 0x39D, 0x3, EffectLayer.RightHand );
m_Table[attacker] = t = Timer.DelayCall( TimeSpan.FromSeconds( delay ), new TimerStateCallback( Expire_Callback ), attacker );
}
示例7: 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 );
}
示例8: OnHit
public override void OnHit( Mobile attacker, Mobile defender, int damage )
{
if( !Validate( attacker ) || !CheckMana( attacker, true ) )
return;
ClearCurrentAbility( attacker );
if( Server.Items.ParalyzingBlow.IsImmune( defender ) ) //After mana consumption intentional
{
attacker.SendLocalizedMessage( 1070804 ); // Your target resists paralysis.
defender.SendLocalizedMessage( 1070813 ); // You resist paralysis.
return;
}
attacker.SendLocalizedMessage( 1063356 ); // You cripple your target with a nerve strike!
defender.SendLocalizedMessage( 1063357 ); // Your attacker dealt a crippling nerve strike!
attacker.PlaySound( 0x204 );
defender.FixedEffect( 0x376A, 9, 32 );
defender.FixedParticles( 0x37C4, 1, 8, 0x13AF, 0, 0, EffectLayer.Waist );
AOS.Damage( defender, attacker, (int)(15.0 * (attacker.Skills[SkillName.Bushido].Value - 50.0) / 70.0 + 10), 100, 0, 0, 0, 0 ); //10-25
defender.Freeze( TimeSpan.FromSeconds( 2.0 ) );
Server.Items.ParalyzingBlow.BeginImmunity( defender, Server.Items.ParalyzingBlow.FreezeDelayDuration );
}
示例9: OnDoubleClick
public override void OnDoubleClick( Mobile from )
{
if ( from.Blessed != true )
{
if ( IsChildOf( from.Backpack ) )
{
new InvulTimer(from).Start();
from.FixedParticles( 0x376A, 9, 32, 5007, EffectLayer.Waist );
from.PlaySound( 0x1E3 );
BasePotion.PlayDrinkEffect( from );
this.Consume();
}
else
{
from.SendMessage("The Potion must be in your backpack.");
}
}
else
{
from.SendMessage( "You are already invulnerable." );
}
}
示例10: OnHit
public override void OnHit( Mobile attacker, Mobile defender, int damage )
{
if ( !Validate( attacker ) || !CheckMana( attacker, true ) )
return;
ClearCurrentAbility( attacker );
Timer t = (Timer) m_Table[attacker];
if ( t != null )
t.Stop();
attacker.SendLocalizedMessage( 1063353 ); // You perform a masterful defense!
m_Table[attacker] = t = Timer.DelayCall( TimeSpan.FromSeconds( 3.0 ), new TimerStateCallback( Expire_Callback ), attacker );
if ( mods == null )
{
mods = new object[1] { new ResistanceMod( ResistanceType.Physical, 70 ) };
m_Table[attacker] = mods;
attacker.AddResistanceMod( (ResistanceMod) mods[0] );
}
att = attacker;
attacker.FixedParticles( 0x375A, 1, 17, 0x7F2, 0x3E8, 0x3, EffectLayer.Waist );
}
示例11: OnDoubleClick
public override void OnDoubleClick( Mobile from )
{
if( !IsChildOf( from.Backpack ) )
{
from.SendLocalizedMessage( 1042001 ); //That must be in your pack to use it.
}
else
{
if( from.Skills.Magery.Base < 85 )
{
from.SendMessage( "The scroll bursts into flame in your hands!" );
from.FixedParticles( 0x36BD, 20, 10, 5044, EffectLayer.Waist );
from.Damage( Utility.RandomMinMax( 40, 55 ) );
this.Delete();
}
else
{
from.Frozen = true;
from.PublicOverheadMessage( MessageType.Spell, from.SpeechHue, true, "In Kal Quas", false );
if( !from.Mounted && from.Body.IsHuman )
from.Animate( 206, 7, 1, true, false, 0 );
from.BeginTarget( 10, false, TargetFlags.None, new TargetCallback( BlessingOfKhopesh_OnTarget ) );
}
}
}
示例12: Target
public void Target( Mobile m )
{
if ( !Caster.CanSee( m ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( m is BaseCreature && ((BaseCreature)m).IsAnimatedDead )
{
Caster.SendLocalizedMessage( 1061654 ); // You cannot heal that which is not alive.
}
else if ( Server.Items.MortalStrike.IsWounded( m ) )
{
Caster.LocalOverheadMessage( MessageType.Regular, 0x22, (Caster == m) ? 1005000 : 1010398 );
}
/* // idea... dont allow lesser heal to heal through poison (but allow it on gheal)
else if ( m.Poisoned || Server.Items.MortalStrike.IsWounded( m ) )
{
Caster.LocalOverheadMessage( MessageType.Regular, 0x22, (Caster == m) ? 1005000 : 1010398 ); // You cannot heal that target/yourself in their/your current state.
}*/
else if ( CheckBSequence( m ) )
{
SpellHelper.Turn( Caster, m );
int toHeal = 1 + (int)( Utility.Random( 15 ) * Caster.Skills[SkillName.Magery].Value / 100.0 );
if ( Caster != m && Caster.NetState != null )
Caster.NetState.Send( new MessageLocalizedAffix( Serial.MinusOne, -1, MessageType.Label, 0x3B2, 3, 1008158, "", AffixType.Append | AffixType.System, (m.Hits+toHeal > m.HitsMax ? m.HitsMax - m.Hits : toHeal).ToString(), "" ) );
m.Heal( toHeal );
m.FixedParticles( 0x376A, 9, 32, 5005, EffectLayer.Waist );
m.PlaySound( 0x1F2 );
}
FinishSequence();
}
示例13: Drink
public override void Drink( Mobile from )
{
if ( from.BeginAction( typeof( LightCycle ) ) )
{
new LightCycle.NightSightTimer( from ).Start();
if( Server.Utilities.StartupSettings.LightingChanged )
from.LightLevel = 15;
else if( from.Map != Map.Trammel )
from.LightLevel = LightCycle.DungeonLevel / 2;
else
from.LightLevel = 6;
from.FixedParticles( 0x376A, 9, 32, 5007, EffectLayer.Waist );
from.PlaySound( 0x1E3 );
BasePotion.PlayDrinkEffect( from );
this.Consume();
}
else
{
from.SendMessage( "You already have nightsight." );
}
}
示例14: LightAirCombo
// Dance of Clouds
// Activate to grant all nearby allies 20% concealment for 60 seconds.
public static void LightAirCombo( Mobile from )
{
from.SendMessage( 2075, "You execute the maneuver: Dance Of The Clouds" );
Party p = Party.Get( from );
object[] objs =
{
AosAttribute.DefendChance, 25
};
if ( p == null )
{
from.SendMessage( 2075, "Monk Boost: +25% defense" );
from.FixedParticles( 0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist );
new EnhancementTimer( from, 15, "monk", objs ).Start();
return;
}
for ( int i = 0; i < p.Members.Count; ++i )
{
if ( !(p.Members[i].Mobile.InRange( from, 10 )) )
continue;
p.Members[i].Mobile.SendMessage( 2075, "Monk Boost: +25% defense" );
p.Members[i].Mobile.FixedParticles( 0x374A, 10, 30, 5013, 1153, 2, EffectLayer.Waist );
new EnhancementTimer( p.Members[i].Mobile, 60, "monk", objs ).Start();
p.Members[i].Mobile.PlaySound( 0x28F );
}
}
示例15: Target
public void Target( Mobile m )
{
if ( !Caster.CanSee( m ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( m is BaseCreature && ((BaseCreature)m).IsAnimatedDead )
{
Caster.SendLocalizedMessage( 1061654 ); // You cannot heal that which is not alive.
}
else if ( Server.Items.MortalStrike.IsWounded( m ) )
{
Caster.LocalOverheadMessage( MessageType.Regular, 0x22, (Caster == m) ? 1005000 : 1010398 );
}
else if ( CheckBSequence( m ) )
{
SpellHelper.Turn( Caster, m );
// Algorithm: (40% of magery) + (1-10)
int toHeal = (int)(Caster.Skills[SkillName.Magery].Value * 0.4) + Utility.Random( 10 ) + 1;
if ( Caster != m && Caster.NetState != null )
Caster.NetState.Send( new MessageLocalizedAffix( Serial.MinusOne, -1, MessageType.Label, 0x3B2, 3, 1008158, "", AffixType.Append | AffixType.System, (m.Hits+toHeal > m.HitsMax ? m.HitsMax - m.Hits : toHeal).ToString(), "" ) );
m.Heal( toHeal );
m.FixedParticles( 0x376A, 9, 32, 5030, EffectLayer.Waist );
m.PlaySound( 0x202 );
}
FinishSequence();
}