local PhysicsService = game:GetService("PhysicsService") local RunService = game:GetService("RunService") PhysicsService:RegisterCollisionGroup("SeatDefault") PhysicsService:CollisionGroupSetCollidable("SeatDefault", "SeatDefault", false) local SimulateFalloff = true local FalloffThreshold = 45 local DistanceDisconnect = 6 local function descendantAdded(d) if d:IsA("Weld") and d.Name == "SeatWeld" then task.spawn(function() task.wait(0) local Seat = d.Parent local Part0 = d.Part0 local Part1 = d.Part1 local Character = Part1.Parent d.Enabled = false local IsNetworkAuto = Part1:GetNetworkOwnershipAuto() local NetworkOwner if not IsNetworkAuto then NetworkOwner = Part1:GetNetworkOwner() end d:SetAttribute("MigratedToV2", true) local A0 = Instance.new("Attachment") A0.Parent = Seat A0.Name = "SeatAttachment" A0.CFrame = d.C0*(d.C1:Inverse()) local Parts = {} local A1 = Instance.new("Attachment") A1.Parent = Part1 local AP = Instance.new("AlignPosition") local AO = Instance.new("AlignOrientation") AP.Parent = Seat AP.Attachment0 = A1 AP.Attachment1 = A0 AP.Responsiveness = 40 AP.MaxForce = math.huge AP.RigidityEnabled = true AP.Name = "SeatAlignPosition" AO.Parent = Seat AO.Attachment0 = A1 AO.Attachment1 = A0 AO.Responsiveness = 100 AO.Name = "SeatAlignOrientation" local Seated = true local Collisions = {} for _, v in ipairs(Character:GetDescendants()) do if v:IsA("BasePart") then Collisions[v] = v.CanCollide end end local SeatCollision = RunService.Stepped:Connect(function() for _, v in ipairs(Character:GetDescendants()) do if v:IsA("BasePart") then v.CanCollide = false end end end) d:GetPropertyChangedSignal("Parent"):Connect(function() if not d:IsDescendantOf(game) then Seated = false A0:Destroy() A1:Destroy() AP:Destroy() AO:Destroy() SeatCollision:Disconnect() for _, v in ipairs(Character:GetDescendants()) do if v:IsA("BasePart") then local CC = Collisions[v] if CC then v.CanCollide = CC end end end if IsNetworkAuto then Part1:SetNetworkOwnershipAuto() else Part1:SetNetworkOwner(NetworkOwner) end end end) local function disconnect() d:Destroy() local humanoid = Part1.Parent:FindFirstChildOfClass("Humanoid") if humanoid then humanoid.Sit = true humanoid:GetPropertyChangedSignal("Sit"):Wait() humanoid.Sit = true end end pcall(function() while Seated do if SimulateFalloff and ((Seat.Orientation.X < -FalloffThreshold or Seat.Orientation.X > FalloffThreshold) or (Seat.Orientation.Z < -FalloffThreshold or Seat.Orientation.Z > FalloffThreshold)) then disconnect() break end if (Part1.Position - Seat.Position).Magnitude > DistanceDisconnect then disconnect() break end pcall(function() local Owner = nil if not Seat:IsGrounded() then Owner = Seat:GetNetworkOwner() end Part1:SetNetworkOwner(Owner) end) task.wait(0.01) end end) end) end end workspace.DescendantAdded:Connect(descendantAdded) for _, v in ipairs(workspace:GetDescendants()) do descendantAdded(v) end