From cc6373646625cf2a05de665d92f4c6e687f27e82 Mon Sep 17 00:00:00 2001 From: Sollace Date: Wed, 12 Sep 2018 02:26:07 +0200 Subject: [PATCH] Fixed errors executing commands --- .../unicopia/command/CommandOverrideGameMode.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/minelittlepony/unicopia/command/CommandOverrideGameMode.java b/src/main/java/com/minelittlepony/unicopia/command/CommandOverrideGameMode.java index e4c08765..986f9cea 100644 --- a/src/main/java/com/minelittlepony/unicopia/command/CommandOverrideGameMode.java +++ b/src/main/java/com/minelittlepony/unicopia/command/CommandOverrideGameMode.java @@ -1,6 +1,6 @@ package com.minelittlepony.unicopia.command; -import com.minelittlepony.unicopia.player.IPlayer; +import com.minelittlepony.unicopia.player.PlayerSpeciesList; import net.minecraft.command.CommandException; import net.minecraft.command.CommandGameMode; @@ -37,7 +37,7 @@ class CommandOverrideGameMode extends CommandGameMode { boolean flying = player.capabilities.isFlying; player.setGameType(m); - player.capabilities.isFlying = ((IPlayer)player).getPlayerSpecies().canFly(); + player.capabilities.isFlying = PlayerSpeciesList.instance().getPlayer(player).getPlayerSpecies().canFly(); if (flying != player.capabilities.isFlying) { player.sendPlayerAbilities();