Immersive Vehicles (Formerly Transport Simulator)

Immersive Vehicles (Formerly Transport Simulator)

4M Downloads

[Enhancement] Variables for missile incoming

gyrohero opened this issue ยท 6 comments

commented

This would allow for instruments that provide a warning if the vehicle is being tracked by a missile. There would be 3 variables: missile_incoming (Boolean), missile_direction (float), and missile_distance (float). If there are multiple missiles incoming, this could be limited to whichever is closest, or possibly be numbered to allow a certain number of alerts.

For implementation, the missile would just have to pass a pointer of itself to the vehicle it's locker onto, simulating its laser or radar signature.

commented

I was thinking that too about the sound thing. Alright, cool.

commented

Should be simple. And would be good as you could link it to an animation for an in-cockpit warning sound. When I get to overhauling the instruments to work with the VAS, then the instrument can play the sound, so it'll be cross-compatible with different vehicles.

commented

WOMP WOMP WOMP
Would this theoretically allow chaff or flares to be automatically deployed as well, once that's added?

commented

@fsendventd Yeah, we can probably set it up so that they deploy based on JSON-defined clamps of the distance/direction variables

commented

I hesitate to have flares automatically deploy. If only because there's not really a point in having missiles that home and lock on if they just automatically get chaffed. Plus, having chaff be part of the VAS is kinda icky. Unless you mean a parameter, but even then, if you have a lock-on variable then that can correlate to chaff deployment without messing with variables.

commented

@DonBruce64 You would eventually run out of flares, they'd have ammo like guns. Plenty of other games (e.g. War Thunder) have automatic flare deployment in certain vehicles, it isn't overpowered.