so i have trying to make a scratch project in roblox (https://scratch.mit.edu/projects/580314315/) and well i decided to use 4 module scripts (1 for the enemy (the smiler), 2 for the player, 3 for utils and 4 for the main initializer) so i can only load the entire thing at once
the initializer has this function named “new” which returns a metatable with variables like the ui, player, localplayer, elements for convinience
but in the other modulescripts when i try to require the initializer, the functions just dont show up
for some reason it only shows up in the smiler module
when i tried running it, the control errored “…Modules.Player.controls:21: attempt to index nil with “MoveDirection””
i think the main cause of this is because new just doenst exist in that module
this is basically what happened
i used the roblox playermodule as reference to my modules btw thats why it shows up in the explorer
does anyone know why this happens and how to fix it