I was wonder how do you get the value of the number like I am trying to get the total number of the wheels by using InPairs and I want to do it.
Program,
function AxleSensor(Vehicle)
local Wheels = {}
for i, v in pairs(Vehicle.Parent.Core:GetChildren()) do
if v.Name == "Wheel" then
table.insert(Wheels,v)
end
end
if Vehicle.Parent:FindFirstChild("Trailer")then
for i, v in pairs(Vehicle.Trailer:GetChildren()) do
if v.Name == "Wheel" then
table.insert(Wheels,v)
end
end
end
script.TotalAxles.Value = Wheels
print(script.TotalAxles.Value)
end