ADHS Posted December 14, 2022 Posted December 14, 2022 (edited) Hello. I am looking to find out how can i check (with script) which module am i flying now in DCS. Thank you. EDIT: Sorry my fault: I'm not refering to check this at runtime, but before mission start. Edited December 14, 2022 by ADHS Democracy was already invented, while Scrat was eating oak fruits.
cfrag Posted December 14, 2022 Posted December 14, 2022 I don't think that you can currently resolve this reliably. If you are writing a single-player mission (with multiple available planes), you can get players, and then (since you know there is only one player) get the player's unit's type. This won't work with more than one players, though, not even if the player 'helps' by using an installed missionCommandForGroup (single-unit groups for players) because I don't know if a client script would be able to reliably retain that knowledge.
ADHS Posted December 14, 2022 Author Posted December 14, 2022 (edited) 8 hours ago, cfrag said: I don't think that you can currently resolve this reliably Thank you for your reply. I didn't express my question properly. EDIT: Sorry my fault: I'm not refering to check this at runtime, but before mission start. Thank you Edited December 14, 2022 by ADHS Democracy was already invented, while Scrat was eating oak fruits.
cfrag Posted December 15, 2022 Posted December 15, 2022 (edited) On 12/14/2022 at 7:29 AM, ADHS said: I'm not refering to check this at runtime, but before mission start While I'm not even sure you can do it after the player enters the game, I think that since at mission start the player isn't even in the game, nor has chosen an airframe at this point, that this is not possible at all. That being said, you gave me an idea - you could trap the player entered event and then check the desc of the playe's unit. Edited December 15, 2022 by cfrag 1
ADHS Posted December 15, 2022 Author Posted December 15, 2022 (edited) 59 minutes ago, cfrag said: you can do it after the player enters the game You are RIGHT! Thank you very much for your idea friend, i will draft it but sadly i have to try it once: RTB. Thank you! Edited December 15, 2022 by ADHS Democracy was already invented, while Scrat was eating oak fruits.
Recommended Posts