Still have questions? Join our Discord server and get real time help.
0

# Parts Freeze While In Mid Air?

Edited 7 days ago

I was testing the exploding parts for my brickbattle game but this happened while testing, they also unfreeze when i move close to them, anyone know how to fix this? https://imgur.com/a/RflGWk4, sorry for the lag.

0
Is there a script that automatically anchors parts? 2b2tpvp 17 — 7d
0
*A lag-remover script? 2b2tpvp 17 — 7d

0

The problem is likely to do with NetworkOwnership. Roblox physics need an "Owner" of the part in order for the physics engine to work properly. Whoever 'owns' the part will be responsible for doing the physics calculations on their computer. Parts automatically change owners behind the scenes whenever the user gets close, and we can also set the ownership manually via the "SetNetworkOwner" method.

-- Insert this in the projectile script:
function onPartHit(part)
--...lines of code
part:SetNetworkOwner(player); --Set the owner to the person who shot the projectile
wait(10);
part:SetNetworkOwnershipAuto(); --Give ownership back to the server
--There are better ways to set the ownership back, but I will leave that up to you.
end