本文整理汇总了C#中Server.Mobile.Emote方法的典型用法代码示例。如果您正苦于以下问题:C# Mobile.Emote方法的具体用法?C# Mobile.Emote怎么用?C# Mobile.Emote使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server.Mobile
的用法示例。
在下文中一共展示了Mobile.Emote方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ApplyEffect
public override void ApplyEffect( Mobile to, Mobile source, int intensity, Item itemSource )
{
if ( source != to )
source.DoHarmful( to );
int chance = Utility.RandomMinMax( 1, 8 );
string sundname = "";
BaseArmor sundered = null;
Layer layer = Layer.FirstValid;
switch( chance )
{
case 1: layer = Layer.InnerTorso; sundname = "armour"; break;
case 2: layer = Layer.InnerLegs; sundname = "leggings"; break;
case 3: layer = Layer.TwoHanded; sundname = "shield"; break;
case 4: layer = Layer.Neck; sundname = "gorget"; break;
case 5: layer = Layer.Gloves; sundname = "gauntlets"; break;
case 6: layer = Layer.Helm; sundname = "helm"; break;
case 7: layer = Layer.Arms; sundname = "arm pads"; break;
case 8: layer = Layer.OneHanded; sundname = "weapon"; break;
}
if( to.FindItemOnLayer( layer ) != null && to.FindItemOnLayer( layer ) is BaseArmor )
sundered = to.FindItemOnLayer( layer ) as BaseArmor;
if( sundered != null )
{
int amt = (int)(intensity * Divisor);
if ( amt <= 0 )
amt = 0;
sundered.HitPoints -= Utility.Random( amt ) + 1;
if( sundered.HitPoints < 0 )
{
sundered.MaxHitPoints += sundered.HitPoints;
sundered.HitPoints = 0;
if( sundered.MaxHitPoints < 0 )
{
sundered.Delete();
to.Emote( "*got {0} {1} destroyed by {2}*", to.Female == true ? "her" : "his", sundname, source.Name );
}
}
to.Emote( "*got {0} {1} damaged by {2}*", to.Female == true ? "her" : "his", sundname, source.Name );
}
}
示例2: OnDoubleClick
public override void OnDoubleClick( Mobile from )
{
if( from == null || !( from is PlayerMobile ) || from.Deleted || !from.Alive || from.Frozen || from.Paralyzed )
return;
PlayerMobile pm = from as PlayerMobile;
if( pm.BloodOfXorgoth != null )
{
from.SendMessage( "You are already under the effect of Blood of Xorgoth." );
return;
}
if( from.Backpack != null && this.ParentEntity == from.Backpack )
{
BasePotion.PlayDrinkEffectNoBottle( from );
from.Emote( "*lets out a roar after drinking the Blood of Xorgoth*" );
pm.BloodOfXorgoth = new BloodOfXorgothTimer( pm, this.Power );
pm.BloodOfXorgoth.Start();
this.Delete();
Pitcher pitcher = new Pitcher();
from.Backpack.DropItem( pitcher );
}
else
from.SendMessage( "That needs to be in your backpack for you to use it." );
}
示例3: PitchTentTimer
public PitchTentTimer( Mobile m, Item tent )
: base(TimeSpan.FromSeconds( 10 ))
{
m_m = m;
m_tent = tent;
m.Emote( "*starts pitching a tent*" );
m_loc = m.Location;
m_tent.Movable = false;
}
示例4: Effect
public static void Effect( Mobile attacker, Mobile defender )
{
if( attacker == null || defender == null || defender.Weapon is Fists || !((BaseWeapon)defender.Weapon).Movable )
return;
if( Utility.RandomBool() && defender.Backpack != null )
{
defender.Backpack.DropItem( (BaseWeapon)defender.Weapon );
defender.Emote( "*was disarmed by {0}*", attacker.Name );
}
else if ( Utility.RandomBool() && attacker.Backpack != null )
{
attacker.Backpack.DropItem( (BaseWeapon)defender.Weapon );
defender.Emote( "*was disarmed by {0}*", attacker.Name );
}
else
{
defender.Emote( "*{0} weapon fell to the ground*", ((IKhaerosMobile)defender).GetPossessivePronoun() );
((BaseWeapon)defender.Weapon).MoveToWorld( defender.Location, defender.Map );
}
}
示例5: Effect
public static void Effect( Mobile defender, int featlevel, int damage, string source )
{
if( source == null )
source = "";
BaseWeapon sundered = defender.Weapon as BaseWeapon;
sundered.HitPoints -= (int)( damage * (featlevel * 0.20) );
if( sundered.HitPoints < 0 )
{
sundered.MaxHitPoints += sundered.HitPoints;
sundered.HitPoints = 0;
if( sundered.MaxHitPoints < 1 )
{
sundered.Delete();
defender.Emote( "*got {0} weapon destroyed{1}*", ((IKhaerosMobile)defender).GetPossessivePronoun(), source );
}
}
defender.Emote( "*got {0} weapon damaged{1}*", ((IKhaerosMobile)defender).GetPossessivePronoun(), source );
}
示例6: OnComponentUsed
public override void OnComponentUsed(AddonComponent ac, Mobile from)
{
if (!from.InRange(GetWorldLocation(), 2))
from.SendMessage("You are too far away.");
else
{
from.Emote("*stirs the brew*");
from.Say("hihihihiiii!");
from.PlaySound(32);
if (!from.Mounted)
from.Animate(33, 5, 1, true, false, 0);
}
}
示例7: OnEquip
public override bool OnEquip( Mobile from )
{
Guild g = from.Guild as Guild;
if(DefSerUss == 0 && g != null)
{
DefSerUss = from.Serial;
from.Emote( "" + from.Name + ", the robe is now your personal item!" );
this.Name = from.Name +"'s " + this.Name +" [" + g.Abbreviation + "]";
base.OnEquip( from );
return true;
}
else if (g == null )
{
this.Name = "Robe";
this.ItemID = 7939;
this.Hue = 0;
this.LootType = LootType.Regular;
base.OnEquip( from );
return true;
}
else if(DefSerUss == from.Serial)
{
from.SendMessage( "Guild Form " + from.Name + " was dressed" );
base.OnEquip( from );
return true;
}
else
{
from.Emote( "*It is not your Guild item...!*" );
return false;
}
}
示例8: 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();
}
示例9: OnTarget
protected override void OnTarget( Mobile from, object targeted )
{
if ( targeted is Mobile )
{
Mobile targ = (Mobile)targeted;
if ( !from.CanSee( targ ) )
{
from.SendMessage( "You Cannot See This Target" );
}
else
{
targ.Emote( "* Ohh-Rah! Get Vanqusihed by the Hands of The Ice-God *" );
targ.BoltEffect( 0 );
targ.Damage( Utility.Random( 5, 65 ) );
from.Emote( "* In Rememberance of Old Man Ice-God!*" );
}
}
}
示例10: OnSwing
public override void OnSwing( Mobile attacker, Mobile defender, bool Cleave )
{
IKhaerosMobile featuser = attacker as IKhaerosMobile;
if( featuser.CanUseMartialPower )
if( BaseWeapon.CheckStam( attacker, FeatLevel, Cleave, false ) )
attacker.Emote( "*focuses and attacks {0} with all {1} strength, in an attempt to stun {2}*", defender.Name, ((IKhaerosMobile)attacker).GetPossessivePronoun(), ((IKhaerosMobile)defender).GetReflexivePronoun() );
}
示例11: OnSwing
public override void OnSwing( Mobile attacker, Mobile defender, bool Cleave )
{
if( defender.Weapon is Fists )
{
attacker.SendMessage( 60, "You cannot use that attack against unarmed foes." );
((IKhaerosMobile)attacker).DisableManeuver();
}
if( BaseWeapon.CheckStam( attacker, FeatLevel, Cleave, false ) )
attacker.Emote( "*firmly clashes {0} weapon against {1}{2} weapon*", attacker.Female == true ? "her" : "his", defender.Name, defender.Name.EndsWith( "s" ) == true ? "'" : "'s" );
}
示例12: OnSwing
public override void OnSwing( Mobile attacker, Mobile defender, bool Cleave )
{
IKhaerosMobile featuser = attacker as IKhaerosMobile;
if ( attacker.Mounted )
{
attacker.SendMessage( 60, "You cannot perform this maneuver while mounted." );
featuser.DisableManeuver();
}
else if ( ((IKhaerosMobile)defender).TrippedTimer != null || CombatSystemAttachment.GetCSA( defender ).PerformingSequence )
{
attacker.SendMessage( 60, "You cannot trip them right now." );
featuser.DisableManeuver();
}
else if( ((BaseWeapon)attacker.Weapon).Skill == SkillName.Polearms )
if( BaseWeapon.CheckStam( attacker, FeatLevel, Cleave, false ) )
attacker.Emote( "*swings {0} polearm in an attempt to trip {1}*", ((IKhaerosMobile)attacker).GetPossessivePronoun(), defender.Name );
else
{
attacker.SendMessage( 60, "You need to be equipping a polearm in order to perform this attack." );
featuser.DisableManeuver();
}
}
示例13: OnGotMeleeAttack
public override void OnGotMeleeAttack(Mobile attacker)
{
if (this.Map != null && attacker != this && 0.1 > Utility.RandomDouble())
{
if (attacker is BaseCreature)
{
BaseCreature pet = (BaseCreature)attacker;
if (pet.ControlMaster != null && (attacker is Dragon || attacker is GreaterDragon || attacker is SkeletalDragon || attacker is WhiteWyrm || attacker is Drake))
{
Combatant = null;
pet.Combatant = null;
Combatant = null;
pet.IsBonded = false;
pet.ControlMaster = null;
pet.Controlled = false;
attacker.Emote(String.Format("* {0} decided to go wild *", attacker.Name));
}
if (pet.ControlMaster != null && 0.1 > Utility.RandomDouble())
{
Combatant = null;
pet.Combatant = pet.ControlMaster;
Combatant = null;
attacker.Emote(String.Format("* {0} is being angered *", attacker.Name));
}
}
}
base.OnGotMeleeAttack(attacker);
}
示例14: OnDoubleClick
public override void OnDoubleClick(Mobile from)
{
if (this.RootParentEntity == from && from.HasFreeHand())
{
from.PlaySound(0x384);
from.Target = new LeechTarget(this);
from.Emote("*readies a leech in " + (from.Female ? "her" : "his") + " hand*");
from.SendMessage("Choose a target whose blood you wish to leech.");
}
else if (this.RootParentEntity != from)
from.SendMessage("That must be in your backpack to use it.");
else if (!from.HasFreeHand())
from.SendMessage("You must have a free hand to do that.");
base.OnDoubleClick(from);
}
示例15: Effect
public static void Effect( Mobile defender, int featlevel, int target )
{
IKhaerosMobile defplayer = defender as IKhaerosMobile;
if( target == 0 )
target = Utility.RandomMinMax( 1, 4 );
switch( target )
{
case 1:
{
if( defplayer.DisabledLegsTimer != null )
defplayer.DisabledLegsTimer.Stop();
defplayer.DisabledLegsTimer = new DisableTimer( defender, featlevel, 1, "legs" );
defplayer.DisabledLegsTimer.Start();
defender.Emote( "*got {0} legs disabled*", ((IKhaerosMobile)defender).GetPossessivePronoun() );
if ( defender is PlayerMobile )
((PlayerMobile)defender).CantRunIconRefresh();
break;
}
case 2:
{
if( defplayer.DisabledLeftArmTimer != null )
defplayer.DisabledLeftArmTimer.Stop();
defplayer.DisabledLeftArmTimer = new DisableTimer( defender, featlevel, 2, "left arm" );
defplayer.DisabledLeftArmTimer.Start();
defender.Emote( "*got {0} left arm disabled*", ((IKhaerosMobile)defender).GetPossessivePronoun() );
break;
}
case 3:
{
if( defplayer.DisabledRightArmTimer != null )
defplayer.DisabledRightArmTimer.Stop();
defplayer.DisabledRightArmTimer = new DisableTimer( defender, featlevel, 3, "right arm" );
defplayer.DisabledRightArmTimer.Start();
defender.Emote( "*got {0} right arm disabled*", ((IKhaerosMobile)defender).GetPossessivePronoun() );
break;
}
case 4: goto case 1;
}
}