Mastering Coordinate Systems and Sprites in 2D Games Quiz

  1. Understanding Local vs. World Coordinates

    In a 2D game scene, a sprite's local coordinates are (10, 20), and its parent object's world position is (200, 100); if the coordinate system is origin-at-top-left, what is the sprite's position in world coordinates?

    1. (210, 120)
    2. (10, 20)
    3. (190, 80)
    4. (-190, -80)
    5. (200, 120)
  2. Sprite Sheet Sub-Region Calculation

    Given a sprite sheet that is 256 pixels wide and 128 pixels tall containing 4 rows and 8 columns of equally sized sprites, what would be the correct pixel coordinates for the top-left corner of the sprite in row 3, column 5 (using zero-based indexing)?

    1. (160, 64)
    2. (128, 80)
    3. (32, 16)
    4. (100, 75)
    5. (64, 96)
  3. Effects of Different Axis Conventions

    In a 2D game engine where the positive Y-axis points down and the origin is at the top-left, which direction does an object move if its Y coordinate increases by 15 units?

    1. Down
    2. Left
    3. Right
    4. Up
    5. Out of Screen
  4. Origins and Rotation Behavior

    If you set a sprite's origin point to (0, 0) (the top-left corner) and rotate it by 90 degrees, how will the sprite's visual position change compared to rotating around its center?

    1. The sprite will rotate around the top-left and may partially move out of its original bounds.
    2. The rotation will look identical to rotating around the center.
    3. The sprite will flip horizontally without changing position.
    4. The rotation will occur around a random point on the sprite.
    5. The sprite remains stationary and does not rotate.
  5. Alpha Transparency and Layering

    In a 2D scene, two sprites are drawn at the same coordinates but on different layers, and the top-unvisible sprite uses a PNG image where some pixels have an alpha value of 0. What visual result is expected at those fully transparent pixels?

    1. Pixels from the lower sprite are visible through the transparent areas of the top sprite.
    2. The entire top sprite disappears, showing only the bottom one.
    3. Both sprites blend equally in the transparent regions.
    4. A magenta placeholder color appears where the top sprite is transparent.
    5. The transparent pixels appear as solid black.