Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Obby with moving parts is extremely laggy?

I built an obby that has about 20 moving objects. These objects are either just spin, rotate, or move side to side. I thought that Roblox could handle this sense it's really not that complicated of motion, but even just having these 20 moving objects seems to be significantly lagging the game. Does anyone have any idea why this might be, or how I could optimize it? I can post an example code of one of my moving parts if it helps.

3 comments

0

Do you move everything with code or do you use BodyMovers aswell?

0

I move everything with code using CFrame

0

Perhaps try moving some stuff with BodyMovers and see if it's less laggy?

1 answer

Ok, so Roblox doesn't handle moving parts on server-side very well. What I do to avoid laggy parts and such, is made everything local-side. What you can do is make a local script in playerScripts that parents all the parts you need into game.Workspace.CurrentCamera, and then move them from client side. This will prevent the server from owning them, reducing server-side replication to the client. Hope I could help, If you have any question post them on this answer. Have a great day!

This discussion is preserved as it was. New answers, comments, and votes are closed.