Disable debug in parachute

This commit is contained in:
PabstMirror 2015-10-24 19:07:23 -05:00
parent b5539db27f
commit fefe24b7eb
2 changed files with 3 additions and 6 deletions

View File

@ -15,9 +15,7 @@
*/
#include "script_component.hpp"
private ["_unit"];
_unit = _this select 0;
params ["_unit"];
(["ACE_Altimeter"] call BIS_fnc_rscLayer) cutRsc ["ACE_Altimeter", "PLAIN", 0, true];
if (isNull (uiNamespace getVariable ["ACE_Altimeter", displayNull])) exitWith {};
@ -27,7 +25,7 @@ GVAR(AltimeterActive) = true;
[{
if (!GVAR(AltimeterActive)) exitWith {[_this select 1] call CALLSTACK(cba_fnc_removePerFrameEventHandler)};
disableSerialization;
EXPLODE_4_PVT(_this select 0,_display,_unit,_oldHeight,_prevTime);
(_this select 0) params ["_display", "_unit", "_oldHeight", "_prevTime"];
if !("ACE_Altimeter" in assignedItems _unit) exitWith {[_this select 1] call CALLSTACK(cba_fnc_removePerFrameEventHandler); call FUNC(hideAltimeter)};
private ["_height", "_hour", "_minute", "_descentRate","_HeightText", "_DecendRate", "_TimeText", "_curTime", "_timeDiff"];
@ -38,7 +36,7 @@ GVAR(AltimeterActive) = true;
_hour = floor daytime;
_minute = floor ((daytime - _hour) * 60);
_height = (getPosASL _unit) select 2;
_height = ((getPosASL _unit) select 2) + EGVAR(common,mapAltitude);
_curTime = ACE_time;
_timeDiff = _curTime - _prevTime;
_descentRate = if(_timeDiff > 0) then {floor((_oldHeight - _height) / _timeDiff)} else {0};

View File

@ -1,4 +1,3 @@
#define DEBUG_ENABLED_PARACHUTE
#define COMPONENT parachute
#include "\z\ace\addons\main\script_mod.hpp"