2024-01-25 12:10:29 +01:00

16 lines
246 B
GDScript

class_name PacketHandler
extends Node
enum Packet {
INVALID = 0,
PING = 1,
LOGIN = 2,
LOGOUT = 3,
PLAYER_STATE = 10,
PLAYER_MOVE = 11,
}
@export var packet_type: Packet
func handle_packet(_data: PackedByteArray, _peer: PacketPeer):
pass