|
group2 0.1.0
CSE 125 Group 2
|
Server-only locomotion bookkeeping. More...
#include <PlayerSimState.hpp>
Public Attributes | |
| bool | canDoubleJump {true} |
| Refreshed only after k_doubleJumpGroundedRefreshTime of continuous grounded OnFoot time. | |
| bool | jumpedThisTick {false} |
| Set during the tick a jump occurs (for lurch setup). | |
| bool | jumpHeldLastTick {false} |
| Was jump key held on the previous tick (edge detection). | |
| float | jumpCooldown {0.0f} |
| Minimum time before double jump is available (s). | |
| float | coyoteTimer {0.0f} |
| Remaining grace time after leaving ground/wall (s). | |
| bool | wasGroundedLastTick {false} |
| float | groundedDuration {0.0f} |
| Time continuously grounded (s); resets on leaving ground. | |
| bool | jumpLurchEnabled {false} |
| True during the lurch grace window after jumping. | |
| float | jumpLurchTimer {0.0f} |
| Time elapsed since the jump that enabled lurch (s). | |
| glm::vec2 | moveInputsOnJump {0.0f} |
| WASD direction when jump started (for direction-change detection). | |
| float | slideTimer {0.0f} |
| How long the current slide has lasted (s). | |
| int | slideFatigueCounter {0} |
| Diminishing returns on consecutive slidehops. | |
| float | slideBoostCooldown {0.0f} |
| Remaining cooldown before next slide boost (s). | |
| int | slideFatigueDecayAccum {0} |
| Tick accumulator for fatigue recovery. | |
| bool | canEnterSlide {true} |
| Cleared when in air, set on landing. | |
| glm::vec3 | wallNormal {0.0f} |
| Normal of the wall being run on. | |
| glm::vec3 | wallForward {0.0f} |
| Direction of travel along the wall. | |
| glm::vec3 | wallAnchor {0.0f} |
| Closest point on the attached wall surface. | |
| float | wallRunTimer {0.0f} |
| Time on current wall (s). | |
| float | wallRunSpeedTimer {0.0f} |
| Timer for the speed-loss delay. | |
| float | exitWallTimer {0.0f} |
| Remaining exit-wall grace time (s). | |
| uint32_t | wallMeshIndex {UINT32_MAX} |
| Current static collision mesh under the wall attachment, if any. | |
| uint32_t | wallTriId {UINT32_MAX} |
| Current mesh triangle under the wall attachment, if any. | |
| physics::TriRegion | wallRegion {physics::TriRegion::Face} |
| Closest feature on wallMeshIndex / wallTriId. | |
| bool | wallAttachmentValid {false} |
| True while the wallrun has a collision-backed attachment. | |
| bool | wallCornerTransitionActive {false} |
| True while carrying a pending external-corner handoff. | |
| glm::vec3 | wallCornerAnchor {0.0f} |
| Corner/seam point used as the transition clearance origin. | |
| glm::vec3 | wallCornerFromNormal {0.0f} |
| Wall normal held until the capsule clears the old wall edge. | |
| glm::vec3 | wallCornerFromForward {0.0f} |
| Old wall tangent held during the corner approach. | |
| glm::vec3 | wallCornerToNormal {0.0f} |
| Pending wall normal to attach after clearance. | |
| glm::vec3 | wallCornerToForward {0.0f} |
| Pending wall tangent to use after clearance. | |
| uint32_t | wallCornerMeshIndex {UINT32_MAX} |
| Pending wall mesh after corner clearance. | |
| uint32_t | wallCornerTriId {UINT32_MAX} |
| Pending wall triangle after corner clearance. | |
| physics::TriRegion | wallCornerRegion {physics::TriRegion::Face} |
| Pending wall feature after clearance. | |
| float | wallCornerTimer {0.0f} |
| Time spent in the active corner transition (s). | |
| glm::vec3 | wallCornerIgnoreNormal {0.0f} |
| Source wall briefly ignored after a corner commit. | |
| float | wallCornerIgnoreTimer {0.0f} |
| Remaining time to suppress source-wall backtracking. | |
| bool | wallrunBlockerActive {false} |
| True while collision is sliding/holding against a non-traversable blocker. | |
| glm::vec3 | wallrunBlockerNormal {0.0f} |
| Collision normal of the active wallrun blocker. | |
| float | wallrunBlockerTimer {0.0f} |
| Time since the blocker was last confirmed by KCC. | |
| int | wallrunBlockedFrames {0} |
| Consecutive frames constrained by the active blocker. | |
| float | wallrunCeilingConstrainedTimer {0.0f} |
| Short grace after head/ceiling contact while wallrun remains valid. | |
| bool | wasWallRunning {false} |
| Set briefly after leaving wallrun (coyote wall jump). | |
| glm::vec3 | pendingKccCorrection {0.0f} |
| One-tick collision-owned correction requested by movement. | |
| physics::KccFrameResult | lastKccResult {} |
| Last collision feedback frame emitted by KCC. | |
| bool | hasLastKccResult {false} |
| True after the first KCC frame has been recorded. | |
| glm::vec3 | kccPreviousPosBefore {0.0f} |
| Previous KCC input position for oscillation detection. | |
| glm::vec3 | kccPreviousPosAfter {0.0f} |
| Previous KCC output position for oscillation detection. | |
| glm::vec3 | kccPreviousDepenDelta {0.0f} |
| Previous depenetration push for oscillation detection. | |
| bool | kccPreviousFrameValid {false} |
| True once previous KCC frame fields are initialized. | |
| int | kccOscillationFrames {0} |
| Consecutive ABAB-style KCC oscillation detections. | |
| glm::vec3 | wallBlacklistNormal {0.0f} |
| float | wallBlacklistHeight {-1e10f} |
| bool | wallBlacklistActive {false} |
| glm::vec3 | lastSafePosition {0.0f} |
| Last KCC-verified non-penetrating capsule center. | |
| bool | lastSafePositionValid {false} |
| bool | grappleCooldownActive {false} |
| True during cooldown between uses. | |
| float | grappleCooldownTimer {0.0f} |
| Remaining cooldown time (s). | |
| float | grapplePullTimer {0.0f} |
| Time spent being pulled (s). | |
| glm::vec3 | grapplePullDir {0.0f} |
| Cached pull direction (toward anchor at fire time). | |
| bool | grappleInputLastTick {false} |
| Edge detection on the grapple key. | |
Server-only locomotion bookkeeping.
Read/written by MovementSystem and CollisionSystem on the server every physics tick. Will be mirrored on the owning client in Phase 5 for prediction; remote clients never see this.
| bool PlayerSimState::canDoubleJump {true} |
Refreshed only after k_doubleJumpGroundedRefreshTime of continuous grounded OnFoot time.
Wall jumps, slidehops, and instant landings do NOT refresh it.
| bool PlayerSimState::canEnterSlide {true} |
Cleared when in air, set on landing.
| float PlayerSimState::coyoteTimer {0.0f} |
Remaining grace time after leaving ground/wall (s).
| float PlayerSimState::exitWallTimer {0.0f} |
Remaining exit-wall grace time (s).
| bool PlayerSimState::grappleCooldownActive {false} |
True during cooldown between uses.
| float PlayerSimState::grappleCooldownTimer {0.0f} |
Remaining cooldown time (s).
| bool PlayerSimState::grappleInputLastTick {false} |
Edge detection on the grapple key.
| glm::vec3 PlayerSimState::grapplePullDir {0.0f} |
Cached pull direction (toward anchor at fire time).
| float PlayerSimState::grapplePullTimer {0.0f} |
Time spent being pulled (s).
| float PlayerSimState::groundedDuration {0.0f} |
Time continuously grounded (s); resets on leaving ground.
Distinguishes fresh ground jumps (lurch-eligible) from bhop chain continuations.
| bool PlayerSimState::hasLastKccResult {false} |
True after the first KCC frame has been recorded.
| float PlayerSimState::jumpCooldown {0.0f} |
Minimum time before double jump is available (s).
| bool PlayerSimState::jumpedThisTick {false} |
Set during the tick a jump occurs (for lurch setup).
| bool PlayerSimState::jumpHeldLastTick {false} |
Was jump key held on the previous tick (edge detection).
| bool PlayerSimState::jumpLurchEnabled {false} |
True during the lurch grace window after jumping.
| float PlayerSimState::jumpLurchTimer {0.0f} |
Time elapsed since the jump that enabled lurch (s).
| int PlayerSimState::kccOscillationFrames {0} |
Consecutive ABAB-style KCC oscillation detections.
| glm::vec3 PlayerSimState::kccPreviousDepenDelta {0.0f} |
Previous depenetration push for oscillation detection.
| bool PlayerSimState::kccPreviousFrameValid {false} |
True once previous KCC frame fields are initialized.
| glm::vec3 PlayerSimState::kccPreviousPosAfter {0.0f} |
Previous KCC output position for oscillation detection.
| glm::vec3 PlayerSimState::kccPreviousPosBefore {0.0f} |
Previous KCC input position for oscillation detection.
| physics::KccFrameResult PlayerSimState::lastKccResult {} |
Last collision feedback frame emitted by KCC.
| glm::vec3 PlayerSimState::lastSafePosition {0.0f} |
Last KCC-verified non-penetrating capsule center.
| bool PlayerSimState::lastSafePositionValid {false} |
| glm::vec2 PlayerSimState::moveInputsOnJump {0.0f} |
WASD direction when jump started (for direction-change detection).
| glm::vec3 PlayerSimState::pendingKccCorrection {0.0f} |
One-tick collision-owned correction requested by movement.
| float PlayerSimState::slideBoostCooldown {0.0f} |
Remaining cooldown before next slide boost (s).
| int PlayerSimState::slideFatigueCounter {0} |
Diminishing returns on consecutive slidehops.
| int PlayerSimState::slideFatigueDecayAccum {0} |
Tick accumulator for fatigue recovery.
| float PlayerSimState::slideTimer {0.0f} |
How long the current slide has lasted (s).
| glm::vec3 PlayerSimState::wallAnchor {0.0f} |
Closest point on the attached wall surface.
| bool PlayerSimState::wallAttachmentValid {false} |
True while the wallrun has a collision-backed attachment.
| bool PlayerSimState::wallBlacklistActive {false} |
| float PlayerSimState::wallBlacklistHeight {-1e10f} |
| glm::vec3 PlayerSimState::wallBlacklistNormal {0.0f} |
| glm::vec3 PlayerSimState::wallCornerAnchor {0.0f} |
Corner/seam point used as the transition clearance origin.
| glm::vec3 PlayerSimState::wallCornerFromForward {0.0f} |
Old wall tangent held during the corner approach.
| glm::vec3 PlayerSimState::wallCornerFromNormal {0.0f} |
Wall normal held until the capsule clears the old wall edge.
| glm::vec3 PlayerSimState::wallCornerIgnoreNormal {0.0f} |
Source wall briefly ignored after a corner commit.
| float PlayerSimState::wallCornerIgnoreTimer {0.0f} |
Remaining time to suppress source-wall backtracking.
| uint32_t PlayerSimState::wallCornerMeshIndex {UINT32_MAX} |
Pending wall mesh after corner clearance.
| physics::TriRegion PlayerSimState::wallCornerRegion {physics::TriRegion::Face} |
Pending wall feature after clearance.
| float PlayerSimState::wallCornerTimer {0.0f} |
Time spent in the active corner transition (s).
| glm::vec3 PlayerSimState::wallCornerToForward {0.0f} |
Pending wall tangent to use after clearance.
| glm::vec3 PlayerSimState::wallCornerToNormal {0.0f} |
Pending wall normal to attach after clearance.
| bool PlayerSimState::wallCornerTransitionActive {false} |
True while carrying a pending external-corner handoff.
| uint32_t PlayerSimState::wallCornerTriId {UINT32_MAX} |
Pending wall triangle after corner clearance.
| glm::vec3 PlayerSimState::wallForward {0.0f} |
Direction of travel along the wall.
| uint32_t PlayerSimState::wallMeshIndex {UINT32_MAX} |
Current static collision mesh under the wall attachment, if any.
| glm::vec3 PlayerSimState::wallNormal {0.0f} |
Normal of the wall being run on.
| physics::TriRegion PlayerSimState::wallRegion {physics::TriRegion::Face} |
Closest feature on wallMeshIndex / wallTriId.
| int PlayerSimState::wallrunBlockedFrames {0} |
Consecutive frames constrained by the active blocker.
| bool PlayerSimState::wallrunBlockerActive {false} |
True while collision is sliding/holding against a non-traversable blocker.
| glm::vec3 PlayerSimState::wallrunBlockerNormal {0.0f} |
Collision normal of the active wallrun blocker.
| float PlayerSimState::wallrunBlockerTimer {0.0f} |
Time since the blocker was last confirmed by KCC.
| float PlayerSimState::wallrunCeilingConstrainedTimer {0.0f} |
Short grace after head/ceiling contact while wallrun remains valid.
| float PlayerSimState::wallRunSpeedTimer {0.0f} |
Timer for the speed-loss delay.
| float PlayerSimState::wallRunTimer {0.0f} |
Time on current wall (s).
| uint32_t PlayerSimState::wallTriId {UINT32_MAX} |
Current mesh triangle under the wall attachment, if any.
| bool PlayerSimState::wasGroundedLastTick {false} |
| bool PlayerSimState::wasWallRunning {false} |
Set briefly after leaving wallrun (coyote wall jump).