Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Advanced Ballistics - Trajectory refinement #5698

Merged
merged 7 commits into from
Nov 10, 2017
Merged

Conversation

ulteq
Copy link
Contributor

@ulteq ulteq commented Oct 28, 2017

More advanced drag update routine:

  • Handles greater simulationIntervals much better:
  • simulationInterval=0.00 -> Error (at 2km): 0.004 MILs
  • simulationInterval=0.05 -> Error (at 2km): 0.030 MILs
  • simulationInterval=0.10 -> Error (at 2km): 0.070 MILs
  • Almost completely FPS invariant

Also:

  • Disables BC degradation in the transonic zone (does not do justice to reality)
  • Corrects the gravity constant (9.80665 -> 9.8066) in all modules
  • Improves the random seed generator (used in the transonic flight calculations)
  • Improves accuracy of the zero angle calculation (at greater zero distances)
  • Recompile DLLs

@ulteq ulteq added kind/enhancement Release Notes: **IMPROVED:** status/WIP labels Oct 28, 2017
trueVelocity[2] = bulletDatabase[index].bulletVelocity[2] - wind[2];
trueSpeed = sqrt(pow(trueVelocity[0], 2) + pow(trueVelocity[1], 2) + pow(trueVelocity[2], 2));
std::vector<double> bulletVelocity = bulletDatabase[index].bulletVelocity;
double time = 0.0f;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

double with float assignment

ballisticCoefficient = bulletDatabase[index].ballisticCoefficients[i + 1];
break;
bulletVelocity = bulletDatabase[index].bulletVelocity;
time = 0.0f;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above

@ulteq ulteq force-pushed the ab-trajectory-refinement branch from 1ef2618 to 9929fb4 Compare October 28, 2017 19:32
@ulteq ulteq removed the status/WIP label Oct 28, 2017
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from 9929fb4 to 3d1e9db Compare October 29, 2017 09:32
@ulteq ulteq force-pushed the ab-vanilla-drag-removal-fix branch from e421afc to 0a3b51e Compare October 29, 2017 09:32
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from 3d1e9db to bfbfff4 Compare October 29, 2017 09:44
@ulteq ulteq force-pushed the ab-vanilla-drag-removal-fix branch from 0a3b51e to 048b076 Compare October 30, 2017 09:08
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from 454bc5b to d8d3575 Compare October 30, 2017 09:08
@ulteq ulteq changed the base branch from ab-vanilla-drag-removal-fix to master November 3, 2017 21:25
@ulteq ulteq added this to the 3.12.0 milestone Nov 3, 2017
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from d8d3575 to aae8a68 Compare November 4, 2017 08:53
@@ -112,7 +112,9 @@ if (_caliber > 0 && _bulletLength > 0 && _bulletMass > 0 && _barrelTwist > 0) th

GVAR(currentbulletID) = (GVAR(currentbulletID) + 1) % 10000;

"ace_advanced_ballistics" callExtension format["new:%1:%2:%3:%4:%5:%6:%7:%8:%9:%10:%11:%12:%13:%14:%15:%16:%17", GVAR(currentbulletID), _airFriction, _ballisticCoefficients, _velocityBoundaries, _atmosphereModel, _dragModel, _stabilityFactor, _twistDirection, _transonicStabilityCoef, getPosASL _projectile, _bulletVelocity, EGVAR(common,mapLatitude), EGVAR(weather,currentTemperature), EGVAR(common,mapAltitude), EGVAR(weather,currentHumidity), EGVAR(weather,currentOvercast), CBA_missionTime toFixed 6];
private _ammoCount = _unit ammo (primaryWeapon _unit);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think AB runs for pistol shots (and maybe spotting rounds?),
unit may not have a rifle
should be able to use _weapon or _muzzle from fired EH

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I should have used _muzzle. I will change it.

ulteq added 4 commits November 8, 2017 15:15
* Handles greater 'simulationIntervals' much better:
* 'simulationInterval=0.00' -> Error (at 2km): 0.004 MILs
* 'simulationInterval=0.05' -> Error (at 2km): 0.030 MILs
* 'simulationInterval=0.10' -> Error (at 2km): 0.070 MILs
* Almost completely FPS invariant
* ArmA is using 9.8066
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from aae8a68 to 6a3a0ea Compare November 8, 2017 14:26
@ulteq ulteq force-pushed the ab-trajectory-refinement branch from 6a3a0ea to d43c88a Compare November 10, 2017 16:25
@ulteq ulteq merged commit 9d69961 into master Nov 10, 2017
@ulteq ulteq deleted the ab-trajectory-refinement branch November 10, 2017 16:29
BaerMitUmlaut pushed a commit that referenced this pull request Aug 5, 2019
Advanced Ballistics - Trajectory refinement
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Release Notes: **IMPROVED:**
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants