train = script.Parent.Train track = script.Parent.Track
script.Parent.Touched:connect(hit) if hit.Name== "Sensor" then
end
end)
This is a partial script for when the train part comes in contact with the sensor part, after that I need to slowly diminish the velocity of the conveyor belt part until the train stops at the station. Would I write it just like a transparency property? please help
just make a For loop to slowly deminish the property value to zero.
something like this:
train = script.Parent.Train track = script.Parent.Track track.Velocity = Vector3.new(whatever you want it to slide like. See figure 1) for speed = 20,0,-1 do track.Velocity = Vector3.new(the previous number, but change one to speed. See figure 2) end
Figure 1: (0,0,20) Figure 2: (0,0,speed)