Basically that. Also do I need to pass a parameter to it?
U can put the event in a variable like local event = RunService.Heartbeat:Connect....
and then call event:Disconnect
Im not sure you understand RunService.Heartbeat is an event, no parameters need to be parsed to it nor does it need to be turned on or off
I want to turn it on and off though because I want to put it in a vehicle script. Also on developer it shows a parameter, delta time. No clue where to pass from or how use that though. RunService.Heartbeat:Connect(function(step)
Ah cool ty. Will the local event automatically start running or do I need to then put the local event into something?
U will have to recreate the event again. So u can connect the local event = RunService.Heartbeat:Connect....
function to for example Seat:GetPropertyChanged(‘Occupant’) or something and then that event will start running again.
then when the player leaves the car, you can call event:Disconnect()
and it will stop.