If you have a Virtual Arsenal loadout that includes a weapon with default components then you cannot load that loadout from a Virtual Arsenal that contains all the necessary pieces. {F24870} {F24871} {F24872}
Description
Details
- Legacy ID
- 2318809310
- Severity
- None
- Resolution
- Open
- Reproducibility
- Always
- Category
- Virtual Arsenal
For example:
- Create a unit and an arsenal box.
- Add the following items to the Virtual Arsenal:
Weapons: ["arifle_MX_F"]
Magazines: ["30Rnd_65x39_caseless_mag", "30Rnd_65x39_caseless_mag_Tracer"]
Items: ["optic_Arco", "acc_pointer_IR", "muzzle_snds_H"]
- Remove EVERYTHING from the unit and then give them the "arifle_MX_RCO_pointer_snds_F"
- Have the unit open arsenal, and save their loadout (with the "arifle_MX_RCO_pointer_snds_F" still selected)
- Leave arsenal and re-open.
- Attempt to load the saved loadout from (4).
Notice that the saved loadout is unloadable even though all the required items for "arifle_MX_RCO_pointer_snds_F" are present (the rifle, ammunition and accessories).
If you continue on:
- Remove the weapon from the player in the Virtual Arsenal
- Equip the MX rifle along with the optics, pointer, and silencer (creating the same rifle loadout as arifle_MX_RCO_pointer_snds_F)
- Save this loadout under a different name in the Virtual Arsenal
- Go to the 'Load' menu
Notice that now the loadout from (9) can be loaded successfully, but the loadout from (4) is still unloadable.
This behaviour is extremely confusing to users (since the box contains all of the required items) and makes it appear that their loadouts aren't saved correctly or that Arsenal is malfunctioning.
Easy to repro in attached example mission with provided loadout. Simply walk to arsenal box, save current loadout and try to reload. If you reconstruct the weapon with items from the box it suddenly becomes loadable.
The user should be able to load their items from the Virtual Arsenal if the required components are present.
At a minimum Arsenal should either:
- warn you when attempting to save a loadout from a box that doesn't contain all the necessary items for it to be re-loaded (i.e. the user would be warned at step (5) that they are saving a loadout on a box that doesn't contain the necessary items)
- inform you about which required items are missing when preventing you from loading a saved loadout
or
- allow you to override the behaviour (through a dialog or something) and load the items that are present anyways - ignoring things it can't load. Something like displaying a warning symbol and tooltip beside loadouts that are only partially available in the 'Load' menu would be sufficient.
It would also be less of an issue if the default unit loadouts actually used separate components for their weapons instead of the composite weapons.
Event Timeline
Better version of example.
Also it appears you cannot load a saved Virtual Arsenal loadout that contains a composite weapon even if that weapon is in the box.
I encountered this same issue, specifically I wasn't able to load loadouts that contained a "composite" weapon, even if I added that composite weapon to the whitelist.
This is down to the fact that in fn_arsenal.sqf, #define GETVIRTUALCARGO uses baseWeapon on each item. When changing the line in question (fn_arsenal.sqf:117) to "_weapon = _x;\" (note the lack of calling baseWeapon on _x) the arsenal performs as expected.
Since I didn't really look to deeply into the rest of the system this might break something subtle...but I haven't noticed anything yet.
The displayed list is still "clean" from multiples since that is checked differently.
I've "fixed" this for myself by overwriting fn_arsenal.sqf with a version that has that line changed via a small addon, which I've attached ["fixedArsenal.7z"] (folder name and config.cpp are inconsistent, so if you want to use it, update config.cpp and pbo it).
Hopefully this (or a more 'thoughtful' fix) makes it into the game soon :)
"Composite" weapons break the system, that is why they were removed after the initial release of the Virtual Arsenal. I highly recommend creating gear loadouts from scratch, rather than using weaponry that is already equipped with sights and or other attachments.
Drakeziel, what's the reason to defend shortcomings and obvious bugs of VA?
Players saving "composite" weapons is quite normal...
If you add an attachment to a weapon that has an attachment, it breaks the system, because it changes the classname... You can't save a loadout with a composite weapon and then change the attachment, it will essentially change the whole weapon. Thus breaking the system [script, init, etc]
You're half-right, Drakeziel.
It is true that 'pre-made composite' weapons are, by definition, weapons with classnames different from their base weapon. E.g. arifle_MX_pointer_F
However no weapon ever changes classname when you attach /detach something to it. Arma3 can happily have an arifle_MX_pointer_F gun and attach a flashlight/silencer/nothing/etc to it.
Also, taking a base weapon (arifle_MX_F) and adding a laserpointer does not turn it into an arifle_MX_pointer_F.
All this issue comes down to is that bis_fnc_arsenal calls bis_fnc_baseWeapon at a time where it shouldn't.
If you had read the comments above you, you'd know that composite weapons aren't some magic that inherently break Arma3, since I've posted that this bug can be resolved with a one-line change in bis_fnc_arsenal.
(Check out @Fixed_Arsenal for a mod that implements, among many other things, this fix)