Player not moving with vehicle seat

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!
    I want the player to be teleported while staying seated in the vehicle seat.

  2. What is the issue? Include screenshots / videos if possible!
    Upon the ship teleporting, the player gets out of the vehicle seat (not sure why) and is left behind, while the ship teleports without the player. The weld that is automatically created to keep the player welded to the vehicle seat upon the player sitting down is also deleted. Any welds that I try to create manually are automatically disabled.

  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I have tried:

  • Creating a new weld, setting the part0 to the seat and and setting the part1 to the player’s HumanoidRootPart, then parenting it to the seat. However, this results in the weld being deleted upon teleporting, which I presume is caused by the player inexplicably standing up, or the weld just being automatically deleted. I have also tried this method but switching around the part0 and part1.

  • Using RunService.Heartbeat to constantly teleport the player to the position of the seat, although this is incredibly erratic and throws the player around within the cabin.

  • Using RunService.RenderStepped to constantly change the character’s Humanoid State to seated.

Example:

1 Like

After teleporting the model, use Seat:Sit(humanoid)

local seat = the seat the player is sitting in
seat:Sit(players humanoid)

Also, what type of welds are you using? How are you teleporting the model?

1 Like

I’m using Model:MoveTo() to teleport the model and I’m using a weld constraint. But wouldn’t this result in the player just being teleported into the ship shortly after being kicked out of it? The goal is to have them remain within the ship the entire time.

I think I’ll just use RunService.Heartbeat in coordination with Seat:Sit(Humanoid) in order to have the player remain seated for the duration of the journey.

I just added values to the original position and my character teleported along while sitting down.

Ah okay. It’s because of MoveTo()
Just tried it in game and I had the same result where I got ‘popped out of my seat’ when I use moveto.

create a primarypart for the model and weld it’s parts:

for _, desc in pairs(THE MODEL:GetDescendants())do
	if desc("BasePart") or desc:IsA("UnionOperation") then
		local weldConstraint = Instance.new("WeldConstraint")
		weldConstraint.Part0 = desc
		weldConstraint.Part1 = script.Parent.Parent.PrimaryPart
		weldConstraint.Parent = desc
		desc.Anchored = false
	end
end

then move the model with cframe instead of using moveto():

model.PrimaryPart.CFrame = CFrame.new(the position you want the car to move to)

3 Likes

Im having a similar problem with the vehicle seat, since I’ve been working on days on my car, but when people test it they can’t drive, I figured out why, and its beacuse they have a blocky body, I need help fixing that, please answer if you can help me, thanks.

Thank you, I was having the same problem, instead of MoveTo, it was PivotTo that was causing the model to not move the seated humanoids.