summaryrefslogtreecommitdiff
path: root/source/mvd_client.c
diff options
context:
space:
mode:
authorAndrey Nazarov <skuller@skuller.net>2008-04-23 15:02:41 +0000
committerAndrey Nazarov <skuller@skuller.net>2008-04-23 15:02:41 +0000
commit49e6170b49fbb933eddec6d0e3f946320c68832f (patch)
tree88d228d6f89103710074fdba041ce80584d5caa6 /source/mvd_client.c
parent8c795585fb0c6c9178d9981f6943da04b7279205 (diff)
Added `dumpents' server command.
Added support for `cl_noskins' value of 2 (default all female skins to `female/athena', all male skins to `male/grunt'). Renamed `scoreshot' command to `aashot', added `aadump' command. Fixed several alignment issues on ARM architecture. Server browser menu now indicates full and password protected servers with color codes. Implemented history search in console with Ctrl+R, Ctrl+S. Removed `cl_railtrail_alpha' variable, all `cl_rail*_color' variables now accept colors in #RRGGBBAA format. Added `map_override' cvar (enables loading map entity lump from external maps/*.ent file). Made `quit' command accept extra arguments. Made `draw' command accept arbitrary colors in #RRGGBBAA format. Fixed debian packages.
Diffstat (limited to 'source/mvd_client.c')
-rw-r--r--source/mvd_client.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source/mvd_client.c b/source/mvd_client.c
index c5a436d..ba68ec6 100644
--- a/source/mvd_client.c
+++ b/source/mvd_client.c
@@ -26,8 +26,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include "mvd_local.h"
#include <setjmp.h>
-list_t mvd_channels;
-list_t mvd_ready;
+LIST_DECL( mvd_channels );
+LIST_DECL( mvd_ready );
+
mvd_t mvd_waitingRoom;
qboolean mvd_dirty;
int mvd_chanid;
@@ -227,7 +228,7 @@ static void MVD_EmitGamestate( mvd_t *mvd ) {
entity_state_t *es;
player_state_t *ps;
size_t length;
- uint16_t *patch;
+ uint8_t *patch;
int flags, extra, portalbytes;
byte portalbits[MAX_MAP_AREAS/8];
@@ -302,7 +303,9 @@ static void MVD_EmitGamestate( mvd_t *mvd ) {
// TODO: write private layouts/configstrings
- *patch = LittleShort( msg_write.cursize - 2 );
+ length = msg_write.cursize - 2;
+ patch[0] = length & 255;
+ patch[1] = ( length >> 8 ) & 255;
}
void MVD_SendGamestate( tcpClient_t *client ) {
@@ -806,7 +809,7 @@ mvd_t *MVD_SetChannel( int arg ) {
return NULL;
}
- if( COM_IsNumeric( s ) ) {
+ if( COM_IsUint( s ) ) {
id = atoi( s );
LIST_FOR_EACH( mvd_t, mvd, &mvd_channels, entry ) {
if( mvd->id == id ) {
@@ -1398,8 +1401,5 @@ void MVD_Register( void ) {
mvd_wait_percent = Cvar_Get( "mvd_wait_percent", "50", 0 );
Cmd_Register( c_mvd );
-
- List_Init( &mvd_channels );
- List_Init( &mvd_ready );
}