I tried using humanoid.Seated event but it didn't work. I want to make a script that deletes the car after a player gets up from a vehicleseat. I'm kinda new and I wanna know how to do it.
--local script--
local event = script.Parent.DeleteCar
local humanoid = game.Players.LocalPlayer.Character:WaitForChild("Humanoid")
local audi = script.Parent.Parent --the car
if not humanoid.Seated then
event:FireServer(audi)
end
--server script--
local event = script.Parent.DeleteCar
event.OnServerEvent:Connect(function(plr, car)
car:Destroy()
end)
i know the script is horribly wrong. I'm kinda new to scripting

3 comments
Show us your script. Btw, you're on the right track with the humanoid.Seated part.
i posted the script
It will only check once, use humanoid.Seated:Connect(function)