Client not waiting until whole model is loaded

So I have tried to wait until the model has loaded using :WaitForChild but that didn’t work.

local model = script.Parent
model.Parent:WaitForChild(model.Name)

local PartsFolder = model:WaitForChild("PartsFolder") -- list of parts

for i,v in ipairs(PartsFolder:GetDescendants()) do
	print(v)-- nothing
end

What I understand is that nothing prints out when you try to print, but what are you trying to print?

Assuming you have StreamingEnabled turned on, just set the model’s streaming mode to Atomic.

Wow! It worked! What does atomic do?

It essentially only streams in the model once any of its basepart children are eligible for streaming in. However, it will only stream out if all of the children are eligible for streaming out.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.