mirror of
https://github.com/p2r3/bareiron.git
synced 2025-10-02 07:35:08 +02:00
refactor to use struct instead of byte buffer
This commit is contained in:
@@ -9,17 +9,8 @@ ssize_t recv_count;
|
||||
uint8_t recv_buffer[256] = {0};
|
||||
|
||||
uint32_t world_seed = 0xA103DE6C;
|
||||
uint8_t block_changes[50 * 1024];
|
||||
|
||||
BlockChange block_changes[20000];
|
||||
int block_changes_count = 0;
|
||||
|
||||
uint8_t player_data[(
|
||||
16 + // UUID
|
||||
4 + // File descriptor
|
||||
2 + // X position (short)
|
||||
2 + // Y position (short)
|
||||
2 + // Z position (short)
|
||||
2 + // Angles (both, i8)
|
||||
1 + // Hotbar slot
|
||||
123 // Inventory (u16 id, u8 count)
|
||||
) * MAX_PLAYERS];
|
||||
int player_data_size = 16 + 4 + 2 + 2 + 2 + 2 + 1 + 123;
|
||||
PlayerData player_data[MAX_PLAYERS];
|
||||
|
Reference in New Issue
Block a user