yuh = workspace.yuh
original = script.Parent.Position
script.Parent.BodyPosition.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
while true do
script.Parent.Anchored= false
script.Parent.BodyPosition.Position = yuh.Position
wait(5)
script.Parent.BodyPosition.Position = original
wait(5)
end
it definitely worked! the platform moves really really fast though, is there any way i could change that? trying the other method too now also suggested by 3rdhoan123
i’ve used the script below, and I placed it in StarterPlayerScripts, but it doesn’t work, so i’m not sure if i’m putting it in the right place, i sort of tweaked it to make it work with my part, any help would be appreciated
local Players = game:GetService("Players")
local player = game.Players.LocalPlayer
local RunService = game:GetService('RunService')
local LastTrainCFrame
local Function
local Function2
Function = RunService.Heartbeat:Connect(function()
--------------------------------------------------------------- CHECK PLATFORM BELOW
local RootPart = player.Character.LowerTorso
local Ignore = player.Character
local ray = Ray.new(RootPart.CFrame.p,Vector3.new(0,-211,0))
local Hit, Position, Normal, Material = workspace:FindPartOnRay(ray,Ignore)
if Hit and Hit.Name == "MoveyWovey" then -- Change "RaftTop" to whatever the moving part's name is
--------------------------------------------------------------- MOVE PLAYER TO NEW POSITON FROM OLD POSITION
local Train = Hit
if LastTrainCFrame == nil then -- If no LastTrainCFrame exists, make one!
LastTrainCFrame = Train.CFrame -- This is updated later.
end
local TrainCF = Train.CFrame
local Rel = TrainCF * LastTrainCFrame:inverse()
LastTrainCFrame = Train.CFrame -- Updated here.
RootPart.CFrame = Rel * RootPart.CFrame -- Set the player's CFrame
--print("set")
else
LastTrainCFrame = nil -- Clear the value when the player gets off.
end
Function2 = player.Character.Humanoid.Died:Connect(function()
Function:Disconnect() -- Stop memory leaks
Function2:Disconnect() -- Stop memory leaks
end)
end)
GFink has helped me find a solution! I used AlignPosition and Attachments to make it work, whilst moving a goal brick back and forth. if anyone is looking at this and needs help, reply to this and i’ll help you out!
i can, yes! if you want to i can send you over a link to a model which i have made that has a script inside it and i’ll explain everything in that script?