From 5c82193457dae58e84b3fe6041b9494feeb2c08a Mon Sep 17 00:00:00 2001 From: Walter Julius Hennecke Date: Mon, 5 Dec 2011 17:04:34 +0100 Subject: [PATCH] changes not worth mentioning --- game/q_math.c | 186 +++++++++++++++++++++++++----------------------- game/q_shared.c | 100 +++++++++++++------------- stefgame.suo | Bin 204800 -> 204800 bytes 3 files changed, 146 insertions(+), 140 deletions(-) diff --git a/game/q_math.c b/game/q_math.c index 3fbcaa1..a609086 100644 --- a/game/q_math.c +++ b/game/q_math.c @@ -1,6 +1,8 @@ -// Copyright (C) 1999-2000 Id Software, Inc. -// -// q_math.c -- stateless support routines that are included in each code module +/* + * Copyright (C) 1999-2000 Id Software, Inc. + * + * q_math.c -- stateless support routines that are included in each code module + */ #include "q_shared.h" int nonansicast = 0; @@ -11,66 +13,66 @@ vec3_t axisDefault[3] = { { 1, 0, 0 }, { 0, 1, 0 }, { 0, 0, 1 } }; vec4_t colorTable[CT_MAX] = { -{0, 0, 0, 0}, // CT_NONE -{0, 0, 0, 1}, // CT_BLACK -{1, 0, 0, 1}, // CT_RED -{0, 1, 0, 1}, // CT_GREEN -{0, 0, 1, 1}, // CT_BLUE -{1, 1, 0, 1}, // CT_YELLOW -{1, 0, 1, 1}, // CT_MAGENTA -{0, 1, 1, 1}, // CT_CYAN -{0.071, 0.271, 0.29, 1},// CT_TEAL -{0.529, 0.373, 0.017, 1},//CT_GOLD -{1, 1, 1, 1}, // CT_WHITE -{0.75, 0.75, 0.75, 1}, // CT_LTGREY -{0.50, 0.50, 0.50, 1}, // CT_MDGREY -{0.25, 0.25, 0.25, 1}, // CT_DKGREY -{0.15, 0.15, 0.15, 1}, // CT_DKGREY2 +{0, 0, 0, 0}, /* CT_NONE */ +{0, 0, 0, 1}, /* CT_BLACK */ +{1, 0, 0, 1}, /* CT_RED */ +{0, 1, 0, 1}, /* CT_GREEN */ +{0, 0, 1, 1}, /* CT_BLUE */ +{1, 1, 0, 1}, /* CT_YELLOW */ +{1, 0, 1, 1}, /* CT_MAGENTA */ +{0, 1, 1, 1}, /* CT_CYAN */ +{0.071, 0.271, 0.29, 1}, /* CT_TEAL */ +{0.529, 0.373, 0.017, 1},/* CT_GOLD */ +{1, 1, 1, 1}, /* CT_WHITE */ +{0.75, 0.75, 0.75, 1}, /* CT_LTGREY */ +{0.50, 0.50, 0.50, 1}, /* CT_MDGREY */ +{0.25, 0.25, 0.25, 1}, /* CT_DKGREY */ +{0.15, 0.15, 0.15, 1}, /* CT_DKGREY2 */ + +{0.688, 0.797, 1, 1}, /* CT_VLTORANGE -- needs values */ +{0.688, 0.797, 1, 1}, /* CT_LTORANGE */ +{0.620, 0.710, 0.894, 1},/* CT_DKORANGE */ +{0.463, 0.525, 0.671, 1},/* CT_VDKORANGE */ + +{0.616, 0.718, 0.898, 1},/* CT_VLTBLUE1 */ +{0.286, 0.506, 0.898, 1},/* CT_LTBLUE1 */ +{0.082, 0.388, 0.898, 1},/* CT_DKBLUE1 */ +{0.063, 0.278, 0.514, 1},/* CT_VDKBLUE1 */ -{0.688, 0.797, 1, 1}, // CT_VLTORANGE -- needs values -{0.688, 0.797, 1, 1}, // CT_LTORANGE -{0.620, 0.710, 0.894, 1}, // CT_DKORANGE -{0.463, 0.525, 0.671, 1}, // CT_VDKORANGE +{0.302, 0.380, 0.612, 1},/* CT_VLTBLUE2 -- needs values */ +{0.196, 0.314, 0.612, 1},/* CT_LTBLUE2 */ +{0.060, 0.227, 0.611, 1},/* CT_DKBLUE2 */ +{0.043, 0.161, 0.459, 1},/* CT_VDKBLUE2 */ -{0.616, 0.718, 0.898, 1}, // CT_VLTBLUE1 -{0.286, 0.506, 0.898, 1}, // CT_LTBLUE1 -{0.082, 0.388, 0.898, 1}, // CT_DKBLUE1 -{0.063, 0.278, 0.514, 1}, // CT_VDKBLUE1 +{0.082, 0.388, 0.898, 1},/* CT_VLTBROWN1 -- needs values */ +{0.082, 0.388, 0.898, 1},/* CT_LTBROWN1 */ +{0.078, 0.320, 0.813, 1},/* CT_DKBROWN1 */ +{0.060, 0.227, 0.611, 1},/* CT_VDKBROWN1 */ -{0.302, 0.380, 0.612, 1}, // CT_VLTBLUE2 -- needs values -{0.196, 0.314, 0.612, 1}, // CT_LTBLUE2 -{0.060, 0.227, 0.611, 1}, // CT_DKBLUE2 -{0.043, 0.161, 0.459, 1}, // CT_VDKBLUE2 +{1, 0.784, 0.365, 1}, /* CT_VLTGOLD1 -- needs values */ +{1, 0.706, 0.153, 1}, /* CT_LTGOLD1 */ +{0.733, 0.514, 0.086, 1},/* CT_DKGOLD1 */ +{0.549, 0.384, 0.063, 1},/* CT_VDKGOLD1 */ -{0.082, 0.388, 0.898, 1}, // CT_VLTBROWN1 -- needs values -{0.082, 0.388, 0.898, 1}, // CT_LTBROWN1 -{0.078, 0.320, 0.813, 1}, // CT_DKBROWN1 -{0.060, 0.227, 0.611, 1}, // CT_VDKBROWN1 +{0.688, 0.797, 1, 1}, /* CT_VLTPURPLE1 -- needs values */ +{0.688, 0.797, 1, 1}, /* CT_LTPURPLE1 */ +{0.313, 0.578, 1, 1}, /* CT_DKPURPLE1 */ +{0.031, 0.110, 0.341, 1},/* CT_VDKPURPLE1 */ -{1, 0.784, 0.365, 1}, // CT_VLTGOLD1 -- needs values -{1, 0.706, 0.153, 1}, // CT_LTGOLD1 -{0.733, 0.514, 0.086, 1}, // CT_DKGOLD1 -{0.549, 0.384, 0.063, 1}, // CT_VDKGOLD1 +{0.688, 0.797, 1, 1}, /* CT_VLTPURPLE2 -- needs values */ +{0.688, 0.797, 1, 1}, /* CT_LTPURPLE2 */ +{0.688, 0.797, 1, 1}, /* CT_DKPURPLE2 */ +{0.031, 0.110, 0.341, 1},/* CT_VDKPURPLE2 */ -{0.688, 0.797, 1, 1}, // CT_VLTPURPLE1 -- needs values -{0.688, 0.797, 1, 1}, // CT_LTPURPLE1 -{0.313, 0.578, 1, 1}, // CT_DKPURPLE1 -{0.031, 0.110, 0.341, 1}, // CT_VDKPURPLE1 +{0.686, 0.808, 0.1, 1}, /* CT_VLTPURPLE3 */ +{0.188, 0.494, 1, 1}, /* CT_LTPURPLE3 */ +{0.094, 0.471, 1, 1}, /* CT_DKPURPLE3 */ +{0.067, 0.325, 0.749, 1},/* CT_VDKPURPLE3 */ -{0.688, 0.797, 1, 1}, // CT_VLTPURPLE2 -- needs values -{0.688, 0.797, 1, 1}, // CT_LTPURPLE2 -{0.688, 0.797, 1, 1}, // CT_DKPURPLE2 -{0.031, 0.110, 0.341, 1}, // CT_VDKPURPLE2 - -{0.686, 0.808, 0.1, 1}, // CT_VLTPURPLE3 -{0.188, 0.494, 1, 1}, // CT_LTPURPLE3 -{0.094, 0.471, 1, 1}, // CT_DKPURPLE3 -{0.067, 0.325, 0.749, 1}, // CT_VDKPURPLE3 - -{1, 0.612, 0.325, 1}, // CT_VLTRED1 -{1, 0.478, 0.098, 1}, // CT_LTRED1 -{1, 0.438, 0, 1}, // CT_DKRED1 -{0.784, 0.329, 0, 1}, // CT_VDKRED1 +{1, 0.612, 0.325, 1}, /* CT_VLTRED1 */ +{1, 0.478, 0.098, 1}, /* CT_LTRED1 */ +{1, 0.438, 0, 1}, /* CT_DKRED1 */ +{0.784, 0.329, 0, 1}, /* CT_VDKRED1 */ }; @@ -184,7 +186,7 @@ vec3_t bytedirs[NUMVERTEXNORMALS] = {-0.587785, -0.425325, -0.688191}, {-0.688191, -0.587785, -0.425325} }; -//============================================================== +/*==============================================================*/ int Q_rand( int *seed ) { *seed = (69069 * *seed + 1); @@ -200,7 +202,7 @@ float Q_crandom( int *seed ) { } -//======================================================= +/*=======================================================*/ signed char ClampChar( int i ) { if ( i < -128 ) { @@ -223,7 +225,7 @@ signed short ClampShort( int i ) { } -// this isn't a real cheap function to call! +/* this isn't a real cheap function to call! */ /** * Converts a direction vector into a byte */ @@ -305,7 +307,7 @@ float NormalizeColor( const vec3_t in, vec3_t out ) { } -//============================================================================ +/*============================================================================*/ /* * \brief Returns false if the triangle is degenrate. @@ -396,10 +398,10 @@ RotateAroundDirection */ void RotateAroundDirection( vec3_t axis[3], float yaw ) { - // create an arbitrary axis[1] + /* create an arbitrary axis[1] */ PerpendicularVector( axis[1], axis[0] ); - // rotate it around axis[0] by yaw + /* rotate it around axis[0] by yaw */ if ( yaw ) { vec3_t temp; @@ -407,7 +409,7 @@ void RotateAroundDirection( vec3_t axis[3], float yaw ) { RotatePointAroundVector( axis[1], axis[0], temp, yaw ); } - // cross to get axis[2] + /* cross to get axis[2] */ CrossProduct( axis[0], axis[1], axis[2] ); } @@ -459,7 +461,7 @@ AnglesToAxis void AnglesToAxis( const vec3_t angles, vec3_t axis[3] ) { vec3_t right; - // angle vectors returns "right" instead of "y axis" + /* angle vectors returns "right" instead of "y axis" */ AngleVectors( angles, axis[0], right, axis[2] ); VectorSubtract( vec3_origin, right, axis[1] ); } @@ -510,8 +512,10 @@ void ProjectPointOnPlane( vec3_t dst, const vec3_t p, const vec3_t normal ) void MakeNormalVectors( const vec3_t forward, vec3_t right, vec3_t up) { float d; - // this rotate and negate guarantees a vector - // not colinear with the original + /* + * this rotate and negate guarantees a vector + * not colinear with the original + */ right[1] = -forward[0]; right[2] = forward[1]; right[0] = forward[2]; @@ -530,7 +534,7 @@ void VectorRotate( vec3_t in, vec3_t matrix[3], vec3_t out ) out[2] = DotProduct( in, matrix[2] ); } -//============================================================================ +/*============================================================================ */ /* * float q_rsqrt( float number ) @@ -549,11 +553,11 @@ float Q_rsqrt( float number ) x2 = number * 0.5F; y = number; - i = * ( long * ) &y; // evil floating point bit level hacking - i = 0x5f3759df - ( i >> 1 ); // what the fuck? + i = * ( long * ) &y; /* evil floating point bit level hacking */ + i = 0x5f3759df - ( i >> 1 ); /* what the fuck? */ y = * ( float * ) &i; - y = y * ( threehalfs - ( x2 * y * y ) ); // 1st iteration -// y = y * ( threehalfs - ( x2 * y * y ) ); // 2nd iteration, this can be removed + y = y * ( threehalfs - ( x2 * y * y ) ); /* 1st iteration */ +// y = y * ( threehalfs - ( x2 * y * y ) ); /* 2nd iteration, this can be removed */ return y; } @@ -664,7 +668,7 @@ float AngleDelta ( float angle1, float angle2 ) { } -//============================================================ +/*============================================================*/ /* @@ -675,7 +679,7 @@ SetPlaneSignbits void SetPlaneSignbits (cplane_t *out) { int bits, j; - // for fast box on planeside test + /* for fast box on planeside test */ bits = 0; for (j=0 ; j<3 ; j++) { if (out->normal[j] < 0) { @@ -734,7 +738,7 @@ int BoxOnPlaneSide (vec3_t emins, vec3_t emaxs, struct cplane_s *p) float dist1, dist2; int sides; -// fast axial cases +/* fast axial cases */ if (p->type < 3) { if (p->dist <= emins[p->type]) @@ -744,7 +748,7 @@ int BoxOnPlaneSide (vec3_t emins, vec3_t emaxs, struct cplane_s *p) return 3; } -// general case +/* general case */ switch (p->signbits) { case 0: @@ -780,7 +784,7 @@ int BoxOnPlaneSide (vec3_t emins, vec3_t emaxs, struct cplane_s *p) dist2 = p->normal[0]*emaxs[0] + p->normal[1]*emaxs[1] + p->normal[2]*emaxs[2]; break; default: - dist1 = dist2 = 0; // shut up compiler + dist1 = dist2 = 0; /* shut up compiler */ break; } @@ -1103,10 +1107,10 @@ vec_t VectorNormalize( vec3_t v ) { return length; } -// -// fast vector normalize routine that does not check to make sure -// that length != 0, nor does it return length -// +/* + * fast vector normalize routine that does not check to make sure + * that length != 0, nor does it return length + */ void VectorNormalizeFast( vec3_t v ) { float ilength; @@ -1276,7 +1280,7 @@ void MatrixMultiply(float in1[3][3], float in2[3][3], float out[3][3]) { void AngleVectors( const vec3_t angles, vec3_t forward, vec3_t right, vec3_t up) { float angle; static float sr, sp, sy, cr, cp, cy; - // static to help MS compiler fp bugs + /* static to help MS compiler fp bugs */ angle = angles[YAW] * (M_PI*2 / 360); sy = sin(angle); @@ -1322,7 +1326,7 @@ void PerpendicularVector( vec3_t dst, const vec3_t src ) ** find the smallest magnitude axially aligned vector ** bias towards using z instead of x or y */ -// for ( pos = 0, i = 0; i < 3; i++ ) +/* for ( pos = 0, i = 0; i < 3; i++ ) */ for ( pos = 0, i = 2; i >= 0; i-- ) { if ( fabs( src[i] ) < minelem ) @@ -1360,13 +1364,13 @@ float flrandom(float min, float max) */ int irandom(int min, int max) { - max++; //so it can round down + max++; /* so it can round down */ return (((rand() & 0x7FFF) * (max - min)) >> 15) + min; } -// use for networking - normalizes a vector, then multiplies it by 65535.0, then calls snap vector on it -// guarantee's a short per vector instead of 4 bytes. +/* use for networking - normalizes a vector, then multiplies it by 65535.0, then calls snap vector on it + guarantee's a short per vector instead of 4 bytes. */ void VectorShort(vec3_t vect) { @@ -1393,7 +1397,7 @@ float Q_powf( float x, int y ) return r; } -//TiM: Vector-Average. Good for calculating origins from bounding boxes +/* TiM: Vector-Average. Good for calculating origins from bounding boxes */ void VectorAverage( vec3_t mins, vec3_t maxs, vec3_t result ) { vec3_t temp; /*int i; @@ -1401,12 +1405,12 @@ void VectorAverage( vec3_t mins, vec3_t maxs, vec3_t result ) { result[i] = ( mins[i] + maxs[i] ) * 0.5; }*/ - //TiM: I 'unno... this way looks l33ter lol + /* TiM: I 'unno... this way looks l33ter lol */ VectorAdd( mins, maxs, temp ); VectorScale( temp, 0.5, result ); } -// Rounds the argument to the next integer. Used by SnapVector. +/* Rounds the argument to the next integer. Used by SnapVector. */ void init_tonextint(qboolean verbose) { float decimal = 0.9; @@ -1459,7 +1463,7 @@ unsigned long atoul( const char *string ) unsigned long value; int c; - // skip whitespace + /* skip whitespace */ while ( *string <= ' ' ) { if ( !*string ) { return 0; @@ -1467,7 +1471,7 @@ unsigned long atoul( const char *string ) string++; } - // read digits + /* read digits */ value = 0; do { c = *string++; @@ -1478,7 +1482,7 @@ unsigned long atoul( const char *string ) value = value * 10 + c; } while ( 1 ); - // not handling 10e10 notation... + /* not handling 10e10 notation... */ return value; } diff --git a/game/q_shared.c b/game/q_shared.c index 3a4c542..269d55c 100644 --- a/game/q_shared.c +++ b/game/q_shared.c @@ -1,13 +1,14 @@ -// Copyright (C) 1999-2000 Id Software, Inc. -// -// q_shared.c -- stateless support routines that are included in each code dll +/* Copyright (C) 1999-2000 Id Software, Inc. + * + * q_shared.c -- stateless support routines that are included in each code dll + */ #include "q_shared.h" -//vmCvar_t rpg_medicsrevive; //RPG-X: RedTechie - To let bg_pmovto work -//vmCvar_t rpg_noclipspectating; //RPG-X J2J: Defined here to prevent link errors when compiling cgame -//qboolean ClientNCSpec = qtrue; //RPG-X J2J: Private flag for weather the client chooses to spectate noclip style +/*vmCvar_t rpg_medicsrevive; //RPG-X: RedTechie - To let bg_pmovto work +vmCvar_t rpg_noclipspectating; //RPG-X J2J: Defined here to prevent link errors when compiling cgame +qboolean ClientNCSpec = qtrue; //RPG-X J2J: Private flag for weather the client chooses to spectate noclip style*/ -//float Q_powf ( float x, int y ); +/* float Q_powf ( float x, int y ); */ float Com_Clamp( float min, float max, float value ) { if ( value < min ) { @@ -61,15 +62,15 @@ void COM_DefaultExtension (char *path, int maxSize, const char *extension ) { char oldPath[MAX_QPATH]; char *src; -// -// if path doesn't have a .EXT, append extension -// (extension should include the .) -// +/* + * if path doesn't have a .EXT, append extension + * (extension should include the .) + */ src = path + strlen(path) - 1; while (*src != '/' && src != path) { if ( *src == '.' ) { - return; // it has an extension + return; /* it has an extension */ } src--; } @@ -86,8 +87,10 @@ void COM_DefaultExtension (char *path, int maxSize, const char *extension ) { ============================================================================ */ -// can't just use function pointers, or dll linkage can -// mess up when qcommon is included in multiple places +/* + *can't just use function pointers, or dll linkage can + * mess up when qcommon is included in multiple places + */ static short (*_BigShort) (short l); static short (*_LittleShort) (short l); static int (*_BigLong) (int l); @@ -97,20 +100,19 @@ static float (*_LittleFloat) (float l); #ifdef _M_IX86 -// -// optimised version for intel stuff... -// +/* + * optimised version for intel stuff... + */ short BigShort(short l){return _BigShort(l);} int BigLong (int l) {return _BigLong(l);} float BigFloat (float l) {return _BigFloat(l);} #define LittleShort(l) l #define LittleLong(l) l #define LittleFloat(l) l -// #else -// -// standard smart byte-swap stuff.... -// +/* + * standard smart byte-swap stuff.... + */ short BigShort(short l){return _BigShort(l);} short LittleShort(short l) {return _LittleShort(l);} int BigLong (int l) {return _BigLong(l);} @@ -184,7 +186,7 @@ void Swap_Init (void) { byte swaptest[2] = {1,0}; -// set the byte swapping variables in a portable manner +/* set the byte swapping variables in a portable manner */ if ( *(short *)swaptest == 1) { _BigShort = ShortSwap; @@ -273,7 +275,7 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) len = 0; com_token[0] = 0; - // make sure incoming data is valid + /* make sure incoming data is valid */ if ( !data ) { *data_p = NULL; @@ -282,7 +284,7 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) while ( 1 ) { - // skip whitespace + /* skip whitespace */ data = SkipWhitespace( data, &hasNewLines ); if ( !data ) { @@ -297,13 +299,13 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) c = *data; - // skip double slash comments + /* skip double slash comments */ if ( c == '/' && data[1] == '/' ) { while (*data && *data != '\n') data++; } - // skip /* */ comments + /* skip comments */ else if ( c=='/' && data[1] == '*' ) { while ( *data && ( *data != '*' || data[1] != '/' ) ) @@ -321,7 +323,7 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) } } - // handle quoted strings + /* handle quoted strings */ if (c == '\"') { data++; @@ -342,7 +344,7 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) } } - // parse a regular word + /* parse a regular word */ do { if (len < MAX_TOKEN_CHARS) @@ -358,7 +360,7 @@ char *COM_ParseExt( char **data_p, qboolean allowLineBreaks ) if (len == MAX_TOKEN_CHARS) { -// Com_Printf ("Token exceeded %i chars, discarded.\n", MAX_TOKEN_CHARS); +/* Com_Printf ("Token exceeded %i chars, discarded.\n", MAX_TOKEN_CHARS); */ len = 0; } com_token[len] = 0; @@ -457,7 +459,7 @@ qboolean COM_ParseVec3( char **data, vec3_t vector ) vector[i] = atof( token ); } - //TiM: Not reeeeally necessary + /* TiM: Not reeeeally necessary */ token = COM_ParseExt( data, qfalse ); if ( token[0] == 0 ) { @@ -505,7 +507,7 @@ qboolean COM_ParseVec4( char **data, vec4_t vector ) vector[i] = atof( token ); } - //TiM: Not reeeeally necessary + /* TiM: Not reeeeally necessary */ token = COM_ParseExt( data, qfalse ); if ( token[0] == 0 ) { @@ -522,7 +524,7 @@ qboolean COM_ParseVec4( char **data, vec4_t vector ) } #if 0 -// no longer used +/* no longer used */ /* =============== COM_ParseInfos @@ -604,7 +606,7 @@ void SkipBracedSection (char **program) { char *token; int depth=0; - if (com_token[0]=='{') { //for tr_shader which just ate the brace + if (com_token[0]=='{') { /* for tr_shader which just ate the brace */ depth = 1; } do { @@ -765,7 +767,7 @@ void Q_strncpyz( char *dest, const char *src, int destsize ) { int Q_stricmpn (const char *s1, const char *s2, int n) { int c1, c2; - // bk001129 - moved in 1.17 fix not in id codebase + /* bk001129 - moved in 1.17 fix not in id codebase */ if ( s1 == NULL ) { if ( s2 == NULL ) return 0; @@ -782,7 +784,7 @@ int Q_stricmpn (const char *s1, const char *s2, int n) { c2 = *s2++; if (!n--) { - return 0; // strings are equal until end point + return 0; /* strings are equal until end point */ } if (c1 != c2) { @@ -798,7 +800,7 @@ int Q_stricmpn (const char *s1, const char *s2, int n) { } } while (c1); - return 0; // strings are equal + return 0; /* strings are equal */ } int Q_strncmp (const char *s1, const char *s2, int n) { @@ -809,7 +811,7 @@ int Q_strncmp (const char *s1, const char *s2, int n) { c2 = *s2++; if (!n--) { - return 0; // strings are equal until end point + return 0; /* strings are equal until end point */ } if (c1 != c2) { @@ -817,7 +819,7 @@ int Q_strncmp (const char *s1, const char *s2, int n) { } } while (c1); - return 0; // strings are equal + return 0; /* strings are equal */ } int Q_stricmp (const char *s1, const char *s2) { @@ -847,7 +849,7 @@ char *Q_strupr( char *s1 ) { return s1; } -// never goes past bounds or leaves without a terminating 0 +/* never goes past bounds or leaves without a terminating 0 */ void Q_strcat( char *dest, int size, const char *src ) { int l1; @@ -907,7 +909,7 @@ char *Q_CleanStr( char *string ) { void QDECL Com_sprintf( char *dest, int size, const char *fmt, ...) { int len; va_list argptr; - char bigbuffer[32000]; // big, but small enough to fit in PPC stack + char bigbuffer[32000]; /* big, but small enough to fit in PPC stack */ va_start (argptr,fmt); len = vsprintf (bigbuffer,fmt,argptr); @@ -926,7 +928,7 @@ void QDECL Com_sprintf( char *dest, int size, const char *fmt, ...) { void QDECL Com_sprintf( char *dest, int size, const char *fmt, ...) { int len; va_list argptr; - char *bigbuffer = NULL; // big, but small enough to fit in PPC stack + char *bigbuffer = NULL; bigbuffer = (char *)malloc(sizeof(char)*32000); if(!bigbuffer) { @@ -962,7 +964,7 @@ FIXME: make this buffer size safe someday */ char * QDECL va( char *format, ... ) { va_list argptr; - static char string[2][32000]; // in case va is called by nested functions + static char string[2][32000]; /* in case va is called by nested functions */ static int index = 0; char *buf; @@ -996,8 +998,8 @@ FIXME: overflow check? */ char *Info_ValueForKey( const char *s, const char *key ) { char pkey[BIG_INFO_KEY]; - static char value[2][BIG_INFO_VALUE]; // use two buffers so compares - // work without stomping on each other + static char value[2][BIG_INFO_VALUE]; /* use two buffers so compares + work without stomping on each other */ static int valueindex = 0; char *o; @@ -1133,7 +1135,7 @@ void Info_RemoveKey( char *s, const char *key ) { if (!strcmp (key, pkey) ) { - strcpy (start, s); // remove this part + strcpy (start, s); /* remove this part */ return; } @@ -1188,7 +1190,7 @@ Info_RemoveKey_Big if (!strcmp (key, pkey) ) { - strcpy (start, s); // remove this part + strcpy (start, s); /* remove this part */ return; } @@ -1257,7 +1259,7 @@ void Info_RemoveKey_Big( char *s, const char *key ) { if (!strcmp (key, pkey) ) { - strcpy (start, s); // remove this part + strcpy (start, s); /* remove this part */ free(value); free(pkey); return; @@ -1432,7 +1434,7 @@ const char *GetStringForID( stringID_table_t *table, int id ) int index = 0; while ( ( table[index].name != NULL ) && - ( table[index].name[0] != 0 )/*VALIDSTRING( table[index].name )*/ )//RPG-X: RedTechie - Compile errors Fixed + ( table[index].name[0] != 0 )/*VALIDSTRING( table[index].name )*/ )/* RPG-X: RedTechie - Compile errors Fixed */ { if ( table[index].id == id ) return table[index].name; @@ -1444,6 +1446,6 @@ const char *GetStringForID( stringID_table_t *table, int id ) } -//==================================================================== +/*====================================================================*/ diff --git a/stefgame.suo b/stefgame.suo index b1c8b0ca394c1244dc54ce152dd6a2a807448093..44712818a398dd3c17ca0772649e6bd6b42cdb41 100644 GIT binary patch delta 1287 zcmY+DdraF^6vyv5^oO-+OCPLprX@gtFg7+MtWnghxJ3{*3sdK747&0v9j{S!naX>A zpc_z&+?g3RbarHJX2~YMOw3k9{KrQ$8e@iG(*>r6C`-Bw;-sG6qa^-u^Zn)A&pGFN z&+p#Oh`uwTKfhliuMpcueh`FOVC+Ds{9!B4>qko{Pm|aa(1`&ZjP+)g2#l@7 zVzE+Hcc}W5s%4V$q5;_SXoVW8RMn%ZSJfI->s0lr>X%eJHvm>Al=4Xpm@< z3-_4cAaA>9wbSaLwIcre4J7F7tdUi-Hnx#@*^+MP=U1}s2G46kmo{InxRS?HFM=&; zAFE@Pg!u^bvMqe_7!_Xp9`rm`ikbY(Bv|1Y%61I2Q}KRAcKo&7`_U31)5zf#$g8h z%BR>m0|O?T?EJ;9q_0g2yFa*EvGsP{rH;r?p}||pJpU}%MArgDFy7B~4z!{6DWmz& zg%7pgJ~aKN^K8=PGrKbmmrDtuT{eq!2pXKDk$LFAO>*_Q!QPVNx!J$>x&K)A&)*YG zdu2HLh#g#t$MG9rG}m^&(|*v5AUAyvLalzr#<9)@Bm!y108_mVXnpG!^y-U-1jHXk_ z_OQq0bUyMq+D$fb$=df<*K6BnN{XGcv7h{s~^pJhV_{y)CC7!y5 z8HrG#5_8xoJVAt)FVEw8erg_5g=eXP=6~;rN9Xa!;UU~0MsMOXCTLW$14~$@^%E`M zk<@-nmmVLFE}=USycGAT+%mdDQyU%-qsyqr;nSE-!%6D`2X}>0BkU)#RVIaEveL|# z!?;c&I*5pzCZd{%dYOPH`Ry>~O1r(vZh^3qk{T8N?{|S+N+}TB6!gU_jmnk6G~#BZ z&mJX3=`$)-lASbBp9Y24ON2U<^v-zEDhk%D7L^Vl^@8eEPu+1(wM6>kWLi(WK?^lF ppfso_q9RU=t|m56xRM8Za1%e-gLbX_{-h@;kN3LX62^p-{{Ufb#@qk^ delta 720 zcmY+A-%Aux6vyv5v$KV})M_9iONbgpI(BDv-I+Cr-F34^%?x@lWE^LOe)*$8k`x!} zEpdqr?>`{YLqrgDdx-`T^Q9>3AzHB))0cXY1zjlZjw@K_!oAgJn+Y!kN7^z@?{`oG=K5zF-B*wDo=g>drk#+D&X;bwp4&qES-a9PZVUv|sv5C)p$3{Px`{oZ}7KCZB@sfb&*0D~$Dw3^ze;vO-W>53t z2KIz}UOTLA2J5}SFlQUP@(azB6}Pd|Pi&DnP|kEp*qLt+sJvLhAhH($se#RIVRhv% zB>PeAmV^$n*IU>=HJBh0Nhz0l+NfA}V@A}_4Z~108Z{MF9f&A~ZucvcS~Qx`*wcV?dT#{b1^>Yaz6yO(T+`E#_F8ATx1b&^7j7YzaOw%k kPc@ujM?OI{n@(a6cTyMw)_4vZ*~ew5;xvt$Fptvlzv#W~x&QzG