Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How can I fix the position?

Something's gone wrong here and I can't get the right coding to position the ball. Can you please help edit it?

SoccerBall = game.Workspace.Part8

Workspace.Part6.CanCollide = false

function Touched(SoccerBall)
	Workspace.Part6.Decal1.Transparency = 0
	Workspace.Part6.CanCollide = false
	wait(3)
	Workspace.Part6.Decal1.Transparency = 1
	Workspace.Part6.CanCollide = true
	SoccerBall.Position = -198.29, 2.28, -111.29
	wait(3)
	Workspace.Part6.Cancollide = false
	
end

script.Parent.Touched:connect(Touched)

Line 11 is the one I want fixing. Could you please help? Thanks!

1 answer

✓ Accepted answer

Position is a single Vector3 value.

SoccerBall.Position = -198.29, 2.28, -111.29

Must be:

SoccerBall.Position = Vector3.new(-198.29, 2.28, -111.29)

2 comments

1

Thank you very much! That has helped me heaps!

0

You're welcome. :-)

This discussion is preserved as it was. New answers, comments, and votes are closed.