diff --git a/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.dll b/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.dll index daf5768..8c1be77 100644 Binary files a/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.dll and b/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.dll differ diff --git a/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.pdb b/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.pdb index 771e148..aa4c77a 100644 Binary files a/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.pdb and b/Unreal/Plugins/EasyBallistics/Binaries/Win64/UnrealEditor-EasyBallistics.pdb differ diff --git a/Unreal/Plugins/EasyBallistics/Source/EasyBallistics/Public/EBBarrel.h b/Unreal/Plugins/EasyBallistics/Source/EasyBallistics/Public/EBBarrel.h index 89ff846..2668965 100644 --- a/Unreal/Plugins/EasyBallistics/Source/EasyBallistics/Public/EBBarrel.h +++ b/Unreal/Plugins/EasyBallistics/Source/EasyBallistics/Public/EBBarrel.h @@ -64,7 +64,7 @@ public: UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Debug", meta = (ToolTip = "Length of the debug aim lines (cm)", EditCondition = "DebugAntiRecoil")) float DebugAntiRecoilLineLength = 200.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Debug", meta = (ToolTip = "Thickness of the debug aim lines", EditCondition = "DebugAntiRecoil")) - float DebugAntiRecoilLineThickness = 2.0f; + float DebugAntiRecoilLineThickness = 0.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Debug|IMU Shock Simulation", meta = (ToolTip = "Enable IMU shock simulation for testing anti-recoil prediction without firing")) bool DebugSimulateIMUShock = false; @@ -78,22 +78,22 @@ public: float DebugIMUShockDisplayTime = 3.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Selects the anti-recoil compensation algorithm. Hover over each option in the dropdown for a detailed description of how it works.")) - EAntiRecoilMode AntiRecoilMode = EAntiRecoilMode::ARM_WeightedRegression; + EAntiRecoilMode AntiRecoilMode = EAntiRecoilMode::ARM_KalmanFilter; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Total time window (seconds) of tracker history to keep. Determines how far back in time samples are stored. Must be greater than DiscardTime. Example: 0.2s at 60fps stores ~12 samples.", ClampMin = "0.05")) - float AntiRecoilBufferTime = 0.2f; + float AntiRecoilBufferTime = 0.15f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Time window (seconds) of most recent samples to exclude as potentially contaminated by IMU recoil shock. The prediction algorithms only use samples older than this. Increase if the shock lasts longer. Safe window = BufferTime - DiscardTime.", ClampMin = "0.0")) - float AntiRecoilDiscardTime = 0.05f; + float AntiRecoilDiscardTime = 0.03f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Controls how the weight curve grows across safe samples in Weighted Regression mode. 1.0 = linear growth (default), >1.0 = recent samples weighted much more heavily (convex curve), <1.0 = more uniform weighting (concave curve), 0.0 = all samples weighted equally (unweighted regression). Formula: weight = pow(sampleIndex+1, exponent).", EditCondition = "AntiRecoilMode == EAntiRecoilMode::ARM_WeightedRegression", ClampMin = "0.0", ClampMax = "5.0")) - float RegressionWeightExponent = 1.0f; + float RegressionWeightExponent = 3.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Kalman filter process noise (higher = more responsive to movement changes, lower = smoother). Since safe samples are already filtered by DiscardTime, this should be high enough to track aiming movements.", EditCondition = "AntiRecoilMode == EAntiRecoilMode::ARM_KalmanFilter", ClampMin = "0.01")) - float KalmanProcessNoise = 50.0f; + float KalmanProcessNoise = 200.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "AntiRecoil", meta = (ToolTip = "Kalman filter measurement noise (higher = trusts model over measurements, lower = trusts measurements). Should be low since safe samples are clean.", EditCondition = "AntiRecoilMode == EAntiRecoilMode::ARM_KalmanFilter", ClampMin = "0.001")) - float KalmanMeasurementNoise = 0.1f; + float KalmanMeasurementNoise = 0.01f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Velocity", meta = (ToolTip = "Bullet inherits barrel velocity, only works with physics enabled or with additional velocity set")) float InheritVelocity = 1.0f; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Velocity", meta = (ToolTip = "Amount of recoil applied to the barrel, only works with physics enabled")) float RecoilMultiplier = 1.0f;