Commit Graph

3 Commits (74996e5e4bc7dba8cf005d613934b740caed54ae)

Author SHA1 Message Date
Nikolay Petrov 8744cb759b feat(interaction): implement pickup, aim and throw mechanics
- Implement Context-Based Input system:
  - Added `IMC_ItemHeld` mapping context.
  - Added logic to switch contexts when picking up/dropping items.
  - Added `Throw` (LMB/R2) and `Aim` (RMB/L2) input actions.

- Refactor Interaction Logic:
  - `Interact`: Now handles picking up items or gently dropping them if held.
  - `OnThrowInput`: Implemented physics-based throw towards camera aim point (center of screen raycast).
  - Added character rotation to face the throw target instantly.

- Update Physics & Movement:
  - Added `bStrafing` mode to `TengriMovementComponent` to allow rotation towards camera view.
  - Updated `TengriPickupActor` to use `bVelChange` for impulses (ignoring mass for consistent throw arc).
  - Tuned throw force and added vertical arc bias.

- Fixes:
  - Resolved rotation logic in MovementComponent to support Aiming state.
2025-12-27 21:55:31 +05:00
Nikolay Petrov c54c9fd6ae feat(movement): implement jump system and air physics (Phases 13-14)
Implemented a responsive, deterministic jump system with "game feel" enhancements and advanced air physics.

Changes:
- **Jump Logic**: Added variable jump height (hold/release control).
- **Game Feel**: Implemented Coyote Time (jump after leaving ledge) and Jump Buffering (early input registration).
- **Air Physics**: Added non-linear gravity (FallingGravityScale) for snappy jumps and Terminal Velocity clamping.
- **Landing**: Added OnLanded delegate with heavy/light landing detection based on impact velocity.
- **Config**: Added auto-calculation logic in PostEditChangeProperty to derive Gravity and JumpVelocity from desired JumpHeight and TimeToApex.
- **Debug**: Added on-screen debug messages for Velocity Z and movement state.
- **Fix**: Moved delegate declaration to global scope to fix blueprint visibility issues.

Relates to: Phase 13, Phase 14
2025-12-26 01:45:13 +05:00
Nikolay Petrov 963e7a34dc rewrite movement to c++ 2025-12-24 19:34:13 +05:00