mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
use event system, polish translation
This commit is contained in:
parent
374b015ee4
commit
5f0a2b1945
@ -124,7 +124,4 @@ class CfgVehicles {
|
||||
GVAR(dragPosition[]) = {0,1.2,0};
|
||||
GVAR(dragDirection) = 180;
|
||||
};
|
||||
class Land_PortableLight_single_off_F: Land_PortableLight_single_F {};
|
||||
class Land_PortableLight_double_F: Land_PortableLight_single_F {};
|
||||
class Land_PortableLight_double_off_F: Land_PortableLight_double_F {};
|
||||
};
|
||||
|
@ -18,6 +18,16 @@ ACE_Modifier = 0;
|
||||
_unit doMove _position;
|
||||
}] call EFUNC(common,addEventHandler);
|
||||
|
||||
["lampTurnOn", {
|
||||
params ["_lamp", "_hitPointsDamage", "_disabledLampDMG"];
|
||||
{if((_x select 1) == _disabledLampDMG) then {_lamp setHit [_x select 0, 0];};nil} count _hitPointsDamage;
|
||||
}] call EFUNC(common,addEventHandler);
|
||||
|
||||
["lampTurnOff", {
|
||||
params ["_lamp", "_hitPointsDamage", "_disabledLampDMG"];
|
||||
{_lamp setHit [_x select 0, (_x select 1) max _disabledLampDMG];nil} count _hitPointsDamage;
|
||||
}] call EFUNC(common,addEventHandler);
|
||||
|
||||
if (!hasInterface) exitWith {};
|
||||
|
||||
GVAR(isOpeningDoor) = false;
|
||||
@ -61,7 +71,7 @@ GVAR(isOpeningDoor) = false;
|
||||
|
||||
//Tap whichever shoulder is closest
|
||||
private _shoulderNum = [0, 1] select (([cursorTarget, ACE_player] call BIS_fnc_relativeDirTo) > 180);
|
||||
|
||||
|
||||
// Statement
|
||||
[ACE_player, cursorTarget, _shoulderNum] call FUNC(tapShoulder);
|
||||
true
|
||||
|
@ -28,11 +28,11 @@ private _hitPointsDamage = [];
|
||||
nil
|
||||
} count _reflectors;
|
||||
|
||||
if(_isOn) then {
|
||||
//turn off this lamp
|
||||
{_lamp sethit [_x select 0, (_x select 1) max DISABLED_LAMP_DMG];nil} count _hitPointsDamage;
|
||||
//if lamp is on turn it off
|
||||
private _eventName = if(_isOn) then {"lampTurnOff"} else {"lampTurnOn"};
|
||||
if(local _lamp) then {
|
||||
[_eventName, [_lamp, _hitPointsDamage, DISABLED_LAMP_DMG]] call EFUNC(common,localEvent);
|
||||
} else {
|
||||
//turn on this lamp
|
||||
{if((_x select 1) == DISABLED_LAMP_DMG) then {_lamp sethit [_x select 0, 0];};nil} count _hitPointsDamage;
|
||||
[_eventName, [_lamp], [_lamp, _hitPointsDamage, DISABLED_LAMP_DMG]] call EFUNC(common,targetEvent);
|
||||
};
|
||||
_lamp setVariable ["ACE_lampOn", !_isOn, true];
|
||||
|
@ -693,9 +693,11 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_TurnOn">
|
||||
<English>Turn on</English>
|
||||
<Polish>Włącz</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_TurnOff">
|
||||
<English>Turn off</English>
|
||||
<Polish>Wyłącz</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_PassMagazine">
|
||||
<English>Pass magazine</English>
|
||||
|
Loading…
Reference in New Issue
Block a user