本文整理匯總了C#中fCraft.Player.GetListName方法的典型用法代碼示例。如果您正苦於以下問題:C# Player.GetListName方法的具體用法?C# Player.GetListName怎麽用?C# Player.GetListName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類fCraft.Player
的用法示例。
在下文中一共展示了Player.GetListName方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: WriteAddEntity
public void WriteAddEntity( byte id, Player player, Position pos ) {
if( player == null ) throw new ArgumentNullException( "player" );
Write( OpCode.AddEntity );
Write( id );
Write( player.GetListName() );
Write( pos.X );
Write( pos.H );
Write( pos.Y );
Write( pos.R );
Write( pos.L );
}
示例2: WriteAddEntity
public void WriteAddEntity( byte id, Player player, Position pos )
{
Write( OutputCodes.AddEntity );
Write( id );
Write( player.GetListName() );
Write( (short)pos.x );
Write( (short)pos.h );
Write( (short)pos.y );
Write( pos.r );
Write( pos.l );
}
示例3: MakeAddEntity
internal static Packet MakeAddEntity( Player player, Position pos ) {
Packet packet = new Packet( 74 );
packet.data[0] = (byte)OutputCodes.AddEntity;
packet.data[1] = (byte)player.id;
ASCIIEncoding.ASCII.GetBytes( player.GetListName().PadRight( 64 ), 0, 64, packet.data, 2 );
ToNetOrder( pos.x, packet.data, 66 );
ToNetOrder( pos.h, packet.data, 68 );
ToNetOrder( pos.y, packet.data, 70 );
packet.data[72] = pos.r;
packet.data[73] = pos.l;
return packet;
}
示例4: ReAddEntity
void ReAddEntity( VisibleEntity entity, Player player, Position newPos ) {
SendNow( PacketWriter.MakeRemoveEntity( entity.Id ) );
SendNow( PacketWriter.MakeAddEntity( entity.Id, player.GetListName(), newPos ) );
entity.LastKnownPosition = newPos;
}
示例5: AddEntity
void AddEntity( Player player, Position newPos ) {
var pos = new VisibleEntity( newPos, freePlayerIDs.Pop(), player.Info.Rank );
entities.Add( player, pos );
SendNow( PacketWriter.MakeAddEntity( pos.Id, player.GetListName(), newPos ) );
}