Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

[Solved myself] Loading large models part by part?

Asked by
zuup123 99
4 years ago
Edited 3 years ago

As the title says, I want to know how to make a large model that has a lot of parts load part by part from ServerStorage or something else. Any suggestions?

0
This is a request ScriptingHelpers clearly stated that you are NOT allowed to request User#30241 0 — 4y
1
Iterate through the descendants of the model and parent them 1 by 1 to the workspace. crywink 419 — 4y
0
Good idea, made it. zuup123 99 — 4y
0
What he said isn't necessarily non-sense, this is not a request site, but your question is borderline. Please check out our help articles and about page: https://scriptinghelpers.org/about and https://scriptinghelpers.org/help M39a9am3R 3210 — 4y
0
Alright! zuup123 99 — 4y

1 answer

Log in to vote
0
Answered by
zuup123 99
4 years ago

So I found out the way to do it. Make a for _,v in pairs loop and :GetChildren() of the model, then load every part to the new model located in the workspace. Script must look like this:

local newModel = Instance.new("Model",workspace)
        new.Name = "Map"

        for i,v in pairs(game.ReplicatedStorage.Maps.Map:GetChildren()) do
        if v:IsA("Part") then
            v:Clone().Parent = newModel
            wait()
        end
        end

This will remove lags for players when loading in a huge map.

Ad

Answer this question