mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge branch 'master' into add-category-optionsmenu
Conflicts: addons/optionsmenu/functions/fnc_serverSettingsMenuUpdateList.sqf addons/optionsmenu/functions/fnc_settingsMenuUpdateList.sqf
This commit is contained in:
commit
c6be0bbb8c
@ -107,3 +107,4 @@ VyMajoris(W-Cephei)<vycanismajoriscsa@gmail.com>
|
||||
Winter <simon@agius-muscat.net>
|
||||
zGuba
|
||||
Drill <drill87@gmail.com>
|
||||
MikeMatrix <m.braun92@gmail.com>
|
||||
|
@ -31,7 +31,7 @@ _actions = [];
|
||||
if (getText (_item >> "ACE_Attachable") != "") then {
|
||||
_displayName = getText(_item >> "displayName");
|
||||
_picture = getText(_item >> "picture");
|
||||
_action = [_x, _displayName, _picture, {_this call FUNC(attach)}, {_this call FUNC(canAttach)}, {}, [_x]] call EFUNC(interact_menu,createAction);
|
||||
_action = [_x, _displayName, _picture, {[{_this call FUNC(attach)}, _this] call EFUNC(common,execNextFrame)}, {_this call FUNC(canAttach)}, {}, [_x]] call EFUNC(interact_menu,createAction);
|
||||
_actions pushBack [_action, [], _target];
|
||||
};
|
||||
};
|
||||
@ -44,7 +44,7 @@ _actions = [];
|
||||
if (getText (_item >> "ACE_Attachable") != "") then {
|
||||
_displayName = getText(_item >> "displayName");
|
||||
_picture = getText(_item >> "picture");
|
||||
_action = [_x, _displayName, _picture, {_this call FUNC(attach)}, {_this call FUNC(canAttach)}, {}, [_x]] call EFUNC(interact_menu,createAction);
|
||||
_action = [_x, _displayName, _picture, {[{_this call FUNC(attach)}, _this] call EFUNC(common,execNextFrame)}, {_this call FUNC(canAttach)}, {}, [_x]] call EFUNC(interact_menu,createAction);
|
||||
_actions pushBack [_action, [], _target];
|
||||
};
|
||||
};
|
||||
|
@ -1,9 +1,9 @@
|
||||
// by commy2
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_wall", "_paper"];
|
||||
private "_paper";
|
||||
|
||||
_wall = _this select 0;
|
||||
params ["_wall"];
|
||||
|
||||
if (local _wall) then {
|
||||
_paper = "UserTexture_1x2_F" createVehicle position _wall;
|
||||
|
@ -341,6 +341,14 @@ if(isMultiplayer && { ACE_time > 0 || isNull player } ) then {
|
||||
GVAR(deviceKeyHandlingArray) = [];
|
||||
GVAR(deviceKeyCurrentIndex) = -1;
|
||||
|
||||
// Register localizations for the Keybinding categories
|
||||
["ACE3 Equipment", localize LSTRING(ACEKeybindCategoryEquipment)] call cba_fnc_registerKeybindModPrettyName;
|
||||
["ACE3 Common", localize LSTRING(ACEKeybindCategoryCommon)] call cba_fnc_registerKeybindModPrettyName;
|
||||
["ACE3 Weapons", localize LSTRING(ACEKeybindCategoryWeapons)] call cba_fnc_registerKeybindModPrettyName;
|
||||
["ACE3 Movement", localize LSTRING(ACEKeybindCategoryMovement)] call cba_fnc_registerKeybindModPrettyName;
|
||||
["ACE3 Scope Adjustment", localize LSTRING(ACEKeybindCategoryScopeAdjustment)] call cba_fnc_registerKeybindModPrettyName;
|
||||
["ACE3 Vehicles", localize LSTRING(ACEKeybindCategoryVehicles)] call cba_fnc_registerKeybindModPrettyName;
|
||||
|
||||
["ACE3 Equipment", QGVAR(openDevice), (localize "STR_ACE_Common_toggleHandheldDevice"),
|
||||
{
|
||||
[] call FUNC(deviceKeyFindValidIndex);
|
||||
|
@ -30,14 +30,14 @@ if (_vehicle isKindOf "Ship" ) then {
|
||||
_emptyPos = (getPosASL _vehicle) call EFUNC(common,ASLtoPosition);
|
||||
_emptyPos = [(_emptyPos select 0) + random(5), (_emptyPos select 1) + random(5), _emptyPos select 2 ];
|
||||
} else {
|
||||
if !(speed _vehicle <1 && {isTouchingGround _vehicle}) then {_validVehiclestate = false};
|
||||
if !(speed _vehicle <1 && {(((getPosATL _vehicle) select 2) < 2)}) then {_validVehiclestate = false};
|
||||
TRACE_1("Vehicle Ground Check", isTouchingGround _vehicle);
|
||||
_emptyPos = ((getPosASL _vehicle) call EFUNC(common,ASLtoPosition) findEmptyPosition [0, 13, typeof _unit]);
|
||||
};
|
||||
};
|
||||
|
||||
TRACE_1("getPosASL Vehicle Check", getPosASL _vehicle);
|
||||
if (!_validVehiclestate) exitwith { diag_log format["Unable to unload patient because invalid vehicle state. Either moving or Not close enough on the ground. %1", getPos _vehicle]; false };
|
||||
if (!_validVehiclestate) exitwith { diag_log format["Unable to unload patient because invalid (%1) vehicle state. Either moving or Not close enough on the ground. position: %2 isTouchingGround: %3 Speed: %4", _vehicle, getPos _vehicle, isTouchingGround _vehicle, speed _vehicle]; false };
|
||||
|
||||
diag_log str _emptyPos;
|
||||
|
||||
|
@ -598,5 +598,83 @@
|
||||
<Polish>Następne urządzenie podręczne</Polish>
|
||||
<Czech>Procházet ruční zařízení</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_Disabled">
|
||||
<English>Disabled</English>
|
||||
<Czech>Zakázáno</Czech>
|
||||
<French>Non</French>
|
||||
<German>Deaktiviert</German>
|
||||
<Italian>Disattivato</Italian>
|
||||
<Polish>Wyłączone</Polish>
|
||||
<Portuguese>Desativado</Portuguese>
|
||||
<Russian>Откл.</Russian>
|
||||
<Spanish>Desactivado</Spanish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_Enabled">
|
||||
<English>Enabled</English>
|
||||
<Czech>Zapnuto</Czech>
|
||||
<French>Oui</French>
|
||||
<German>Aktiviert</German>
|
||||
<Italian>Attivato</Italian>
|
||||
<Polish>Włączone</Polish>
|
||||
<Portuguese>Ativado</Portuguese>
|
||||
<Russian>Вкл.</Russian>
|
||||
<Spanish>Activado</Spanish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_Yes">
|
||||
<English>Yes</English>
|
||||
<German>Ja</German>
|
||||
<Spanish>Si</Spanish>
|
||||
<Polish>Tak</Polish>
|
||||
<Czech>Ano</Czech>
|
||||
<French>Oui</French>
|
||||
<Russian>Да</Russian>
|
||||
<Hungarian>Igen</Hungarian>
|
||||
<Portuguese>Sim</Portuguese>
|
||||
<Italian>Si</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_No">
|
||||
<English>No</English>
|
||||
<German>Nein</German>
|
||||
<Spanish>No</Spanish>
|
||||
<Polish>Nie</Polish>
|
||||
<Czech>Ne</Czech>
|
||||
<French>Non</French>
|
||||
<Russian>Нет</Russian>
|
||||
<Hungarian>Nem</Hungarian>
|
||||
<Portuguese>Não</Portuguese>
|
||||
<Italian>No</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_DoNotForce">
|
||||
<English>Do Not Force</English>
|
||||
<Polish>Nie wymuszaj</Polish>
|
||||
<Spanish>No forzar</Spanish>
|
||||
<German>Nicht erzwingen</German>
|
||||
<Czech>Nevynucovat</Czech>
|
||||
<Portuguese>Não forçar</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryEquipment">
|
||||
<English>ACE3 Equipment</English>
|
||||
<Polish>ACE3 Wyposażenie</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryCommon">
|
||||
<English>ACE3 Common</English>
|
||||
<Polish>ACE3 Ogólne</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryWeapons">
|
||||
<English>ACE3 Weapons</English>
|
||||
<Polish>ACE3 Broń</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryMovement">
|
||||
<English>ACE3 Movement</English>
|
||||
<Polish>ACE3 Ruch</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryScopeAdjustment">
|
||||
<English>ACE3 Scope Adjustment</English>
|
||||
<Polish>ACE3 Regulacja optyki</Polish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Common_ACEKeybindCategoryVehicles">
|
||||
<English>ACE3 Vehicles</English>
|
||||
<Polish>ACE3 Pojazdy</Polish>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
|
@ -123,7 +123,8 @@ class CfgVehicles {
|
||||
displayName = "$STR_ACE_ROLLWIRE";
|
||||
distance = 4;
|
||||
condition = "true";
|
||||
statement = QUOTE([ARR_2(_target,_player)] call FUNC(deploy));
|
||||
//wait a frame to handle "Do When releasing action menu key" option:
|
||||
statement = QUOTE([ARR_2({_this call FUNC(deploy)}, [ARR_2(_target,_player)])] call EFUNC(common,execNextFrame));
|
||||
showDisabled = 0;
|
||||
exceptions[] = {};
|
||||
priority = 5;
|
||||
|
@ -37,7 +37,7 @@ deleteVehicle _wirecoil;
|
||||
_unit setVariable [QGVAR(wireDeployed), false];
|
||||
|
||||
GVAR(deployPFH) = [{
|
||||
EXPLODE_4_PVT(_this select 0,_wireNoGeo,_wireNoGeoPos,_unit,_action);
|
||||
EXPLODE_3_PVT(_this select 0,_wireNoGeo,_wireNoGeoPos,_unit);
|
||||
|
||||
private ["_range", "_posStart", "_posEnd", "_dirVect", "_dir", "_anim", "_wire"];
|
||||
_posStart = (_wireNoGeo modelToWorldVisual (_wireNoGeo selectionPosition "start")) call EFUNC(common,positionToASL);
|
||||
@ -73,7 +73,7 @@ GVAR(deployPFH) = [{
|
||||
{
|
||||
_wireNoGeo animate [_x, _anim];
|
||||
} foreach WIRE_FAST;
|
||||
}, 0, [_wireNoGeo, _wireNoGeoPos, _unit, _action]] call CBA_fnc_addPerFrameHandler;
|
||||
}, 0, [_wireNoGeo, _wireNoGeoPos, _unit]] call CBA_fnc_addPerFrameHandler;
|
||||
|
||||
[localize "STR_ACE_ROLLWIRE", "", ""] call EFUNC(interaction,showMouseHint);
|
||||
|
||||
|
@ -2,6 +2,8 @@ class ACE_Settings {
|
||||
class GVAR(EnableCombatDeafness) {
|
||||
value = 1;
|
||||
typeName = "BOOL";
|
||||
displayName = CSTRING(CombatDeafness_DisplayName);
|
||||
description = CSTRING(CombatDeafness_Description);
|
||||
};
|
||||
class GVAR(EarplugsVolume) {
|
||||
value = 0.5;
|
||||
|
@ -109,6 +109,27 @@ class CfgVehicles {
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class DisableEarRinging {
|
||||
displayName = CSTRING(DisableEarRinging);
|
||||
typeName = "NUMBER";
|
||||
class values {
|
||||
class DoNotForce {
|
||||
default = 1;
|
||||
name = ECSTRING(common,DoNotForce);
|
||||
value = -1;
|
||||
};
|
||||
/* Probably don't want to allow forcing ear ringing for people who have serious problems with the effect
|
||||
class NotDisabled {
|
||||
name = ECSTRING(common,No);
|
||||
value = 0;
|
||||
};
|
||||
*/
|
||||
class IsDisabled {
|
||||
name = ECSTRING(common,Yes);
|
||||
value = 1;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
class ModuleDescription {
|
||||
description = CSTRING(Module_Description);
|
||||
|
@ -16,4 +16,9 @@ if !(_activated) exitWith {};
|
||||
|
||||
[_logic, QGVAR(enableCombatDeafness), "EnableCombatDeafness"] call EFUNC(common,readSettingFromModule);
|
||||
|
||||
// Do Not Force - read module setting only non-default is set due to using SCALAR
|
||||
if ((_logic getVariable "DisableEarRinging") != -1) then {
|
||||
[_logic, QGVAR(DisableEarRinging), "DisableEarRinging"] call EFUNC(common,readSettingFromModule);
|
||||
};
|
||||
|
||||
diag_log text "[ACE]: Hearing Module Initialized.";
|
||||
|
@ -126,7 +126,7 @@
|
||||
<Portuguese>Ativar surdez em combate?</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Hearing_CombatDeafness_Description">
|
||||
<English>Enable combat deafness?</English>
|
||||
<English>Reduces the hearing ability as the player takes hearing damage</English>
|
||||
<Polish>Możliwość chwilowej utraty słuchu przy głośnych wystrzałach i jednoczesnym braku włożonych stoperów</Polish>
|
||||
<Spanish>Habilita la sordera de combate</Spanish>
|
||||
<German>Aktiviere Taubheit im Gefecht?</German>
|
||||
@ -134,7 +134,7 @@
|
||||
<Portuguese>Ativar surdez em combate?</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Hearing_Module_Description">
|
||||
<English></English>
|
||||
<English>Controls combat deafness and ear ringing. When activated, players can be deafened when a gun is fired in their vicinity or an explosion takes place without hearing protection</English>
|
||||
<Polish>Głuchota bojowa pojawia się w momentach, kiedy stoimy w pobliżu broni wielkokalibrowej bez ochrony słuchu, lub np. podczas ostrzału artyleryjskiego. Moduł ten pozwala na włączenie lub wyłączenie tego efektu.</Polish>
|
||||
<German>Dieses Modul aktiviert/deaktiviert die Taubheit im Gefecht. Wenn aktiviert, können Spieler ohne Gehörschutz taub werden, wenn eine Waffe in ihrer Nähe abgefeuert wird oder eine Explosion stattfindet.</German>
|
||||
<Czech>Ztráta sluchu je možná ve chvíly, kdy se v bezprostřední blízkosti střílí z velkorážní zbraně nebo při bombardování a osoba je bez ochrany sluchu (např. špunty). Tento modul umožňuje tuto věc povolit nebo zakázat.</Czech>
|
||||
|
@ -91,7 +91,7 @@ class CfgVehicles {
|
||||
|
||||
class ACE_JoinGroup {
|
||||
displayName = CSTRING(JoinGroup);
|
||||
condition = QUOTE([ARR_2(_player,_target)] call DFUNC(canJoinGroup));
|
||||
condition = QUOTE(GVAR(EnableTeamManagement) && {[ARR_2(_player,_target)] call DFUNC(canJoinGroup)});
|
||||
statement = QUOTE([_player] joinSilent group _target);
|
||||
showDisabled = 0;
|
||||
priority = 2.6;
|
||||
@ -351,7 +351,7 @@ class CfgVehicles {
|
||||
hotkey = "7";
|
||||
};
|
||||
class ACE_Gesture_Yes {
|
||||
displayName = CSTRING(Gestures_Yes);
|
||||
displayName = ECSTRING(common,Yes);
|
||||
condition = QUOTE(canStand _target);
|
||||
statement = QUOTE(_target playActionNow ([ARR_2('gestureYes','gestureNod')] select floor random 2););
|
||||
showDisabled = 1;
|
||||
@ -359,7 +359,7 @@ class CfgVehicles {
|
||||
hotkey = "8";
|
||||
};
|
||||
class ACE_Gesture_No {
|
||||
displayName = CSTRING(Gestures_No);
|
||||
displayName = ECSTRING(common,No);
|
||||
condition = QUOTE(canStand _target);
|
||||
statement = QUOTE(_target playActionNow 'gestureNo';);
|
||||
showDisabled = 1;
|
||||
|
@ -385,30 +385,6 @@
|
||||
<Portuguese>Olá</Portuguese>
|
||||
<Italian>Ciao</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_Gestures_Yes">
|
||||
<English>Yes</English>
|
||||
<German>Ja</German>
|
||||
<Spanish>Si</Spanish>
|
||||
<Polish>Tak</Polish>
|
||||
<Czech>Ano</Czech>
|
||||
<French>Oui</French>
|
||||
<Russian>Да</Russian>
|
||||
<Hungarian>Igen</Hungarian>
|
||||
<Portuguese>Sim</Portuguese>
|
||||
<Italian>Si</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_Gestures_No">
|
||||
<English>No</English>
|
||||
<German>Nein</German>
|
||||
<Spanish>No</Spanish>
|
||||
<Polish>Nie</Polish>
|
||||
<Czech>Ne</Czech>
|
||||
<French>Non</French>
|
||||
<Russian>Нет</Russian>
|
||||
<Hungarian>Nem</Hungarian>
|
||||
<Portuguese>Não</Portuguese>
|
||||
<Italian>No</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Interaction_WeaponOnBack">
|
||||
<English>Put weapon on back</English>
|
||||
<German>Waffe wegstecken</German>
|
||||
|
@ -14,7 +14,13 @@
|
||||
|
||||
visibleMap &&
|
||||
{alive ACE_player} &&
|
||||
{"ItemMap" in (assignedItems ACE_player)} &&
|
||||
{
|
||||
scopeName "hasMap";
|
||||
{
|
||||
if (_x isKindOf ["ItemMap", configFile >> "CfgWeapons"]) exitWith {true breakOut "hasMap"};
|
||||
} forEach (assignedItems ACE_player);
|
||||
false
|
||||
} &&
|
||||
{"ACE_MapTools" in (items ACE_player)} &&
|
||||
{!GVAR(mapTool_isDragging)} &&
|
||||
{!GVAR(mapTool_isRotating)}
|
||||
|
@ -246,6 +246,8 @@ class ACE_Medical_Actions {
|
||||
callbackProgress = "";
|
||||
animationPatient = "";
|
||||
animationCaller = ""; // TODO
|
||||
animationCallerProne = "";
|
||||
animationCallerSelfProne = "";
|
||||
itemConsumed = 0;
|
||||
litter[] = {};
|
||||
};
|
||||
|
@ -92,7 +92,7 @@ class CfgVehicles {
|
||||
typeName = "NUMBER";
|
||||
class values {
|
||||
class disable {
|
||||
name = CSTRING(disabled);
|
||||
name = ECSTRING(common,Disabled);
|
||||
value = 0;
|
||||
};
|
||||
class normal {
|
||||
@ -101,7 +101,7 @@ class CfgVehicles {
|
||||
default = 1;
|
||||
};
|
||||
class full {
|
||||
name = CSTRING(enabled);
|
||||
name = ECSTRING(common,Enabled);
|
||||
value = 2;
|
||||
};
|
||||
};
|
||||
@ -198,8 +198,8 @@ class CfgVehicles {
|
||||
description = CSTRING(AdvancedMedicalSettings_consumeItem_PAK_Description);
|
||||
typeName = "NUMBER";
|
||||
class values {
|
||||
class keep { name = CSTRING(No); value = 0; };
|
||||
class remove { name = CSTRING(Yes); value = 1; default = 1; };
|
||||
class keep { name = ECSTRING(common,No); value = 0; };
|
||||
class remove { name = ECSTRING(common,Yes); value = 1; default = 1; };
|
||||
};
|
||||
};
|
||||
class useCondition_PAK {
|
||||
@ -220,7 +220,7 @@ class CfgVehicles {
|
||||
class vehicle { name = CSTRING(AdvancedMedicalSettings_vehicle); value = 1; };
|
||||
class facility { name = CSTRING(AdvancedMedicalSettings_facility); value = 2; };
|
||||
class vehicleAndFacility { name = CSTRING(AdvancedMedicalSettings_vehicleAndFacility); value = 3; default = 1; };
|
||||
class disabled { name = CSTRING(AdvancedMedicalSettings_disabled); value = 4;};
|
||||
class disabled { name = ECSTRING(common,Disabled); value = 4;};
|
||||
};
|
||||
};
|
||||
class medicSetting_SurgicalKit: medicSetting_PAK {
|
||||
@ -280,7 +280,7 @@ class CfgVehicles {
|
||||
typeName = "NUMBER";
|
||||
defaultValue = 0;
|
||||
class values {
|
||||
class disable { name = CSTRING(disabled); value = 0; default = 1;};
|
||||
class disable { name = ECSTRING(common,Disabled); value = 0; default = 1;};
|
||||
class playerOnly { name = CSTRING(playeronly); value = 1; };
|
||||
class playerAndAI { name = CSTRING(playersandai); value = 2; };
|
||||
};
|
||||
@ -373,11 +373,11 @@ class CfgVehicles {
|
||||
typeName = "NUMBER";
|
||||
class values {
|
||||
class none {
|
||||
name = CSTRING(No);
|
||||
name = ECSTRING(common,No);
|
||||
value = 0;
|
||||
};
|
||||
class medic {
|
||||
name = CSTRING(Yes);
|
||||
name = ECSTRING(common,Yes);
|
||||
value = 1;
|
||||
default = 1;
|
||||
};
|
||||
|
@ -156,7 +156,7 @@ if (_caller == _target) then {
|
||||
_callerAnim = [getText (_config >> "animationCallerSelf"), getText (_config >> "animationCallerSelfProne")] select (stance _caller == "PRONE");
|
||||
};
|
||||
|
||||
_caller setvariable [QGVAR(selectedWeaponOnTreatment), currentWeapon _caller];
|
||||
_caller setvariable [QGVAR(selectedWeaponOnTreatment), (weaponState _caller)];
|
||||
|
||||
// Cannot use secondairy weapon for animation
|
||||
if (currentWeapon _caller == secondaryWeapon _caller) then {
|
||||
|
@ -44,9 +44,14 @@ if (vehicle _caller == _caller) then {
|
||||
};
|
||||
_caller setvariable [QGVAR(treatmentPrevAnimCaller), nil];
|
||||
|
||||
_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]);
|
||||
if (_weaponSelect != "") then {
|
||||
_caller selectWeapon _weaponSelect;
|
||||
_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), []]);
|
||||
if ((_weaponSelect params [["_previousWeapon", ""]]) && {(_previousWeapon != "") && {_previousWeapon in (weapons _caller)}}) then {
|
||||
for "_index" from 0 to 99 do {
|
||||
_caller action ["SwitchWeapon", _caller, _caller, _index];
|
||||
//Just check weapon, muzzle and mode (ignore ammo in case they were reloading)
|
||||
if (((weaponState _caller) select [0,3]) isEqualTo (_weaponSelect select [0,3])) exitWith {TRACE_1("Restoring", (weaponState _caller));};
|
||||
if ((weaponState _caller) isEqualTo ["","","","",0]) exitWith {ERROR("weaponState not found");};
|
||||
};
|
||||
} else {
|
||||
_caller action ["SwitchWeapon", _caller, _caller, 99];
|
||||
};
|
||||
|
@ -42,9 +42,14 @@ if (vehicle _caller == _caller) then {
|
||||
};
|
||||
_caller setvariable [QGVAR(treatmentPrevAnimCaller), nil];
|
||||
|
||||
_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]);
|
||||
if (_weaponSelect != "") then {
|
||||
_caller selectWeapon _weaponSelect;
|
||||
_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), []]);
|
||||
if ((_weaponSelect params [["_previousWeapon", ""]]) && {(_previousWeapon != "") && {_previousWeapon in (weapons _caller)}}) then {
|
||||
for "_index" from 0 to 99 do {
|
||||
_caller action ["SwitchWeapon", _caller, _caller, _index];
|
||||
//Just check weapon, muzzle and mode (ignore ammo in case they were reloading)
|
||||
if (((weaponState _caller) select [0,3]) isEqualTo (_weaponSelect select [0,3])) exitWith {TRACE_1("Restoring", (weaponState _caller));};
|
||||
if ((weaponState _caller) isEqualTo ["","","","",0]) exitWith {ERROR("weaponState not found");};
|
||||
};
|
||||
} else {
|
||||
_caller action ["SwitchWeapon", _caller, _caller, 99];
|
||||
};
|
||||
|
@ -2928,24 +2928,6 @@
|
||||
<Polish>Traktuj jednostki zdalnie sterowane (przez Zeusa) jako AI, nie jako graczy?</Polish>
|
||||
<Czech>Ošetřit vzdáleně ovládané jednotky jako AI, ne jako hráče?</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_disabled">
|
||||
<English>Disabled</English>
|
||||
<Russian>Отключено</Russian>
|
||||
<Polish>Wyłączone</Polish>
|
||||
<Spanish>Desactivado</Spanish>
|
||||
<German>Deaktiviert</German>
|
||||
<Czech>Zakázáno</Czech>
|
||||
<Portuguese>Desativado</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_enabled">
|
||||
<English>Enabled</English>
|
||||
<Russian>Включено</Russian>
|
||||
<Polish>Włączone</Polish>
|
||||
<Spanish>Activado</Spanish>
|
||||
<German>Aktiviert</German>
|
||||
<Czech>Povoleno</Czech>
|
||||
<Portuguese>Ativado</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_preventInstaDeath_DisplayName">
|
||||
<English>Prevent instant death</English>
|
||||
<Russian>Отключить мгновенную смерть</Russian>
|
||||
@ -3237,15 +3219,6 @@
|
||||
<Czech>Vozidla a zařízení</Czech>
|
||||
<Portuguese>Veículos e instalações</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_AdvancedMedicalSettings_disabled">
|
||||
<English>Disabled</English>
|
||||
<Russian>Отключено</Russian>
|
||||
<Polish>Wyłączone</Polish>
|
||||
<Spanish>Desactivado</Spanish>
|
||||
<German>Deaktiviert</German>
|
||||
<Czech>Zakázáno</Czech>
|
||||
<Portuguese>Desativado</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_AdvancedMedicalSettings_medicSetting_SurgicalKit_DisplayName">
|
||||
<English>Allow Surgical kit (Adv)</English>
|
||||
<Russian>Разрешить хирургический набор (усл.)</Russian>
|
||||
@ -3612,30 +3585,6 @@
|
||||
<Czech>[ACE] Zdravotnické zásoby (pokročilé)</Czech>
|
||||
<Portuguese>[ACE] Caixa com suprimentos médicos (Avançados)</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Yes">
|
||||
<English>Yes</English>
|
||||
<German>Ja</German>
|
||||
<Spanish>Si</Spanish>
|
||||
<Polish>Tak</Polish>
|
||||
<Czech>Ano</Czech>
|
||||
<French>Oui</French>
|
||||
<Russian>Да</Russian>
|
||||
<Hungarian>Igen</Hungarian>
|
||||
<Portuguese>Sim</Portuguese>
|
||||
<Italian>Si</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_No">
|
||||
<English>No</English>
|
||||
<German>Nein</German>
|
||||
<Spanish>No</Spanish>
|
||||
<Polish>Nie</Polish>
|
||||
<Czech>Ne</Czech>
|
||||
<French>Non</French>
|
||||
<Russian>Нет</Russian>
|
||||
<Hungarian>Nem</Hungarian>
|
||||
<Portuguese>Não</Portuguese>
|
||||
<Italian>No</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_AnyTime">
|
||||
<English>Anytime</English>
|
||||
<Czech>Kdykoli</Czech>
|
||||
|
@ -11,7 +11,7 @@ class ACE_Settings {
|
||||
isClientSettable = 1;
|
||||
displayName = CSTRING(ShowPlayerNames);
|
||||
description = CSTRING(ShowPlayerNames_Desc);
|
||||
values[] = {CSTRING(Disabled), CSTRING(Enabled), CSTRING(OnlyCursor), CSTRING(OnlyKeypress), CSTRING(OnlyCursorAndKeypress)};
|
||||
values[] = {ECSTRING(common,Disabled), CSTRING(Enabled), CSTRING(OnlyCursor), CSTRING(OnlyKeypress), CSTRING(OnlyCursorAndKeypress)};
|
||||
};
|
||||
class GVAR(showPlayerRanks) {
|
||||
value = 1;
|
||||
@ -42,7 +42,7 @@ class ACE_Settings {
|
||||
isClientSettable = 1;
|
||||
displayName = CSTRING(ShowSoundWaves);
|
||||
description = CSTRING(ShowSoundWaves_Desc);
|
||||
values[] = {CSTRING(Disabled), CSTRING(NameTagSettings), CSTRING(AlwaysShowAll)};
|
||||
values[] = {ECSTRING(common,Disabled), CSTRING(NameTagSettings), CSTRING(AlwaysShowAll)};
|
||||
};
|
||||
class GVAR(playerNamesViewDistance) {
|
||||
value = 5;
|
||||
|
@ -16,7 +16,7 @@ class CfgVehicles {
|
||||
class values {
|
||||
class DoNotForce {
|
||||
default = 1;
|
||||
name = CSTRING(DoNotForce);
|
||||
name = ECSTRING(common,DoNotForce);
|
||||
value = -1;
|
||||
};
|
||||
class ForceHide {
|
||||
@ -54,7 +54,7 @@ class CfgVehicles {
|
||||
class values {
|
||||
class DoNotForce {
|
||||
default = 1;
|
||||
name = CSTRING(DoNotForce);
|
||||
name = ECSTRING(common,DoNotForce);
|
||||
value = -1;
|
||||
};
|
||||
class ForceHide {
|
||||
@ -74,7 +74,7 @@ class CfgVehicles {
|
||||
class values {
|
||||
class DoNotForce {
|
||||
default = 1;
|
||||
name = CSTRING(DoNotForce);
|
||||
name = ECSTRING(common,DoNotForce);
|
||||
value = -1;
|
||||
};
|
||||
class ForceHide {
|
||||
|
@ -149,14 +149,6 @@
|
||||
<Czech>Zobrazit jména a hodnosti pro spřátelené AI jednotky? Výchozí: Nevynucovat</Czech>
|
||||
<Portuguese>Mostra o nome e patente para unidades IA aliadas? Padrão: Não forçar</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_NameTags_DoNotForce">
|
||||
<English>Do Not Force</English>
|
||||
<Polish>Nie wymuszaj</Polish>
|
||||
<Spanish>No forzar</Spanish>
|
||||
<German>Nicht erzwingen</German>
|
||||
<Czech>Nevynucovat</Czech>
|
||||
<Portuguese>Não forçar</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_NameTags_ForceHide">
|
||||
<English>Force Hide</English>
|
||||
<Polish>Wymuś ukrycie</Polish>
|
||||
@ -213,22 +205,6 @@
|
||||
<Czech>Tento modul umožňuje si přizpůsobit nastavení a vzdálenost jmenovky.</Czech>
|
||||
<Portuguese>Este módulo permite que você personalize as configurações e distâncias de etiquetas de nome.</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_NameTags_Disabled">
|
||||
<English>Disabled</English>
|
||||
<Polish>Wyłączone</Polish>
|
||||
<Spanish>Desactivado</Spanish>
|
||||
<German>Deaktiviert</German>
|
||||
<Czech>Zakázáno</Czech>
|
||||
<Portuguese>Desativado</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_NameTags_Enabled">
|
||||
<English>Enabled</English>
|
||||
<Polish>Włączone</Polish>
|
||||
<Spanish>Activado</Spanish>
|
||||
<German>Aktiviert</German>
|
||||
<Czech>Povoleno</Czech>
|
||||
<Portuguese>Ativado</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_NameTags_OnlyCursor">
|
||||
<English>Only on Cursor</English>
|
||||
<Polish>Tylko pod kursorem</Polish>
|
||||
|
@ -64,8 +64,8 @@ if (count _filteredCollection > 0) then {
|
||||
// Created disable/enable options for bools
|
||||
if ((_setting select 1) == "BOOL") then {
|
||||
lbClear 400;
|
||||
lbAdd [400, (localize LSTRING(Disabled))];
|
||||
lbAdd [400, (localize LSTRING(Enabled))];
|
||||
lbAdd [400, (localize ELSTRING(common,No))];
|
||||
lbAdd [400, (localize ELSTRING(common,Yes))];
|
||||
_settingsValue = [0, 1] select _settingsValue;
|
||||
} else {
|
||||
lbClear 400;
|
||||
|
@ -44,7 +44,7 @@ switch (GVAR(optionMenu_openTab)) do {
|
||||
|
||||
// Created disable/enable options for bools
|
||||
_settingsText = if ((_x select 1) == "BOOL") then {
|
||||
[(localize LSTRING(Disabled)), (localize LSTRING(Enabled))] select _settingsValue;
|
||||
[(localize ELSTRING(common,No)), (localize ELSTRING(common,Yes))] select _settingsValue;
|
||||
} else {
|
||||
(_x select 5) select _settingsValue;
|
||||
};
|
||||
|
@ -64,8 +64,8 @@ if (count _filteredCollection > 0) then {
|
||||
// Created disable/enable options for bools
|
||||
if ((_setting select 1) == "BOOL") then {
|
||||
lbClear 400;
|
||||
lbAdd [400, (localize LSTRING(Disabled))];
|
||||
lbAdd [400, (localize LSTRING(Enabled))];
|
||||
lbAdd [400, (localize ELSTRING(common,No))];
|
||||
lbAdd [400, (localize ELSTRING(common,Yes))];
|
||||
_settingsValue = [0, 1] select _settingsValue;
|
||||
} else {
|
||||
lbClear 400;
|
||||
|
@ -36,7 +36,7 @@ switch (GVAR(optionMenu_openTab)) do {
|
||||
|
||||
// Created disable/enable options for bools
|
||||
_settingsText = if ((_x select 1) == "BOOL") then {
|
||||
[(localize LSTRING(Disabled)), (localize LSTRING(Enabled))] select _settingsValue;
|
||||
[(localize ELSTRING(common,No)), (localize ELSTRING(common,Yes))] select _settingsValue;
|
||||
} else {
|
||||
(_x select 5) select _settingsValue;
|
||||
};
|
||||
|
@ -73,30 +73,6 @@
|
||||
<Italian>Valori</Italian>
|
||||
<Portuguese>Valores</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_OptionsMenu_Enabled">
|
||||
<English>Yes</English>
|
||||
<German>Ja</German>
|
||||
<Spanish>Si</Spanish>
|
||||
<Polish>Tak</Polish>
|
||||
<Czech>Ano</Czech>
|
||||
<French>Oui</French>
|
||||
<Russian>Да</Russian>
|
||||
<Hungarian>Igen</Hungarian>
|
||||
<Portuguese>Sim</Portuguese>
|
||||
<Italian>Si</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_OptionsMenu_Disabled">
|
||||
<English>No</English>
|
||||
<German>Nein</German>
|
||||
<Spanish>No</Spanish>
|
||||
<Polish>Nie</Polish>
|
||||
<Czech>Ne</Czech>
|
||||
<French>Non</French>
|
||||
<Russian>Нет</Russian>
|
||||
<Hungarian>Nem</Hungarian>
|
||||
<Portuguese>Não</Portuguese>
|
||||
<Italian>No</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_OptionsMenu_Setting">
|
||||
<English>Setting:</English>
|
||||
<Czech>Nastavení:</Czech>
|
||||
@ -372,4 +348,4 @@
|
||||
<Polish>Wszystkie kategorie</Polish>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
</Project>
|
||||
|
@ -6,7 +6,6 @@ class CfgVehicles {
|
||||
};
|
||||
class TransportBackpacks {
|
||||
MACRO_ADDBACKPACK(ACE_NonSteerableParachute,4);
|
||||
MACRO_ADDBACKPACK(ACE_ReserveParachute,4);
|
||||
};
|
||||
};
|
||||
|
||||
@ -93,7 +92,7 @@ class CfgVehicles {
|
||||
class ACE_ReserveParachute: ACE_NonSteerableParachute {
|
||||
author = ECSTRING(common,ACETeam);
|
||||
displayName = CSTRING(ReserveParachute);
|
||||
scope = 2;
|
||||
scope = 1;
|
||||
mass = 70;
|
||||
ParachuteClass = "NonSteerable_Parachute_F";
|
||||
ace_reserveParachute = "";
|
||||
|
@ -5,7 +5,8 @@ class CfgVehicles {
|
||||
class ACE_Sandbags {
|
||||
displayName = CSTRING(DeploySandbag);
|
||||
condition = QUOTE(call FUNC(canDeploy));
|
||||
statement = QUOTE(call FUNC(deploy));
|
||||
//wait a frame to handle "Do When releasing action menu key" option:
|
||||
statement = QUOTE([ARR_2({_this call FUNC(deploy)}, [])] call EFUNC(common,execNextFrame));
|
||||
exceptions[] = {"isNotSwimming"};
|
||||
showDisabled = 1;
|
||||
priority = 4;
|
||||
|
105
addons/sitting/CfgMoves.hpp
Normal file
105
addons/sitting/CfgMoves.hpp
Normal file
@ -0,0 +1,105 @@
|
||||
// Enable visual head movement while free-looking
|
||||
#define MACRO_ANIMATION \
|
||||
head = "headDefault";
|
||||
|
||||
class CfgMovesBasic;
|
||||
class CfgMovesMaleSdr: CfgMovesBasic {
|
||||
class States {
|
||||
class HubSittingChairA_idle1;
|
||||
class GVAR(HubSittingChairA_idle1): HubSittingChairA_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairA_idle2;
|
||||
class GVAR(HubSittingChairA_idle2): HubSittingChairA_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairA_idle3;
|
||||
class GVAR(HubSittingChairA_idle3): HubSittingChairA_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairA_move1;
|
||||
class GVAR(HubSittingChairA_move1): HubSittingChairA_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairB_idle1;
|
||||
class GVAR(HubSittingChairB_idle1): HubSittingChairB_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairB_idle2;
|
||||
class GVAR(HubSittingChairB_idle2): HubSittingChairB_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairB_idle3;
|
||||
class GVAR(HubSittingChairB_idle3): HubSittingChairB_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairB_move1;
|
||||
class GVAR(HubSittingChairB_move1): HubSittingChairB_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairC_idle1;
|
||||
class GVAR(HubSittingChairC_idle1): HubSittingChairC_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairC_idle2;
|
||||
class GVAR(HubSittingChairC_idle2): HubSittingChairC_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairC_idle3;
|
||||
class GVAR(HubSittingChairC_idle3): HubSittingChairC_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairC_move1;
|
||||
class GVAR(HubSittingChairC_move1): HubSittingChairC_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUA_idle1;
|
||||
class GVAR(HubSittingChairUA_idle1): HubSittingChairUA_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUA_idle2;
|
||||
class GVAR(HubSittingChairUA_idle2): HubSittingChairUA_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUA_idle3;
|
||||
class GVAR(HubSittingChairUA_idle3): HubSittingChairUA_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUA_move1;
|
||||
class GVAR(HubSittingChairUA_move1): HubSittingChairUA_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUB_idle1;
|
||||
class GVAR(HubSittingChairUB_idle1): HubSittingChairUB_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUB_idle2;
|
||||
class GVAR(HubSittingChairUB_idle2): HubSittingChairUB_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUB_idle3;
|
||||
class GVAR(HubSittingChairUB_idle3): HubSittingChairUB_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUB_move1;
|
||||
class GVAR(HubSittingChairUB_move1): HubSittingChairUB_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUC_idle1;
|
||||
class GVAR(HubSittingChairUC_idle1): HubSittingChairUC_idle1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUC_idle2;
|
||||
class GVAR(HubSittingChairUC_idle2): HubSittingChairUC_idle2 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUC_idle3;
|
||||
class GVAR(HubSittingChairUC_idle3): HubSittingChairUC_idle3 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
class HubSittingChairUC_move1;
|
||||
class GVAR(HubSittingChairUC_move1): HubSittingChairUC_move1 {
|
||||
MACRO_ANIMATION
|
||||
};
|
||||
};
|
||||
};
|
@ -39,7 +39,7 @@ class CfgVehicles {
|
||||
class ACE_MainActions { \
|
||||
displayName = ECSTRING(interaction,MainAction); \
|
||||
selection = ""; \
|
||||
distance = 1.25; \
|
||||
distance = 1.5; \
|
||||
condition = "true"; \
|
||||
class GVAR(Sit) { \
|
||||
displayName = CSTRING(Sit); \
|
||||
|
@ -12,6 +12,7 @@ class CfgPatches {
|
||||
};
|
||||
};
|
||||
|
||||
#include "CfgEventHandlers.hpp"
|
||||
#include "ACE_Settings.hpp"
|
||||
#include "CfgEventHandlers.hpp"
|
||||
#include "CfgMoves.hpp"
|
||||
#include "CfgVehicles.hpp"
|
||||
|
@ -10,17 +10,16 @@
|
||||
* Can Sit Down <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [seat, player] call ace_sitting_fnc_canSit;
|
||||
* [seat, player] call ace_sitting_fnc_canSit
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_seat,_player);
|
||||
params ["_seat", "_player"];
|
||||
|
||||
// Sitting enabled, is seat object, not occupied and standing up (or not on a big slope)
|
||||
GVAR(enable) &&
|
||||
{getNumber (configFile >> "CfgVehicles" >> typeOf _seat >> QGVAR(canSit)) == 1} &&
|
||||
{isNil{_seat getVariable QGVAR(seatOccupied)}} &&
|
||||
{isNil {_seat getVariable QGVAR(seatOccupied)}} &&
|
||||
{round (vectorUp _seat select 0) == 0 && {round (vectorUp _seat select 1) == 0} && {round (vectorUp _seat select 2) == 1}}
|
||||
|
@ -15,7 +15,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_player);
|
||||
params ["_player"];
|
||||
|
||||
// Sitting
|
||||
(_player getVariable [QGVAR(isSitting),false])
|
||||
(_player getVariable [QGVAR(isSitting), false])
|
||||
|
@ -9,40 +9,40 @@
|
||||
* Random Animation <STRING>
|
||||
*
|
||||
* Example:
|
||||
* _animation = call ace_sitting_fnc_getRandomAnimation;
|
||||
* _animation = call ace_sitting_fnc_getRandomAnimation
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_animations"];
|
||||
private "_animations";
|
||||
|
||||
// Animations Pool
|
||||
_animations = [
|
||||
"HubSittingChairUA_idle1",
|
||||
"HubSittingChairUA_idle2",
|
||||
"HubSittingChairUA_idle3",
|
||||
"HubSittingChairUA_move1",
|
||||
"HubSittingChairUB_idle1",
|
||||
"HubSittingChairUB_idle2",
|
||||
"HubSittingChairUB_idle3",
|
||||
"HubSittingChairUB_move1",
|
||||
"HubSittingChairUC_idle1",
|
||||
"HubSittingChairUC_idle2",
|
||||
"HubSittingChairUC_idle3",
|
||||
"HubSittingChairUC_move1",
|
||||
"HubSittingChairA_idle1",
|
||||
"HubSittingChairA_idle2",
|
||||
"HubSittingChairA_idle3",
|
||||
"HubSittingChairA_move1",
|
||||
"HubSittingChairB_idle1",
|
||||
"HubSittingChairB_idle2",
|
||||
"HubSittingChairB_idle3",
|
||||
"HubSittingChairB_move1",
|
||||
"HubSittingChairC_idle1",
|
||||
"HubSittingChairC_idle2",
|
||||
"HubSittingChairC_idle3",
|
||||
"HubSittingChairC_move1"
|
||||
QGVAR(HubSittingChairA_idle1),
|
||||
QGVAR(HubSittingChairA_idle2),
|
||||
QGVAR(HubSittingChairA_idle3),
|
||||
QGVAR(HubSittingChairA_move1),
|
||||
QGVAR(HubSittingChairB_idle1),
|
||||
QGVAR(HubSittingChairB_idle2),
|
||||
QGVAR(HubSittingChairB_idle3),
|
||||
QGVAR(HubSittingChairB_move1),
|
||||
QGVAR(HubSittingChairC_idle1),
|
||||
QGVAR(HubSittingChairC_idle2),
|
||||
QGVAR(HubSittingChairC_idle3),
|
||||
QGVAR(HubSittingChairC_move1),
|
||||
QGVAR(HubSittingChairUA_idle1),
|
||||
QGVAR(HubSittingChairUA_idle2),
|
||||
QGVAR(HubSittingChairUA_idle3),
|
||||
QGVAR(HubSittingChairUA_move1),
|
||||
QGVAR(HubSittingChairUB_idle1),
|
||||
QGVAR(HubSittingChairUB_idle2),
|
||||
QGVAR(HubSittingChairUB_idle3),
|
||||
QGVAR(HubSittingChairUB_move1),
|
||||
QGVAR(HubSittingChairUC_idle1),
|
||||
QGVAR(HubSittingChairUC_idle2),
|
||||
QGVAR(HubSittingChairUC_idle3),
|
||||
QGVAR(HubSittingChairUC_move1)
|
||||
];
|
||||
|
||||
// Select random animation
|
||||
|
@ -9,13 +9,13 @@
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* player call ace_sitting_fnc_handleInterrupt;
|
||||
* player call ace_sitting_fnc_handleInterrupt
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_player);
|
||||
params ["_player"];
|
||||
|
||||
if (_player getVariable [QGVAR(isSitting), false]) then {
|
||||
_player call FUNC(stand);
|
||||
|
@ -10,18 +10,21 @@
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [seat, seatPos] call ace_sitting_fnc_hasChairMoved;
|
||||
* [seat, seatPos] call ace_sitting_fnc_hasChairMoved
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_seat,_seatPosOrig);
|
||||
params ["_seat", "_seatPosOrig"];
|
||||
|
||||
TRACE_2("Chair position",_seatPosOrig,getPosASL _seat);
|
||||
|
||||
(getPosASL _seat) params ["_seatX", "_seatY", "_seatZ"];
|
||||
_seatPosOrig params ["_seatOrigX", "_seatOrigY", "_seatOrigZ"];
|
||||
|
||||
// Check each coordinate due to possibility of tiny movements in simulation
|
||||
(getPosASL _seat) select 0 < (_seatPosOrig select 0) - 0.01 || {(getPosASL _seat) select 0 > (_seatPosOrig select 0) + 0.01} ||
|
||||
{(getPosASL _seat) select 1 < (_seatPosOrig select 1) - 0.01 || {(getPosASL _seat) select 1 > (_seatPosOrig select 1) + 0.01}} ||
|
||||
{(getPosASL _seat) select 2 < (_seatPosOrig select 2) - 0.01 || {(getPosASL _seat) select 2 > (_seatPosOrig select 2) + 0.01}}
|
||||
if (abs (_seatX - _seatOrigX) > 0.01) exitWith {true};
|
||||
if (abs (_seatY - _seatOrigY) > 0.01) exitWith {true};
|
||||
if (abs (_seatZ - _seatOrigZ) > 0.01) exitWith {true};
|
||||
false
|
||||
|
@ -3,18 +3,22 @@
|
||||
* Initializes the Sitting module.
|
||||
*
|
||||
* Arguments:
|
||||
* Whatever the module provides.
|
||||
* 0: The module logic <LOGIC>
|
||||
* 1: Units <ARRAY>
|
||||
* 2: Activated <BOOL>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
if !(isServer) exitWith {};
|
||||
|
||||
PARAMS_3(_logic,_units,_activated);
|
||||
params ["_logic", "_units", "_activated"];
|
||||
|
||||
if !(_activated) exitWith {};
|
||||
if (!_activated) exitWith {};
|
||||
|
||||
[_logic, QGVAR(enable), "enable"] call EFUNC(common,readSettingFromModule);
|
||||
|
||||
|
@ -14,12 +14,11 @@
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_configFile", "_sitDirection", "_sitPosition", "_sitRotation", "_sitDirectionVisual"];
|
||||
|
||||
PARAMS_2(_seat,_player);
|
||||
params ["_seat", "_player"];
|
||||
|
||||
// Set global variable for standing up
|
||||
GVAR(seat) = _seat;
|
||||
@ -34,7 +33,8 @@ _sitPosition = getArray (_configFile >> QGVAR(sitPosition));
|
||||
_sitRotation = if (isNumber (_configFile >> QGVAR(sitRotation))) then {getNumber (_configFile >> QGVAR(sitRotation))} else {45}; // Apply default if config entry not present
|
||||
|
||||
// Get random animation and perform it (before moving player to ensure correct placement)
|
||||
[_player, call FUNC(getRandomAnimation), 2] call EFUNC(common,doAnimation);
|
||||
[_player, call FUNC(getRandomAnimation), 2] call EFUNC(common,doAnimation); // Correctly places when using non-transitional animations
|
||||
[_player, "", 1] call EFUNC(common,doAnimation); // Correctly applies animation's config values (such as disallow throwing of grenades, intercept keybinds... etc).
|
||||
|
||||
// Set direction and position
|
||||
_player setDir _sitDirection;
|
||||
@ -49,12 +49,13 @@ _seat setVariable [QGVAR(seatOccupied), true, true]; // To prevent multiple peop
|
||||
_sitDirectionVisual = getDirVisual _player; // Needed for precision and issues with using above directly
|
||||
_seatPosOrig = getPosASL _seat;
|
||||
[{
|
||||
EXPLODE_5_PVT(_this select 0,_player,_sitDirectionVisual,_sitRotation,_seat,_seatPosOrig);
|
||||
|
||||
params ["_args", "_pfhId"];
|
||||
_args params ["_player", "_sitDirectionVisual", "_sitRotation", "_seat", "_seatPosOrig"];
|
||||
|
||||
// Remove PFH if not sitting any more
|
||||
if !(_player getVariable [QGVAR(isSitting), false]) exitWith {
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
TRACE_1("Remove PFH",_player getVariable [ARR_2(QGVAR(isSitting),false)]);
|
||||
[_pfhId] call cba_fnc_removePerFrameHandler;
|
||||
TRACE_1("Remove PFH",_player getVariable [ARR_2(QGVAR(isSitting), false)]);
|
||||
};
|
||||
|
||||
// Stand up if chair moves
|
||||
|
@ -15,7 +15,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_player);
|
||||
params ["_player"];
|
||||
|
||||
// Restore animation
|
||||
[_player, "", 2] call EFUNC(common,doAnimation);
|
||||
|
@ -6,7 +6,7 @@ class CfgVehicles {
|
||||
displayName = CSTRING(DisplayName);
|
||||
function = QFUNC(moduleInit);
|
||||
scope = 2;
|
||||
isGlobal = 0; // Server only
|
||||
isGlobal = 1;
|
||||
isTriggerActivated = 0;
|
||||
isDisposable = 0;
|
||||
icon = QUOTE(PATHTOF(UI\Icon_Module_Slideshow_ca.paa));
|
||||
|
@ -10,19 +10,19 @@
|
||||
* 4: Current Slideshow <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
* List of actions <ARRAY>
|
||||
*
|
||||
* Example:
|
||||
* [[object], ["image"], ["name"], controller, 1] call ace_slideshow_fnc_addSlideActions
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_5(_objects,_images,_names,_controller,_currentSlideshow);
|
||||
private "_actions";
|
||||
|
||||
params ["_objects", "_images", "_names", "_controller", "_currentSlideshow"];
|
||||
|
||||
private ["_actions"];
|
||||
_actions = [];
|
||||
{
|
||||
_actions pushBack
|
||||
@ -32,10 +32,10 @@ _actions = [];
|
||||
_names select _forEachIndex,
|
||||
"",
|
||||
{
|
||||
EXPLODE_2_PVT(_this select 2,_objects,_image);
|
||||
(_this select 2) params ["_objects", "_image"];
|
||||
{
|
||||
_x setObjectTextureGlobal [0, _image]
|
||||
} forEach _objects;
|
||||
} count _objects;
|
||||
},
|
||||
{true},
|
||||
{},
|
||||
|
@ -4,25 +4,23 @@
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Objects <ARRAY>
|
||||
* 1: Controller Objects <ARRAY>
|
||||
* 2: Image Paths <ARRAY>
|
||||
* 3: Action Names <ARRAY>
|
||||
* 4: Duration <NUMBER> (0 disables automatic transitions)
|
||||
* 1: Image Paths <ARRAY>
|
||||
* 2: State Variable Name <ARRAY>
|
||||
* 3: Duration <NUMBER> (0 disables automatic transitions)
|
||||
*
|
||||
* Return Value:
|
||||
* Parsed List <ARRAY>
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [objects, controllers, images, actionNames, duration] call ace_slideshow_fnc_autoTransition
|
||||
* [objects, images, "ace_slideshow_slideshow1", duration] call ace_slideshow_fnc_autoTransition
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_4(_objects,_images,_varString,_duration);
|
||||
private "_currentSlide";
|
||||
|
||||
private ["_currentSlide"];
|
||||
params ["_objects", "_images", "_varString", "_duration"];
|
||||
|
||||
// Get current slide number of this slideshow
|
||||
_currentSlide = missionNamespace getVariable [_varString, 0];
|
||||
@ -36,10 +34,8 @@ missionNamespace setVariable [_varString, _currentSlide];
|
||||
// Set slide
|
||||
{
|
||||
_x setObjectTextureGlobal [0, _images select _currentSlide];
|
||||
} forEach _objects;
|
||||
} count _objects;
|
||||
|
||||
// Log current slide and execute Next slide
|
||||
TRACE_4("Auto-transition",_images select _currentSlide,_currentSlide,count _images,_duration);
|
||||
|
||||
|
||||
// Next slide
|
||||
[FUNC(autoTransition), [_objects, _images, _varString, _duration], _duration] call EFUNC(common,waitAndExecute);
|
||||
|
@ -17,10 +17,11 @@
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_5(_objects,_controllers,_images,_names,_duration);
|
||||
private ["_currentSlideshow", "_actionsObject", "_actionsClass", "_mainAction", "_slidesAction", "_varString"];
|
||||
|
||||
params ["_objects", "_controllers", "_images", "_names", "_duration"];
|
||||
|
||||
// Verify data
|
||||
if (count _images != count _names || {count _images == 0} || {count _names == 0}) exitWith {
|
||||
@ -30,7 +31,8 @@ if (count _images != count _names || {count _images == 0} || {count _names == 0}
|
||||
// Objects synced to the module
|
||||
{
|
||||
_objects pushBack _x;
|
||||
} forEach (synchronizedObjects _logic);
|
||||
nil
|
||||
} count (synchronizedObjects _logic);
|
||||
|
||||
// If no controllers use objects as controllers
|
||||
if (count _controllers == 0) then {
|
||||
@ -39,19 +41,26 @@ if (count _controllers == 0) then {
|
||||
|
||||
TRACE_4("Information",_objects,_controllers,_images,_names);
|
||||
|
||||
// Default images on whiteboards (first image)
|
||||
{
|
||||
_x setObjectTextureGlobal [0, _images select 0];
|
||||
} forEach _objects;
|
||||
if (isServer) then {
|
||||
// Default images on whiteboards (first image)
|
||||
{
|
||||
_x setObjectTextureGlobal [0, _images select 0];
|
||||
} count _objects;
|
||||
|
||||
// Number of slideshows (multiple modules support)
|
||||
GVAR(slideshows) = GVAR(slideshows) + 1;
|
||||
};
|
||||
|
||||
// Number of slideshows (multiple modules support)
|
||||
GVAR(slideshows) = GVAR(slideshows) + 1;
|
||||
private ["_currentSlideshow"];
|
||||
_currentSlideshow = GVAR(slideshows); // Local variable in case GVAR gets changed during execution of below code
|
||||
|
||||
// If interaction menu module is not present, set default duration value
|
||||
if !(["ace_interact_menu"] call EFUNC(common,isModLoaded)) then {
|
||||
_duration = 5;
|
||||
diag_log text format ["[ACE]: Slideshow: Interaction Menu module not present, defaulting duration value to %1", _duration];
|
||||
};
|
||||
|
||||
// Add interactions if automatic transitions are disabled, else setup automatic transitions
|
||||
if (_duration == 0) then {
|
||||
private ["_actionsObject", "_actionsClass", "_mainAction", "_slidesAction"];
|
||||
{
|
||||
// Add MainAction if one does not already exist
|
||||
_actionsObject = _x getVariable [QEGVAR(interact_menu,actions), []];
|
||||
@ -65,10 +74,12 @@ if (_duration == 0) then {
|
||||
// Add Slides sub-action and populate with images
|
||||
_slidesAction = [QGVAR(Slides), localize LSTRING(Interaction), "", {}, {true}, {(_this select 2) call FUNC(addSlideActions)}, [_objects,_images,_names,_x,_currentSlideshow], [0,0,0], 2] call EFUNC(interact_menu,createAction);
|
||||
[_x, 0, ["ACE_MainActions"], _slidesAction] call EFUNC(interact_menu,addActionToObject);
|
||||
} forEach _controllers;
|
||||
nil
|
||||
} count _controllers;
|
||||
} else {
|
||||
if !(isServer) exitWith {};
|
||||
|
||||
// Formatted GVAR string (multiple modules support)
|
||||
private ["_varString"];
|
||||
_varString = format [QGVAR(slideshow%1), _currentSlideshow];
|
||||
TRACE_1("Current Slide",_varString);
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_3(_list,_removeWhitespace,_checkNil);
|
||||
params ["_list", "_removeWhitespace", "_checkNil"];
|
||||
|
||||
private ["_splittedList", "_listNoWhitespace", "_nilCheckPassedList"];
|
||||
|
||||
@ -30,7 +30,8 @@ _listNoWhitespace = [];
|
||||
if (_removeWhitespace) then {
|
||||
{
|
||||
_listNoWhitespace pushBack ([_x] call EFUNC(common,stringRemoveWhiteSpace));
|
||||
} forEach _splittedList;
|
||||
nil
|
||||
} count _splittedList;
|
||||
_list = _listNoWhitespace;
|
||||
};
|
||||
|
||||
@ -45,7 +46,7 @@ if (_checkNil) then {
|
||||
_nilCheckPassedList = _nilCheckPassedList + "," + _x;
|
||||
};
|
||||
};
|
||||
} forEach _list;
|
||||
} count _list;
|
||||
|
||||
// Add Array characters and parse into array
|
||||
_list = "[" + _nilCheckPassedList + "]";
|
||||
@ -54,4 +55,4 @@ if (_checkNil) then {
|
||||
|
||||
TRACE_4("Lists",_splittedList,_listNoWhitespace,_nilCheckPassedList,_list);
|
||||
|
||||
_list
|
||||
_list // return
|
||||
|
@ -12,18 +12,16 @@
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
//#define DEBUG_MODE_FULL
|
||||
#include "script_component.hpp"
|
||||
|
||||
if !(isServer) exitWith {};
|
||||
|
||||
PARAMS_3(_logic,_units,_activated);
|
||||
|
||||
if !(_activated) exitWith {};
|
||||
// Exit on Headless Client
|
||||
if (!hasInterface && !isDedicated) exitWith {};
|
||||
|
||||
private ["_objects", "_controllers", "_images", "_names", "_duration"];
|
||||
|
||||
_logic = [_this, 0, objNull, [objNull]] call BIS_fnc_param;
|
||||
params [["_logic", objNull, [objNull]], "_units", "_activated"];
|
||||
|
||||
if !(_activated) exitWith {};
|
||||
if (isNull _logic) exitWith {};
|
||||
|
||||
// Extract variables from logic
|
||||
|
@ -1,30 +1,30 @@
|
||||
/*
|
||||
* Author: Rocko, Ruthberg
|
||||
*
|
||||
* Pick up spotting scope
|
||||
*
|
||||
* Arguments:
|
||||
* 0: spotting scope <OBJECT>
|
||||
* 1: unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [spotting_scope, player] call ace_spottingscope_fnc_pickup
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_spottingScope,_unit);
|
||||
params ["_spottingScope", "_unit"];
|
||||
|
||||
if ((_unit call CBA_fnc_getUnitAnim) select 0 == "stand") then {
|
||||
_unit playMove "AmovPercMstpSrasWrflDnon_diary";
|
||||
};
|
||||
|
||||
[{
|
||||
PARAMS_2(_spottingScope,_unit);
|
||||
|
||||
params ["_spottingScope", "_unit"];
|
||||
|
||||
[_unit, "ACE_SpottingScope"] call EFUNC(common,addToInventory);
|
||||
deleteVehicle _spottingScope;
|
||||
|
||||
}, [_spottingScope, _unit], 1, 0]call EFUNC(common,waitAndExecute);
|
||||
|
@ -1,21 +1,22 @@
|
||||
/*
|
||||
* Author: Rocko, Ruthberg
|
||||
*
|
||||
* Place down spotting scope
|
||||
*
|
||||
* Arguments:
|
||||
* 0: unit <OBJECT>
|
||||
* 1: scope class <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, "ACE_SpottingScope"] call ace_spottingscope_fnc_place
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_scopeClass);
|
||||
params ["_unit", "_scopeClass"];
|
||||
|
||||
_unit removeItem _scopeClass;
|
||||
|
||||
@ -24,18 +25,17 @@ if ((_unit call CBA_fnc_getUnitAnim) select 0 == "stand") then {
|
||||
};
|
||||
|
||||
[{
|
||||
PARAMS_1(_unit);
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
private ["_direction", "_position", "_spottingScope"];
|
||||
_direction = getDir _unit;
|
||||
_position = (getPosASL _unit) vectorAdd [0.8 * sin(_direction), 0.8 * cos(_direction), 0.02];
|
||||
|
||||
|
||||
_spottingScope = "ACE_SpottingScopeObject" createVehicle [0, 0, 0];
|
||||
_spottingScope setDir _direction;
|
||||
_spottingScope setPosASL _position;
|
||||
if ((getPosATL _spottingScope select 2) - (getPos _spottingScope select 2) < 1E-5) then {
|
||||
_spottingScope setVectorUp (surfaceNormal (position _spottingScope));
|
||||
_spottingScope setVectorUp (surfaceNormal (position _spottingScope));
|
||||
};
|
||||
_unit reveal _spottingScope;
|
||||
|
||||
}, [_unit], 1, 0] call EFUNC(common,waitAndExecute);
|
||||
|
@ -82,7 +82,8 @@ class CfgVehicles {
|
||||
displayName = CSTRING(Position);
|
||||
distance = 4;
|
||||
condition = "true";
|
||||
statement = QUOTE([ARR_2(_target,_player)] call FUNC(positionTL));
|
||||
//wait a frame to handle "Do When releasing action menu key" option:
|
||||
statement = QUOTE([ARR_2({_this call FUNC(positionTL)}, [ARR_2(_target,_player)])] call EFUNC(common,execNextFrame));
|
||||
showDisabled = 0;
|
||||
exceptions[] = {};
|
||||
priority = 5;
|
||||
|
@ -9,7 +9,7 @@
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [_ladder] call ace_tacticalladder_fnc_cancelTLdeploy;
|
||||
* [_ladder] call ace_tacticalladder_fnc_cancelTLdeploy
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
@ -17,16 +17,16 @@
|
||||
|
||||
#define __ANIMS ["extract_1","extract_2","extract_3","extract_4","extract_5","extract_6","extract_7","extract_8","extract_9","extract_10","extract_11"]
|
||||
|
||||
PARAMS_1(_ladder);
|
||||
params ["_ladder"];
|
||||
|
||||
detach _ladder;
|
||||
_ladder animate ["rotate", 0];
|
||||
{
|
||||
_ladder animate [_x, 0];
|
||||
} forEach __ANIMS;
|
||||
} count __ANIMS;
|
||||
|
||||
call EFUNC(interaction,hideMouseHint);
|
||||
[ACE_player, "DefaultAction", ACE_player getVariable [QGVAR(Deploy), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "zoomtemp", ACE_player getVariable [QGVAR(Cancel), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "DefaultAction", ACE_player getVariable [QGVAR(Deploy), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "zoomtemp", ACE_player getVariable [QGVAR(Cancel), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
|
||||
GVAR(ladder) = objNull;
|
||||
|
@ -6,16 +6,16 @@
|
||||
* 0: ladder <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* Success?
|
||||
* Success <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [_ladder] call ace_tacticalladder_fnc_confirmTLdeploy;
|
||||
* [_ladder] call ace_tacticalladder_fnc_confirmTLdeploy
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_ladder);
|
||||
params ["_ladder"];
|
||||
|
||||
private ["_pos1", "_pos2"];
|
||||
_pos1 = getPosASL GVAR(ladder);
|
||||
@ -23,8 +23,8 @@ _pos2 = (GVAR(ladder) modelToWorld (GVAR(ladder) selectionPosition "check2")) ca
|
||||
if (lineIntersects [_pos1, _pos2, GVAR(ladder)]) exitWith { false };
|
||||
|
||||
call EFUNC(interaction,hideMouseHint);
|
||||
[ACE_player, "DefaultAction", ACE_player getVariable [QGVAR(Deploy), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "zoomtemp", ACE_player getVariable [QGVAR(Cancel), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "DefaultAction", ACE_player getVariable [QGVAR(Deploy), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[ACE_player, "zoomtemp", ACE_player getVariable [QGVAR(Cancel), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
|
||||
detach _ladder;
|
||||
GVAR(ladder) = objNull;
|
||||
|
@ -3,13 +3,13 @@
|
||||
* Deploy tactical ladder
|
||||
*
|
||||
* Arguments:
|
||||
* Nothing
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* call ace_tacticalladder_fnc_deployTL;
|
||||
* [] call ace_tacticalladder_fnc_deployTL
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
@ -9,13 +9,13 @@
|
||||
* Handled <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* 1 call ace_tacticalladder_fnc_handleScrollWheel;
|
||||
* [1] call ace_tacticalladder_fnc_handleScrollWheel;
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_scroll);
|
||||
params ["_scroll"];
|
||||
|
||||
if (isNull GVAR(ladder)) exitWith { false };
|
||||
|
||||
@ -37,7 +37,7 @@ if (GETMVAR(ACE_Modifier,0) == 0) then {
|
||||
if (GVAR(ladder) animationPhase (format["extract_%1", _currentStep]) == 1) then {
|
||||
GVAR(ladder) animate [format["extract_%1", _currentStep], 0];
|
||||
GVAR(currentStep) = _currentStep - 1;
|
||||
};
|
||||
};
|
||||
};
|
||||
} else {
|
||||
// Tilting
|
||||
@ -45,4 +45,4 @@ if (GETMVAR(ACE_Modifier,0) == 0) then {
|
||||
GVAR(ladder) animate ["rotate", GVAR(currentAngle)];
|
||||
};
|
||||
|
||||
true
|
||||
true
|
||||
|
@ -7,10 +7,10 @@
|
||||
* 1: unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* Success?
|
||||
* Success <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [_ladder, _unit] call ace_tacticalladder_fnc_pickupTL;
|
||||
* [_ladder, _unit] call ace_tacticalladder_fnc_pickupTL
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
@ -18,7 +18,7 @@
|
||||
|
||||
if ((backpack ACE_player) != "") exitWith { false };
|
||||
|
||||
PARAMS_2(_ladder,_unit);
|
||||
params ["_ladder", "_unit"];
|
||||
|
||||
deleteVehicle _ladder;
|
||||
_unit addBackpack "ACE_TacticalLadder_Pack";
|
||||
|
@ -10,7 +10,7 @@
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [_ladder, _unit] call ace_tacticalladder_fnc_positionTL;
|
||||
* [_ladder, _unit] call ace_tacticalladder_fnc_positionTL
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
@ -18,11 +18,11 @@
|
||||
|
||||
#define __ANIMS ["extract_1","extract_2","extract_3","extract_4","extract_5","extract_6","extract_7","extract_8","extract_9","extract_10","extract_11"]
|
||||
|
||||
PARAMS_2(_ladder,_unit);
|
||||
params ["_ladder", "_unit"];
|
||||
|
||||
{
|
||||
_ladder animate [_x, 0];
|
||||
} forEach __ANIMS;
|
||||
} count __ANIMS;
|
||||
|
||||
_unit switchMove "amovpercmstpslowwrfldnon_player_idlesteady03";
|
||||
_ladder attachTo [_unit, [0, 0.75, 0], ""]; // Position ladder in front of player
|
||||
@ -30,7 +30,7 @@ _ladder attachTo [_unit, [0, 0.75, 0], ""]; // Position ladder in front of playe
|
||||
_ladder animate ["rotate", 0];
|
||||
{
|
||||
_ladder animate [_x, 1];
|
||||
} forEach ["extract_1", "extract_2", "extract_3"]; // Extract ladder at head height (extract_3)
|
||||
} count ["extract_1", "extract_2", "extract_3"]; // Extract ladder at head height (extract_3)
|
||||
|
||||
GVAR(ladder) = _ladder;
|
||||
GVAR(cancelTime) = ACE_time + 1; // Workaround to prevent accidental canceling
|
||||
|
@ -17,7 +17,7 @@ class CfgVehicles {
|
||||
|
||||
class Item_Base_F;
|
||||
class ACE_Item_Tripod: Item_Base_F {
|
||||
author[] = {"Rocko", "Scubaman3D"};
|
||||
author[] = {"Rocko", "Scubaman3D"};
|
||||
scope = 2;
|
||||
scopeCurator = 2;
|
||||
displayName = CSTRING(DisplayName);
|
||||
@ -76,7 +76,8 @@ class CfgVehicles {
|
||||
displayName = CSTRING(Adjust);
|
||||
distance = 5;
|
||||
condition = "true";
|
||||
statement = QUOTE(_target call FUNC(adjust));
|
||||
//wait a frame to handle "Do When releasing action menu key" option:
|
||||
statement = QUOTE([ARR_2({_this call FUNC(adjust)}, [_target])] call EFUNC(common,execNextFrame));
|
||||
showDisabled = 0;
|
||||
exceptions[] = {};
|
||||
priority = 5;
|
||||
|
@ -1,37 +1,39 @@
|
||||
/*
|
||||
* Author: Ruthberg
|
||||
*
|
||||
* Adjust tripod height
|
||||
*
|
||||
* Arguments:
|
||||
* 0: tripod <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [tripod] call ace_tripod_fnc_adjust
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_tripod);
|
||||
params ["_tripod"];
|
||||
|
||||
GVAR(adjuster) = ACE_player;
|
||||
GVAR(adjusting) = true;
|
||||
|
||||
GVAR(adjustPFH) = [{
|
||||
EXPLODE_1_PVT(_this select 0,_tripod);
|
||||
|
||||
params ["_args", "_pfhId"];
|
||||
_args params ["_tripod"];
|
||||
|
||||
if (GVAR(adjuster) != ACE_player || !GVAR(adjusting)) exitWith {
|
||||
call EFUNC(interaction,hideMouseHint);
|
||||
[ACE_player, "DefaultAction", ACE_player getVariable [QGVAR(Adjust), -1]] call EFUNC(Common,removeActionEventHandler);
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
[_pfhId] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
|
||||
{
|
||||
_tripod animate [_x, 1 - GVAR(height)];
|
||||
} foreach ["slide_down_tripod", "retract_leg_1", "retract_leg_2", "retract_leg_3"];
|
||||
|
||||
} count ["slide_down_tripod", "retract_leg_1", "retract_leg_2", "retract_leg_3"];
|
||||
|
||||
}, 0, [_tripod]] call CBA_fnc_addPerFrameHandler;
|
||||
|
||||
[localize "STR_ACE_Tripod_Done", "", localize "STR_ACE_Tripod_ScrollAction"] call EFUNC(interaction,showMouseHint);
|
||||
|
@ -9,13 +9,13 @@
|
||||
* handled <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* 1.2 call ace_tripod_fnc_handleScrollWheel;
|
||||
* [1.2] call ace_tripod_fnc_handleScrollWheel;
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_scroll);
|
||||
params ["_scroll"];
|
||||
|
||||
if (GETMVAR(ACE_Modifier,0) == 0 || GVAR(adjustPFH) == -1) exitWith { false };
|
||||
|
||||
|
@ -1,30 +1,30 @@
|
||||
/*
|
||||
* Author: Rocko, Ruthberg
|
||||
*
|
||||
* Pick up tripod
|
||||
*
|
||||
* Arguments:
|
||||
* 0: tripod <OBJECT>
|
||||
* 1: unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [tripod, player] call ace_tripod_fnc_pickup
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_tripod,_unit);
|
||||
params ["_tripod", "_unit"];
|
||||
|
||||
if ((_unit call CBA_fnc_getUnitAnim) select 0 == "stand") then {
|
||||
_unit playMove "AmovPercMstpSrasWrflDnon_diary";
|
||||
};
|
||||
|
||||
[{
|
||||
PARAMS_2(_tripod,_unit);
|
||||
params ["_tripod", "_unit"];
|
||||
|
||||
[_unit, "ACE_Tripod"] call EFUNC(common,addToInventory);
|
||||
deleteVehicle _tripod;
|
||||
|
||||
}, [_tripod, _unit], 1, 0]call EFUNC(common,waitAndExecute);
|
||||
|
@ -1,21 +1,22 @@
|
||||
/*
|
||||
* Author: Rocko, Ruthberg
|
||||
*
|
||||
* Place down tripod
|
||||
*
|
||||
* Arguments:
|
||||
* 0: unit <OBJECT>
|
||||
* 1: tripod class <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Nothing
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, "ACE_Tripod"] call ace_tripod_fnc_place
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_tripodClass);
|
||||
params ["_unit", "_tripodClass"];
|
||||
|
||||
_unit removeItem _tripodClass;
|
||||
|
||||
@ -24,27 +25,29 @@ if ((_unit call CBA_fnc_getUnitAnim) select 0 == "stand") then {
|
||||
};
|
||||
|
||||
[{
|
||||
PARAMS_1(_unit);
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
private ["_direction", "_position", "_tripod"];
|
||||
_direction = getDir _unit;
|
||||
_position = (getPosASL _unit) vectorAdd [0.8 * sin(_direction), 0.8 * cos(_direction), 0.02];
|
||||
|
||||
|
||||
_tripod = "ACE_TripodObject" createVehicle [0, 0, 0];
|
||||
{
|
||||
_tripod animate [_x, 1];
|
||||
} foreach ["slide_down_tripod", "retract_leg_1", "retract_leg_2", "retract_leg_3"];
|
||||
|
||||
} count ["slide_down_tripod", "retract_leg_1", "retract_leg_2", "retract_leg_3"];
|
||||
|
||||
[{
|
||||
EXPLODE_3_PVT(_this select 0,_tripod,_direction,_position);
|
||||
params ["_args", "_pfhId"];
|
||||
_args params ["_tripod", "_direction", "_position"];
|
||||
|
||||
if (_tripod animationPhase "slide_down_tripod" == 1) then {
|
||||
_tripod setDir _direction;
|
||||
_tripod setPosASL _position;
|
||||
if ((getPosATL _tripod select 2) - (getPos _tripod select 2) < 1E-5) then {
|
||||
_tripod setVectorUp (surfaceNormal (position _tripod));
|
||||
_tripod setVectorUp (surfaceNormal (position _tripod));
|
||||
};
|
||||
[_this select 1] call CBA_fnc_removePerFrameHandler;
|
||||
[_pfhId] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
}, 0, [_tripod, _direction, _position]] call CBA_fnc_addPerFrameHandler;
|
||||
|
||||
|
||||
}, [_unit], 1, 0] call EFUNC(common,waitAndExecute);
|
||||
|
@ -20,7 +20,10 @@
|
||||
|
||||
private ["_previousMags","_newMags","_keyMagazine","_keyName"];
|
||||
|
||||
params ["_unit", "_veh", "_useCustom"];
|
||||
if (!params [["_unit", objNull, [objNull]], ["_veh", objNull, [objNull]], ["_useCustom", false, [false]]]) exitWith {
|
||||
ERROR("Input wrong type");
|
||||
};
|
||||
TRACE_3("params",_unit,_veh,_useCustom);
|
||||
|
||||
if (isNull _unit) exitWith {ERROR("null unit");};
|
||||
if (isNull _veh) exitWith {ERROR("null vehicle");};
|
||||
|
@ -18,6 +18,7 @@
|
||||
private ["_vehConfigSide","_vehSide","_returnValue"];
|
||||
|
||||
params ["_veh"];
|
||||
TRACE_1("params",_veh);
|
||||
|
||||
if (isNull _veh) exitWith {ERROR("null vehicle"); "error"};
|
||||
|
||||
|
@ -19,6 +19,7 @@
|
||||
if (!isServer) exitWith {};
|
||||
|
||||
params ["_vehicle"];
|
||||
TRACE_1("params",_vehicle);
|
||||
|
||||
[{
|
||||
//If the module wasn't placed, just exit (needs to be in wait because objectInitEH is before moduleInit)
|
||||
@ -41,4 +42,4 @@ params ["_vehicle"];
|
||||
};
|
||||
};
|
||||
//Delay call until mission start (so everyone has the eventHandler's installed)
|
||||
}, [_vehicle], 0.25, 0.25] call EFUNC(common,waitAndExecute);
|
||||
}, [_vehicle], 0.25] call EFUNC(common,waitAndExecute);
|
||||
|
@ -19,6 +19,7 @@
|
||||
private ["_returnValue","_sideKeyName","_customKeys"];
|
||||
|
||||
params ["_unit", "_veh"];
|
||||
TRACE_2("params",_unit,_veh);
|
||||
|
||||
if (isNull _unit) exitWith {ERROR("null unit"); false};
|
||||
if (isNull _veh) exitWith {ERROR("null vehicle"); false};
|
||||
|
@ -23,6 +23,7 @@
|
||||
private ["_vehLockpickStrenth","_condition","_returnValue"];
|
||||
|
||||
params ["_unit", "_veh", "_funcType"];
|
||||
TRACE_3("params",_unit,_veh,_funcType);
|
||||
|
||||
if (isNull _unit) exitWith {ERROR("null unit"); false};
|
||||
if (isNull _veh) exitWith {ERROR("null vehicle"); false};
|
||||
|
@ -20,6 +20,7 @@
|
||||
if (!isServer) exitWith {};
|
||||
|
||||
params ["_logic", "_syncedUnits", "_activated"];
|
||||
TRACE_3("params",_logic,_syncedObjects,_activated);
|
||||
|
||||
if (!_activated) exitWith {WARNING("Vehicle Lock Init Module - placed but not active");};
|
||||
|
||||
|
@ -20,6 +20,7 @@
|
||||
if (!isServer) exitWith {};
|
||||
|
||||
params ["_logic", "_syncedObjects", "_activated"];
|
||||
TRACE_3("params",_logic,_syncedObjects,_activated);
|
||||
|
||||
if !(_activated) exitWith {WARNING("Vehicle Lock Sync Module - placed but not active");};
|
||||
|
||||
|
@ -17,6 +17,7 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
params ["_unit", "_container"];
|
||||
TRACE_2("params",_unit,_container);
|
||||
|
||||
//Only check for player:
|
||||
if (_unit != ace_player) exitWith {false};
|
||||
|
@ -19,6 +19,7 @@
|
||||
private ["_currentKeys"];
|
||||
|
||||
params ["_veh", "_key"];
|
||||
TRACE_2("params",_veh,_key);
|
||||
|
||||
if (!isServer) exitWith {ERROR("only run on server");};
|
||||
if (isNull _veh) exitWith {ERROR("null vehicle");};
|
||||
|
@ -19,6 +19,7 @@
|
||||
private ["_lockNumber"];
|
||||
|
||||
params ["_veh", "_isLocked"];
|
||||
TRACE_2("params",_veh,_isLocked);
|
||||
|
||||
_lockNumber = if (_isLocked) then {2} else {0};
|
||||
TRACE_2("Setting Lock State", _veh, _lockNumber);
|
||||
|
@ -17,10 +17,10 @@
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_show_prompt);
|
||||
|
||||
private["_land_vehicle","_air_vehicle"];
|
||||
|
||||
params ["_show_prompt"];
|
||||
|
||||
if (!GVAR(enabled) || isNull ACE_player) exitWith {};
|
||||
|
||||
_land_vehicle = (vehicle ACE_player) isKindOf "LandVehicle";
|
||||
|
@ -20,7 +20,7 @@
|
||||
|
||||
private ["_text","_new_view_distance","_view_distance_limit","_object_view_distance_coeff"];
|
||||
|
||||
PARAMS_2(_index_requested,_show_prompt);
|
||||
params ["_index_requested", "_show_prompt"];
|
||||
|
||||
_new_view_distance = [_index_requested] call FUNC(returnValue); // changes the setting index into an actual view distance value
|
||||
_object_view_distance_coeff = [GVAR(objectViewDistanceCoeff)] call FUNC(returnObjectCoeff); // changes the setting index into a coefficient.
|
||||
|
@ -17,7 +17,7 @@
|
||||
|
||||
if (!isServer) exitWith {};
|
||||
|
||||
PARAMS_3(_logic,_units,_activated);
|
||||
params ["_logic", "_units", "_activated"];
|
||||
|
||||
if (!_activated) exitWith {
|
||||
diag_log text "[ACE]: View Distance Limit Module is placed but NOT active.";
|
||||
|
@ -1,7 +1,7 @@
|
||||
/*
|
||||
* Author: Winter
|
||||
* Returns the object view distance coefficient according to the given index
|
||||
*
|
||||
*
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Object View Distance setting Index <SCALAR>
|
||||
@ -17,10 +17,10 @@
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_index);
|
||||
|
||||
private ["_return"];
|
||||
|
||||
params ["_index"];
|
||||
|
||||
_return = switch (_index) do {
|
||||
case 0: {0.00}; // Off
|
||||
case 1: {0.20}; // Very Low
|
||||
@ -31,4 +31,4 @@ _return = switch (_index) do {
|
||||
default {0.50}; // something broke if this returns
|
||||
};
|
||||
|
||||
_return;
|
||||
_return;
|
||||
|
@ -17,10 +17,10 @@
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_index);
|
||||
|
||||
private ["_return"];
|
||||
|
||||
params ["_index"];
|
||||
|
||||
_return = switch (_index) do {
|
||||
case 0: {-1};
|
||||
case 1: {500};
|
||||
@ -40,4 +40,4 @@ _return = switch (_index) do {
|
||||
default {1000};
|
||||
};
|
||||
|
||||
_return;
|
||||
_return;
|
||||
|
@ -1,21 +1,26 @@
|
||||
/*
|
||||
* Author: esteldunedain
|
||||
*
|
||||
* Count how many grenade magazines the unit has on the uniform and vest.
|
||||
*
|
||||
* Argument:
|
||||
* 0: Muzzle name
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Muzzle Class <STRING>
|
||||
*
|
||||
* Return value:
|
||||
* 0: Number of magazines
|
||||
* 1: First magazine name
|
||||
* Return Value:
|
||||
* 0: Number of magazines <NUMBER>
|
||||
* 1: First magazine name <STRING>
|
||||
*
|
||||
* Example:
|
||||
* [player, currentMuzzle player] call ace_weaponselect_fnc_countMagazinesForGrenadeMuzzle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_muzzle);
|
||||
|
||||
private ["_uniformMags", "_vestMags", "_backpackMags", "_numberOfMagazines", "_magazineClasses", "_firstMagazine"];
|
||||
|
||||
params ["_unit", "_muzzle"];
|
||||
|
||||
_uniformMags = getMagazineCargo uniformContainer _unit;
|
||||
_vestMags = getMagazineCargo vestContainer _unit;
|
||||
_backpackMags = getMagazineCargo backpackContainer _unit;
|
||||
|
@ -1,24 +1,28 @@
|
||||
/*
|
||||
* Author: esteldunedain
|
||||
*
|
||||
* Display a grenade type and quantity.
|
||||
*
|
||||
* Argument:
|
||||
* 0: magazine class
|
||||
* 1: number of magazines
|
||||
* Arguments:
|
||||
* 0: magazine class <STRING>
|
||||
* 1: number of magazines <NUMBER>
|
||||
*
|
||||
* Return value:
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [currentMagazine player, 3] call ace_weaponselect_fnc_displayGrenadeTypeAndNumber
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
if !(GVAR(DisplayText)) exitwith {};
|
||||
|
||||
PARAMS_2(_magazine,_numberofMagazines);
|
||||
|
||||
private ["_color", "_name", "_text", "_picture"];
|
||||
|
||||
_color = [[1,0,0], [1,1,1]] select (_numberofMagazines > 0);
|
||||
params ["_magazine", "_numberofMagazines"];
|
||||
|
||||
_color = [[1, 0, 0], [1, 1, 1]] select (_numberofMagazines > 0);
|
||||
_name = getText (configFile >> "CfgMagazines" >> _magazine >> "displayNameShort");
|
||||
|
||||
_text = [format["%1 x%2", _name, _numberofMagazines], _color] call EFUNC(common,stringToColoredText);
|
||||
|
@ -1,17 +1,29 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Find the next Grenade Magazine.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Grenade Type ("All", "Frag", "NonFrag") <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Magazine classname <STRING>
|
||||
*
|
||||
* Example:
|
||||
* ["All"] call ace_weaponselect_fnc_findNextGrenadeMagazine
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_allMags", "_allMuzzles", "_magazines"];
|
||||
private ["_allMags", "_allMuzzles", "_magazines", "_start", "_index", "_nextMagazine"];
|
||||
|
||||
PARAMS_1(_type); //"All", "Frag" or "NonFrag"
|
||||
params ["_type"];
|
||||
|
||||
_allMags = missionNamespace getVariable [format [QGVAR(%1Magazines), _type], []];
|
||||
_allMuzzles = missionNamespace getVariable [format [QGVAR(%1Muzzles), _type], []];
|
||||
|
||||
_magazines = magazines ACE_player;
|
||||
|
||||
private ["_start", "_index", "_nextMagazine"];
|
||||
|
||||
_start = [GVAR(CurrentGrenadeMuzzleOther), GVAR(CurrentGrenadeMuzzleFrag)] select GVAR(CurrentGrenadeMuzzleIsFrag);
|
||||
_index = _allMuzzles find _start;
|
||||
|
||||
|
@ -1,17 +1,29 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Find the next Grenade Muzzle.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Grenade Type ("All", "Frag", "NonFrag") <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Class name of next throw muzzle <STRING>
|
||||
*
|
||||
* Example:
|
||||
* ["All"] call ace_weaponselect_fnc_findNextGrenadeMuzzle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_allMags", "_allMuzzles", "_magazines"];
|
||||
private ["_allMags", "_allMuzzles", "_magazines", "_start", "_index", "_nextMuzzle"];
|
||||
|
||||
PARAMS_1(_type); //"All", "Frag" or "NonFrag"
|
||||
params ["_type"];
|
||||
|
||||
_allMags = missionNamespace getVariable [format [QGVAR(%1Magazines), _type], []];
|
||||
_allMuzzles = missionNamespace getVariable [format [QGVAR(%1Muzzles), _type], []];
|
||||
|
||||
_magazines = magazines ACE_player;
|
||||
|
||||
private ["_start", "_index", "_nextMuzzle"];
|
||||
|
||||
_start = [GVAR(CurrentGrenadeMuzzleOther), GVAR(CurrentGrenadeMuzzleFrag)] select GVAR(CurrentGrenadeMuzzleIsFrag);
|
||||
_index = _allMuzzles find _start;
|
||||
|
||||
|
@ -1,9 +1,23 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Fire Vehicle Smoke Launcher.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicle <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [vehicle player] call ace_weaponselect_fnc_fireSmokeLauncher
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_turret", "_weapons"];
|
||||
|
||||
PARAMS_1(_vehicle);
|
||||
params ["_vehicle"];
|
||||
|
||||
_turret = [_vehicle] call EFUNC(common,getTurretCommander);
|
||||
|
||||
|
@ -1,4 +1,18 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Returns the selected Grenade Muzzle.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* Class name of selected throw muzzle <STRING>
|
||||
*
|
||||
* Example:
|
||||
* [] call ace_weaponselect_fnc_getSelectedGrenade
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
[GVAR(CurrentGrenadeMuzzleOther), GVAR(CurrentGrenadeMuzzleFrag)] select GVAR(CurrentGrenadeMuzzleIsFrag)
|
||||
|
@ -1,9 +1,24 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Play the change firemode sound for specified weapon at units position.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Weapon <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, currentWeapon player] call ace_weaponselect_fnc_playChangeFiremodeSound
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_sound"];
|
||||
|
||||
PARAMS_2(_unit,_weapon);
|
||||
params ["_unit", "_weapon"];
|
||||
|
||||
_sound = getArray (configFile >> "CfgWeapons" >> _weapon >> "changeFiremodeSound");
|
||||
|
||||
|
@ -1,17 +1,21 @@
|
||||
/*
|
||||
* Author: commy2
|
||||
*
|
||||
* The unit will put its current weapon away.
|
||||
*
|
||||
* Argument:
|
||||
* 0: What unit should put the current weapon on back? (Object)
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
*
|
||||
* Return value:
|
||||
* None.
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player] call ace_weaponselect_fnc_putWeaponAway
|
||||
*
|
||||
* Public: NO
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_1(_unit);
|
||||
params ["_unit"];
|
||||
|
||||
[_unit] call EFUNC(common,fixLoweredRifleAnimation);
|
||||
|
||||
|
@ -1,25 +1,28 @@
|
||||
/*
|
||||
* Author: esteldunedain, commy2
|
||||
*
|
||||
* Cycle through all grenades.
|
||||
*
|
||||
* Argument:
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
* Example:
|
||||
* [player] call ace_weaponselect_fnc_selectGrenadeAll
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_text", "_nextMuzzle"];
|
||||
|
||||
PARAMS_1(_unit);
|
||||
params ["_unit"];
|
||||
|
||||
_nextMuzzle = ["All"] call FUNC(findNextGrenadeMuzzle);
|
||||
|
||||
if (_nextMuzzle != "") then {
|
||||
|
||||
|
||||
private ["_magazines", "_magazine", "_count", "_return"];
|
||||
_magazines = GVAR(AllMagazines) select (GVAR(AllMuzzles) find _nextMuzzle);
|
||||
reverse _magazines;
|
||||
|
@ -1,19 +1,23 @@
|
||||
/*
|
||||
* Author: esteldunedain, commy2
|
||||
*
|
||||
* Cycle through frags.
|
||||
*
|
||||
* Argument:
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
* Example:
|
||||
* [player] call ace_weaponselect_fnc_selectGrenadeFrag
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_text", "_nextMuzzle"];
|
||||
|
||||
PARAMS_1(_unit);
|
||||
params ["_unit"];
|
||||
|
||||
_nextMuzzle = ["Frag"] call FUNC(findNextGrenadeMuzzle);
|
||||
|
||||
|
@ -1,19 +1,23 @@
|
||||
/*
|
||||
* Author: esteldunedain, commy2
|
||||
*
|
||||
* Cycle through non explosive grenades.
|
||||
*
|
||||
* Argument:
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
* Example:
|
||||
* [player] call ace_weaponselect_fnc_selectGrenadeOther
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_nextMuzzle", "_text"];
|
||||
|
||||
PARAMS_1(_unit);
|
||||
params ["_unit"];
|
||||
|
||||
_nextMuzzle = ["NonFrag"] call FUNC(findNextGrenadeMuzzle);
|
||||
|
||||
|
@ -1,17 +1,22 @@
|
||||
/*
|
||||
* Author: commy2
|
||||
*
|
||||
* The player will select the specified weapon or will change to the next firing mode if the weapon was already selected.
|
||||
*
|
||||
* Argument:
|
||||
* 0: A weapon (String)
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Weapon <STRING>
|
||||
*
|
||||
* Return value:
|
||||
* None.
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, currentWeapon player] call ace_weaponselect_fnc_selectWeaponMode
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_weapon);
|
||||
params ["_unit", "_weapon"];
|
||||
|
||||
if (_weapon == "") exitWith {};
|
||||
|
||||
|
@ -1,17 +1,22 @@
|
||||
/*
|
||||
* Author: commy2
|
||||
*
|
||||
* The player will select the specified weapon and change to the first additional muzzle. E.g. the grenade launcher of a assault rifle.
|
||||
*
|
||||
* Argument:
|
||||
* 0: A weapon (String)
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Weapon <STRING>
|
||||
*
|
||||
* Return value:
|
||||
* None.
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, currentWeapon player] call ace_weaponselect_fnc_selectWeaponMuzzle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_weapon);
|
||||
params ["_unit", "_weapon"];
|
||||
|
||||
if (_weapon == "") exitWith {};
|
||||
|
||||
|
@ -1,7 +1,23 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Select weapon for unit in vehicle.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Vehicle <OBJECT>
|
||||
* 2: Weapon index <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, vehicle player, 1] call ace_weaponselect_fnc_selectWeaponVehicle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_3(_unit,_vehicle,_index);
|
||||
params ["_unit", "_vehicle", "_index"];
|
||||
|
||||
private "_turret";
|
||||
_turret = [_unit] call EFUNC(common,getTurretIndex);
|
||||
|
@ -1,21 +1,25 @@
|
||||
/*
|
||||
* Author: esteldunedain
|
||||
*
|
||||
* Select the next grenade muzzle to throw.
|
||||
*
|
||||
* Argument:
|
||||
* muzzle name
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Muzzlename <STRING>
|
||||
*
|
||||
* Return value:
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, currentMuzzle player] call ace_weaponselect_fnc_setNextGrenadeMuzzle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
PARAMS_2(_unit,_muzzle);
|
||||
|
||||
private ["_uniformMags", "_vestMags", "_backpackMags", "_i", "_uniformMagsToRemove", "_vestMagsToRemove", "_backpackMagsToRemove", "_firstMagazine", "_throwMuzzleNames"];
|
||||
|
||||
params ["_unit", "_muzzle"];
|
||||
|
||||
_uniformMags = getMagazineCargo uniformContainer _unit;
|
||||
_vestMags = getMagazineCargo vestContainer _unit;
|
||||
_backpackMags = getMagazineCargo backpackContainer _unit;
|
||||
|
@ -1,11 +1,27 @@
|
||||
// by commy2
|
||||
/*
|
||||
* Author: commy2
|
||||
* Display Grenade information on grenade throw.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: unit - Object the event handler is assigned to <OBJECT>
|
||||
* 1: weapon - Fired weapon <STRING>
|
||||
* 2: muzzle - Muzzle that was used <STRING>
|
||||
* 3: mode - Current mode of the fired weapon <STRING>
|
||||
* 4: ammo - Ammo used <STRING>
|
||||
* 5: magazine - magazine name which was used <STRING>
|
||||
* 6: projectile - Object of the projectile that was shot <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [_unit, _weapon, _muzzle, _mode, _ammo, _magazine, _projectile] call ace_weaponselect_fnc_throwGrenade
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_unit","_weapon","_magazine"];
|
||||
|
||||
_unit = _this select 0;
|
||||
_weapon = _this select 1;
|
||||
_magazine = _this select 5;
|
||||
params ["_unit", "_weapon", "", "", "", "_magazine"];
|
||||
|
||||
if (_weapon != "Throw") exitWith {};
|
||||
|
||||
|
@ -47,7 +47,7 @@ GVAR(WindInfo) = true;
|
||||
};
|
||||
|
||||
if (_windSpeed > 0.2) then {
|
||||
_playerDir = getDir ACE_player;
|
||||
_playerDir = (ACE_player call CBA_fnc_headDir) select 0;
|
||||
_windDir = (ACE_wind select 0) atan2 (ACE_wind select 1);
|
||||
_windIndex = round(((_playerDir - _windDir + 360) % 360) / 30);
|
||||
_windIndex = _windIndex % 12;
|
||||
|
@ -21,9 +21,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_unit", "_bullet"];
|
||||
_unit = _this select 0;
|
||||
_bullet = _this select 6;
|
||||
params ["_unit", "", "", "", "_ammo", "", "_bullet"];
|
||||
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false] && (_bullet isKindOf "BulletBase") && (_unit isKindOf "Man")) exitWith {false};
|
||||
|
||||
@ -34,6 +32,6 @@ if (!((_bullet isKindOf "BulletBase") || (_bullet isKindOf "GrenadeBase"))) exit
|
||||
if (_unit distance ACE_player > GVAR(simulationRadius)) exitWith {false};
|
||||
if (!([_unit] call EFUNC(common,isPlayer))) exitWith {false};
|
||||
|
||||
GVAR(trackedBullets) pushBack [_bullet, getNumber(configFile >> "cfgAmmo" >> (_this select 4) >> "airFriction")];
|
||||
GVAR(trackedBullets) pushBack [_bullet, getNumber(configFile >> "cfgAmmo" >> _ammo >> "airFriction")];
|
||||
|
||||
true;
|
@ -15,10 +15,7 @@
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_logic", "_units", "_activated"];
|
||||
_logic = _this select 0;
|
||||
_units = _this select 1;
|
||||
_activated = _this select 2;
|
||||
params ["_logic", "_units", "_activated"];
|
||||
|
||||
if !(_activated) exitWith {};
|
||||
|
||||
|
@ -18,11 +18,12 @@
|
||||
|
||||
[{
|
||||
// BEGIN_COUNTER(pfeh);
|
||||
private["_accel", "_accelRef", "_bulletSpeed", "_bulletVelocity", "_deleted", "_deltaT", "_drag", "_dragRef", "_isWind", "_lastTime", "_trueSpeed", "_trueVelocity"];
|
||||
private["_accel", "_accelRef", "_bulletSpeed", "_bulletVelocity", "_deleted", "_deltaT", "_drag", "_dragRef", "_isWind", "_trueSpeed", "_trueVelocity"];
|
||||
|
||||
_lastTime = (_this select 0) select 0;
|
||||
params ["_args"];
|
||||
_args params ["_lastTime"];
|
||||
_deltaT = ACE_time - _lastTime;
|
||||
(_this select 0) set [0, ACE_time];
|
||||
_args set [0, ACE_time];
|
||||
_deleted = 0;
|
||||
_isWind = (vectorMagnitude ACE_wind > 0);
|
||||
|
||||
|
@ -22,6 +22,7 @@ Keeping track of Arma 3 issues that need to be fixed. If you want to support us
|
||||
* [James2464: 0023725: All Environment Rocks Should Have PhysX LODs](http://feedback.arma3.com/view.php?id=23725)
|
||||
* [Jaynus: 0023679: Display event handler return values for mouse buttons should be respected](http://feedback.arma3.com/view.php?id=23679)
|
||||
* [Heisenberg: 0023741: Switching between optic modes of a sniper scope (AMS, DMS, MOS) will result in a blurred vision](http://feedback.arma3.com/view.php?id=23741)
|
||||
* [AgentRev: 0022310: setObjectTextureGlobal causing "Cannot load texture" errors when used with valid mission files](http://feedback.arma3.com/view.php?id=22310)
|
||||
|
||||
**Resolved:**
|
||||
|
||||
|
@ -78,6 +78,12 @@ Slide duration | 0 (0 = disabled, number is in seconds)
|
||||
- Only objects with hiddenSelection 0 can be used as "screens".
|
||||
- If you set a duration the remotes will be disabled. (If the remotes are disabled `ace_interaction` is not needed)
|
||||
- You can have multiple sets of images on different screens, see the advanced slideshow below.
|
||||
- It is advisable images resolution sizes are powers of 2 (eg. 512x512) to avoid graphical glitches in them.
|
||||
|
||||
<div class="panel callout">
|
||||
<h5>Note:</h5>
|
||||
<p>Mission MUST be in a PBO format (not bare folder) when used on a dedicated server due to an [issue](http://feedback.arma3.com/view.php?id=22310) to prevent errors.</p>
|
||||
</div>
|
||||
|
||||
### 3.2 Basic slideshow
|
||||
*A set of 4 images that are swapped via a remote*
|
||||
|
Loading…
Reference in New Issue
Block a user