A few discussions recently(ok forever) have been talking about relative weapon value and also difficulty in getting weapons to shoot at the things that they should be shooting at. Most proposed solutions run up into balance issues or run into AI complexity issues.
The main problem is that both weapons and the AI needs to be generic enough to deal with randomized fits while also having as small a managerial impact on players. Players already have an advantage in the ability to make their own fits and prevent all randomization; giving them the advantage to being able to tweak individual weapon AI at the same time would make them that much more powerful while increasing the players managerial load*.
The obvious, oft proposed, and wrong answer to this is to tweak individual weapon AI that makes them ignore certain classes of targets when they're on auto-fire. But this has problems of its own. Weapons may need to fill multiple roles on different ships and they may need to fill those roles when on auto-fire. I've long used Assault Chainguns as anti-fighter on capital ships even before the buff. But a change that made them ignore fighters would impact my playstyle and a change that made them prioritize fighters would impact the playstyle of someone who wanted to use them with safety overrides.... It could also impact the effectiveness of a randomized ship that had AC's fit in its main slots while also fielding a lot of other PD type weapons. The AI could either think its all anti-fighter and so never close with an enemy thinking its unarmed. Or it might crash the boards and then not shoot at the target in front of its face because it was distracted.
There is a solution i think that can fix things in general without too much issue. It would make all ships much more combat effective and prevent a lot of bad AI behavior. And its an accuracy clutch**. When deciding whether or not to fire a weapon the AI would use more or less the same routines it currently uses with one exception. If its current targets available cross section is smaller than its current recoil adjusted accuracy by enough of a percentage it prevents the weapon from firing. What the percentage value would have to be to work i am not sure (different weapons could have different clutches but this would require more tweaking) but i am reasonably positive that this would fix a lot of issues players currently have with weapons and their behavior in the game
This has the advantages of
- Allowing even highly inaccurate weapons to be used as point defense at significantly reduced DPS
- Preventing highly inaccurate weapons from dumping flux at targets they cannot hit
- Preventing ammo limited weapons from dumping rounds into the void
- Continuing to allow highly agile ships to utilize their mobility to avoid fire
- Allowing weapons to be more effectively balanced against various target types using accuracy, recoil, and shot velocity
- Benefiting all ships evenly with minimal AI, managerial, and design overhead
Additionally (and not necessarily) this could make it easier to implement AI routines which do have a semblance of "smartness" to them. A clutched weapon might search for a new target that it would not be clutched against and a non-clutched weapon might shoot continually at the first target it acquired. In this way point defense/anti-fighter weapons wouldn't stop being anti-fighter as soon as a frigate showed up and would get less confused against fighters and other fast moving ships in general preferring to focus a target down rather than switch to whatever is closest.
Edit: As an example of how this would work. I assume that the game knows
A) The distance to the target ship (Because it reports this to the player)
B) The size of the target ships hit box (because it has to know both what its shooting at and that object must be loaded into memory)
C) The current accuracy angle of the weapon.(Because it reports this to the player by drawing it on the weapon)
If i know the distance to the target ship and the size of the target ship then then getting the angle of the arc of the target ship is simple using the inverse tangent of the radius of the ship/Distance and multiplying by 2. If you then divided by the current accuracy angle of the weapon this would give you a percentage equal to the amount of effective accuracy(as if shooting at an unmoving target). If that was say, lower than 50%, the weapon stops firing. If it was greater than 50% the weapon starts firing again. Weapons that fire in a burst could calculate based on the last bullet that the burst would fire(which should also be easy to figure). Oblate ships make things a little more complicated because they have variable presented sides. But the game could use the larger or the smaller radius of the oval without too much of an issue.(except for maybe the Odyssey)
As an example. Lets say that a HAG is shooting at a Medusa and the game has an accuracy clutch of 70%. The medusa is at 1000 range and (lets suppose) it has a radius of 50. Twice the inverse tangent of 50/1000 is equal to 5.72 degrees. So the HAG would shoot at the Medusa until such a time as as its accuracy angle was lower than 8.18 degrees. If the medusa moved closer, to 500 range, then the HAG would fire until its accuracy angle was 16.3 degrees. At max range(1400) the accuracy clutch would stop the weapon firing at 5.84 degrees.
The clutch isn't going to figure for projectile speed. Its still trying to lead the target as normal. So agile ships still get to avoid. Its just saying "if i shoot this what is the probability that i hit given that i accurately lead and the target continues its trajectory"? And if it comes up with "utter shite" it stops shooting.
*And this is bad. Think about a game like Divinity:OS and all the management you needed to do for all the characters in order to set up things how you wanted. Now instead think of a game like slay the spire, which has similar complexity in its deck building to D:OS's characters but enforces a lack of management except incrementally. Slay the Spire is an amazing game that is super easy to replay and Divinity:OS, while still a good game, is not easy to replay because its managerial load isnt constrained in a way that prevents it from becoming onerous.
**For those unaware of the term. "clutch" means to "grasp tightly" and is used in many different and seemingly disparate situations. A clutch in a car engages/disengages the transmission from the engine by "grasping tightly". A person who is clutch "grasps tightly to opportunity" in high pressure situations. To clutch a variable means to control that variable tightly. So in this situation the idea is that the weapon stops firing when its accuracy gets low in order to tightly control is accuracy.