Protocol Specification - Hmart/ludowars GitHub Wiki
Move Packet (Packet ID: 1)
1. Entity ID (4 byte)
2. X (float, 4 bytes)
3. Y (float, 4 bytes)
4. north (1 byte)
5. south (1 byte)
6. west (1 byte)
7. east (1 byte)
8. fire (1 byte)
9. secondary (1 byte)
10. mouse x (float, 4 byte)
11. mouse y (float, 4 byte)
Assign Packet (Packet ID: 2)
1. Entity ID (4 byte)
State Packet (Packet ID: 3)
1. x (4 bytes, float), y (4 bytes, float), width (4 bytes, float), height (4 bytes, float)
2. entity count (2 bytes, short)
3. entity list:
- id (4 bytes)
- controller class name (256 bytes)
- representation class name (256 bytes)
- driver class name (256 bytes)
- X (float, 4 bytes)
- Y (float, 4 bytes)
- velocity X (float, 4 bytes)
- velocity Y (float, 4 bytes)
- angle (float, 4 bytes)
- width (int 4 bytes)
- height (int 4 bytes)
Add Entity (Packet ID: 4)
1. id (4 bytes)
2. controller class name (256 bytes)
3. representation class name (256 bytes)
4. driver class name (256 bytes)
5. X (float, 4 bytes)
6. Y (float, 4 bytes)
7. velocity X (float, 4 bytes)
8. velocity Y (float, 4 bytes)
9. angle (float, 4 bytes)
10. width (int 4 bytes)
11. height (int 4 bytes)
Delete Entity (Packet ID: 5)
1. id (4 bytes)
Update Entity (Packet ID: 6)
1. id (4 bytes)
2. controller class name (256 bytes)
3. representation class name (256 bytes)
4. driver class name (256 bytes)
5. X (float, 4 bytes)
6. Y (float, 4 bytes)
7. velocity X (float, 4 bytes)
8. velocity Y (float, 4 bytes)
9. angle (float, 4 bytes)
10. width (int 4 bytes)
11. height (int 4 bytes)
Chat Packet (Packet ID: 7)
1. Text length (2 bytes)
2. Text (n bytes)