Move netmodule handling into handlers namespace

Add handler for teleport pylons, and permission for teleport pylons
This commit is contained in:
Chris 2020-06-02 12:59:14 +09:30
parent 4d1fd54a7c
commit 48d610d33f
9 changed files with 401 additions and 152 deletions

View file

@ -0,0 +1,23 @@
using System.IO;
namespace TShockAPI.Handlers.NetModules
{
/// <summary>
/// Describes a handler for a net module
/// </summary>
public interface INetModuleHandler
{
/// <summary>
/// Reads the net module's data from the given stream
/// </summary>
/// <param name="data"></param>
void Deserialize(MemoryStream data);
/// <summary>
/// Provides handling for the packet and determines if it should be accepted or rejected
/// </summary>
/// <param name="player"></param>
/// <param name="rejectPacket"></param>
void HandlePacket(TSPlayer player, out bool rejectPacket);
}
}