Class SimpleBackend

java.lang.Object
dev.engine_room.flywheel.lib.backend.SimpleBackend
All Implemented Interfaces:
Backend

public final class SimpleBackend extends Object implements Backend
  • Constructor Details

    • SimpleBackend

      public SimpleBackend(int priority, Function<net.minecraft.world.level.LevelAccessor,Engine> engineFactory, BooleanSupplier isSupported)
  • Method Details

    • builder

      public static SimpleBackend.Builder builder()
    • createEngine

      public Engine createEngine(net.minecraft.world.level.LevelAccessor level)
      Description copied from interface: Backend
      Create a new engine instance.
      Specified by:
      createEngine in interface Backend
    • priority

      public int priority()
      Description copied from interface: Backend
      The priority of this backend.

      The backend with the highest priority upon first launch will be chosen as the default backend.

      If the selected backend becomes unavailable for whatever reason, the next supported backend with a LOWER priority than the selected one will be chosen.

      Specified by:
      priority in interface Backend
      Returns:
      The priority of this backend.
    • isSupported

      public boolean isSupported()
      Description copied from interface: Backend
      Check if this backend is supported.
      Specified by:
      isSupported in interface Backend