lisongmechlab / lsml

Li Song Mech Lab
http://lisongmechlab.github.io/lsml/
GNU General Public License v3.0
42 stars 6 forks source link

incorrectly named function in LSML code 'canDoubleFire' #777

Closed sestrand closed 2 years ago

sestrand commented 2 years ago

LSML version: 2.0.14 Screen resolution: 3440x1440 Java version: 8u330

In the lsml code, canDoubleFire() in BallisticWeapon.class returns true if jamming chance is not zero. this is not really the definition of the value and I think it has lead to some potential misinterpretation or misuse in the code in other spots. I do not think we can guarantee that jamming chance will always be >0 for all UACs. and in the code, RAC behavior is tied to this being true as well... I think this boolean should have a different name...

canDoubleFire() is also potentially incorrect both for which class it is applied to and the name itself. While the value in the PGI files for ShotsDuringCooldown currently sits in only autocannons and always has a value of 1... this does not mean PGI will leave it as 1. or just to UACs.

LiSongMWO commented 2 years ago

I've fixed this in commit 713a19352aa8b4462f0801cd5c29b43ca98791a7