Phobos icon indicating copy to clipboard operation
Phobos copied to clipboard

Warhead / weapon detonation at superweapon target cell

Open Starkku opened this issue 3 years ago • 1 comments

GenericWarhead SW substitute (that works in tandem with any SW type) with proper support for all weapon / warhead features.

Code for the feature itself is pretty simple, however proper support for determining which building fired the SW required porting over large amount of helper functions from Ares 0.A though. As a result the weapon / warhead is considered to be fired by the building that fired the SW, which supports SW.RangeMinimum/Maximum etc (same as GenericWarhead SW).


Warhead or Weapon detonation at target cell

  • Any superweapon can now detonate a Warhead or a weapon at superweapon's target cell.
    • If both Detonate.Warhead and Detonate.Weapon are set, latter takes precedence.
    • Detonate.Damage, if not set, defaults to weapon ´DamageforDetonate.Weaponand 0 forDetonate.Warhead`.
    • Both the weapon and Warhead behave as if fired by whatever building fired the Superweapon. This respects controls like SW.RangeMinimum/Maximum (similar to Ares' GenericWarhead superweapon in this regard).

In rulesmd.ini:

[SOMESW]           ; Super Weapon
Detonate.Warhead=  ; Warhead
Detonate.Weapon=   ; WeaponType
Detonate.Damage=   ; integer

Starkku avatar Sep 30 '22 17:09 Starkku

Nightly build for this pull request:

github-actions[bot] avatar Sep 30 '22 17:09 github-actions[bot]