|
OpenEnroth 135c41f
|
#include "Engine/Pid.h"#include "Engine/Time/Duration.h"#include "Library/Geometry/Vec.h"#include "Library/Geometry/BBox.h"Classes | |
| struct | CollisionState |
Functions | |
| void | CollideIndoorWithGeometry (bool ignore_ethereal) |
| void | CollideOutdoorWithModels (bool ignore_ethereal) |
| void | CollideIndoorWithDecorations () |
| void | CollideOutdoorWithDecorations (Vec2i gridPos) |
| bool | CollideIndoorWithPortals () |
| bool | CollideWithActor (int actor_idx, int override_radius) |
| void | _46ED8A_collide_against_sprite_objects (Pid pid) |
| void | CollideWithParty (bool jagged_top) |
| void | ProcessActorCollisionsBLV (Actor &actor, bool isAboveGround, bool isFlying) |
| void | ProcessActorCollisionsODM (Actor &actor, bool isFlying) |
| void | ProcessPartyCollisionsBLV (int sectorId, int min_party_move_delta_sqr, int *faceId, int *faceEvent) |
| void | ProcessPartyCollisionsODM (Vec3f *partyNewPos, Vec3f *partyInputSpeed, int *floorFaceId, bool *partyNotOnModel, bool *partyHasHitModel, int *triggerID) |
| bool | hasShorterSolution (const float a, const float b, const float c, const float curSoln, float *outNewSoln, bool inside=false) |
Variables | |
| CollisionState | collision_state |
| void _46ED8A_collide_against_sprite_objects | ( | Pid | pid | ) |
| void CollideIndoorWithDecorations | ( | ) |
| void CollideIndoorWithGeometry | ( | bool | ignore_ethereal | ) |
Performs collisions with level geometry in indoor levels. Updates collision_state.
| ignore_ethereal | Whether ethereal faces should be ignored by this function. |
| bool CollideIndoorWithPortals | ( | ) |
Performs collision checks with portals. Updates collision_state. If the collision did happen, then adjusted_move_distance member is set to 0xFFFFFF (basically a large number).
| void CollideOutdoorWithDecorations | ( | Vec2i | gridPos | ) |
| gridPos | Grid coordinates. |
| void CollideOutdoorWithModels | ( | bool | ignore_ethereal | ) |
Performs collisions with models in outdoor levels. Updates collision_state.
| ignore_ethereal | Whether ethereal faces should be ignored by this function. |
| bool CollideWithActor | ( | int | actor_idx, |
| int | override_radius | ||
| ) |
| actor_idx | Actor index. |
| override_radius | Override actor's radius. Pass zero to use original radius. |
| void CollideWithParty | ( | bool | jagged_top | ) |
| jagged_top | Makes collision happen even if the monster would end up above the party. However, for the collision to happen, corresponding bounding boxes still need to intersect. |
| bool hasShorterSolution | ( | const float | a, |
| const float | b, | ||
| const float | c, | ||
| const float | curSoln, | ||
| float * | outNewSoln, | ||
| bool | inside = false |
||
| ) |
Finds whether this quadratic (of the form AX^2 + BX + C = 0) can be solved and if the solution is smaller than out current solution. Returns true if a smaller non negative solution is found.
| a | A component of quadratic. | |
| b | B component of quadratic. | |
| c | C component of quadratic. | |
| curSoln | Current input smallest solution to test against. | |
| [out] | outNewSoln | New smallest non negative solution. This value is not set if the function returns false. |
| inside | If you want collision with any point inside radius - for cylinder decorations/party |
| void ProcessActorCollisionsBLV | ( | Actor & | actor, |
| bool | isAboveGround, | ||
| bool | isFlying | ||
| ) |
Handles actor movement - performs collision detection, updates actor's position, handles sliding on slopes, deceleration, etc.
| actor | Actor to move. |
| isAboveGround | Whether the actor is currently above ground (stands on air, basically). |
| isFlying | Whether the actor is a flying creature that can fly (e.g. not paralyzed). |
| void ProcessActorCollisionsODM | ( | Actor & | actor, |
| bool | isFlying | ||
| ) |
| void ProcessPartyCollisionsBLV | ( | int | sectorId, |
| int | min_party_move_delta_sqr, | ||
| int * | faceId, | ||
| int * | faceEvent | ||
| ) |
| void ProcessPartyCollisionsODM | ( | Vec3f * | partyNewPos, |
| Vec3f * | partyInputSpeed, | ||
| int * | floorFaceId, | ||
| bool * | partyNotOnModel, | ||
| bool * | partyHasHitModel, | ||
| int * | triggerID | ||
| ) |
|
extern |