Minecraft v0.1.0 Minecraft.Protocol.Handler View Source

Server-side handler for responding to client packets.

Link to this section Summary

Functions

Handles a packet from a client, and returns either a response packet, or {:ok, :noreply}

Link to this section Functions

Link to this function handle(packet, conn) View Source
handle(packet :: struct(), Minecraft.Connection.t()) ::
  {:ok, :noreply | struct(), Minecraft.Connection.t()}
  | {:error, :unsupported_protocol, Minecraft.Connection.t()}

Handles a packet from a client, and returns either a response packet, or {:ok, :noreply}.