Massive lag spike when loading a big map with baseparts from serverstorage to workspace... How do I make the game smoother?

I’ve released my game called Bloxy Roads. Which is a PvP obby race game with cars and large maps. Fast paced action.

What I want to achieve is I want to prevent a big lag spike when a map loads.

Is there a way to count how many Memory is inside a specific map before loading it?

What if I could load bit by bit the map? I want it to be quick. Also where would I add the event that fires once the map has fully loaded into the workspace?

The issue currently is that the lag spike causes a delay in the map preview which messes things up for the client.

1 Like

An easy fix is to turn on streaming enabled in the Workspace properties, what it does is only load things near the player. If you use this however, beware that if you have that get unloaded by the client that are required for local scripts, the scripts could break

uhm I know that. Streaming enable is bugged

You can use the Content Provider Service on roblox to load assets in games, pretty sure that can add optimization for when the game is loading. ContentProvider.RequestQueueSize can be used to determine the amount of memory that is needed to load!

Content provider doesn’t work on parts though

It does it can load all assets in the game just create a loop.