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

Go to the source code of this file.
Functions | |
| int | AAS_AgainstLadder (vec3_t origin) |
| float | AAS_BFGJumpZVelocity (vec3_t origin) |
| int | AAS_ClientMovementHitBBox (struct aas_clientmove_s *move, int entnum, vec3_t origin, int presencetype, int onground, vec3_t velocity, vec3_t cmdmove, int cmdframes, int maxframes, float frametime, vec3_t mins, vec3_t maxs, int visualize) |
| int | AAS_DropToFloor (vec3_t origin, vec3_t mins, vec3_t maxs) |
| int | AAS_HorizontalVelocityForJump (float zvel, vec3_t start, vec3_t end, float *velocity) |
| void | AAS_InitSettings (void) |
| void | AAS_JumpReachRunStart (struct aas_reachability_s *reach, vec3_t runstart) |
| int | AAS_OnGround (vec3_t origin, int presencetype, int passent) |
| int | AAS_PredictClientMovement (struct aas_clientmove_s *move, int entnum, vec3_t origin, int presencetype, int onground, vec3_t velocity, vec3_t cmdmove, int cmdframes, int maxframes, float frametime, int stopevent, int stopareanum, int visualize) |
| float | AAS_RocketJumpZVelocity (vec3_t origin) |
| void | AAS_SetMovedir (vec3_t angles, vec3_t movedir) |
| int | AAS_Swimming (vec3_t origin) |
|
|
Definition at line 123 of file be_aas_move.c. References aas_area_t, aas_face_t, aas_plane_t, AAS_PointAreaNum(), AAS_PointInsideFace(), aasworld, abs(), aas_areasettings_s::areaflags, aas_s::areas, aas_s::areasettings, aas_plane_s::dist, DotProduct, f, aas_face_s::faceflags, aas_s::faceindex, aas_s::faces, aas_area_s::firstface, i, aas_plane_s::normal, aas_area_s::numfaces, aas_face_s::planenum, aas_s::planes, aas_areasettings_s::presencetype, vec3_t, and VectorCopy. Referenced by BotMoveToGoal(). 00124 {
00125 int areanum, i, facenum, side;
00126 vec3_t org;
00127 aas_plane_t *plane;
00128 aas_face_t *face;
00129 aas_area_t *area;
00130
00131 VectorCopy(origin, org);
00132 areanum = AAS_PointAreaNum(org);
00133 if (!areanum)
00134 {
00135 org[0] += 1;
00136 areanum = AAS_PointAreaNum(org);
00137 if (!areanum)
00138 {
00139 org[1] += 1;
00140 areanum = AAS_PointAreaNum(org);
00141 if (!areanum)
00142 {
00143 org[0] -= 2;
00144 areanum = AAS_PointAreaNum(org);
00145 if (!areanum)
00146 {
00147 org[1] -= 2;
00148 areanum = AAS_PointAreaNum(org);
00149 } //end if
00150 } //end if
00151 } //end if
00152 } //end if
00153 //if in solid... wrrr shouldn't happen
00154 if (!areanum) return qfalse;
00155 //if not in a ladder area
00156 if (!(aasworld.areasettings[areanum].areaflags & AREA_LADDER)) return qfalse;
00157 //if a crouch only area
00158 if (!(aasworld.areasettings[areanum].presencetype & PRESENCE_NORMAL)) return qfalse;
00159 //
00160 area = &aasworld.areas[areanum];
00161 for (i = 0; i < area->numfaces; i++)
00162 {
00163 facenum = aasworld.faceindex[area->firstface + i];
00164 side = facenum < 0;
00165 face = &aasworld.faces[abs(facenum)];
00166 //if the face isn't a ladder face
00167 if (!(face->faceflags & FACE_LADDER)) continue;
00168 //get the plane the face is in
00169 plane = &aasworld.planes[face->planenum ^ side];
00170 //if the origin is pretty close to the plane
00171 if (abs(DotProduct(plane->normal, origin) - plane->dist) < 3)
00172 {
00173 if (AAS_PointInsideFace(abs(facenum), origin, 0.1f)) return qtrue;
00174 } //end if
00175 } //end for
00176 return qfalse;
00177 } //end of the function AAS_AgainstLadder
|
Here is the call graph for this function:

