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

If part is at specific location, then it will print something, how?

Asked by 4 years ago

I'm doing a script that when a part is on the specific location, then the code will run but I can't think of any idea to make that... Any ideas?

1 answer

Log in to vote
0
Answered by
Velsity 218 Moderation Voter
4 years ago
local YourPosition = Vector3.new(0,0,0)
workspace.Baseplate:GetPropertyChangedSignal("Position"):Connect(function()
    if workspace.Baseplate.Position == YourPosition then
        print("yeee")
    end
end)

This will fire whenever the position has been changed, and then it will check if it is at your position. (YourPosition) variable.

Ad

Answer this question