Snap
Westwood implemented a multi-stage target snap system through three key functions that control projectile coordinate correction: In-Flight Snap optimizes ballistic trajectory in real-time, Pre-Explosion Distance Correction performs close-range position calibration, and Pre-Explosion State Correction makes final adaptations based on target state; each stage's activation is strictly constrained by projectile properties (Airburst/Inaccurate/EMEffect), target characteristics, and dynamic parameters, with specific behavioral differences detailed below:
| Phase Function | Activation Conditions | Additional Requirements | Final Effect | ||
|---|---|---|---|---|---|
| In-Flight Snap | Airburst=no && Inaccurate=no | Projectile is about to detonate OR velocity>=128 OR velocity * 2 > distance to target | Snaps the projectile to the target's location | ||
| Pre-Explosion Distance Correction | Airburst=no && Inaccurate=no | Distance between projectile and target < 32 leptons | Corrects explosion coordinates to target's current location | ||
| Pre-Explosion State Correction | Airburst=no && EMEffect=no | Distance[1] between projectile and target < 42 leptons (with compensation for buildings as in footnote) | Non-Building Targets | Alive | Target entity center |
| Dying (in death sequence) | Follows death animation position | ||||
| Dead | Corpse position | ||||
| Building Targets | Alive | Target entity center | |||
| Destroyed | Center of rubble | ||||
Examples
EMEffect=yes, others=no:
- In-flight snap still works (does not depend on EMEffect)
- Explosion coordinates are corrected at close range (<32 leptons)
- State correction is skipped
Airburst=yes, others=no:
- All snap functions are disabled
- Projectile follows air burst logic
Inaccurate=yes, others=no:
- In-flight and close-range snap are disabled
- State correction (including building rubble) still works
Bugs/Side-Effects/Unexpected Limitations
For projectiles with Inviso=yes, these condition checks are redundant and can introduce accuracy issues when conditions are not met.
- This bug has been fixed in Phobos Build#30.
Footnotes
- ↑
If the target is a BuildingType, the distance check is compensated based on its Foundation settings.
The distance value used in the check = original distance - 64 * (FoundationWidth + FoundationHeight)