Class GameEngine

java.lang.Object
com.toxicrain.rainengine.core.GameEngine

public class GameEngine extends Object
  • Field Details

    • windowManager

      public static com.github.strubium.windowmanager.window.WindowManager windowManager
    • gamePaused

      public static boolean gamePaused
  • Constructor Details

    • GameEngine

      public GameEngine()
  • Method Details

    • run

      public static void run()
    • drawMap

      public static void drawMap(BatchRenderer batchRenderer)
    • createPerspectiveProjectionMatrix

      public static FloatBuffer createPerspectiveProjectionMatrix(float fov, float aspectRatio, float near, float far)
      Creates a perspective projection matrix.
      Parameters:
      fov - the field of view angle in degrees
      aspectRatio - the aspect ratio of the viewport (width/height)
      near - the distance to the near clipping plane
      far - the distance to the far clipping plane
      Returns:
      a FloatBuffer containing the perspective projection matrix
    • getPerspectiveProjectionMatrixBuffer

      public static FloatBuffer getPerspectiveProjectionMatrixBuffer()
      Gets the perspective projection matrix.
      Returns:
      The FloatBuffer containing the perspective projection matrix