Jump to content

Recommended Posts

Posted

hi there,

 

when i change my LUA-skript and restart the mission, i see that the old version is still loaded in the temp folder. How can i force the ME to get the latest version of the script file?

 

thanks!

Posted

While not applicable for publishing missions when you are testing lua code you can call a loadfile that looks at a specific folder location on your PC. Since it is running a local file all you gotta do is save the file where-ever you are editing it and restart the mission. Then when done you switch back to embedding it in the miz with do script file. 

 

local path ='J:\\Dropbox\\\Projects\\DCSMissions\\'

assert(loadfile(path .. "myCode.lua"))()

  • Thanks 1

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Posted
vor 19 Stunden schrieb Grimes:

While not applicable for publishing missions when you are testing lua code you can call a loadfile that looks at a specific folder location on your PC. Since it is running a local file all you gotta do is save the file where-ever you are editing it and restart the mission. Then when done you switch back to embedding it in the miz with do script file. 

 

local path ='J:\\Dropbox\\\Projects\\DCSMissions\\'

assert(loadfile(path .. "myCode.lua"))()

Thanks!!

Posted
Am 26.9.2021 um 02:08 schrieb Grimes:

While not applicable for publishing missions when you are testing lua code you can call a loadfile that looks at a specific folder location on your PC. Since it is running a local file all you gotta do is save the file where-ever you are editing it and restart the mission. Then when done you switch back to embedding it in the miz with do script file. 

 

local path ='J:\\Dropbox\\\Projects\\DCSMissions\\'

assert(loadfile(path .. "myCode.lua"))()

Works pretty fine. I couldn't find it in the documentation. I think it it worth a note!

Posted

http://www.lua.org/manual/5.2/manual.html#pdf-loadfile

 

The hoggit wiki doesn't really cover any of the built in lua functionality other than linking to a few lua pages that are useful. TBH I haven't put much thought into adding anything like that to it because the information is out there and more detailed than what could be added to the wiki. Maybe a basic FAQ type page with a few general tidbits like that or something would suffice. 

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...