本文整理汇总了C#中InternalItem类的典型用法代码示例。如果您正苦于以下问题:C# InternalItem类的具体用法?C# InternalItem怎么用?C# InternalItem使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
InternalItem类属于命名空间,在下文中一共展示了InternalItem类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AnkhEast
public AnkhEast( bool bloodied )
: base(bloodied ? 0x1E5D : 0x4)
{
Movable = false;
m_Item = new InternalItem( bloodied, this );
}
示例2: LargeForgeWest
public LargeForgeWest() : base( 0x199A )
{
Movable = false;
m_Item = new InternalItem( this );
m_Item2 = new InternalItem2( this );
}
示例3: Target
public void Target( IPoint3D p )
{
if ( !Caster.CanSee( p ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( CheckSequence() )
{
SpellHelper.Turn( Caster, p );
SpellHelper.GetSurfaceTop( ref p );
Effects.PlaySound( p, Caster.Map, 0x382 );
Point3D loc = new Point3D( p.X, p.Y, p.Z );
Item item = new InternalItem( loc, Caster.Map, Caster );
}
FinishSequence();
}
示例4: Target
public void Target( Mobile m )
{
if ( !Caster.CanSee( m ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( CheckHSequence( m ) )
{
SpellHelper.Turn( Caster, m );
speak=m.Squelched;
m.PlaySound( 0x19 );
m.Paralyze( TimeSpan.FromSeconds( 20.0 ) );
m.FixedParticles( 0x375A, 2, 10, 5027, 0x3D, 2, EffectLayer.Waist );
m.Hidden = true;
m.Squelched = true;
{
Point3D loc = new Point3D( m.X, m.Y, m.Z );
Item item = new InternalItem( loc, Caster.Map, Caster,m , speak );
}
}
FinishSequence();
}
示例5: Tapestry1N
public Tapestry1N()
: base(0xEAA)
{
Movable = false;
m_Item = new InternalItem( this );
}
示例6: AnkhNorth
public AnkhNorth(bool bloodied)
: base(bloodied ? 0x1E5D : 0x4)
{
this.Movable = false;
this.m_Item = new InternalItem(bloodied, this);
}
示例7: DuelWall
public DuelWall( bool northsouth, Mobile from, Mobile to )
: base(0x80)
{
m_From = from;
m_To = to;
Movable = false;
if( northsouth )
{
m_Item1 = new InternalItem( this, 1, 0 );
m_Item2 = new InternalItem( this, -1, 0 );
m_XOffset1 = 1;
m_XOffset2 = -1;
m_YOffset1 = 0;
m_YOffset2 = 0;
}
else
{
m_Item1 = new InternalItem( this, 0, 1 );
m_Item2 = new InternalItem( this, 0, -1 );
m_XOffset1 = 0;
m_XOffset2 = 0;
m_YOffset1 = 1;
m_YOffset2 = -1;
}
m_Timer = new InternalTimer( this, TimeSpan.FromSeconds( 10.0 ), m_From, m_To );
m_Timer.Start();
m_End = DateTime.Now + TimeSpan.FromSeconds( 3.0 );
Effects.PlaySound( new Point3D( X, Y, Z ), Map, 0x1F6 );
}
示例8: Effect
public void Effect( Point3D loc, Map map, bool checkMulti )
{
if ( map == null || (!Core.AOS && Caster.Map != map) )
{
Caster.SendLocalizedMessage( 1005570 ); // You can not gate to another facet.
}
else if ( !map.CanFit( loc.X, loc.Y, loc.Z, 16 ) )
{
Caster.SendLocalizedMessage( 501942 ); // That location is blocked.
}
else if ( (checkMulti && SpellHelper.CheckMulti( loc, map )) )
{
Caster.SendLocalizedMessage( 501942 ); // That location is blocked.
}
else if ( !SpellHelper.CheckTravel( Caster, loc, map, TravelType.Gate ) && Caster.AccessLevel == AccessLevel.Player )
{
Caster.PlaySound( 0x5C );
}
else if ( CheckSequence() )
{
Caster.SendLocalizedMessage( 501024 ); // You open a magical gate to another location
Effects.PlaySound( Caster.Location, Caster.Map, 0x20E );
InternalItem firstGate = new InternalItem( loc, map );
firstGate.MoveToWorld( Caster.Location, Caster.Map );
Effects.PlaySound( loc, map, 0x20E );
InternalItem secondGate = new InternalItem( Caster.Location, Caster.Map );
secondGate.MoveToWorld( loc, map );
}
FinishSequence();
}
示例9: Target
public void Target( IPoint3D p )
{
if ( !Caster.CanSee( p ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( SpellHelper.CheckTown( p, Caster ) && CheckSequence() )
{
SpellHelper.Turn( Caster, p );
SpellHelper.GetSurfaceTop( ref p );
int dx = Caster.Location.X - p.X;
int dy = Caster.Location.Y - p.Y;
int rx = (dx - dy) * 44;
int ry = (dx + dy) * 44;
bool eastToWest;
if ( rx >= 0 && ry >= 0 )
{
eastToWest = false;
}
else if ( rx >= 0 )
{
eastToWest = true;
}
else if ( ry >= 0 )
{
eastToWest = true;
}
else
{
eastToWest = false;
}
Effects.PlaySound( p, Caster.Map, 0x20B );
TimeSpan duration = TimeSpan.FromSeconds( Caster.Skills[SkillName.Magery].Value * 0.28 + 2.0 ); // (28% of magery) + 2.0 seconds
int itemID = eastToWest ? 0x3946 : 0x3956;
for ( int i = -2; i <= 2; ++i )
{
Point3D loc = new Point3D( eastToWest ? p.X + i : p.X, eastToWest ? p.Y : p.Y + i, p.Z );
bool canFit = SpellHelper.AdjustField( ref loc, Caster.Map, 12, false );
if ( !canFit )
continue;
Item item = new InternalItem( loc, Caster.Map, duration, itemID, Caster );
item.ProcessDelta();
Effects.SendLocationParticles( EffectItem.Create( loc, Caster.Map, EffectItem.DefaultDuration ), 0x376A, 9, 10, 5051 );
}
}
FinishSequence();
}
示例10: Deserialize
public override void Deserialize( GenericReader reader )
{
base.Deserialize( reader );
int version = reader.ReadInt();
m_Item = reader.ReadItem() as InternalItem;
}
示例11: LargeForgeEast
public LargeForgeEast()
: base(0x197A)
{
this.Movable = false;
this.m_Item = new InternalItem(this);
this.m_Item2 = new InternalItem2(this);
}
示例12: Target
public void Target( IPoint3D p )
{
if( !Caster.CanSee( p ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if( SpellHelper.CheckTown( p, Caster ) && CheckSequence() )
{
SpellHelper.Turn( Caster, p );
SpellHelper.GetSurfaceTop( ref p );
int dx = Caster.Location.X - p.X;
int dy = Caster.Location.Y - p.Y;
int rx = (dx - dy) * 44;
int ry = (dx + dy) * 44;
bool eastToWest;
if( rx >= 0 && ry >= 0 )
{
eastToWest = false;
}
else if( rx >= 0 )
{
eastToWest = true;
}
else if( ry >= 0 )
{
eastToWest = true;
}
else
{
eastToWest = false;
}
Effects.PlaySound( p, Caster.Map, 0x1F6 );
for( int i = -1; i <= 1; ++i )
{
Point3D loc = new Point3D( eastToWest ? p.X + i : p.X, eastToWest ? p.Y : p.Y + i, p.Z );
bool canFit = SpellHelper.AdjustField( ref loc, Caster.Map, 22, true );
//Effects.SendLocationParticles( EffectItem.Create( loc, Caster.Map, EffectItem.DefaultDuration ), 0x376A, 9, 10, 5025 );
if( !canFit )
continue;
Item item = new InternalItem( loc, Caster.Map, Caster );
Effects.SendLocationParticles( item, 0x376A, 9, 10, 5025 );
//new InternalItem( loc, Caster.Map, Caster );
}
}
FinishSequence();
}
示例13: Deserialize
public override void Deserialize(GenericReader reader)
{
base.Deserialize(reader);
int version = reader.ReadInt();
switch (version)
{
case 1:
m_Chaos = reader.ReadBool();
break;
}
m_Item = reader.ReadItem() as InternalItem;
}
示例14: Target
public void Target( Mobile m )
{
if ( !Caster.CanSee( m ) )
{
Caster.SendLocalizedMessage( 500237 ); // Target can not be seen.
}
else if ( CheckHSequence( m ) )
{
SpellHelper.Turn( Caster, m );
double duration;
// Algorithm: ((20% of AnimalTamin) + 7) seconds [- 50% if resisted] seems to work??
duration = 7.0 + (Caster.Skills[DamageSkill].Value * 0.2);
// Resist if Str + Dex / 2 is greater than CastSkill eg. AnimalLore seems to work??
if ( ( Caster.Skills[CastSkill].Value ) < ( ( m.Str + m.Dex ) * 0.5 ) )
duration *= 0.5;
// no less than 0 seconds no more than 9 seconds
if ( duration < 0.0 )
duration = 0.0;
if ( duration > 9.0 )
duration = 9.0;
m.PlaySound( 0x2A1 );
m.Paralyze( TimeSpan.FromSeconds( duration ) );
m.FixedParticles( 0x375A, 2, 10, 5027, 0x3D, 2, EffectLayer.Waist );
{
Point3D loc = new Point3D( m.X, m.Y, m.Z );
Item item = new InternalItem( loc, Caster.Map, Caster );
}
}
FinishSequence();
}
示例15: DecorativeSwordNorth
public DecorativeSwordNorth()
: base(0x1565)
{
Movable = false;
m_Item = new InternalItem( this );
}