Game Development Reference
In-Depth Information
For reference, here's what I saw in my log when the launch failed:
D/OpenGLRenderer(11473): GL error from OpenGLRenderer: 0x502
E/OpenGLRenderer(11473):
GL_INVALID_OPERATION
Following that: nothing. The app just stopped launching.
Turning on OpenGL traces fixed that problem for me; when I turned it off, the app failed
to launch again. If you get the same freeze with the same error message, check if enabling
OpenGL traces fixes that problem for you too. Since it doesn't hurt to have this option en-
abled, you can just leave it turned on.
Confirming Deployment to Android
When you create a new SpriteBuilder project with SpriteBuilder v1.3 or later, it will auto-
matically have support for Android built-in.
Over the course of the topic, you've already created a decently complex project, and
maybe you know this adage: “Complex systems tend to have complex problems.” There-
fore, it's best to rule out as many additional problems first by trying Android support with
a new SpriteBuilder project. You can either follow the descriptions here or open the 14 -
HelloSpriteBuilder Android project.
Creating a New SpriteBuilder Project
Open SpriteBuilder, and select File New Project to create a new project. Name it
HelloSpriteBuilder , and save it wherever you like. (Your Documents folder would be a
good choice.) The new project contains a MainScene.ccb with a color node and the
SpriteBuilder logo.
Have a quick look at the File Project Settings dialog. You'll see both iOS and Android
platforms selected, as shown in Figure 13-9 . This means SpriteBuilder will publish two
sets of resources, one for iOS and one for Android. You can deselect the phone , phonehd ,
tablet , and tablethd resources for each platform individually. For now, leave them all se-
lected.
Search WWH ::




Custom Search