Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

What's wrong with Vector.3.new?

Asked by
Xianon 105
10 years ago

I test it but nothing happens and output does not return me any error or message.

local brick = script.Parent
local cd = script.Parent.ClickDetector
local RD = script.Parent.Parent.Door1.RD
local LD = script.Parent.Parent.Door1.LD
local RDS = script.Parent.Parent.Door1.RDS
local LDS = script.Parent.Parent.Door1.LDS




function onMouseClick(player)
    if not player then return end
        LD.BodyPosition.position = Vector3.new(0, 0, 5)
        LD.BodyPosition.maxForce = Vector3.new(0, 0, 5000)



    end



cd.MouseClick:connect(onMouseClick)


0
It's MaxForce. Shawnyg 4330 — 10y

1 answer

Log in to vote
-1
Answered by 10 years ago

Your use of the argument is wrong. It HAS to be clicked by a player, so the check is unneeded at line 11 and 12. Take out the argument and the whole of line 12 and try running it.

Ad

Answer this question