|
|
Definition at line 352 of file be_aas_move.c. References AAS_WeaponJumpZVelocity(). Referenced by AAS_Reachability_WeaponJump(). 00353 {
00354 //bfg radius damage is 1000 (p_weapon.c: weapon_bfg_fire)
00355 return AAS_WeaponJumpZVelocity(origin, 120);
00356 } //end of the function AAS_BFGJumpZVelocity
|
Here is the call graph for this function:

|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Definition at line 1014 of file be_aas_move.c. References AAS_ClientMovementPrediction(), move(), and SE_HITBOUNDINGBOX. Referenced by AAS_BestReachableFromJumpPadArea(). 01021 {
01022 return AAS_ClientMovementPrediction(move, entnum, origin, presencetype, onground,
01023 velocity, cmdmove, cmdframes, maxframes,
01024 frametime, SE_HITBOUNDINGBOX, 0,
01025 mins, maxs, visualize);
01026 } //end of the function AAS_ClientMovementHitBBox
|
Here is the call graph for this function:

|
||||||||||||||||
|
Definition at line 56 of file be_aas_move.c. References AAS_Trace(), bsp_trace_t, CONTENTS_SOLID, bsp_trace_s::endpos, bsp_trace_s::startsolid, vec3_t, and VectorCopy. Referenced by AAS_SetWeaponJumpAreaFlags(), and BotInitLevelItems(). 00057 {
00058 vec3_t end;
00059 bsp_trace_t trace;
00060
00061 VectorCopy(origin, end);
00062 end[2] -= 100;
00063 trace = AAS_Trace(origin, mins, maxs, end, 0, CONTENTS_SOLID);
00064 if (trace.startsolid) return qfalse;
00065 VectorCopy(trace.endpos, origin);
00066 return qtrue;
00067 } //end of the function AAS_DropToFloor
|
Here is the call graph for this function:

|
||||||||||||||||||||
|
Definition at line 1062 of file be_aas_move.c. References aassettings, aas_settings_s::phys_gravity, aas_settings_s::phys_maxvelocity, sqrt(), t, top, vec3_t, and VectorSubtract. Referenced by AAS_FindFaceReachabilities(), AAS_Reachability_Jump(), AAS_Reachability_JumpPad(), AAS_Reachability_WeaponJump(), AAS_ShowReachability(), and BotTravel_WalkOffLedge(). 01063 {
01064 float phys_gravity, phys_maxvelocity;
01065 float maxjump, height2fall, t, top;
01066 vec3_t dir;
01067
01068 phys_gravity = aassettings.phys_gravity;
01069 phys_maxvelocity = aassettings.phys_maxvelocity;
01070
01071 //maximum height a player can jump with the given initial z velocity
01072 maxjump = 0.5 * phys_gravity * (zvel / phys_gravity) * (zvel / phys_gravity);
01073 //top of the parabolic jump
01074 top = start[2] + maxjump;
01075 //height the bot will fall from the top
01076 height2fall = top - end[2];
01077 //if the goal is to high to jump to
01078 if (height2fall < 0)
01079 {
01080 *velocity = phys_maxvelocity;
01081 return 0;
01082 } //end if
01083 //time a player takes to fall the height
01084 t = sqrt(height2fall / (0.5 * phys_gravity));
01085 //direction from start to end
01086 VectorSubtract(end, start, dir);
01087 //
01088 if ( (t + zvel / phys_gravity) == 0.0f ) {
01089 *velocity = phys_maxvelocity;
01090 return 0;
01091 }
01092 //calculate horizontal speed
01093 *velocity = sqrt(dir[0]*dir[0] + dir[1]*dir[1]) / (t + zvel / phys_gravity);
01094 //the horizontal speed must be lower than the max speed
01095 if (*velocity > phys_maxvelocity)
01096 {
01097 *velocity = phys_maxvelocity;
01098 return 0;
01099 } //end if
01100 return 1;
01101 } //end of the function AAS_HorizontalVelocityForJump
|
Here is the call graph for this function:

|
Here is the call graph for this function:

