How data is loaded in games

How do other games handle data loading? What gets loaded and on what scale? How to properly organize data loading in your own games using ModuleScript? For example, this screenshot from Guts & Blackpowder - it looks like something massive is loading there, doesn’t it? I don’t think UI loading looks like this:

function UIController.LoadUI()
  ReplicatedStorage.MainGui:Clone().Parent = plr.PlayerGui
  print("Loaded Game UI")
end

IMG_20250331_180637_765

I believe they used ContentProvider:IsLoaded(), cmiiw fellas

1 Like

If you want a good answer then here’s my advice. Start watching tutorials on how to use module scripts and specifically test them yourself so you can learn and understand how they work. Least important thing you could add to your game is stuff related to loading. Modules are definitely great for organizing though and honestly it’s worth learning how to use them

1 Like

Most of those don’t have to do anything with ContentProvider, it’s probably them just logging what the Framework is doing.

So if our framework let’s say had a folder called Services / Handlers and each one of those was structured like this: (Just an example of a basic Framework)

local Handler = { }

local function doSomethingFunny()
   print("Best script ever!")
end

function Handler.Start()
   -- Start the Handler / Service

   doSomethingFunny()
end

return Handler

and then the Framework would simply go thru each Handler, require it and after the Handler.Start() function has finished running we would print the message

local Handlers = { }

for Index, Handler in pairs(script["Handlers"]:GetChildren()) do
   Handlers[Handler.Name] = require(Handler)
end

-- Start the Handlers

for Index, Handler in pairs(Handlers) do
   Handler.Framework = Handlers
   Handler.Start()

   print("Loaded Handler: " .. Index)
end
1 Like

A 10 seconds search would’ve been easier.

On the side, how to organise your work via module scripts? Well, try. Find the most suiting style for you. There is no omnibus. Experiment and see what you prefer the most.

1 Like