Answered by
4 years ago Edited 4 years ago
To directly answer your question
It is because crusher.Position(Vector3.new(57.89, 12.335, 5.205)
does not have a second closing bracket.
Long answer
I doubt this would do anything anyway. Its hard to tell what you are trying to do. I assume you want to move the crusher
when it reaches a certain position. If so it should look like this:
1 | local crusher = game.Workspace.Crusher.Crusher |
3 | if crusher.position = = Vector 3. new( 57.89 , 12.335 , 5.205 ) then |
4 | crusher.Position = Vector 3. new( 57.89 , - 2.665 , 5.205 ) |
Lets break this down
if crusher.position == Vector3.new(57.89, 12.335, 5.205) then
this is how comparative statements should look, you have the first value (crusher.position
) then a comparative operator (==
) lastly the second value (Vector3.new(57.89, 12.335, 5.205)
). This will only execute the code contained within it when value one is exactly equal to value two.
crusher.Position = Vector3.new(57.89, -2.665, 5.205)
this is how you set variables, you have your first value (crusher.Position
) an equal sign and your second value that you will append to the first (Vector3.new(57.89, -2.665, 5.205)
).
Though I'm not sure if this is the goal.