How to prevent players automatically sitting in seats

I want to prevent players from sitting in seats automatically by going close to them, as is the typical behaviour. However, I cannot use Seat.Disabled, because I want NPCs to be able to sit in the seats via scripting, which Seat.Disabled prevents completely (as according to the API reference, setting this to true causes the seat to ‘act as a normal part’.)

Am I wrong about Seat.Disabled, and if not, what would be the best way of doing this?

2 Likes

you can also destroy the seatweld to make players get up. so you’ll only need to check if there’s an NPC sitting in it, and if not, destroy the seatweld.

1 Like

Wouldn’t this cause issues, in that players would repeatedly sit and then immediately be unsat, as opposed to just not being sat down at all?

1 Like

yes, it will do weird seating and unseating stuff, but there is a debounce to sitting.
Also, what if you disable it from the client instead of the server?

Just an idea but you could change the seat’s all locally so that the server can make the NPCs sit but the player’s won’t. Do you want a permanent change or do you want to be able to toggle the seats on and off?

Nope, not true you are still able to use the Seat:Sit() function to make any humanoid sit-down because the sit function does the seat-welding for you. I do it to prevent the humanoid mech from sitting on that sit that is welded onto the model.

9 Likes