Main Page | Class Hierarchy | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals

l_utils.h File Reference

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Data Structures

struct  foundfile_s

Defines

#define _X   0
#define _Y   1
#define _Z   2
#define crandom()   (2.0 * (random() - 0.5))
#define FloatAbs(x)   (*(float *) &((* (int *) &(x)) & 0x7FFFFFFF))
#define IntAbs(x)   (~(x))
#define MAX_PATH   64
#define Maximum(x, y)   (x > y ? x : y)
#define Minimum(x, y)   (x < y ? x : y)
#define PATHSEPERATOR_CHAR   '/'
#define PATHSEPERATOR_STR   "/"
#define random()   ((rand () & 0x7fff) / ((float)0x7fff))

Typedefs

typedef foundfile_s foundfile_t

Functions

void AppendPathSeperator (char *path, int length)
void ConvertPath (char *path)
qboolean FindFileInPak (char *pakfile, char *filename, foundfile_t *file)
qboolean FindQuakeFile (char *basedir, char *gamedir, char *filename, foundfile_t *file)
void Vector2Angles (vec3_t value1, vec3_t angles)


Define Documentation

#define _X   0
 

Definition at line 53 of file l_utils.h.

#define _Y   1
 

Definition at line 54 of file l_utils.h.

#define _Z   2
 

Definition at line 55 of file l_utils.h.

 
#define crandom  )     (2.0 * (random() - 0.5))
 

Definition at line 45 of file l_utils.h.

Referenced by BotAimAtEnemy(), BotAttackMove(), BotFinishTravel_WaterJump(), BotMapScripts(), BotRoamGoal(), BotTravel_WaterJump(), Bullet_Fire(), CG_AddParticleToScene(), CG_AddPlayerWeapon(), CG_BigExplode(), CG_BubbleTrail(), CG_DrawPlayerHead(), CG_DrawStatusBarHead(), CG_GibPlayer(), CG_MachineGunEjectBrass(), CG_Particle_OilSlick(), CG_ParticleBloodCloud(), CG_ParticleBubble(), CG_ParticleDust(), CG_ParticleExplosion(), CG_ParticleImpactSmokePuff(), CG_ParticleSmoke(), CG_ParticleSnow(), CG_ParticleSnowFlurry(), CG_ParticleSparks(), CG_PlasmaTrail(), CG_ShotgunEjectBrass(), CG_Speaker(), Drop_Item(), EvolveFuzzySeperator_r(), FinishSpawningItem(), func_timer_think(), multi_trigger(), Terrain_AddMovePoint(), Touch_Item(), Use_Shooter(), and Use_Target_Delay().

#define FloatAbs  )     (*(float *) &((* (int *) &(x)) & 0x7FFFFFFF))
 

Definition at line 50 of file l_utils.h.

#define IntAbs  )     (~(x))
 

Definition at line 51 of file l_utils.h.

#define MAX_PATH   64
 

Definition at line 24 of file l_utils.h.

#define Maximum x,
y   )     (x > y ? x : y)
 

Definition at line 47 of file l_utils.h.

#define Minimum x,
y   )     (x < y ? x : y)
 

Definition at line 48 of file l_utils.h.

#define PATHSEPERATOR_CHAR   '/'
 

Definition at line 38 of file l_utils.h.

#define PATHSEPERATOR_STR   "/"
 

Definition at line 31 of file l_utils.h.

 
#define random  )     ((rand () & 0x7fff) / ((float)0x7fff))
 

Definition at line 43 of file l_utils.h.

