local brick=script.Parent 
while true  do 
	wait()
	
	for I=1,20 do 
		
		brick.CFrame=brick.CFrame+Vector3.new(1,0,0) 
		wait() 
	end 
	
	
	wait(1) 
	
	for I=1,20 do 
		
		brick.CFrame=brick.CFrame+Vector3.new(-1,0,0) 
		wait()
		
	end
	wait(1)
end 


this is what i did for now but the player doesnt stick on the part. any ideas??

2 comments

0

Don’t use CFrame, it just creates the illusion of movement. It won’t have any effect on your character... here, use this: https://developer.roblox.com/en-us/api-reference/class/BodyPosition

0

im familliar with the bodyPosition but i dont know how to modify it so the player will move with the part. can someone maybe give me an example of how to do it and the script?