Hey,
I’m trying to structure things more nicely and having my interface files on require files that load in. Now im having difficulty access/ sharing out the functions from one to another.
I can call a function that is in menu_letters.lua from the main file (menu_letters.menuOut) but what I require is to call a function from the main file in the required module… so below I need to call menuOpen in the main file from the file that is being required… like using _parent in Flash…
How is this possible?
main.lua
super = require("menu\_letters")
level = super:newMain()
menuOpen = function( event )
transition.to(btn\_menutab, { time = 500, rotation = 180 })
end
menu_letters.lua
menuOut = function( event )
transition.to(btn\_menutab, { time = 500, rotation = 0 })
end
[import]uid: 21298 topic_id: 17048 reply_id: 317048[/import]
[import]uid: 3826 topic_id: 17048 reply_id: 64003[/import]