ACE3
ACE3 copied to clipboard
CSW - Add CSW ammo handling to wheeled vehicles
When merged this pull request will:
- Add ammo handling to the vehicle's interaction menu
- Adds a few more ammo types that these vehicles require
- This support was extended to SOG and RHS compats. I would do more but I don't own any other CDLCs
- The new csw turrents all got custom load and unload times.
- magazine locations were left on the vehicle, but they can be moved else were if someone has the time to find the correct name selections for about 75 objects (<- maybe someone who has a lot more free time then me)
- stringTables where added, translations will be needed later
- SOG got two more ui pictures, one for zpu and one for m40 ammo
- RHS slap ammo was added to CSW but only the 400 count for crows weapon systems
Videos of use https://youtu.be/biR3zFmbXpU
November 1st 2022 Update Video https://youtu.be/mUeDi7owfO4
here are svgs of the inheritance that I used
All the cDLC's have a compatibility data mod in the Workshop for those who don't have the cDLC, the diff being it's only good for joining the multiplayer and checking the stuff out in Arsenal, if the descriptions can be trusted.
yeah I'm a bit iffy on compatibility data, the only one that I trust is the sog one.
Without code changes this is dirty implementation.
Reload should be only from turret seat. On some vehicles only turned out. In your video at 1:03 SPG auto reloaded. As I understand ammo not removed/unloaded from turret on spawn. I think vehicle inventory can not be used for loading/unloading mags in this implementation. Will work only from/to backpack?
Also in theory some mags should be interchangeable between vehicle and player's weapon. For example M240.
I think vehicle inventory can not be used for loading/unloading mags in this implementation. Will work only from/to backpack?
bd396d1 Added support for getting ammo out of the vehicle, but originally this work already if you had ammo in the vehicle because CWS uses nearestSupplies for searching. [PR here] (https://github.com/acemod/ACE3/pull/8776)
Also in theory some mags should be interchangeable between vehicle and player's weapon. For example M240.
m240 is defined that way. https://github.com/acemod/ACE3/blob/a088e717af24b8988f7b1c41e713030b9d0b8cac/optionals/compat_rhs_usf3/CfgMagazineGroups.hpp#L27 There is actually multiple of those in the magazinegroups.
Reload should be only from turret seat. On some vehicles only turned out.
I disagree on that idea. If the weapon is out in the open and I can see it and physically touch it then why should I not be able to operate it like a regular static weapon. The difference is that one weapon is attached to wheel while the other is not.
In your video at 1:03 SPG auto reloaded
Turrets auto reload when empty or unload. I believe that is a base game feature.
I disagree on that idea. If the weapon is out in the open and I can see it and physically touch it then why should I not be able to operate it like a regular static weapon. The difference is that one weapon is attached to wheel while the other is not.
IRL you can't reach a gun from ground on any vehicle. Even on pickup. Also IRL some weapons only reachable from certain(not always gunner) seats. Reload from anywhere feels like exploit.
ammo handling to wheeled vehicles
What is wrong with tracked?
My intent was just Wheeled vehicles. I don't have plans to expand this pr. It's already big enough for review.
imo I don't like the mix of the vanilla system of storing extra ammo. Spawning a vehicle with 3 extra mags, but only being able to unload them and never reload feels really weird to me. I think it'd be better to have a onInit handler that removes all the compatible default ammo and switch them to CSW mags in the inventory whenever the system is enabled.
That's a genius idea!
imo I don't like the mix of the vanilla system of storing extra ammo. Spawning a vehicle with 3 extra mags, but only being able to unload them and never reload feels really weird to me. I think it'd be better to have a onInit handler that removes all the compatible default ammo and switch them to CSW mags in the inventory whenever the system is enabled.
Moving the magazines to inventory may break loadouts for existing missions.
Moving the magazines to inventory may break loadouts for existing missions.
Was there not a way to go over the cargo space limit?
yeah, I know addItemCargoGlobal will do that
Moving the magazines to inventory may break loadouts for existing missions.
Was there not a way to go over the cargo space limit?
addItemCargoGlobal will do it as killerswin2 says, but that's still problematic as a full inventory prevents players from putting things into the inventory during gameplay.
For example, if the vehicle has a toolkit and is overfilled with CSW ammo, I take the toolkit to repair the vehicle, now I cannot put the toolkit back in the vehicle.
setMaxLoad to compensate for the additional items?
Still preferable to the current mix of vanilla and inventory
setMaxLoadto compensate for the additional items?Still preferable to the current mix of vanilla and inventory
That could work, get normal inventory capacity, get mass of all vehicle magazines, setMaxLoad to the total, add the vehicle magazines
Alright, implemented. It's a option. If players don't want it they can have it turned off.
Linking a belt from a vehicle inventory deletes the magazine and breaks the link condition.
I don't have any time to do this pr for the next three weeks.
someone else, will have to implement changes and bring this up to standards
We'll get to this.