Jump to content

Radar detection trigger in mission editor


Black6
 Share

Recommended Posts

Hi, I miss a trigger in mission editor, which would react on target detection (radar/visual). I imagine something similar like "unit/part of group/ part of coalition in zone" in combination with specific unit.
e.g. IF unit(radar) DETECTS unit(target)/part of group/part of coalition DO ....

 

I´am trying to bypass it by lua script, but without any succes yet 😞

  • Like 3
Link to comment
Share on other sites

+1. That'd be very useful for missions where avoiding detection is critical.

The vCVW-17 is looking for Hornet and Tomcat pilots and RIOs. Join the vCVW-17 Discord.

1197644828_Screen_200911_044202-Copy.png.74d8c09ee9060cffd7408a75ab2c13ef.png

HP Reverb G2, Z370 Aorus Gaming 7, i7-8700K, 3090 FTW3 Ultra, 32GB DDR4, 960 Pro, 970 Evo Plus, WD Gold 6TB, Seasonic Prime Platinum

F/A-18C, AV-8B, JF-17, A-10C (C II), M-2000C, F-16C, F-14, BS2, UH-1H, P-51D, Sptifire, FC3

Link to comment
Share on other sites

16 minutes ago, Black6 said:

Hi, I miss a trigger in mission editor, which would react on target detection (radar/visual). I imagine something similar like "unit/part of group/ part of coalition in zone" in combination with specific unit.
e.g. IF unit(radar) DETECTS unit(target)/part of group/part of coalition DO ....

 

I´am trying to bypass it by lua script, but without any succes yet 😞

 

Hi, here is an example with DCS script. It uses this function DCS func isTargetDetected - DCS World Wiki - Hoggitworld.com

 

In my example the RWR detection of SAM site radar by a wingman is evaluated every seconds, and displays a message when the SAM is RWR detected (which also stops the evaluation).

 

You can adapt it to your need (name of "target" unit to be detected, name of "detecting" unit, and type of detection : radar, visual, etc...), also the "do" function when detected in my example is in the script, but you can change the line that displays text to instead activate a flag - example trigger.action.setUserFlag( "2", true ) , and then add a trigger to do whatever you want when the flag n°2 gets activated.

test-RWR-detection-message.miz

  • Thanks 2
Link to comment
Share on other sites

55 minutes ago, toutenglisse said:

 

Hi, here is an example with DCS script. It uses this function DCS func isTargetDetected - DCS World Wiki - Hoggitworld.com

 

In my example the RWR detection of SAM site radar by a wingman is evaluated every seconds, and displays a message when the SAM is RWR detected (which also stops the evaluation).

 

You can adapt it to your need (name of "target" unit to be detected, name of "detecting" unit, and type of detection : radar, visual, etc...), also the "do" function when detected in my example is in the script, but you can change the line that displays text to instead activate a flag - example trigger.action.setUserFlag( "2", true ) , and then add a trigger to do whatever you want when the flag n°2 gets activated.

test-RWR-detection-message.miz 8.64 kB · 3 downloads

I have to switch to 2.7. This will take some time. Could you replace F-18 by F-16 or F-5? I don´t have this module.

Thanks

Link to comment
Share on other sites

3 minutes ago, Black6 said:

I have to switch to 2.7. This will take some time. Could you replace F-18 by F-16 or F-5? I don´t have this module.

Thanks

 

You can open the mission file in mission editor, click on the F-18 group and change the type from hornet to whatever you want and save (it just needs that the unit/pilot names remain the same for the script to work).

Link to comment
Share on other sites

+99999999999999999999

 

This would also be very useful for SAM sites - whether or not they are able to detect an incoming missile (likely to be an ARM) and shut down. At the moment I have to take a guess at what range a particular RADAR would be able to detect one and shut down.

Modules I own: F-14A/B, F/A-18C, Supercarrier, F-16CM, AJS-37, F-5E-3, MiG-21bis, Ka-50, A-10C (+ A-10C II), UH-1H, Mi-8MTV2, P-47D, P-51D, FC3, MiG-15bis, Yak-52, CA, C-101, Hawk

Terrains I own: Syria, The Channel, SoH

 

System (RIP my old PC): Dell XPS 15 9570 w/ Intel i7-8750H, NVIDIA GTX 1050Ti Max-Q, 16GB DDR4, 500GB Samsung PM871 SSD (upgraded with 1TB Samsung 970 EVO Plus SSD)

 

VKB Gunfighter Mk.II w. MCG Pro

 

Dreams: https://uk.pcpartpicker.com/list/mBG4dD

Link to comment
Share on other sites

8 hours ago, Northstar98 said:

+99999999999999999999

 

This would also be very useful for SAM sites - whether or not they are able to detect an incoming missile (likely to be an ARM) and shut down. At the moment I have to take a guess at what range a particular RADAR would be able to detect one and shut down.

 

Hi, the "Controller.isTargetDetected" function also work with weapon detection.


Here is a mission example (using Mist because of event handler that I'm only able to make work with Mist...) with 1) a event handler that detects HARM shot and track it for the SAM SR unit's radar detection, 2) a detection function that makes SAM SR unit to go GREEN state (radar off) for 45 seconds (can be changed) when a HARM is detected (with a defined delay to turn GREEN), then go back to RED state and start again detection (with a defined delay to restart detection).


