Anyone have a way where I can detect when a player sits in a seat, and then open a GUI. When they get up from the seat, it closes?
You could use a Changed event to detect when the occupant property of the seat changes to a new humanoid. When the property is nil, the seat is empty. When someone sits in the seat, the occupant property gets set to that player's humanoid.
local seat = LOCATION_OF_SEAT seat.Changed:connect(function(property) if property == "Occupant" then local humanoid = seat.Occupant local player = game.Players:GetPlayerFromCharacter(humanoid.Parent) if player then -- code end end end)