aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPetr Ilin <hevav@hevav.dev>2023-01-02 22:26:02 +0300
committerPetr Ilin <hevav@hevav.dev>2023-01-02 22:26:02 +0300
commit711a554a773184610b183405276ccc516907d872 (patch)
tree8844bf48c8b7aa9cc3150d2cc7677c6dd0f9d183 /src
parent30ca033a92526e51c0763b5fe1da38a5b476c799 (diff)
downloadLimboAuth-711a554a773184610b183405276ccc516907d872.tar.gz
LimboAuth-711a554a773184610b183405276ccc516907d872.tar.bz2
LimboAuth-711a554a773184610b183405276ccc516907d872.zip
disable-falling config option
Diffstat (limited to 'src')
-rw-r--r--src/main/java/net/elytrium/limboauth/Settings.java1
-rw-r--r--src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java6
2 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/net/elytrium/limboauth/Settings.java b/src/main/java/net/elytrium/limboauth/Settings.java
index 9f50164..29fa14b 100644
--- a/src/main/java/net/elytrium/limboauth/Settings.java
+++ b/src/main/java/net/elytrium/limboauth/Settings.java
@@ -140,6 +140,7 @@ public class Settings extends YamlConfig {
@Comment("World file type: \"schematic\" (1.12.2 and lower, not recommended), \"structure\" block .nbt (any Minecraft version is supported, but the latest one is recommended).")
public String WORLD_FILE_TYPE = "structure";
public String WORLD_FILE_PATH = "world.nbt";
+ public boolean DISABLE_FALLING = true;
@Comment("World time in ticks (24000 ticks == 1 in-game day)")
public long WORLD_TICKS = 1000L;
diff --git a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java
index b459008..a3c4e6f 100644
--- a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java
+++ b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java
@@ -120,7 +120,11 @@ public class AuthSessionHandler implements LimboSessionHandler {
this.player = player;
this.ip = this.proxyPlayer.getRemoteAddress().getAddress().getHostAddress();
- this.player.disableFalling();
+ if (Settings.IMP.MAIN.DISABLE_FALLING) {
+ this.player.disableFalling();
+ } else {
+ this.player.enableFalling();
+ }
Serializer serializer = LimboAuth.getSerializer();