I'm trying to import a variable declared in the global script to a module
but im getting error >:(
// Script header for module 'WalkToInteraction'
import int chargoing;
// main global script file
int chargoing = 0;
export chargoing;
o/
You can't do that. Modules are loaded before the global script so in modules, you can only import stuff from preceding modules.
What you could do is define and export the variable in the module, then import it in the global script header.
Did you know that you can use rep_ex, on_mouse_click etc. in modules as well?
thanks again!
I didnt know that
o/