Apollo
Developers
Mods
ToggleSneak

Toggle Sneak/Sprint

Make the sprinting and sneaking keys toggleable instead of needing to be held down.

Integration

How to toggle the mod

public void toggleToggleSneakSprintExample(Player viewer, boolean value) {
    Optional<ApolloPlayer> apolloPlayerOpt = Apollo.getPlayerManager().getPlayer(viewer.getUniqueId());
    apolloPlayerOpt.ifPresent(apolloPlayer -> this.modSettingModule.getOptions().set(apolloPlayer, ModToggleSneak.ENABLED, value));
}

Available options

  • ENABLED

    • Config Key: enabled
    • Values
      • Type: Boolean
      • Default: true
  • TOGGLE_SPRINT

    • Config Key: toggle-sprint
    • Values
      • Type: Boolean
      • Default: true
  • TOGGLE_SNEAK

    • Config Key: toggle-sneak
    • Values
      • Type: Boolean
      • Default: false
  • TOGGLE_SNEAK_CONTAINER

    • Config Key: toggle-sneak-container
    • Values
      • Type: Boolean
      • Default: false
  • DOUBLE_TAP

    • Config Key: double-tap
    • Values
      • Type: Boolean
      • Default: true
  • FLY_BOOST

    • Config Key: fly-boost
    • Values
      • Type: Boolean
      • Default: true
  • FLY_BOOST_AMOUNT

    • Config Key: fly-boost-amount
    • Values
      • Type: Integer
      • Default: 4
      • Minimum: 2
      • Maximum: 8