-
Notifications
You must be signed in to change notification settings - Fork 735
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
CSW - Remove 'Disabled' option from Ammo Handling #9322
base: master
Are you sure you want to change the base?
CSW - Remove 'Disabled' option from Ammo Handling #9322
Conversation
Implemented #9322 (comment) |
I think we just need to add a new I don't like how the mk6 setting could disable assembly the logic before was
if we're getting rid of the disabled setting, then it should just always be on |
// Skip if CSW is explicitly disabled (assemblyMode = 0) | ||
if ((_vehicle getVariable [QGVAR(assemblyMode), 3]) == 0) exitWith {_return}; |
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.
// Skip if CSW is explicitly disabled (assemblyMode = 0) | |
if ((_vehicle getVariable [QGVAR(assemblyMode), 3]) == 0) exitWith {_return}; | |
// Skip if CSW reload is explicitly disabled | |
if (_vehicle getVariable [QGVAR(reloadDisabled), false]) exitWith {_return}; |
if ((GVAR(ammoHandling) == 0) && {!([false, true, true, GVAR(defaultAssemblyMode)] select (_target getVariable [QGVAR(assemblyMode), 3]))}) exitWith { false }; | ||
[_player, _target, ["isNotSwimming", "isNotSitting"]] call EFUNC(common,canInteractWith) | ||
// If CSW isn't disabled for this static we enable ammo handling | ||
((_target getVariable [QGVAR(assemblyMode), 3]) != 0) && |
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.
((_target getVariable [QGVAR(assemblyMode), 3]) != 0) && | |
(!(_target getVariable [QGVAR(reloadDisabled), false])) && |
@@ -88,7 +88,7 @@ if (hasInterface && {!(_typeOf in GVAR(initializedStaticTypes))}) then { | |||
_ammoActionPath = [_typeOf, 0, ["ACE_MainActions"], _ammoAction] call EFUNC(interact_menu,addActionToClass); | |||
}; | |||
|
|||
if (["ACE_reload"] call EFUNC(common,isModLoaded)) then { | |||
if (["ACE_reload"] call EFUNC(common,isModLoaded) && {(_target getVariable [QGVAR(assemblyMode), 3]) != 0}) then { |
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.
if (["ACE_reload"] call EFUNC(common,isModLoaded) && {(_target getVariable [QGVAR(assemblyMode), 3]) != 0}) then { | |
if (["ACE_reload"] call EFUNC(common,isModLoaded) && {!(_target getVariable [QGVAR(reloadDisabled), false])}) then { |
I like the idea of ammo handling being completely separate from assemblyMode. I originally wanted to do that just that. I have another idea in mind but I'll make a spin-off to the CSW PR saga as code is easier to read. |
Currently testing 9234. To me, it doesn't make sense to keep |
When merged this pull request will:
Ammo Handling for players is now available solely based on the weapon's assembly mode:
assemblyMode
set to anything other than0
will have ammo handling enabled.assemblyMode
set to0
will not use any of CSW's systems.IMPORTANT
Component - Add|Fix|Improve|Change|Make|Remove {changes}
.