Skip to content

Commit

Permalink
fixes _gun variable
Browse files Browse the repository at this point in the history
fixes _gun variable
Updated german text
  • Loading branch information
nk3nny committed Feb 18, 2024
1 parent 4b8e9b4 commit 6aff806
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
11 changes: 5 additions & 6 deletions addons/wp/functions/fnc_taskArtilleryRegister.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -36,21 +36,20 @@ if (_artillery isEqualTo []) exitWith {false};

// check for MLRS
{
private _gunner = gunner _x;
private _assignedRoles = assignedVehicleRole _gunner;
private _assignedRoles = assignedVehicleRole (gunner _x);

// gunner doesn't have a proper turret!
if ((count _assignedRoles) < 2) then {
_gun setVariable [QEGVAR(main,isArtilleryMRLS), false];
_x setVariable [QEGVAR(main,isArtilleryMRLS), false];
} else {
// get the callout for what this vehicle shoots!
private _turretPath = _assignedRoles select 1;
private _turret = (_gun weaponsTurret _turretPath) select 0;
private _turret = (_x weaponsTurret _turretPath) select 0;
private _nameSound = getText (configFile >> "CfgWeapons" >> _turret >> "nameSound");
if (_nameSound isEqualTo "rockets") then {
_gun setVariable [QEGVAR(main,isArtilleryMRLS), true];
_x setVariable [QEGVAR(main,isArtilleryMRLS), true];
} else {
_gun setVariable [QEGVAR(main,isArtilleryMRLS), false];
_x setVariable [QEGVAR(main,isArtilleryMRLS), false];
};
};
} forEach _artillery;
Expand Down
2 changes: 1 addition & 1 deletion addons/wp/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
</Key>
<Key ID="STR_Lambs_WP_Module_TaskArtillery_MainSalvo_Tooltip">
<English>Number of rounds in the main salvo. MLRS artillery ignore this value.</English>
<German>Anzahl an Schüssen der Hauptsalve.</German>
<German>Anzahl an Schüssen der Hauptsalve. MLRS-Artillerie ignoriert diesen Wert.</German>
</Key>
<Key ID="STR_Lambs_WP_Module_TaskArtillery_Spread_DisplayName">
<English>Spread</English>
Expand Down

0 comments on commit 6aff806

Please sign in to comment.