I have a script that runs through every module within a folder and is trying to automatically make them inherit from their parent module. I want to essentially change the table of the module into a metatable with __index pointing towards their parent module, which itself could point towards another one… etc.
Is there a way I can do this without some janky workaround, like, setting it directly?
What I have
What I want the script to fill in automatically for me
For clarification, I want it to be filled in upon playing the game, and simply not be written in explicitly. If you want a module to inherit from another one, drag and drop it into another module and the game should take care of the rest for you. That kind of thing.