Commit Graph

21 Commits

Author SHA1 Message Date
1e1a29baef chore: ignore les binaires compilés
Ajoute Unreal/Plugins/*/Binaries/ et les patterns *.dll/*.pdb/*.exp/*.lib/*.exe/*.dylib au .gitignore, et retire de l'index les 22 binaires précédemment trackés. Évite de polluer le dépôt avec les artefacts de build régénérables.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-03 11:03:37 +02:00
b98d89c609 Fix ClientSideAim RPC spam from observer clients
Use GetLocalRole()==ROLE_AutonomousProxy instead of GetRemoteRole()==ROLE_Authority
to restrict the ClientAim/ShootRepCSA RPC path to the owning client only.
Observers (SimulatedProxy) early-out instead of attempting to send Server RPCs
on weapons they don't own, which was spamming "No owning connection" warnings
and doing useless work. Default ClientAimUpdateFrequency raised to 60 Hz.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-23 16:06:22 +02:00
f6a0cdc1c4 no message 2026-04-21 17:26:26 +02:00
97e8b709a0 binaries + python
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 08:48:39 +01:00
58df608550 Fix penetration/ricochet bugs: division by zero, edge cases, incidence angle
P0 - Division by zero fixes:
- Clamp PhysMaterial->Density to min 0.001 before division
- Clamp MuzzleVelocity averages to min 1.0 in all divisions
- Clamp PhysMaterial->Restitution to [0, 1]

P1 - Edge case guards:
- Stop bullet immediately when velocity is near-zero (prevents NaN)
- Handle near-zero cross product at very shallow grazing angles
- Handle zero-length bounceAngle in ricochet calculation

P2 - Improvements:
- Fix typo: BlockTIme -> BlockTime
- Add incidence angle factor to penetration depth: grazing shots
  penetrate less (5% at ~5deg) while head-on shots get full depth

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 19:29:45 +01:00
ba6b35b3d9 binaries + python 2026-03-18 19:08:24 +01:00
1a5b107b1f Remove obsolete features: calibration, IMU shock sim, quadratic regression, HUD, aim stabilization
Remove ~920 lines of dead code:
- Calibration system (replaced by Python analyze_shots.py)
- IMU shock simulation (no longer needed for testing)
- Debug HUD overlay (values are in CSV logs instead)
- Debug line thickness property (fixed to 0)
- Quadratic regression anti-recoil mode (linear regression sufficient)
- AdaptiveMinSpeed property (optimized to 0, not useful)
- AimStabilization dead zone (smoothing done in Blueprint instead)

Remaining anti-recoil modes: Buffer, LinearExtrapolation,
WeightedLinearRegression, KalmanFilter, AdaptiveExtrapolation

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 18:47:12 +01:00
cd097e4e55 Optimize adaptive extrapolation defaults from real-world test data
- Update defaults from test-driven optimization:
  BufferTime=200ms, DiscardTime=30ms, Sensitivity=3.0,
  DeadZone=0.95, MinSpeed=0.0, Damping=5.0
- Add ShotFired column to CSV recording for contamination analysis
- Rewrite Python optimizer with 6-parameter search (sensitivity,
  dead zone, min speed, damping, buffer time, discard time)
- Fix velocity weighting order bug in Python simulation
- Add dead zone, min speed threshold, and damping to Python sim
- Add shot contamination analysis (analyze_shots.py) to measure
  exact IMU perturbation duration per shot
- Support multi-file optimization with mean/worst_case strategies
- Add jitter and overshoot scoring metrics

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 18:33:14 +01:00
4e9c33778c binaries 2026-03-17 20:00:12 +01:00
48737b60c9 Tune adaptive extrapolation defaults, add AdaptiveMinSpeed property, fix debug visuals
- Add AdaptiveMinSpeed UPROPERTY (default 30 cm/s) to avoid false deceleration at low speeds
- Update default values: BufferTime=300ms, DiscardTime=40ms, Sensitivity=1.5, Damping=8.0
- Replace debug spheres with points to not obstruct aiming view
- Add detailed debug logs with [LOW]/[DZ]/[DEC] tags for dead zone diagnosis
- Convert buffer/discard time units to milliseconds
- Set AdaptiveExtrapolation as default AntiRecoil mode
- Fix DLL copy error handling in DinkeyPlugin and ViveVBS build scripts
- Add AimStabilization dead zone with smooth transition (no hard jumps)
- Add AimSmoothingSpeed property for temporal aim smoothing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 19:50:39 +01:00
83188b1fa1 no message 2026-03-16 18:27:00 +01:00
af723c944b Rework adaptive extrapolation: deceleration detection + dead zone + debug HUD
Replace variance-based confidence (caused constant lag) with targeted
deceleration detection: compares recent speed (last 25% of safe window)
to average speed. During steady movement ratio≈1 → zero lag.
Only reduces extrapolation when actual braking is detected.

- AdaptiveSensitivity: now a power exponent (0.1-5.0, default 1.0)
- AdaptiveDeadZone: new parameter (default 0.8) to ignore normal
  speed fluctuations and only react to real deceleration
- DebugAntiRecoilHUD: real-time display of ratio, confidence, speeds, errors
- EndPlay: auto-close CSV file when stopping play (no more locked files)
- Python script updated to match new deceleration-based algorithm

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 18:25:54 +01:00
fa257fb87b Add adaptive extrapolation mode, quadratic regression, CSV analysis tool
Anti-recoil prediction improvements:
- New ARM_AdaptiveExtrapolation mode: velocity variance-based confidence
  with separate pos/aim tracking and low-speed protection
- New ARM_WeightedLinearRegression mode: preserves original simple linear fit
- ARM_WeightedRegression upgraded to quadratic (y=a+bt+ct²) with
  linear/quadratic blend and velocity-reversal clamping
- ExtrapolationDamping parameter (all modes): exp decay on extrapolated velocity
- CSV recording (RecordPredictionCSV) for offline parameter tuning
- Python analysis tool (Tools/analyze_antirecoil.py) to find optimal
  AdaptiveSensitivity from recorded data

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 15:21:50 +01:00
1b32c1eef1 Rename plugin root directory from EasyBallistics to PS_Ballistics
Only the top-level plugin folder is renamed. Internal module name
and .uplugin file remain unchanged (EasyBallistics).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 20:18:20 +01:00
ed901a90d5 Add comprehensive tooltips to all UPROPERTY declarations
Adds detailed tooltips (units, ranges, behavior, examples) to 82 UPROPERTY
across EBBullet.h (42), EBBarrel.h (25), and EBMaterialResponseMap.h (15).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 20:17:37 +01:00
c6fd71dc0b BP 2026-03-13 19:47:44 +01:00
eeb039c24a Update anti-recoil default values from calibration testing
Set Kalman Filter as default mode with tuned parameters:
BufferTime=0.15, DiscardTime=0.03, KalmanProcessNoise=200,
KalmanMeasurementNoise=0.01, RegressionWeightExponent=3.0,
DebugAntiRecoilLineThickness=0.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 19:45:03 +01:00
669b65a30f Fix retrace OwnerSafe bug and restore debug trace colors
Save and restore OwnerSafe state during retrace to prevent the bullet
from hitting the owner's actors when replaying a previous trace where
OwnerSafe was true. Also fix debug DrawDebugLine in Trace.cpp to use
proper velocity-based colors instead of hardcoded values.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 19:32:43 +01:00
9b9c5254db no message 2026-03-13 18:13:41 +01:00
72dfc39771 Add anti-recoil prediction system with 3 algorithms + debug visualization
- Add EAntiRecoilMode enum: Disabled, Buffer, Linear Extrapolation,
  Weighted Regression (default), Kalman Filter
- Replace frame-based buffer with time-based FTimestampedTransform history
- Add AntiRecoilBufferTime/DiscardTime for time-based sample management
- Implement 3 prediction methods in new AntiRecoilPredict.cpp:
  linear extrapolation, weighted least-squares regression, simplified Kalman
- Add RegressionWeightExponent parameter to control weight curve shape
- Add debug visualization: green (raw tracker), red (predicted aim),
  yellow (uncorrected aim persisting 3s after IMU shock)
- Add IMU shock simulation for testing without physical firing
- Fix shotTrace DrawDebugLine: correct endpoint and color

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 17:55:50 +01:00
9c4061da5b Initial Commit 2026-03-13 15:35:51 +01:00