mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Common - Fix disableUserInput blocking respawn (#9053)
This commit is contained in:
parent
8d2d49202d
commit
b4005bca43
@ -107,11 +107,24 @@ if (_state) then {
|
||||
};
|
||||
|
||||
GVAR(disableInputPFH) = [{
|
||||
if (isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) && {!visibleMap && {isNull findDisplay IDD_INTERRUPT} && {isNull findDisplay IDD_RSCDISPLAYCURATOR} && {isNull findDisplay IDD_TEAMSWITCH}}) then {
|
||||
if (isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) && {!visibleMap && {isNull findDisplay IDD_INTERRUPT} && {isNull findDisplay IDD_RSCDISPLAYCURATOR} && {isNull findDisplay IDD_TEAMSWITCH}}) exitWith {
|
||||
[GVAR(disableInputPFH)] call CBA_fnc_removePerFrameHandler;
|
||||
GVAR(disableInputPFH) = nil;
|
||||
[true] call FUNC(disableUserInput);
|
||||
};
|
||||
|
||||
// Allow user input if the player is respawning and a respawn template (menu position or spectator)
|
||||
// is open (otherwise they cannot click the respawn button)
|
||||
if (
|
||||
!alive player
|
||||
&& {playerRespawnTime != -1}
|
||||
&& {
|
||||
missionNamespace getVariable ["BIS_RscRespawnControlsMap_shown", false]
|
||||
|| {missionNamespace getVariable ["BIS_RscRespawnControlsSpectate_shown", false]}
|
||||
}
|
||||
) exitWith {
|
||||
[false] call FUNC(disableUserInput);
|
||||
};
|
||||
}, 0, []] call CBA_fnc_addPerFrameHandler;
|
||||
} else {
|
||||
if (!isNil QGVAR(disableInputPFH)) then {
|
||||
|
Loading…
Reference in New Issue
Block a user