From ae29ca99dde89f8b975ce7b3a716411ab2028e50 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Thu, 11 Jul 2024 13:48:42 +0200 Subject: send map metadata --- test-client/protocol.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'test-client/protocol.ts') diff --git a/test-client/protocol.ts b/test-client/protocol.ts index ddbc43c8..10b5b2dc 100644 --- a/test-client/protocol.ts +++ b/test-client/protocol.ts @@ -20,13 +20,19 @@ export type PlayerID = number export type ItemIndex = number export type TileIndex = number +export interface MapMetadata { + name: string, + players: number, + difficulty: number, +} + export interface Gamedata { item_names: string[], // Look-up table for ItemIndex tile_names: string[], // Look-up table for TileIndex tile_collide: boolean[], // Look-up table for TileIndex to check tile collision with players tile_interact: boolean[], // Look-up table for TileIndex to check if a tile is interactable spawn: Vec2, // Where players spawn when they join. - map_names: string[], + maps: { [key: string]: MapMetadata }, } export type PacketS = -- cgit v1.2.3-70-g09d2