Interface Elytra


@NonExtendable @RenderThread public interface Elytra
Elytra flight the way strict servers check it, shared by every flight module so that two of them never fight over the glide (each would otherwise hold back the same pings and swap the same chest slot): To change the glide's movement itself (fly it at a set speed, boost it), listen to GlideEvent.
private final NoDurability noDurability = Myriad.elytra().noDurability(this);

protected void onEnable() {
    Myriad.elytra().addPilot(this);   // this implements Elytra.Pilot
    noDurability.enable();
}
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    A flight module flying the local player.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Lets pilot fly the local player until removePilot(Elytra.Pilot).
    A flight for owner that crosses open country without fireworks, for any server: it dives until fast, pulls up and eases back to level, which holds its height, about 27 blocks a second (about 18 with No Durability where Grim simulates the glide, so 2b2t's chunks come in ahead of it).
    The chest swapper, shared by every flight.
    A flight for owner that flies straight along its heading at a set speed, holding a height, only where the server doesn't simulate the glide (AntiCheat.Profile#simulatesGlide() false: NoCheatPlus, singleplayer); Grim sets it back from the first tick.
    The glide hold, shared by every flight; one owner arms it at a time.
    A new No Durability engine for owner's flight: enable it when the flight starts.
    void
    Stops pilot flying the local player; nothing happens if it wasn't added.
  • Method Details

    • addPilot

      void addPilot(Elytra.Pilot pilot)
      Lets pilot fly the local player until removePilot(Elytra.Pilot).
    • removePilot

      void removePilot(Elytra.Pilot pilot)
      Stops pilot flying the local player; nothing happens if it wasn't added. Call it when the module turns off.
    • noDurability

      NoDurability noDurability(NoDurability.Owner owner)
      A new No Durability engine for owner's flight: enable it when the flight starts. Each call makes another; keep the one you get.
    • chestSwap

      ChestSwap chestSwap()
      The chest swapper, shared by every flight.
    • altitude

      Flight altitude(NoDurability.Owner owner)
      A flight for owner that crosses open country without fireworks, for any server: it dives until fast, pulls up and eases back to level, which holds its height, about 27 blocks a second (about 18 with No Durability where Grim simulates the glide, so 2b2t's chunks come in ahead of it). It takes off only from the air. The owner says whether to keep the elytra from wearing and hears its messages.
    • control

      Flight control(NoDurability.Owner owner)
      A flight for owner that flies straight along its heading at a set speed, holding a height, only where the server doesn't simulate the glide (AntiCheat.Profile#simulatesGlide() false: NoCheatPlus, singleplayer); Grim sets it back from the first tick. Speed builds as fast as NoCheatPlus's elytra check allows. It takes off from the ground by itself while it has a speed.
    • glideHold

      GlideHold glideHold()
      The glide hold, shared by every flight; one owner arms it at a time.