Skip to content

Commit

Permalink
botai path removed from project refs #33
Browse files Browse the repository at this point in the history
  • Loading branch information
IR4T4 committed May 7, 2012
1 parent cfdd5b2 commit 55b1352
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 113 deletions.
89 changes: 0 additions & 89 deletions src/botai/botai.h

This file was deleted.

10 changes: 5 additions & 5 deletions src/botlib/be_interface.c
Expand Up @@ -50,8 +50,7 @@ botlib_globals_t botlibglobals;

botlib_export_t be_botlib_export;
botlib_import_t botimport;
//
int bot_developer;

//qtrue if the library is setup
int botlibsetup = qfalse;

Expand Down Expand Up @@ -105,15 +104,14 @@ int Sys_MilliSeconds(void)
//===========================================================================
qboolean BotLibSetup(char *str)
{
// return qtrue;

if (!botlibglobals.botlibsetup)
{
botimport.Print(PRT_ERROR, "%s: bot library used before being setup\n", str);
return qfalse;
} //end if
return qtrue;
} //end of the function BotLibSetup

//===========================================================================
//
// Parameter: -
Expand All @@ -125,7 +123,6 @@ int Export_BotLibSetup(qboolean singleplayer)
{
int errnum;

bot_developer = LibVarGetValue("bot_developer");
//initialize byte swapping (litte endian etc.)
Log_Open("botlib.log");
//
Expand All @@ -147,6 +144,7 @@ int Export_BotLibSetup(qboolean singleplayer)

return BLERR_NOERROR;
} //end of the function Export_BotLibSetup

//===========================================================================
//
// Parameter: -
Expand Down Expand Up @@ -190,6 +188,7 @@ int Export_BotLibShutdown(void)
#endif
return BLERR_NOERROR;
} //end of the function Export_BotLibShutdown

//===========================================================================
//
// Parameter: -
Expand All @@ -201,6 +200,7 @@ int Export_BotLibVarSet(char *var_name, char *value)
LibVarSet(var_name, value);
return BLERR_NOERROR;
} //end of the function Export_BotLibVarSet

//===========================================================================
//
// Parameter: -
Expand Down
1 change: 0 additions & 1 deletion src/botlib/be_interface.h
Expand Up @@ -84,7 +84,6 @@ typedef struct botlib_globals_s

extern botlib_globals_t botlibglobals;
extern botlib_import_t botimport;
extern int bot_developer; //true if developer is on

//
int Sys_MilliSeconds(void);
13 changes: 0 additions & 13 deletions src/botlib/botlib.h
Expand Up @@ -36,7 +36,6 @@

#define BOTLIB_API_VERSION 2

struct aas_clientmove_s;
struct aas_entityinfo_s;
struct bot_consolemessage_s;
struct bot_match_s;
Expand All @@ -62,25 +61,13 @@ typedef void (*BotPolyFunc)(int color, int numPoints, float *points);

#define BLOCKINGFLAG_MOVER (~0x7fffffff)

//debug line colors
#define LINECOLOR_NONE -1
#define LINECOLOR_RED 1 //0xf2f2f0f0L
#define LINECOLOR_GREEN 2 //0xd0d1d2d3L
#define LINECOLOR_BLUE 3 //0xf3f3f1f1L
#define LINECOLOR_YELLOW 4 //0xdcdddedfL
#define LINECOLOR_ORANGE 5 //0xe0e1e2e3L

//Print types
#define PRT_MESSAGE 1
#define PRT_WARNING 2
#define PRT_ERROR 3
#define PRT_FATAL 4
#define PRT_EXIT 5

//console message types
#define CMS_NORMAL 0
#define CMS_CHAT 1

//botlib error codes
#define BLERR_NOERROR 0 //no error
#define BLERR_LIBRARYNOTSETUP 1 //library not setup
Expand Down
1 change: 0 additions & 1 deletion src/botlib/botlib_stub.c
Expand Up @@ -121,7 +121,6 @@ void botlib_stub(void)

int PC_LoadSourceHandle(const char *filename)
{
// rain - FIXME - LoadSourceFile should take a const filename
return (int)LoadSourceFile(filename);
}

Expand Down
7 changes: 3 additions & 4 deletions src/botlib/l_log.c
Expand Up @@ -41,11 +41,9 @@
#include "be_interface.h" //for botimport.Print
#include "l_libvar.h"

#define MAX_LOGFILENAMESIZE 1024

typedef struct logfile_s
{
char filename[MAX_LOGFILENAMESIZE];
char filename[MAX_QPATH];
FILE *fp;
int numwrites;
} logfile_t;
Expand Down Expand Up @@ -76,9 +74,10 @@ void Log_AlwaysOpen(char *filename)
botimport.Print(PRT_ERROR, "can't open the log file %s\n", filename);
return;
} //end if
strncpy(logfile.filename, filename, MAX_LOGFILENAMESIZE);
strncpy(logfile.filename, filename, MAX_QPATH);
botimport.Print(PRT_MESSAGE, "Opened log %s\n", logfile.filename);
} //end of the function Log_Create

//===========================================================================
//
// Parameter: -
Expand Down

0 comments on commit 55b1352

Please sign in to comment.