Hi Guys, It's been a long time since i needed your help, but i'm stuck with a scope issue for my license script.
I'll Try to explain:
- I've got a mse file, with a few critical functions and a variable into.
- The script download the file into a specific folder,then i call "FileIn Thefile" and the next line is supposed to execute a function found into this file.
-If i launch max, and evaluate the script, the function is not found, but if i evaluate it a second time, the function is found and the script continue... A classic scope issue.
Here is the code:
--Download Usefull Function and execute from server
local targetfunction = ("RF_DecryptFunction.mse")
local tempfunction = (getdir #userscripts + "\RF_DecryptFunction.mse")
download targetfunction tempfunction
FileIn tempfunction
deletefile tempfunction
free targetfunction
free tempfunction
I've read about the difference between filein and include, but don't understand the main differences.
Once this part evaluated, i just want to use some functions i thought stocked into RAM (== Globals ? ) and free them right after.
Thanks.
Florent.
miauu · 2015-09-14