I have a scope, its welded together nicely.
When I put it in ReplicatedStorage and start a server with 1 client, then the client welds will not have the exact same cframe as original.
The server have the correct one but the client has a very distorted one.
This is the difference between the scope on the server and the client:
This repo file does not run any scripts, its just a model in ReplicatedStorage.
I’ll give repo-file to all staff workers but can’t post it publicly since it’s an important asset to my game that I don’t want to share with everybody.
Just some quick sanitary checks that may or may not be related,
Is your model welded before putting it in workspace? Do you throw it in workspace before welding it? Are you welding it at runtime or is it welded before the game even starts?
If none of those work, PM me a repro because I do similar stuff all of the time
local function weld(i,b)
local weld1 = Instance.new("Weld")
weld1.Name = b.Name
weld1.Part0 = i
weld1.Part1 = b
weld1.C1 = b.CFrame:inverse()*i.CFrame
weld1.Parent = i
end
I used the welding code you sent me and it works now.
I would still claim that it’s partially a roblox issue since the server and client doesnt have the exact same info…
Heres the code that fixed it (credits to @AbstractAlex)
local w = Instance.new(“Weld”)
w.C1 = v.CFrame:toObjectSpace(base.CFrame)
w.Part0 = base
w.Part1 = v
w.Parent = base
I’ve also learned that welding parts closest to the world origin (0,0,0 position) seems to work best. I had issues where welding my airplanes far away ended up with offset parts. Welding them in the center of the map and then moving them fixed that. Probably precision error stuff.