network.h
author signde
Sun, 12 Sep 2004 20:15:18 +0000
changeset 220 dc1710f96b39
parent 211 2954c4b30525
child 228 f65dec6727d9
permissions -rw-r--r--
(svn r221) -Feature: console command and variable hooking
-Fix: added another network.c stub
-Consolecommand: "scrollto <tile>" center main view on <tile> [Darkvater]
-Consolecommand: "resettile <tile>" force bulldoze <tile> without any checks (DEBUG only) [Darkvater]
-Fix: resetengines is hooked to be not available in network games
-Codechange: "connect <connectstr>": the connect command now uses a connectionstring like the network-gui
-Fix: Direct Connect editbox can handle up to max ~35 characters [Darkvater]
#ifndef NETWORK_H
#define NETWORK_H

typedef struct NetworkGameInfo {
	char server_name[40];			// name of the game
	char server_revision[8];	// server game version
	byte server_lang;					// langid
	byte players_max;					// max players allowed on server
	byte players_on;					// current count of players on server
	uint16 game_date;					// current date
	char game_password[10];		// should fit ... 10 chars
	char map_name[40];				// map which is played ["random" for a randomized map]
	uint map_width;						// map width / 8
	uint map_height;					// map height / 8
	byte map_set;							// graphical set
} NetworkGameInfo;

//typedef struct NetworkGameList;

typedef struct NetworkGameList {
	NetworkGameInfo item;
	uint32 ip;
	uint16 port;
	struct NetworkGameList * _next;
} NetworkGameList;

NetworkGameInfo _network_game;
NetworkGameList * _network_game_list;

#endif /* NETWORK_H */