Codez_X
(Maidenless)
May 1, 2020, 2:38pm
#2
Moving doors?Do you mean open then door by clicking or pressing f?
No, look at video please…
Im trying to make doors move even when they are anchored (soo players cant push them)
NilFloat
(NilFloat)
May 1, 2020, 2:40pm
#4
So you are changing value of CFrame as model (are the doors model)?
You can still change the CFrame with the part anchored. If you’re using it already you don’t need to change anything
1 Like
I cant it wont move when anchored
It moves Open1 and Open2 and Union and Part moves with it
Ah, you can use :SetPrimaryPartCFrame () instead and put the parts for each door in a model. This will allow you to maintain the same behaviour
NilFloat
(NilFloat)
May 1, 2020, 2:45pm
#9
You can try to weld them to the primary part and then change the CFrame.
luketeam5
(luketeam5)
May 1, 2020, 2:57pm
#10
Ye but people are still able to push it
NilFloat
(NilFloat)
May 1, 2020, 2:59pm
#11
Yeah and anchor them now. I use TweenService on anchored parts also welded to primary part and animations works.
luketeam5
(luketeam5)
May 1, 2020, 3:00pm
#12
Soo if i use tween it should work?
0V_ex
(vex)
May 1, 2020, 3:03pm
#13
CFrame manipulation would work too. Make sure your part is anchored by default.
PS: Did not read the replies, gonna do that now.
NilFloat
(NilFloat)
May 1, 2020, 3:03pm
#14
Yeah, but I had to weld other parts, I had an model with different parts and those had to move at the same time as primary part but because you have doors is just a little bit more complicated because you will need different tweens to use just because of two seperate doors which are moving.
0V_ex
(vex)
May 1, 2020, 3:04pm
#15
That’s clearly because the Union is a child of the door. If a parent is moving, its children would move along with it too.
luketeam5
(luketeam5)
May 1, 2020, 3:05pm
#16
Ye i know that, but i need to make it anchored but still be able to move it using CFrame
0V_ex
(vex)
May 1, 2020, 3:06pm
#17
Anchor the door, and all its children. Then try your script. If it still doesn’t work, would you mind showing us the script?
luketeam5
(luketeam5)
May 1, 2020, 3:07pm
#18
Can you give me tween (moving script) example?
EDIT: I need to move it (0,0,-2)
and then after -2 finishes: (0,0.5,0)
Better solution by @colbert2677
Edit (06/30/2021): Due to the release of the new pivot APIs and the thankful deprecation of SetPrimaryPartCFrame, the legacy method of CFraming is now also appropriate and you do not necessarily need to use this welding method. Do note that the pivot CFrame is different from the PrimaryPart CFrame though, so you will have to account for that when writing your proxy objects.
Edit (05/31/2023): Roblox has an official code sample for model tweening! It’s very lightweight and covers the necessities…
1 Like
luketeam5
(luketeam5)
May 1, 2020, 3:17pm
#20
GetPrimaryPartCFrame is not a valid member of part