It works very well, but you need to tweak the different "defined delays" to makes SAM SR unit's survivability to varie from "untouchable" to "easy to kill with HARM". (if delays are 1 seconds for : HARM detection / GREEN STATE, and RED STATE / start again to detect, or if delay between GREEN and back to RED state is long enough, then the unit will be untouchable by HARM ! Can only be disabled by GPS glide bomb launched during GREEN state for example)


In my example I've put a short 45 seconds delay between GREEN and back to RED states, and a 30 seconds delay between RED STATE / start again to detect, so if HARM is still in position to track again when SAM SR goes RED and close enough to reach it within 30 seconds, it will hit it. The SAM SR unit gets disabled almost every times with these settings.


Tunable triggers/delays are :
1) alarm state GREEN - Time since flag 2 - X seconds (time between detection and GREEN state command)
2) alarm state RED - Time since flag 3 - X seconds (time between GREEN state command and RED state command)
3) restart HARM detection - Time since flag 4 - X seconds (time between RED state command and restart of HARM detection)


Works for 1 HARM tracked at a time (in my example the 2 hornets only shoot 1 HARM at a time), it would probably needs a table of existing HARMs and detection of all HARMs through table to be really efficient in all cases. (and tracking/detecting all kinds of ARM also)
Play mission in F10 map view and use time acceleration to see things happening (with displayed messages each time something happens), play with the delays settings in triggers, if you want.

test-HARM-detection-Mist.miz

  • Thanks 1
Link to comment
Share on other sites

On 5/7/2021 at 3:03 PM, toutenglisse said:

 

Hi, here is an example with DCS script. It uses this function DCS func isTargetDetected - DCS World Wiki - Hoggitworld.com

 

In my example the RWR detection of SAM site radar by a wingman is evaluated every seconds, and displays a message when the SAM is RWR detected (which also stops the evaluation).

 

You can adapt it to your need (name of "target" unit to be detected, name of "detecting" unit, and type of detection : radar, visual, etc...), also the "do" function when detected in my example is in the script, but you can change the line that displays text to instead activate a flag - example trigger.action.setUserFlag( "2", true ) , and then add a trigger to do whatever you want when the flag n°2 gets activated.

test-RWR-detection-message.miz 8.64 kB · 8 downloads

Many thanks for your help. Now it works just like i wished. Now, I´m able to adapt it for any purpose i need.

Syria_000.miz

Link to comment
Share on other sites

Posted (edited)

Wait, it's tied to the AI wingman's RWR? Cause AI wingmen can do some crazy shit, pop up and get detected while your own plane is doing NOE flying just fine. 

 

I want to do something similar except with clients in coop multiplayer. 


Edited by WelshZeCorgi
Link to comment
Share on other sites

+1
And to be honest this would make things delightful.

Problem is it should not be triggered by the radar beam simply hitting your aircraft. It has to be modeled so you are identified as an aircraft and not ground clutter. And tall order coming here; distinguish if it sees a confirmed hostile or just an unknown or friendly. So we can inside the editor just set that up and have aircraft launch from airbases.

Link to comment
Share on other sites

4 hours ago, Ducksen said:

+1
And to be honest this would make things delightful.

Problem is it should not be triggered by the radar beam simply hitting your aircraft. It has to be modeled so you are identified as an aircraft and not ground clutter. And tall order coming here; distinguish if it sees a confirmed hostile or just an unknown or friendly. So we can inside the editor just set that up and have aircraft launch from airbases.

 

AI RADARs almost certainly don't take in clutter into effect - if it's within the scan zone, and as a radial velocity over a threshold it can see it so long as LOS isn't blocked. This is something that was fairly easy to see in the sensors.lua file, but that along with several others was hidden as part of the 2.7 update.

 

Pretty sure there's also some accounting for a spherical Earth too.  

Modules I own: F-14A/B, F/A-18C, Supercarrier, F-16CM, AJS-37, F-5E-3, MiG-21bis, Ka-50, A-10C (+ A-10C II), UH-1H, Mi-8MTV2, P-47D, P-51D, FC3, MiG-15bis, Yak-52, CA, C-101, Hawk

Terrains I own: Syria, The Channel, SoH

 

System (RIP my old PC): Dell XPS 15 9570 w/ Intel i7-8750H, NVIDIA GTX 1050Ti Max-Q, 16GB DDR4, 500GB Samsung PM871 SSD (upgraded with 1TB Samsung 970 EVO Plus SSD)

 

VKB Gunfighter Mk.II w. MCG Pro

 

Dreams: https://uk.pcpartpicker.com/list/mBG4dD

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
On 5/7/2021 at 5:38 AM, Black6 said:

Hi, I miss a trigger in mission editor, which would react on target detection (radar/visual). I imagine something similar like "unit/part of group/ part of coalition in zone" in combination with specific unit.
e.g. IF unit(radar) DETECTS unit(target)/part of group/part of coalition DO ....

 

I´am trying to bypass it by lua script, but without any succes yet 😞

Yup +1 just give us the trigger back.  

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...