Same game work diferently in roblox and in studio

then use the collision groups so that all the trucks can go through the wall, PhysicsService | Documentation - Roblox Creator Hub

We can’t really do much without seeing the source code.

He said that everything is being done through tweening on the server and thats clearly the problem

Edit: I tween var, and I copy it to models position using :SetPrimaryPartCFrame

Correct me if I am wrong but I am pretty sure that when you play in studio, everything is running locally on your machine. In the actual game, most things are running on Roblox’s servers. Try to do optimize more of your intensive scripts to run locally (if possible).

1 Like

Thats still intensive I recommend you apply the methods I told you in the previous replies instead

I have extremely good pc, but I am not sure, that this will work for people having pc like my old computer

You really don’t have to worry about that at all. You will be surprised how much computing power a decent computer has. A lot can be ran locally.

You are missing the point. Discord and Roblox are very different. You can’t simply put everything on the server, it will lag the game for all players. If users can’t even run Discord, they will definitely not be playing Roblox. You would not want to put all the eggs in one basket, distribute it to other baskets. In this case, don’t just rely on the server, distribute to players’ local machines.

Why to give the same job to all clients, when it will only complicate situation

Because when the server has less load, it will be less laggy?

I just wanted to add that he should not do it your way with moving the cars because although it would be faster, it would be easier to exploit since the hit detection would have to be done locally as well. it would be better to use the part.Velocity method I outlined earlier.

Yes, but when client will render cars, nothing easier, than freezing hitbox

Your method would work for sure. What I am trying to say is maybe move the detailed cars moving locally, and in server move a hit box and detect player collisions like that. So you still can do collisions not locally.

Yes, but server must share hitbox position with client, or the graphic hitbox will be at different pos, than the real

Thats still too much workload for the server

Not really, the server now doesn’t have to move the detailed car and only has to move a frame of the hitbox. The detailed car will be moved locally.

he uses set primarypart cframe so only the primary part is moved

SetPrimaryPartCFrame moves the primary part but also every other part in the model relative to the primary part, not just the primary part. This function is terrible though: there have been many issues with floating point imprecisions. Now while that’s unavoidable for any floating value, SetPrimaryPartCFrame butchers it in the way that it works and it causes models to tear apart. Ideally it should not be used.

and when i create welds nd tween only base part?