Add debug info

This commit is contained in:
Brandon Danyluk 2021-03-18 23:43:07 -06:00
parent 51542f9053
commit 2fd4f70c5b

View File

@ -107,7 +107,14 @@ if ((_minDeflection != 0 || {_maxDeflection != 0}) && {_profileAdjustedTargetPos
_acceleration set [_forEachIndex, _pidSum]; _acceleration set [_forEachIndex, _pidSum];
} forEach _acceleration; } forEach _acceleration;
if (accTime > 0) then { #ifdef DRAW_GUIDANCE_INFO
TRACE_1("",_acceleration);
private _projectilePosAGL = ASLToAGL _projectilePos;
private _debugAcceleration = [_acceleration#0, 0, _acceleration#1];
drawLine3D [_projectilePosAGL, _projectilePosAGL vectorAdd ((_projectile vectorModelToWorldVisual _debugAcceleration) vectorMultiply 5), [1, 0, 0, 1]];
#endif
if (!isGamePaused && accTime > 0) then {
_acceleration params ["_pitchChange", "_yawChange"]; _acceleration params ["_pitchChange", "_yawChange"];
private _clampedPitch = (-_pitchChange min _pitchDegreesPerSecond) max -_pitchDegreesPerSecond; private _clampedPitch = (-_pitchChange min _pitchDegreesPerSecond) max -_pitchDegreesPerSecond;