Heres the code:
Line 11 is this: “if sound == 1 then” I dont see whats wrong…
local ui = require("ui")
local sound = 1
function createoptions
-- clearmainmenu()
if sound == 1 then
--Sound is ON
Sound = ui.newButton {
default = "buttonRed.png",
over = "buttonRedOver.png",
onPress = togglesound(1),
onRelease = togglesound(1),
text = "On",
emboss = true
}
else
Sound = ui.newButton{
default = "buttonRed.png",
over = "buttonRedOver.png",
onPress = togglesound(0),
onRelease = togglesound(0),
text = "Off",
emboss = true
}
end
end
[import]uid: 44393 topic_id: 8022 reply_id: 308022[/import]