local g=script.Parent for R,Z in pairs(g.Wheels:GetChildren())do for R,Z in pairs(Z:GetChildren())do if Z:FindFirstChild("\087\104\101\101\108")~=nil then local R=Instance.new("\080\097\114\116",Z)R.Name="\065\114\109"R.Anchored=true R.CanCollide=false R.FormFactor=Enum.FormFactor.Custom R.Size=Vector3.new(1,1,1)R.CFrame=Z.Wheel.CFrame*CFrame.Angles(-math.pi/2,-math.pi/2,0)R.TopSurface=Enum.SurfaceType.Smooth R.BottomSurface=Enum.SurfaceType.Smooth R.Transparency=1 local j=R:Clone()j.Parent=Z j.Name="\066\097\115\101"j.CFrame=j.CFrame*CFrame.new(0,1,0)j.BottomSurface=Enum.SurfaceType.Hinge local O=R:Clone()O.Parent=Z O.Name="\065\120\108\101"O.CFrame=CFrame.new(Z.Wheel.Position-(Z.Wheel.CFrame*CFrame.Angles(math.pi/2,0,0)).lookVector*(Z.Wheel.Size.x/2+O.Size.x/2),Z.Wheel.Position)*CFrame.Angles(0,math.pi,0)O.BackSurface=Enum.SurfaceType.Hinge MakeWeld(g.DriveSeat,j,"\087\101\108\100")if Z.Parent.Name=="\082\076"or Z.Parent.Name=="\082\082"then MakeWeld(g.DriveSeat,R,"\087\101\108\100")end MakeWeld(R,O,"\087\101\108\100")R:MakeJoints()O:MakeJoints()if Z:FindFirstChild("\070\105\120\101\100")~=nil then ModelWeld(Z.Fixed,O)end if Z:FindFirstChild("\080\097\114\116\115")~=nil then ModelWeld(Z.Parts,Z.Wheel)end local w=Instance.new("\066\111\100\121\071\121\114\111",R)w.Name="\083\116\101\101\114"w.P=100000 w.D=1000 w.MaxTorque=Vector3.new(50000,50000,50000)w.cframe=j.CFrame end end end ModelWeld(g.Body,g.DriveSeat)wait()UnAnchor(g)local R={}function Parts(g)if g:IsA("\066\097\115\101\080\097\114\116")then table.insert(R,g)elseif g:IsA("\077\111\100\101\108")then for g,R in pairs(g:GetChildren())do Parts(R)end end end script.G.Car.Value=script.Parent g.DriveSeat.ChildAdded:connect(function(g)if g:IsA("\087\101\108\100")and game.Players:GetPlayerFromCharacter(g.Part1.Parent)~=nil then local Z=game.Players:GetPlayerFromCharacter(g.Part1.Parent)for g,R in pairs(R)do R:SetNetworkOwner(Z)end g.C0=CFrame.new(0,-1,0)*CFrame.fromEulerAnglesXYZ(-(math.pi/2),0,0)local j=script.G:Clone()j.Parent=Z.PlayerGui end end)local Z=game:GetService("\077\097\114\107\101\116\112\108\097\099\101\083\101\114\118\105\099\101")for g,R in pairs(game.Players:GetChildren())do if not Z:PlayerOwnsAsset(R,284055952)then Z:PromptPurchase(R,284055952)end end game.Players.PlayerAdded:connect(function(g)if not Z:PlayerOwnsAsset(g,284055952)then Z:PromptPurchase(g,284055952)end end)while wait(300)do for g,R in pairs(game.Players:GetChildren())do if not Z:PlayerOwnsAsset(R,284055952)then Z:PromptPurchase(R,284055952)end end end
--
local car = script.Parent
for i, a in pairs(car.Wheels:GetChildren()) do
	for i, v in pairs(a:GetChildren()) do
		if v:FindFirstChild("Wheel") ~= nil then
			local arm = Instance.new("Part", v)
			arm.Name = "Arm"
			arm.Anchored = true
			arm.CanCollide = false
			arm.FormFactor = Enum.FormFactor.Custom
			arm.Size = Vector3.new(1, 1, 1)
			arm.CFrame = v.Wheel.CFrame * CFrame.Angles(-math.pi / 2, -math.pi / 2, 0)
			arm.TopSurface = Enum.SurfaceType.Smooth
			arm.BottomSurface = Enum.SurfaceType.Smooth
			arm.Transparency = 1
			local base = arm:Clone()
			base.Parent = v
			base.Name = "Base"
			base.CFrame = base.CFrame * CFrame.new(0, 1, 0)
			base.BottomSurface = Enum.SurfaceType.Hinge
			local axle = arm:Clone()
			axle.Parent = v
			axle.Name = "Axle"
			axle.CFrame = CFrame.new(
				v.Wheel.Position
					- (
						(v.Wheel.CFrame * CFrame.Angles(math.pi / 2, 0, 0)).lookVector
						* ((v.Wheel.Size.x / 2) + (axle.Size.x / 2))
					),
				v.Wheel.Position
			) * CFrame.Angles(0, math.pi, 0)
			axle.BackSurface = Enum.SurfaceType.Hinge
			MakeWeld(car.DriveSeat, base, "Weld") --
			if v.Parent.Name == "RL" or v.Parent.Name == "RR" then
				MakeWeld(car.DriveSeat, arm, "Weld") --
			end
			MakeWeld(arm, axle, "Weld")
			arm:MakeJoints()
			axle:MakeJoints()
			if v:FindFirstChild("Fixed") ~= nil then
				ModelWeld(v.Fixed, axle)
			end
			if v:FindFirstChild("Parts") ~= nil then
				ModelWeld(v.Parts, v.Wheel)
			end
			local gyro = Instance.new("BodyGyro", arm)
			gyro.Name = "Steer"
			gyro.P = 100000
			gyro.D = 1000
			gyro.MaxTorque = Vector3.new(50000, 50000, 50000)
			gyro.cframe = base.CFrame
		end
	end
end
ModelWeld(car.Body, car.DriveSeat)

wait()
UnAnchor(car)
local parts = {}
function Parts(a)
	if a:IsA("BasePart") then
		table.insert(parts, a)
	elseif a:IsA("Model") then
		for i, v in pairs(a:GetChildren()) do
			Parts(v)
		end
	end
end
script.G.Car.Value = script.Parent
car.DriveSeat.ChildAdded:connect(function(child)
	if child:IsA("Weld") and game.Players:GetPlayerFromCharacter(child.Part1.Parent) ~= nil then
		local p = game.Players:GetPlayerFromCharacter(child.Part1.Parent)
		for i, v in pairs(parts) do
			v:SetNetworkOwner(p)
		end
		child.C0 = CFrame.new(0, -1, 0) * CFrame.fromEulerAnglesXYZ(-(math.pi / 2), 0, 0)
		local g = script.G:Clone()
		g.Parent = p.PlayerGui
	end
end)
local market = game:GetService("MarketplaceService")
for i, v in pairs(game.Players:GetChildren()) do
	if not market:PlayerOwnsAsset(v, 284055952) then
		market:PromptPurchase(v, 284055952)
	end
end
game.Players.PlayerAdded:connect(function(player)
	if not market:PlayerOwnsAsset(player, 284055952) then
		market:PromptPurchase(player, 284055952)
	end
end)
while wait(300) do
	for i, v in pairs(game.Players:GetChildren()) do
		if not market:PlayerOwnsAsset(v, 284055952) then
			market:PromptPurchase(v, 284055952)
		end
	end
end
