(Would be great if someone with greater rep created the Citrus Engine tag and add it to this question)

I want to make a game where my inner starling stage dimensions are 320x240. My game will have three parts:

  • A vertical (left-aligned 32x208) toolbar in Rect(0, 0, 32, 208)
  • A horizontal (bottom-aligned 320x32) toolbar in Rect(0, 208, 320, 32)
  • The game content (right-top-aligned 288x208) in the remaining area: Rect(32, 0, 288, 208). It will be handled by the state, view, and camera.

The layout would look like this

My game would consist of only one playable state (which would render the level content by fetching the data from the server), and would be reset when the player goes to another map (other states are meaningless here since they are just form/UI states).

Please correct me if I'm wrong with these steps, and help me with the further:

  • I can set cameraLensWidth to 288px and cameraLensHeight to 208.
  • I can set the inner center to 0.5 and 0.5 with no deadZone (my game will require it), and set the bounds to Rect(0, 0, myMapWidth * tileWidth, myMapHeight * tileHeight) to track player movement only inside the map, and ensuring the camera follows the target by focusing it in its center (as long as it can).
  • What I don't know is how to ensure the camera top-left corner position be at (0, 32).

What must I do to ensure the last point?



You must log in to answer this question.

Browse other questions tagged .