walder/Skynet-IADS

LUA Error when a new HARM is identified

baleBaron opened this issue · 0 comments

Im getting LUA Error when a new HARM is identified while another SAM has one of its radars destroyed.

ERROR SCRIPTING (Main): MIST|doScheduledFunctions|1300: Error in scheduled function: $1[string "C:\Users\XXXXX\AppData\Local\Temp\DCS\/~mis00000F0C.lua"]:1896: Object doesn't exist

How I reproduce:
Destroy radar of one SAM site in the IADS network (fastest way through F10 trigger)
Launch HARM at another site
When this HARM gets identified, and the site with one bad radar gets notified, error happens

Error is triggered from SkynetIADSAbstractRadarElement:informOfHARM()

A simple radar:isExist() guard in skynet-iads-abstract-radar-element.lua appears to solve this for me.