omskTransmash Posted June 19, 2020 Share Posted June 19, 2020 (edited) Hello, I am new to mission scripting, but I searched the forum for hours and still has no solution. I am trying to restrict giving a player TGP or Jammer modules, however, getAmmo() only returns weapons and somehow getSensors() doesnt return anything.. Any help or workaround would be useful. I mean, TGP is a big deal, and nobody should take it for granted! :lol: Edited June 19, 2020 by zakk95 Link to comment Share on other sites More sharing options...
Grimes Posted June 19, 2020 Share Posted June 19, 2020 You don't. A few aircraft actually have the rendering of a targeting pod on them as part of the aircraft model and not a weapon that gets attached to the model. For instance the F-14B is like this with the Lantirn. So for objects that do it this way you can use Unit.getDrawArgumentValue to check. You'd have to load up the model viewer or possibly the units payload definition files to find the argument value. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum Link to comment Share on other sites More sharing options...
omskTransmash Posted June 20, 2020 Author Share Posted June 20, 2020 You don't. A few aircraft actually have the rendering of a targeting pod on them as part of the aircraft model and not a weapon that gets attached to the model. For instance the F-14B is like this with the Lantirn. So for objects that do it this way you can use Unit.getDrawArgumentValue to check. You'd have to load up the model viewer or possibly the units payload definition files to find the argument value. Again, great thanks Grimes! So maybe there is a way, albeit not so beautiful one :smilewink: I will try that and find out! You are the best! Link to comment Share on other sites More sharing options...
Recommended Posts