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

Overhauling torpedo interactions #5000

Merged
merged 10 commits into from
Jun 7, 2023

Conversation

Garanas
Copy link
Member

@Garanas Garanas commented May 30, 2023

Closes #4979 and related to #3969

Torpedo bombers

All projectiles dropped by Torpedo Bombers now interact with anti torpedo defenses. This includes both the projectile-based and the flare-based anti torpedo defenses. All torpedo bombers drop their ordinance in a similar arc as strategic bombers.

One exception is that when aiming a torpedo bomber aims on the current position of the unit instead of aiming where the unit is predicted to be when the projectiles impacts. This is done to guarantee a valid firing solution so that all torpedo bombers will always drop their ordinance.

Ordinance dropped by torpedo bombers have their velocity reset as they hit the water surface. This prevents the projectile from immediately impacting with the ocean floor when the water is too shallow. The projectile accelerate to full speed in about 3 to 4 seconds.

Torpedo behavior

All projectiles that are considered a torpedo have their properties standardized, with minor factional differences. They used to be all over the place. Roughly speaking:

  • For all factions: each projectile has an acceleration range of 2, with a base acceleration of 5. As a result the acceleration of a projectile is any value between <3, 7>, This prevents the uncanny effect where multiple torpedo's follow the exact same trajectory. All projectiles have a minimum life time of 10 seconds, ordinance from torpedo bombers have a minimum life time of 15 seconds
  • Cybran faction: each torpedo has a turn rate of 180 and a minor 'zig zag' factor.
  • UEF Faction: each torpedo has a turn rate of 165 and a minor 'zig zag' factor.
  • Aeon faction: each torpedo has a turn rate of 190 and a decent 'zig zag' factor.
  • Seraphim faction: each torpedo has a turn rate of 200 and no 'zig zag' factor.

Flare-based torpedo defenses

All flare-based torpedo defenses now have a maximum number of torpedo's that they can redirect.

Projectile-based torpedo defenses

All projectile-based torpedo defenses act in a similar, smart fashion to tactical missile defenses where they try to not overshoot a single torpedo.

Other changes

Fixes all sorts of inconsistencies across the code base, including but not limited to:

  • Wrong base class
  • Lack of use of effects
  • Improper use of effects
  • Duplicated code across the hierarchy
  • Missmatch of sound with number of projectiles

@Garanas Garanas linked an issue May 30, 2023 that may be closed by this pull request
@Garanas Garanas added the area: balance related to units balance label May 31, 2023
@Garanas Garanas changed the title Working on UEF torpedo's Overhauling torpedo interactions Jun 1, 2023
@Garanas Garanas added this to the Balance iteration I milestone Jun 7, 2023
@Garanas Garanas marked this pull request as ready for review June 7, 2023 16:00
@Garanas Garanas merged commit e6e91b6 into deploy/fafbeta Jun 7, 2023
@MrRowey
Copy link
Member

MrRowey commented Jun 7, 2023

@Garanas could have given me a heads up going to be fun adding this to the patch notes 🤣

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: balance related to units balance feature: anti projectile weaponry related to torpedo and tactical defense weapons
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Balance idea: Torp Bomber Anti Torp Interaction
2 participants