Recently I've been in a project using deep learning in air combat. And as a crazy player of DCS, it undoubtfully became my choice for simulation. In order to get mission records automatically, the mission needs to unpause itself when started, and I'm stuck on this step.
I check the trigger in mission editor carefully and there is no action to unpause mission. So I try to write a lua script and I checked the official api file in \DCSWorld\API. To my pleasure, I found DCS.setPause() function. However, when I enter it in mission editor and start the mission, an error pop up, saying "attempt to index global 'DCS' (a nil value)". I have tried other functions in DCS api and some lua official api, for example io, and the error still occur (when using io api, the error become "attempt to index global 'io (a nil value)"). It seems that the mission script environment in DCS doesn't contain such api, so lua script cannot use those functions. But in "DCS_ControlAPI" file, it is clearly stated that those api are contained and ready for usage.
How can I solve this error? Or are their other ways to automatically skip pause when mission starts?