Skip to content

Commit

Permalink
Merge pull request #405 from CBATeam/headDir-154-bwc
Browse files Browse the repository at this point in the history
Make fnc_headDir compatible with the 1.54 ports
  • Loading branch information
Killswitch00 committed Jul 3, 2016
2 parents 4b7655c + 7ccd231 commit 011e17c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
4 changes: 4 additions & 0 deletions addons/common/fnc_headDir.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,11 @@ if (_unit != call CBA_fnc_currentUnit) then {
private _diff = -_azimuth;

if !(_offset isEqualTo "") then {
#ifndef LINUX_BUILD
ADD(_diff,_unit getDir ([_offset] call CBA_fnc_getPos));
#else
ADD(_diff,[ARR_2(_unit,[_offset] call CBA_fnc_getPos)] call BIS_fnc_dirTo);
#endif
};
if (_diff < 0) then {
ADD(_diff,360);
Expand Down
2 changes: 2 additions & 0 deletions addons/common/fnc_headDir_Linux.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#define LINUX_BUILD
#include "fnc_headDir.sqf"
5 changes: 5 additions & 0 deletions addons/linux/CfgFunctions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ class CfgFunctions {
};
};
class CBA {

class Anims {
F_FILEPATH(common,headDir);
};

class Entities {
F_FILEPATH(common,getAlive);
F_FILEPATH(common,getMagazineIndex);
Expand Down

0 comments on commit 011e17c

Please sign in to comment.