pagenum = ""
local pgnum = script.Parent.Parent.PGNUM.Value
if pgnum == "2" then
function onclicked()
pagenum = 2-1
pgnum = 2
script.Parent.Parent.pg.Text = "Page "..pagenum..""
script.Parent.Parent.pg1.Visible = true
script.Parent.Parent.pg2.Visible = false
end
end
script.Parent.MouseButton1Down:connect(onclicked)
It's supposed to act like a click change page type thing. You click the right arrow, it changes pgnum to 2, then left arrow checks if the value of pgnum is 2. if it is then if you press the left arrow it will go back to page 1
but the value doesn't change, why?
