mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Added fastrope keybind (#5606)
* Add fastrope keybind * Add canInteractWith checks * Fix player -> ACE_player
This commit is contained in:
parent
750382ff67
commit
c211cbf82b
@ -8,7 +8,21 @@
|
||||
[FUNC(fastRopeServerPFH), 0, _this] call CBA_fnc_addPerFrameHandler;
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
|
||||
// Keybinds
|
||||
["ACE3 Vehicles", QGVAR(fastRope), localize LSTRING(Interaction_fastRope), {
|
||||
if ((vehicle ACE_player) == ACE_player) exitWith {false};
|
||||
if (!([ACE_player, vehicle ACE_player, []] call EFUNC(common,canInteractWith))) exitWith {false};
|
||||
if ([ACE_player, vehicle ACE_player] call FUNC(canFastRope)) then {
|
||||
[ACE_player, vehicle ACE_player] call FUNC(fastRope);
|
||||
true
|
||||
} else {
|
||||
false
|
||||
};
|
||||
}, ""] call CBA_fnc_addKeybind;
|
||||
|
||||
["ACE3 Vehicles", QGVAR(cutRopes), localize LSTRING(Interaction_cutRopes), {
|
||||
if ((vehicle ACE_player) == ACE_player) exitWith {false};
|
||||
if (!([ACE_player, vehicle ACE_player, []] call EFUNC(common,canInteractWith))) exitWith {false};
|
||||
if ([vehicle ACE_player] call FUNC(canCutRopes)) then {
|
||||
[vehicle ACE_player] call FUNC(cutRopes);
|
||||
true
|
||||
@ -18,7 +32,6 @@
|
||||
}, {false}] call CBA_fnc_addKeybind;
|
||||
|
||||
|
||||
|
||||
#ifdef DRAW_FASTROPE_INFO
|
||||
addMissionEventHandler ["Draw3D", {
|
||||
if (!(cursorObject isKindOf "Helicopter")) exitWith {};
|
||||
|
Loading…
Reference in New Issue
Block a user