Skip to content
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

"shots" calculation error #99

Open
haifron opened this issue Nov 27, 2022 · 0 comments
Open

"shots" calculation error #99

haifron opened this issue Nov 27, 2022 · 0 comments

Comments

@haifron
Copy link

haifron commented Nov 27, 2022

The calculation for number of shots for a weapon with a projectile that splits
(https://github.com/FAForever/spooky-db/blob/master/app/js/UnitDecorator.js#L190)
should be
shots = shots * projectileMultiplierLookup[weapon.ProjectileId];
not
shots = projectileMultiplierLookup[weapon.ProjectileId];

This would fix the niche case of the Solace, which fires multiple splitting projectiles. (It is the only unit with splitting projectiles that has MuzzleSalvoSize > 1).

At the moment:
shots = split amount

With the fix:
shots = projectiles fired per reload * split amount

PS:
Prior to #98, solace's calculation was:
shots = projectiles fired per reload.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant