r705 - in trunk/code: botlib game
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Fri Apr 14 16:35:47 EDT 2006
Author: tma
Date: 2006-04-14 16:35:47 -0400 (Fri, 14 Apr 2006)
New Revision: 705
Modified:
trunk/code/botlib/be_interface.c
trunk/code/game/ai_main.c
Log:
* Output botlib.log in a sensible place (from Erik Auerswald)
Modified: trunk/code/botlib/be_interface.c
===================================================================
--- trunk/code/botlib/be_interface.c 2006-04-14 20:28:28 UTC (rev 704)
+++ trunk/code/botlib/be_interface.c 2006-04-14 20:35:47 UTC (rev 705)
@@ -136,12 +136,14 @@
int Export_BotLibSetup(void)
{
int errnum;
+ char logfilename[MAX_QPATH];
bot_developer = LibVarGetValue("bot_developer");
memset( &botlibglobals, 0, sizeof(botlibglobals) ); // bk001207 - init
//initialize byte swapping (litte endian etc.)
// Swap_Init();
- Log_Open("botlib.log");
+ Com_sprintf(logfilename, sizeof(logfilename), "%s%cbotlib.log", LibVarGetString("homedir"), PATH_SEP);
+ Log_Open(logfilename);
//
botimport.Print(PRT_MESSAGE, "------- BotLib Initialization -------\n");
//
Modified: trunk/code/game/ai_main.c
===================================================================
--- trunk/code/game/ai_main.c 2006-04-14 20:28:28 UTC (rev 704)
+++ trunk/code/game/ai_main.c 2006-04-14 20:35:47 UTC (rev 705)
@@ -1628,6 +1628,9 @@
//cd directory
trap_Cvar_VariableStringBuffer("fs_cdpath", buf, sizeof(buf));
if (strlen(buf)) trap_BotLibVarSet("cddir", buf);
+ //home directory
+ trap_Cvar_VariableStringBuffer("fs_homepath", buf, sizeof(buf));
+ if (strlen(buf)) trap_BotLibVarSet("homedir", buf);
//
#ifdef MISSIONPACK
trap_BotLibDefine("MISSIONPACK");
More information about the quake3-commits
mailing list