Fixed teleporting

This commit is contained in:
high 2011-08-11 00:27:56 -04:00
parent 2a0bf9036a
commit 3312b769c4
6 changed files with 124 additions and 73 deletions

30
TShockAPI/Net/SpawnMsg.cs Normal file
View file

@ -0,0 +1,30 @@
using System.Collections.Generic;
using System.IO;
using System.Linq;
using TerrariaAPI;
using XNAHelpers;
namespace TShockAPI.Net
{
public class SpawnMsg : BaseMsg
{
public override PacketTypes ID
{
get
{
return PacketTypes.PlayerSpawn;
}
}
public int TileX { get; set; }
public int TileY {get;set;}
public byte PlayerIndex { get; set; }
public override void Pack(Stream stream)
{
stream.WriteInt8(PlayerIndex);
stream.WriteInt32(TileX);
stream.WriteInt32(TileY);
}
}
}