Referenced by AAS_RandomGoalArea(), AIEnter_Respawn(), AINode_Battle_Fight(), AINode_Seek_ActivateEntity(), AINode_Seek_LTG(), AINode_Seek_NBG(), BotAddressedToBot(), BotAIBlocked(), BotAimAtEnemy(), BotAttackMove(), BotChat_Death(), BotChat_EndLevel(), BotChat_EnemySuicide(), BotChat_EnterGame(), BotChat_ExitGame(), BotChat_HitNoDeath(), BotChat_HitNoKill(), BotChat_HitTalking(), BotChat_Kill(), BotChat_Random(), BotChat_StartLevel(), BotCheckAttack(), BotCheckConsoleMessages(), BotChooseInitialChatMessage(), BotCTFSeekGoals(), BotDumpRandomStringList(), BotGetAlternateRouteGoal(), BotGetLongTermGoal(), BotGoCamp(), BotLoadRandomStrings(), BotMatch_AttackEnemyBase(), BotMatch_Camp(), BotMatch_DefendKeyArea(), BotMatch_GetFlag(), BotMatch_GetItem(), BotMatch_HelpAccompany(), BotMatch_Kill(), BotMatch_LeadTheWay(), BotMatch_Patrol(), BotMatch_ReturnFlag(), BotMatch_RushBase(), BotRandomMove(), BotRandomOpponentName(), BotRandomWeaponName(), BotReplaceWeightedSynonyms(), BotReplyChat(), BotRoamGoal(), BotTeamAI(), BotVoiceChat_Camp(), BotVoiceChat_Defend(), BotVoiceChat_FollowMe(), BotVoiceChat_GetFlag(), BotVoiceChat_Offense(), BotVoiceChat_ReturnFlag(), BotWantsToCamp(), Bullet_Fire(), CG_BloodPool(), CG_BubbleTrail(), CG_Bullet(), CG_DrawPlayerHead(), CG_DrawStatusBarHead(), CG_FragmentBounceMark(), CG_GetVoiceChat(), CG_LaunchExplode(), CG_LaunchGib(), CG_MachineGunEjectBrass(), CG_MissileHitWall(), CG_ParticleDust(), CG_ShotgunEjectBrass(), CG_Tracer(), CL_ChangeReliableCommand(), EvolveFuzzySeperator_r(), FS_FOpenFileRead(), FuzzyWeightUndecided(), FuzzyWeightUndecided_r(), G_AddRandomBot(), GeneticSelection(), Hunk_Trash(), RandomString(), SelectRandomFurthestSpawnPoint(), and Terrain_AddMovePoint().


Typedef Documentation

typedef struct foundfile_s foundfile_t
 

Referenced by PC_Directive_include().


Function Documentation

void AppendPathSeperator char *  path,
int  length
 

Definition at line 94 of file l_utils.c.

References length(), and strlen().

Referenced by AASOuputFile(), CreateAASFilesForAllBSPFiles(), FindQuakeFilesWithPakFilter(), and main().

00095 {
00096     int pathlen = strlen(path);
00097 
00098     if (strlen(path) && length-pathlen > 1 && path[pathlen-1] != '/' && path[pathlen-1] != '\\')
00099     {
00100         path[pathlen] = PATHSEPERATOR_CHAR;
00101         path[pathlen+1] = '\0';
00102     } //end if
00103 } //end of the function AppenPathSeperator

Here is the call graph for this function:

void ConvertPath char *  path  ) 
 

Definition at line 80 of file l_utils.c.

Referenced by FindQuakeFiles(), FindQuakeFilesInPak(), and FindQuakeFilesInZip().

00081 {
00082     while(*path)
00083     {
00084         if (*path == '/' || *path == '\\') *path = PATHSEPERATOR_CHAR;
00085         path++;
00086     } //end while
00087 } //end of the function ConvertPath

qboolean FindFileInPak char *  pakfile,
char *  filename,
foundfile_t file
 

qboolean FindQuakeFile char *  basedir,
char *  gamedir,
char *  filename,
foundfile_t file
 

void Vector2Angles vec3_t  value1,
vec3_t  angles
 


Generated on Thu Aug 25 12:44:39 2005 for Quake III Arena by  doxygen 1.3.9.1