|
||||||||||||
|
Referenced by AAS_ShowReachability(), and BotTravel_Jump(). |
|
||||||||||||||||
|
Definition at line 185 of file be_aas_move.c. References aas_plane_t, AAS_PlaneFromNum(), aas_trace_t, AAS_TraceClientBBox(), aassettings, DotProduct, aas_trace_s::endpos, aas_trace_s::fraction, aas_plane_s::normal, aas_settings_s::phys_maxsteepness, aas_trace_s::planenum, aas_trace_s::startsolid, up, vec3_t, and VectorCopy. Referenced by AAS_ClientMovementPrediction(), BotMoveToGoal(), and BotWalkInDirection(). 00186 {
00187 aas_trace_t trace;
00188 vec3_t end, up = {0, 0, 1};
00189 aas_plane_t *plane;
00190
00191 VectorCopy(origin, end);
00192 end[2] -= 10;
00193
00194 trace = AAS_TraceClientBBox(origin, end, presencetype, passent);
00195
00196 //if in solid
00197 if (trace.startsolid) return qfalse;
00198 //if nothing hit at all
00199 if (trace.fraction >= 1.0) return qfalse;
00200 //if too far from the hit plane
00201 if (origin[2] - trace.endpos[2] > 10) return qfalse;
00202 //check if the plane isn't too steep
00203 plane = AAS_PlaneFromNum(trace.planenum);
00204 if (DotProduct(plane->normal, up) < aassettings.phys_maxsteepness) return qfalse;
00205 //the bot is on the ground
00206 return qtrue;
00207 } //end of the function AAS_OnGround
|
Here is the call graph for this function:

|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Definition at line 994 of file be_aas_move.c. References AAS_ClientMovementPrediction(), move(), and vec3_t. Referenced by AAS_JumpReachRunStart(), AAS_Reachability_Jump(), AAS_Reachability_JumpPad(), AAS_Reachability_Teleport(), AAS_Reachability_WeaponJump(), AAS_ShowReachability(), AAS_TestMovementPrediction(), and BotWalkInDirection(). 01001 {
01002 vec3_t mins, maxs;
01003 return AAS_ClientMovementPrediction(move, entnum, origin, presencetype, onground,
01004 velocity, cmdmove, cmdframes, maxframes,
01005 frametime, stopevent, stopareanum,
01006 mins, maxs, visualize);
01007 } //end of the function AAS_PredictClientMovement
|
Here is the call graph for this function:

|
|
Definition at line 341 of file be_aas_move.c. References AAS_WeaponJumpZVelocity(). Referenced by AAS_Reachability_WeaponJump(), and AAS_ShowReachability(). 00342 {
00343 //rocket radius damage is 120 (p_weapon.c: Weapon_RocketLauncher_Fire)
00344 return AAS_WeaponJumpZVelocity(origin, 120);
00345 } //end of the function AAS_RocketJumpZVelocity
|
Here is the call graph for this function:

|
||||||||||||
|
Definition at line 235 of file be_aas_move.c. References AngleVectors(), MOVEDIR_DOWN, MOVEDIR_UP, NULL, VEC_DOWN, VEC_UP, VectorCompare(), and VectorCopy. 00236 {
00237 if (VectorCompare(angles, VEC_UP))
00238 {
00239 VectorCopy(MOVEDIR_UP, movedir);
00240 } //end if
00241 else if (VectorCompare(angles, VEC_DOWN))
00242 {
00243 VectorCopy(MOVEDIR_DOWN, movedir);
00244 } //end else if
00245 else
00246 {
00247 AngleVectors(angles, movedir, NULL, NULL);
00248 } //end else
00249 } //end of the function AAS_SetMovedir
|
Here is the call graph for this function:

|
|
Definition at line 215 of file be_aas_move.c. References AAS_PointContents(), CONTENTS_LAVA, CONTENTS_SLIME, vec3_t, and VectorCopy. Referenced by AAS_ClientMovementPrediction(), AAS_TestMovementPrediction(), BotMoveInDirection(), BotMoveToGoal(), and BotReachabilityArea(). 00216 {
00217 vec3_t testorg;
00218
00219 VectorCopy(origin, testorg);
00220 testorg[2] -= 2;
00221 if (AAS_PointContents(testorg) & (CONTENTS_LAVA|CONTENTS_SLIME|CONTENTS_WATER)) return qtrue;
00222 return qfalse;
00223 } //end of the function AAS_Swimming
|
Here is the call graph for this function:

1.3.9.1