-
Notifications
You must be signed in to change notification settings - Fork 740
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pylons - Fix old weapons not being removed #6100
Conversation
Fix #6088 - Use removeWeaponTurret instead of removeWeaponGlobal - Fix "Too Far" warning showing on completion
addons/pylons/XEH_postInit.sqf
Outdated
{ | ||
if (_aircraft turretLocal _x) then { | ||
TRACE_3("removing",_aircraft,_x,_removeWeapon); | ||
_aircraft removeWeaponTurret [_removeWeapon, [-1]]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[-1]
-> _x
? I didn't test yet but it looks strange.
@@ -149,7 +149,10 @@ if (!GVAR(isCurator)) then { | |||
isNull (GVAR(currentAircraft) getVariable [QGVAR(currentUser), objNull]) || | |||
{(ace_player distanceSqr GVAR(currentAircraft)) > GVAR(searchDistanceSqr)} | |||
}, { | |||
[localize LSTRING(TooFar), false, 5] call EFUNC(common,displayText); | |||
TRACE_3("disconnect/far",GVAR(currentAircraft), ace_player distance GVAR(currentAircraft),GVAR(currentAircraft) getVariable QGVAR(currentUser)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a rogue space in the macro.
|
||
// Remove the weapon of current pylon from aircraft IF weapon is only on this pylon | ||
private _removeWeapon = ""; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe call it _weaponToRemove
?
Co-Authored-By: Ozan Eğitmen <[email protected]>
* Pylons - Fix old weapons not being removed Fix #6088 - Use removeWeaponTurret instead of removeWeaponGlobal - Fix "Too Far" warning showing on completion * Fix _x * Fix var name Co-Authored-By: Ozan Eğitmen <[email protected]>
Fix #6088
Tag @654wak654
I have no idea why
removeWeaponGlobal
doesn't work for pilot seat of some RHS helis, butremoveWeaponTurret
works just fine.