mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Inlined PFHs in Switchunits
This commit is contained in:
parent
2b56b919db
commit
9c29ff0c57
@ -20,7 +20,7 @@ params ["_sidesToShow"];
|
||||
|
||||
GVAR(AllMarkerNames) = [];
|
||||
|
||||
_fnc_pfhMarkAiOnMap = {
|
||||
[{
|
||||
params ["_args"];
|
||||
_args params ["_sides"];
|
||||
|
||||
@ -63,6 +63,4 @@ _fnc_pfhMarkAiOnMap = {
|
||||
};
|
||||
} count allUnits;
|
||||
};
|
||||
};
|
||||
|
||||
[_fnc_pfhMarkAiOnMap, 1.5, [_sidesToShow]] call CBA_fnc_addPerFrameHandler;
|
||||
}, 1.5, [_sidesToShow]] call CBA_fnc_addPerFrameHandler;
|
||||
|
@ -20,7 +20,7 @@ params ["_originalPlayerUnit"];
|
||||
|
||||
[_originalPlayerUnit] joinSilent GVAR(OriginalGroup);
|
||||
|
||||
_fnc_pfhSwitchBack = {
|
||||
[{
|
||||
params ["_args", "_pfhId"];
|
||||
_args params ["_originalPlayerUnit", "_currentUnit"];
|
||||
|
||||
@ -34,6 +34,4 @@ _fnc_pfhSwitchBack = {
|
||||
|
||||
[_pfhId] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
};
|
||||
|
||||
[_fnc_pfhSwitchBack, 0.2, _this] call CBA_fnc_addPerFrameHandler;
|
||||
}, 0.2, _this] call CBA_fnc_addPerFrameHandler;
|
||||
|
@ -15,7 +15,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_nearestEnemyPlayers", "_allNearestPlayers", "_oldUnit", "_leave", "_fnc_pfhSwitchUnit"];
|
||||
private ["_nearestEnemyPlayers", "_allNearestPlayers", "_oldUnit", "_leave"];
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
@ -44,7 +44,7 @@ if (_leave) exitWith {
|
||||
//[_unit] joinSilent group player;
|
||||
[[_unit, player], QUOTE({(_this select 0) setVariable [ARR_3(QUOTE(QGVAR(OriginalOwner)), owner (_this select 0), true)]; (_this select 0) setOwner owner (_this select 1)}), 1] call EFUNC(common,execRemoteFnc);
|
||||
|
||||
_fnc_pfhSwitchUnit = {
|
||||
[{
|
||||
private ["_respawnEhId", "_oldOwner"];
|
||||
params ["_args", "_pfhId"];
|
||||
_args params ["_unit", "_oldUnit"];
|
||||
@ -78,6 +78,4 @@ _fnc_pfhSwitchUnit = {
|
||||
|
||||
[_pfhId] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
};
|
||||
|
||||
[_fnc_pfhSwitchUnit, 0.2, [_unit, player]] call CBA_fnc_addPerFrameHandler;
|
||||
}, 0.2, [_unit, player]] call CBA_fnc_addPerFrameHandler;
|
||||
|
Loading…
Reference in New Issue
Block a user