Skip to content

Latest commit

 

History

History
39 lines (33 loc) · 2.71 KB

Basics.MD

File metadata and controls

39 lines (33 loc) · 2.71 KB

Basic Space Engineers engine info

Units and position

  • The unit of distance in the game is one meter. Speed is in meters per second.
  • One big block size is 2.5 game meters. Some vectors are sent in meters, some are sent in "cubes".
  • Block size is in large cubes so for example 1x1x1 large block is 2.5x2.5x2.5 in meters.
  • Use enum CubeSize and/or LARGE_BLOCK_CUBE_SIDE_SIZE, SMALL_BLOCK_CUBE_SIDE_SIZE constants for converting.
  • 5 small blocks to one big block. (So small block cube is 0.5x0.5x0.5 meters.)
  • Engineer character can fit into space of 2x3x2 in small blocks (1x1.5x1 meters), however the size in the code is 1x1.8x1.
  • The position of character is at its bottom, the camera is not. The offset vector between the bottom of character and the camera in 1st person view is: (x=0, y=1.6369286, z=0). Use Character.DISTANCE_CENTER_CAMERA constant (or you can use the difference between position and camera position).
  • Block position is always between minPosition and maxPosition, but it doesn't always have to be in the center of the block (or sometimes it's identical to minPosition). To locate the center of the block, use midway between minPosition and maxPosition (extension function centerPosition) .

Character and camera orientation

  • The character forward vector is identical to the camera forward vector; when moving to a side, both forward vectors are changed.
  • The character up vector differs from the camera up vector when walking. Imagine character moving his head to look up rather than the whole body.
  • When jetpack is on, up vectors are identical. Imagine character rotating the whole body to look up.
  • This works for the 3rd person camera mode, unknown for other modes.
  • There is a possibility to move the camera around character. What is happening with internal variables has not been explored.

Blocks

The description of Blocks is in a separate file.