Skip to content
This repository was archived by the owner on Nov 13, 2022. It is now read-only.

Using NetworkHandler

Vitalij edited this page Mar 14, 2014 · 1 revision

The main thing.

So, how to use my NetworkHandler? Create your custom IMinecraft class and implement all stuff from it.

Create an instance of NetworkHandler, subscribe on events and then use Start()

public NetworkHandler Handler = new NetworkHandler(*Your IMinecraft class*)

// -- Register our event handlers.
Handler.OnPacketHandled += RaisePacketHandled;

// -- Connect to the server and begin reading packets.
Handler.Start();

Don't forget, you need first send HandshakePacket and LoginStartPacket.

Handler.Send(*Your packet*);

Done. Now you will get packets from server. Good luck with parsing it, hehehe.

Clone this wiki locally