Stats.Locked.Changed:Connect(function()ToogleLock(Stats.Locked.Value)end)Stats.Color.Changed:Connect(function()CarColor()end)Fuel=script.Parent.Parent.Stats.Fuel MainPart=script.Parent.Parent.Body.Main while wait(.5)do if oldpos==nil then oldpos=MainPart.Position else newpos=MainPart.Position Fuel.Value=Fuel.Value-(oldpos-newpos).Magnitude/150 oldpos=newpos end end


Stats.Locked.Changed:Connect(function()
ToogleLock(Stats.Locked.Value)
end)
Stats.Color.Changed:Connect(function()
CarColor()
end)



Fuel = script.Parent.Parent.Stats.Fuel
MainPart = script.Parent.Parent.Body.Main
while wait(.5) do
if oldpos == nil then
oldpos = MainPart.Position
else
newpos = MainPart.Position
Fuel.Value = Fuel.Value - (oldpos - newpos).Magnitude/150
oldpos = newpos
end
end















