This block of code seems to be the culprit for crashing my app in the Xcode Simulator.
audioBtn = display.newGroup()
if soundOn then
audioBtn:insert(display.newImage( "audio\_on.png", true))
else
audioBtn:insert(display.newImage( "audio\_off.png", true))
end
audioBtn.x = display.contentWidth - 80
audioBtn.y = display.contentHeight - 34
audioBtn:addEventListener("tap", onAudioBtn )
The images exist, are all lower case and I’ve not seen any evidence that the images are corrupt.
I’ve commented out the “if” leaving the creation of the group, the positioning of it and the event handler in place, still crashes. I’ve commented out the event handler. The only way it builds and runs in Xcode simulator is to comment out the whole block.
Any ideas?
I guess I could switch to a movie clip, to do this, but I’m not sure what else is going on.
Rob [import]uid: 19626 topic_id: 7705 reply_id: 307705[/import]