Interface SolaPlatform.GameLoopProvider

Enclosing class:
SolaPlatform
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface protected static interface SolaPlatform.GameLoopProvider
GameLoopProvider is a FunctionalInterface defining the contract for providing a GameLoop implementation for the sola game engine to use.
  • Method Details

    • create

      GameLoop create(EventHub eventHub, Consumer<Float> updateMethod, Runnable renderMethod, int targetUpdatesPerSecond)
      Creates a new GameLoop instance
      Parameters:
      eventHub - the EventHub instance
      updateMethod - the update method that is called each frame
      renderMethod - the render method that is called each frame
      targetUpdatesPerSecond - the target updates per second for the game loop
      Returns:
      a new GameLoop instance