From e117bfac912736ac01eba26d4a8291835bef8f81 Mon Sep 17 00:00:00 2001 From: GanyusLeftHorn <1244229+GanyusLeftHorn@users.noreply.github.com> Date: Fri, 24 Jun 2022 11:21:16 -0700 Subject: [PATCH] Move worldlevel for World to Player::setWorldLevel --- src/main/java/emu/grasscutter/game/player/Player.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/emu/grasscutter/game/player/Player.java b/src/main/java/emu/grasscutter/game/player/Player.java index 932148c9d..b2d13879c 100644 --- a/src/main/java/emu/grasscutter/game/player/Player.java +++ b/src/main/java/emu/grasscutter/game/player/Player.java @@ -447,6 +447,8 @@ public class Player { } public void setWorldLevel(int level) { + this.getWorld().setWorldLevel(newWorldLevel); + this.setProperty(PlayerProperty.PROP_PLAYER_WORLD_LEVEL, level); this.sendPacket(new PacketPlayerPropNotify(this, PlayerProperty.PROP_PLAYER_WORLD_LEVEL)); @@ -545,7 +547,6 @@ public class Player { 0; if (newWorldLevel != currentWorldLevel) { - this.getWorld().setWorldLevel(newWorldLevel); this.setWorldLevel(newWorldLevel); } }