Skip to content

Commit

Permalink
Disable debug in parachute
Browse files Browse the repository at this point in the history
  • Loading branch information
PabstMirror committed Oct 25, 2015
1 parent b5539db commit fefe24b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
8 changes: 3 additions & 5 deletions addons/parachute/functions/fnc_showAltimeter.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -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 {};
Expand All @@ -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"];
Expand All @@ -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};
Expand Down
1 change: 0 additions & 1 deletion addons/parachute/script_component.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#define DEBUG_ENABLED_PARACHUTE
#define COMPONENT parachute
#include "\z\ace\addons\main\script_mod.hpp"

Expand Down

1 comment on commit fefe24b

@bux
Copy link
Member

@bux bux commented on fefe24b Oct 25, 2015

Choose a reason for hiding this comment

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

👍

Please sign in to comment.