I’m trying to build a set of scrolling bus destination signs. But I just can’t find why one of the frames of the SurfaceGuis is refusing to move despite the scripting being correct. (as far as I know.)
Here is the script for one of the buttons that is supposed to move the blinds.
It is supposed to work by moving the Y offset of each Guis position. The front and back is to that the text is displayed on both sides of the part that the SGUIs are on. Oddly the back one works fine but the FRONT one is just not working. Output shows absolutely no errors or anything.
local Blind = script.Parent.Parent.Blind
function scroll()
Held = true
print(Held)
while Held == true do
if Blind.Front.Frame.Position.Y.Offset > -379 then
Blind.Front.Frame.Position = UDim2.new(Blind.Front.Frame.Position.X.Scale, Blind.Front.Frame.Position.X.Offset, Blind.Front.Frame.Position.Y.Scale, (Blind.Front.Frame.Position.Y.Offset - 0.01))
Blind.Back.Frame.Position = UDim2.new(0, 150, 0, (Blind.Back.Frame.Position.Y.Offset - 0.01) -60 )
print("Scrolling")
end
wait()
end
end
function Stop()
Held = false
print(Held)
end
script.Parent.SurfaceGui.TextButton.MouseButton1Up:Connect(Stop)
script.Parent.SurfaceGui.TextButton.MouseButton1Down:Connect(scroll)
For context as to how this script is supposed to work then I’ve attached the model of the blinds here.
broken dest blinds.rbxm (13.5 KB)
I’ve got to the point where I’m ready to just ditch this…
edit: Don’t mind the other script that is there that says RHB BMC BLINDS. That’s just a leftover from the original system the blind used.