FakePlayer: Player null check

This commit is contained in:
noil 2021-03-04 22:48:20 -05:00
parent a37d2092a5
commit bd0cc23834

View File

@ -24,7 +24,7 @@ public final class FakePlayerModule extends Module {
@Override
public void onEnable() {
super.onEnable();
if (mc.world != null) {
if (mc.player != null && mc.world != null) {
entity = new EntityOtherPlayerMP(mc.world, new GameProfile(mc.player.getUniqueID(), username.getValue()));
entity.copyLocationAndAnglesFrom(mc.player);
entity.inventory.copyInventory(mc.player.inventory);