Seat:Sit() does not consistently work from client

Reproduction Steps

This is based on my own tests, along with this post Seat:Sit() NOT WORKING! which mentions that Sit isn’t supposed to be used on client, which sounds ludacris, but seems to be the case here. SImply have a seat and call Seat:Sit(LocalPlayer.Character.Humanoid) from the client, and on occassion it will break/. If this is intentional, then why? There’s no reason for it to server side only

Expected Behavior

Can be found here:

On occassion, calling Seat:Sit() for a valid Humanoid does not work

Actual Behavior

On occasion, you will not sit, which breaks gameplay

Issue Area: Engine
Issue Type: Other
Impact: High
Frequency: Often

8 Likes

Thanks for the report! Could you provide a script with this issue occurring?

1 Like
local Player = game.Players.LocalPlayer
local Seat = workspace.Seat

Seat:Sit(Player.Character.Humanoid)

it’s sporadic though. Sometime it works, sometimes it doesn’t. Not replicable consistently

1 Like

I also notice this. Why is this happening? Are we not supposed to call Seat:Sit() from the client? Makes little sense. Can we have some light on this issue?

Repro is trivial just make a prompt or click detector that makes you sit from the client and press it a few times. There seems to be some internal debounce but I can’t really tell.

EDIT: Mitigation found. Retry in a loop like a neanderthal :moyai:

function sitHumanoid(seat: Seat, hum: Humanoid, retries: number?)
    retries = retries or 20
    for i = 1, retries do
        print("trying to sit", i)
        if seat.Occupant ~= hum then
            seat:Sit(hum)
        else
            break
        end
        task.wait(.1)
    end
end

From my tests the debounce seems to be around 1-1.2 seconds.

2 Likes

Yeah a retry loop seems like the way to go. I love how Roblox is like “give feedback for new feature” while ignoring years old stuff.
Here’s my refactor of your code:

local function sit(seat: Seat, hum: Humanoid, retries: number?)
    if retries == nil then retries = 20 end
    for i = 1, retries do
        if seat.Occupant == hum then break end
        seat:Sit(hum)
        task.wait(0.25)
    end
end
1 Like

Can we PLEASE get any update on this? This bug completely broke my game so now it has to be private until fixed.

Still occuring. Been left in the dark for 7 months, would love a update

Looping won’t work either

2 Likes

Not sure if it’s the same issue, but I have found that it consistently does nothing (including no console error) if you call Seat:Sit(Humanoid) where Seat is a locally created instance.

Seats that the server can see?
Works fine, sits every time.

Seats that only the client can see / the client has created?
Silent fail every time.

4 Likes

Same issue here. Attempted with retries and stuff too, no success. Doesn’t even let me sit down in a locally created seat by touching it