Commit Graph

5 Commits (14d36968054bc6a47e60529a122fb033505afb21)

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 963e7a34dc rewrite movement to c++ 2025-12-24 19:34:13 +05:00
Nikolay Petrov f572fdebca [code] Add ts instruments & refactor all code 2025-09-02 22:33:33 +05:00
Nikolay Petrov 24e515e80d [code] Stage 4: Test Results without documentation & tests 2025-08-24 19:49:19 +05:00
Nikolay Petrov bb6ebc6ff6 [code] Stage 2 complete: Professional debug infrastructure for deterministic movement system
Core Features:
- Paginated debug interface with keyboard navigation (PageUp/PageDown, Tab toggle)
- Real-time monitoring: Movement Constants, Surface Classification, Performance Metrics
- Modular component architecture: AC_DebugHUD (logic) + WBP_DebugHUD (UI)
- Enhanced Input integration with hotkey support
- Configurable update frequency for performance optimization

Technical Implementation:
- S_DebugPage struct with extensible update function system
- Comprehensive testing suite (system, content generation, navigation)
- Safe array operations with bounds checking
- Widget lifecycle management with visibility control
- TypeScript enum integration for Blueprint compatibility

Performance & Quality:
- <1ms initialization, <0.1ms per frame update
- Minimal UI footprint with Size-To-Content optimization
- 100% test coverage with automated validation
- Memory-safe widget management
- FPS impact <1% when active

Developer Experience:
- Easy page registration system for future extensions
- Clear separation of concerns between components
- Detailed documentation and decision logging
- Error handling for edge cases and invalid states

Files Added:
- AC_DebugHUD.ts - Core debug system component
- WBP_DebugHUD.ts - UI widget for display
- Debug enums, structs, and input actions
- Updated BP_MainCharacter integration
- Comprehensive documentation (TDD_Debug.md, DecisionLog_02.md)

Ready for Stage 3: Toast messages system
2025-08-21 19:57:48 +05:00