Xander_ Posted June 29, 2020 Share Posted June 29, 2020 Hey, so I have added a respawn script to my mission and made it respawn the JTAC Reaper drones, AWACS, and Tankers. This works fine. My issue is I have them all set to invisible and after they respawn they seem to lose the invisible command and then get shot down immediately. Does anyone know how I can fix this so I can have my mission running on my server 24/7 and not have everything shot down by the red AI after it respawns when its set to invisible? Link to comment Share on other sites More sharing options...
johnv2pt0 Posted June 30, 2020 Share Posted June 30, 2020 I use this in one of my missions: local function S_Invis_1() if Group.getByName('I-SUB #001') ~= nil then local sub1 = Group.getByName("I-SUB #001") local SetInvisible = { id = 'SetInvisible', params = { value = true }} sub1:getController():setCommand(SetInvisible) end end S_Invis_1() Link to comment Share on other sites More sharing options...
Xander_ Posted June 30, 2020 Author Share Posted June 30, 2020 I use this in one of my missions: local function S_Invis_1() if Group.getByName('I-SUB #001') ~= nil then local sub1 = Group.getByName("I-SUB #001") local SetInvisible = { id = 'SetInvisible', params = { value = true }} sub1:getController():setCommand(SetInvisible) end end S_Invis_1() So I just add this as a do script or do I add this onto my respawn script then change the "I-SUB #001" for my unit name? Link to comment Share on other sites More sharing options...
johnv2pt0 Posted June 30, 2020 Share Posted June 30, 2020 You would need to change "I-SUB #001" to your object's Group name and then call the function S_Invis_1() every time after it has respawned so it will set it invisible. Link to comment Share on other sites More sharing options...
Recommended Posts