So, I’ll explain this logically so you understand what is going on here, what you’re looking to do is to check if the button is toggled by using a bool i.e:
local Toggled = false
if Toggled == false then
Toggled = true
elseif Toggled == true then
Toggled = false
This will check if it is open or not, and set it accordingly. I will not give you the code DIRECTLY, so I’ll have you figure it out. So, what you want to do next is change the color of red to green, this can be done via this:
Frame.Color3 = Color3.fromRGB(0,255,0)
and then you want to set it’s position to the right, simply you can just add on the position to the frame that exists, which I’m assuming it does, and assuming it’s the red frame.
You do this:
Frame:TweenPosition(Frame.Position + UDim2.new(.5,0,0,0),"In","Sine",.1) -- You can change it to whatever you like.
Then to do it to un-toggle, you do it backwards. Good luck!