What I’m attempting to achieve is the lines at the bottom to toggle open when the relevant page is open, it does work, but it isn’t as responsive and ends up toggling all of the options as shown here :
I use the GetPropertyChangedSignal event to signal a change in “Current Page” and in that function it recognises what page its on and animates some other things for my aesthetic needs and then fires a function to Tween the event like this:
local info = TweenInfo.new(
0.2,
Enum.EasingStyle.Linear,
Enum.EasingDirection.InOut
)
local goals = {
Position = UDim2.new(0.5, 0, 1, 0),
Size = UDim2.new(0, 0, 0.01, 0)
}
local tween = qTween:Create(instance,info,goals)
tween:Play()
end
I’ve tried to change the speed to 0.001 but does no justice
also could I say I’m using UIPageLayout
more of the script
PageHolder.UIPageLayout:GetPropertyChangedSignal("CurrentPage"):connect(function()
local CurrentPage = tostring(PageHolder.UIPageLayout.CurrentPage)
local switch
if CurrentPage == "MyGamesphere" then
switch = "Dot1"
local instance = MyGamesphereFrame.TextButton.Detail
animatestaytopbar(instance)
end
if CurrentPage == "Teams" then
switch = "Dot2"
local instance = TeamsFrame.TextButton.Detail
animatestaytopbar(instance)
end
if CurrentPage == "Store" then
switch = "Dot3"
local instance = StoreFrame.TextButton.Detail
animatestaytopbar(instance)
end
if CurrentPage == "Settings" then
switch = "Dot4"
local instance = SettingsFrame.TextButton.Detail
animatestaytopbar(instance)
end
local instance = MainFrame[switch].ActiveDot
local info = TweenInfo.new(
0.2,
Enum.EasingStyle.Bounce,
Enum.EasingDirection.InOut
)
local goals = {
Position = UDim2.new(0, 0, 0, 0),
Size = UDim2.new(0.471, 0, 0.719, 0)
}
local tween = qTween:Create(instance,info,goals)
tween:Play()
local children = {}
table.insert(children,MainFrame.Dot1)
table.insert(children,MainFrame.Dot2)
table.insert(children,MainFrame.Dot3)
table.insert(children,MainFrame.Dot4)
for i,v in pairs(children) do
if v.Name ~= switch then
local instance = v.ActiveDot
local info = TweenInfo.new(
0.2,
Enum.EasingStyle.Bounce,
Enum.EasingDirection.InOut
)
local goals = {
Position = UDim2.new(0, 0, 0, 0),
Size = UDim2.new(0.0, 0, 0.0, 0)
}
local tween = qTween:Create(instance,info,goals)
tween:Play()
end
end
end)
^^ Function to find the change in “CurrentPage”