Parenting to "game"

Can I parent instances to “game” by using Instance.new("Folder", game)?
It technically works, but does it have any major drawbacks? I’d like to use it as a parent for my modules that I’ll require from many scripts

1 Like

You can, but if were you, I would find it a little confusing not bieng able to see the scripts in the explorer.

1 Like

Why game? Why not ReplicatedStorage?

1 Like

Its all still in the explorer. It’d just make it easier to require thinks (require(game.Modules.x)) (im lazy)

1 Like

I dont know, your choice personally. But sure, I dont think there are any draw backs.

I guess an alternative is ServerStorage, as it only runs on the server and is only visible on the server, same as what your saying.

Your choice, if its easier for you, then sure.

btw, i didnt even know you could do that, might use it sometime.

1 Like

It’s more-so the root of your project, and what you want could most likely be achieved with a “Module Loader” placed in your replicated storage that automatically calls require() on your modules and caches them for later usage, then you could retrieve them using a function from the original module example MyModules.Get("Module Name")

I also don’t believe there is any documentation on game’s replication whether its replicated to the server/client or both, so if anyone knows feel free to chime in.

Edit: changed post to be a bit more accurate.

1 Like

I’m pretty sure instances parented to game do not save to roblox

EDIT: just tested, they don’t save.

2 Likes