Hi so i was making a press f to enter and leave the vehicle with the proximityprompt that worked very well with the left seats but i had problems with the right ones. Since when you leave the seat you get teleported 5 studs from the seat, in the right seats it will teleport you to the left making you going to the left seat. So you would say that i would need to change to -5, but its like its not updating, i even put -100 and it teleported me 5 studs still, i dont know why.
any help would be good
heres the script
local proximityPrompt = script.Parent
local seat = proximityPrompt.Parent
seat:GetPropertyChangedSignal("Occupant"):Connect(function()
if seat.Occupant then
proximityPrompt.Enabled = false
seat.Parent.Parent.Parent.DriveSeat:FindFirstChildWhichIsA("ProximityPrompt").Enabled = false
seat.Parent.SeatRR.ProximityPrompt.Enabled = false
seat.Parent.SeatRL.ProximityPrompt.Enabled = false
else
proximityPrompt.Enabled = true
seat.Parent.Parent.Parent.DriveSeat:FindFirstChildWhichIsA("ProximityPrompt").Enabled = true
seat.Parent.SeatRR.ProximityPrompt.Enabled = true
seat.Parent.SeatRL.ProximityPrompt.Enabled = true
end
end)
proximityPrompt.Triggered:Connect(function(player)
seat:Sit(player.Character.Humanoid)
end)
proximityPrompt.Triggered:Connect(function(player)
if player.Character.Humanoid.Sit == true then
player.Character.Humanoid.HumanoidRootPart.CFrame = player.Character.Humanoid.HumanoidRootPart.CFrame + Vector3.new(0, 0, -100)
end
end)
might i add that im so frustated with this, im 2 days just scripting to enter and leave a vehicle, there should be some official way of doing this.