diff options
author | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2007-09-05 18:17:46 +0000 |
---|---|---|
committer | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2007-09-05 18:17:46 +0000 |
commit | d37536edf4660f3c46e4876b6d72e9a200549ffe (patch) | |
tree | 637eb5f3e49f4075ecdef97a31f5e8157cee73a2 /code/botlib | |
parent | 4496eacc4ec7406fd694693da5a7f9589933f7fd (diff) | |
download | ioquake3-aero-d37536edf4660f3c46e4876b6d72e9a200549ffe.tar.gz ioquake3-aero-d37536edf4660f3c46e4876b6d72e9a200549ffe.zip |
* Merge unified-sdl to trunk
* Bump Q3_VERSION to 1.35
git-svn-id: svn://svn.icculus.org/quake3/trunk@1161 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code/botlib')
-rw-r--r-- | code/botlib/be_ai_chat.c | 6 | ||||
-rw-r--r-- | code/botlib/be_ai_goal.c | 18 | ||||
-rw-r--r-- | code/botlib/be_ai_move.c | 2 | ||||
-rw-r--r-- | code/botlib/be_ai_move.h | 2 | ||||
-rw-r--r-- | code/botlib/be_ai_weap.c | 2 | ||||
-rw-r--r-- | code/botlib/be_interface.c | 10 | ||||
-rw-r--r-- | code/botlib/l_memory.c | 2 | ||||
-rw-r--r-- | code/botlib/l_precomp.c | 2 | ||||
-rw-r--r-- | code/botlib/l_script.c | 4 |
9 files changed, 22 insertions, 26 deletions
diff --git a/code/botlib/be_ai_chat.c b/code/botlib/be_ai_chat.c index 7e560da..6d64cf6 100644 --- a/code/botlib/be_ai_chat.c +++ b/code/botlib/be_ai_chat.c @@ -1439,7 +1439,7 @@ int StringsMatch(bot_matchpiece_t *pieces, bot_match_t *match) //if the last piece was a variable string if (lastvariable >= 0) { - assert( match->variables[lastvariable].offset >= 0 ); // bk001204 + assert( match->variables[lastvariable].offset >= 0 ); match->variables[lastvariable].length = strlen(&match->string[ (int) match->variables[lastvariable].offset]); } //end if @@ -1500,7 +1500,7 @@ void BotMatchVariable(bot_match_t *match, int variable, char *buf, int size) { if (match->variables[variable].length < size) size = match->variables[variable].length+1; - assert( match->variables[variable].offset >= 0 ); // bk001204 + assert( match->variables[variable].offset >= 0 ); strncpy(buf, &match->string[ (int) match->variables[variable].offset], size-1); buf[size-1] = '\0'; } //end if @@ -2316,7 +2316,7 @@ int BotExpandChatMessage(char *outmessage, char *message, unsigned long mcontext } //end if if (match->variables[num].offset >= 0) { - assert( match->variables[num].offset >= 0 ); // bk001204 + assert( match->variables[num].offset >= 0 ); ptr = &match->string[ (int) match->variables[num].offset]; for (i = 0; i < match->variables[num].length; i++) { diff --git a/code/botlib/be_ai_goal.c b/code/botlib/be_ai_goal.c index 3706519..fbcc20f 100644 --- a/code/botlib/be_ai_goal.c +++ b/code/botlib/be_ai_goal.c @@ -176,22 +176,22 @@ typedef struct bot_goalstate_s float avoidgoaltimes[MAX_AVOIDGOALS]; //times to avoid the goals } bot_goalstate_t; -bot_goalstate_t *botgoalstates[MAX_CLIENTS + 1]; // bk001206 - FIXME: init? +bot_goalstate_t *botgoalstates[MAX_CLIENTS + 1]; // FIXME: init? //item configuration -itemconfig_t *itemconfig = NULL; // bk001206 - init +itemconfig_t *itemconfig = NULL; //level items -levelitem_t *levelitemheap = NULL; // bk001206 - init -levelitem_t *freelevelitems = NULL; // bk001206 - init -levelitem_t *levelitems = NULL; // bk001206 - init +levelitem_t *levelitemheap = NULL; +levelitem_t *freelevelitems = NULL; +levelitem_t *levelitems = NULL; int numlevelitems = 0; //map locations -maplocation_t *maplocations = NULL; // bk001206 - init +maplocation_t *maplocations = NULL; //camp spots -campspot_t *campspots = NULL; // bk001206 - init +campspot_t *campspots = NULL; //the game type -int g_gametype = 0; // bk001206 - init +int g_gametype = 0; //additional dropped item weight -libvar_t *droppedweight = NULL; // bk001206 - init +libvar_t *droppedweight = NULL; //======================================================================== // diff --git a/code/botlib/be_ai_move.c b/code/botlib/be_ai_move.c index 332c204..27a855a 100644 --- a/code/botlib/be_ai_move.c +++ b/code/botlib/be_ai_move.c @@ -51,8 +51,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA //#define DEBUG_ELEVATOR //#define DEBUG_GRAPPLE -// bk001204 - redundant bot_avoidspot_t, see be_ai_move.h - //movement state //NOTE: the moveflags MFL_ONGROUND, MFL_TELEPORTED, MFL_WATERJUMP and // MFL_GRAPPLEPULL must be set outside the movement code diff --git a/code/botlib/be_ai_move.h b/code/botlib/be_ai_move.h index d960c3c..a32d939 100644 --- a/code/botlib/be_ai_move.h +++ b/code/botlib/be_ai_move.h @@ -102,8 +102,6 @@ typedef struct bot_moveresult_s #define bot_moveresult_t_cleared(x) bot_moveresult_t (x) = {0, 0, 0, 0, 0, 0, 0, {0, 0, 0}, {0, 0, 0}} -// bk001204: from code/botlib/be_ai_move.c -// TTimo 04/12/2001 was moved here to avoid dup defines typedef struct bot_avoidspot_s { vec3_t origin; diff --git a/code/botlib/be_ai_weap.c b/code/botlib/be_ai_weap.c index 50b0dea..0aab5e8 100644 --- a/code/botlib/be_ai_weap.c +++ b/code/botlib/be_ai_weap.c @@ -51,7 +51,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA #define WEAPON_OFS(x) (size_t)&(((weaponinfo_t *)0)->x) #define PROJECTILE_OFS(x) (size_t)&(((projectileinfo_t *)0)->x) -//weapon definition // bk001212 - static +//weapon definition static fielddef_t weaponinfo_fields[] = { {"number", WEAPON_OFS(number), FT_INT}, //weapon number diff --git a/code/botlib/be_interface.c b/code/botlib/be_interface.c index 7f30300..9ef6756 100644 --- a/code/botlib/be_interface.c +++ b/code/botlib/be_interface.c @@ -21,7 +21,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ /***************************************************************************** - * name: be_interface.c // bk010221 - FIXME - DEAD code elimination + * name: be_interface.c * * desc: bot library interface * @@ -140,7 +140,7 @@ int Export_BotLibSetup(void) char *homedir, *gamedir; bot_developer = LibVarGetValue("bot_developer"); - memset( &botlibglobals, 0, sizeof(botlibglobals) ); // bk001207 - init + memset( &botlibglobals, 0, sizeof(botlibglobals) ); //initialize byte swapping (litte endian etc.) // Swap_Init(); homedir = LibVarGetString("homedir"); @@ -860,9 +860,9 @@ GetBotLibAPI ============ */ botlib_export_t *GetBotLibAPI(int apiVersion, botlib_import_t *import) { - assert(import); // bk001129 - this wasn't set for baseq3/ - botimport = *import; - assert(botimport.Print); // bk001129 - pars pro toto + assert(import); + botimport = *import; + assert(botimport.Print); Com_Memset( &be_botlib_export, 0, sizeof( be_botlib_export ) ); diff --git a/code/botlib/l_memory.c b/code/botlib/l_memory.c index 0dad5b6..da063ab 100644 --- a/code/botlib/l_memory.c +++ b/code/botlib/l_memory.c @@ -100,7 +100,7 @@ void *GetMemory(unsigned long size) { void *ptr; memoryblock_t *block; - assert(botimport.GetMemory); // bk001129 - was NULL'ed + assert(botimport.GetMemory); ptr = botimport.GetMemory(size + sizeof(memoryblock_t)); block = (memoryblock_t *) ptr; block->id = MEM_ID; diff --git a/code/botlib/l_precomp.c b/code/botlib/l_precomp.c index 74276a4..91b9a7b 100644 --- a/code/botlib/l_precomp.c +++ b/code/botlib/l_precomp.c @@ -669,7 +669,7 @@ void PC_AddBuiltinDefines(source_t *source) { char *string; int builtin; - } builtin[] = { // bk001204 - brackets + } builtin[] = { { "__LINE__", BUILTIN_LINE }, { "__FILE__", BUILTIN_FILE }, { "__DATE__", BUILTIN_DATE }, diff --git a/code/botlib/l_script.c b/code/botlib/l_script.c index e721891..5e4b128 100644 --- a/code/botlib/l_script.c +++ b/code/botlib/l_script.c @@ -706,14 +706,14 @@ int PS_ReadNumber(script_t *script, token_t *token) { c = *script->script_p; //check for a LONG number - if ( (c == 'l' || c == 'L') // bk001204 - brackets + if ( (c == 'l' || c == 'L') && !(token->subtype & TT_LONG)) { script->script_p++; token->subtype |= TT_LONG; } //end if //check for an UNSIGNED number - else if ( (c == 'u' || c == 'U') // bk001204 - brackets + else if ( (c == 'u' || c == 'U') && !(token->subtype & (TT_UNSIGNED | TT_FLOAT))) { script->script_p++; |