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

Vector3 not respecting "collisions" box being unchecked?

Asked by 5 years ago

I am making a door that will open when touched by a specific NPC, that works fine so far, but I am having a problem, when I want this function between the door and the NPC to happen a Vector3 command will be sent for put the door back to it's original position (I did this for prevent the door from moving multiple times with a CFrame command I used, since debounce isn't working):

door1.Position = Vector3.new(-5.93, 4.05, -10.925)
door2.Position = Vector3.new(-6.43, 4.05, -11.675)

When this happens the door won't return to it's original position, instead it will be put on top of the door's frame, despite the "Collisions" box being unchecked.

0
try editing its cframe CjayPlyz 643 — 5y
0
Since the debounce isn't working properly and causing the "OnTouch" function to repeat multiple times, editing the CFrame will cause a huge mess as it will need just one player to spam this Function and mess it up. MasterChanneLXL 7 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago
Edited 5 years ago

I suggest you change the CFrame of the part instead of the Position if you want it to be accurate.

All you have to do is:

door1.CFrame= CFrame.new(Vector3.new(-5.93, 4.05, -10.925))
door2.CFrame= CFrame.new(Vector3.new(-6.43, 4.05, -11.675))

0
Thank you! MasterChanneLXL 7 — 5y
Ad

Answer this question