mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
change remaining ace events to CBA 'addPlayerEventHandler'
This commit is contained in:
parent
047ac8c3f2
commit
08886f413c
@ -284,7 +284,7 @@ enableCamShake true;
|
|||||||
//////////////////////////////////////////////////
|
//////////////////////////////////////////////////
|
||||||
|
|
||||||
// Set the name for the current player
|
// Set the name for the current player
|
||||||
["ace_playerChanged", {
|
["unit", {
|
||||||
params ["_newPlayer","_oldPlayer"];
|
params ["_newPlayer","_oldPlayer"];
|
||||||
|
|
||||||
if (alive _newPlayer) then {
|
if (alive _newPlayer) then {
|
||||||
@ -294,7 +294,7 @@ enableCamShake true;
|
|||||||
if (alive _oldPlayer) then {
|
if (alive _oldPlayer) then {
|
||||||
[_oldPlayer] call FUNC(setName);
|
[_oldPlayer] call FUNC(setName);
|
||||||
};
|
};
|
||||||
}] call CBA_fnc_addEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////
|
//////////////////////////////////////////////////
|
||||||
@ -328,20 +328,19 @@ enableCamShake true;
|
|||||||
}] call CBA_fnc_addPlayerEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
// "playerVisionModeChanged" event
|
// "playerVisionModeChanged" event
|
||||||
["visionmode", {
|
["visionMode", {
|
||||||
["ace_playerVisionModeChanged", _this] call CBA_fnc_localEvent;
|
["ace_playerVisionModeChanged", _this] call CBA_fnc_localEvent;
|
||||||
}] call CBA_fnc_addPlayerEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
// "cameraViewChanged" event
|
// "cameraViewChanged" event
|
||||||
["cameraview", {
|
["cameraView", {
|
||||||
["ace_cameraViewChanged", _this] call CBA_fnc_localEvent;
|
["ace_cameraViewChanged", _this] call CBA_fnc_localEvent;
|
||||||
}] call CBA_fnc_addPlayerEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
["visiblemap", {
|
["visibleMap", {
|
||||||
["ace_visibleMapChanged", _this] call CBA_fnc_localEvent;
|
["ace_visibleMapChanged", _this] call CBA_fnc_localEvent;
|
||||||
}] call CBA_fnc_addPlayerEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
|
|
||||||
GVAR(OldIsCamera) = false;
|
GVAR(OldIsCamera) = false;
|
||||||
|
|
||||||
[{
|
[{
|
||||||
|
@ -108,7 +108,7 @@ call FUNC(determineZoom);
|
|||||||
}] call CBA_fnc_addPlayerEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
|
||||||
if (GVAR(mapGlow)) then {
|
if (GVAR(mapGlow)) then {
|
||||||
["ace_visibleMapChanged", {
|
["visibleMap", {
|
||||||
params ["_player", "_mapOn"];
|
params ["_player", "_mapOn"];
|
||||||
if (_mapOn) then {
|
if (_mapOn) then {
|
||||||
if (!alive _player && !isNull GVAR(glow)) then {
|
if (!alive _player && !isNull GVAR(glow)) then {
|
||||||
@ -128,7 +128,7 @@ call FUNC(determineZoom);
|
|||||||
[""] call FUNC(flashlightGlow);
|
[""] call FUNC(flashlightGlow);
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}] call CBA_fnc_addEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}] call CBA_fnc_addEventHandler;
|
}] call CBA_fnc_addEventHandler;
|
||||||
|
@ -22,7 +22,7 @@ GVAR(mapTool_isRotating) = false;
|
|||||||
((findDisplay 12) displayCtrl 51) ctrlAddEventHandler ["Draw", {_this call FUNC(updateMapToolMarkers);}];
|
((findDisplay 12) displayCtrl 51) ctrlAddEventHandler ["Draw", {_this call FUNC(updateMapToolMarkers);}];
|
||||||
}, []] call CBA_fnc_waitUntilAndExecute;
|
}, []] call CBA_fnc_waitUntilAndExecute;
|
||||||
|
|
||||||
["ace_visibleMapChanged", {
|
["visibleMap", {
|
||||||
params ["", "_mapOn"];
|
params ["", "_mapOn"];
|
||||||
if (_mapOn) then {
|
if (_mapOn) then {
|
||||||
// Show GPS if required
|
// Show GPS if required
|
||||||
@ -31,4 +31,4 @@ GVAR(mapTool_isRotating) = false;
|
|||||||
// Hide GPS
|
// Hide GPS
|
||||||
[false] call FUNC(openMapGps);
|
[false] call FUNC(openMapGps);
|
||||||
};
|
};
|
||||||
}] call CBA_fnc_addEventHandler;
|
}] call CBA_fnc_addPlayerEventHandler;
|
||||||
|
Loading…
Reference in New Issue
Block a user