I have been getting the workspace by typing “game.workspace” for quite long ago, then I realized you can just type in “workspace” instead so I then started using it.
I’m just wondering: what’s the most optimized way / best way there to get the Workspace?
Is there something wrong with getting the Workspace by:
--using
workspace
--instead of...
game.workspace
--or (I don't even use this one)
game:GetService("Workspace")
I always thought typing “workspace” was a good practice since it’s more compact and also less text means cleaner code, but is it really the best option there?
Please, let me know what you think down below. Thanks for your help.
there’s no point in this;
indexing workspace is just as simple as doing game.Workspace or workspace simply, it’s loaded implicitly almost as immediately as a player joins, it won’t affect performance (or at least not significantly enough)
When I began scripting, I used tutorials, some people used workspace, some people used game.Workspace. I thought game.Workspace was more advanced, but turns out no difference!
I never knew you could use “workspace” instead of game.Workspace or game:GetService(“Workspace”)
I’ve only saw it in 1 script, but thought it was a mistake
Well, thanks for the info