Hi, I have a problem with tweening parts which are inside a ViewportFrame. It`s a book which is supposed to open with these lines of code:
local GuiPageRotatingPart = ViewPortFrame.RecipeGuibook.BookLidRotatingPart
local OpenGuiTweenInf = TweenInfo.new(1, Enum.EasingStyle.Quad, Enum.EasingDirection.Out)
local OpenGuiTweenGoal = {CFrame = GuiPageRotatingPart.CFrame * CFrame.Angles(0, 0, math.rad(180))}
local OpenGuiTweenAnimation = TweenService:Create(GuiPageRotatingPart, OpenGuiTweenInf, OpenGuiTweenGoal)
OpenGuiTweenAnimation:Play()
(The green line here shows how its welded to each other.)
Now I have a problem. I’ve read some posts where people say that ViewportFrames have diffrent dynamics than in the workspace. So that means welds won’t work as they are supposed to.
The only thing spinning here is the small red marked part which is supposed to spin the booklid with it because it’s welded to each other.
(And yes everything is how it’s supposed to be. Everything is correctly welded and not anchored except if something needs to be anchored. It also works if I put it into the workspace.)
If there isn’t a way to do it with welds inside a ViewportFrame, do I need to do it with a script? And how would I make it rotate like this?
(This is the same model but in the workspace instead of the ViewportFrame inside the PlayerGui)