I think the title i开发者_如何学运维s pretty clear.
The way I see it is there are two things :
- the sprites for display
- the bodies for physics
Sprites can be moved in the screen when the level to display is to wide for the screen. But static bodies ? Can they be moved ? What's the pattern here ?
You scroll the graphics, not the objects in the world. They physics objects always stay at absolute coordinates, and you draw the graphics with an offset. Cocos2D doesn't really give you a camera or anything you can move around (well, not really anyway), you simply have to offset your entire scene.
精彩评论