2014-01-27 05:00:36 +01:00
|
|
|
package appeng.core.features.registries;
|
|
|
|
|
2014-07-09 22:07:53 +02:00
|
|
|
import com.mojang.authlib.GameProfile;
|
|
|
|
|
2014-01-27 05:00:36 +01:00
|
|
|
import net.minecraft.entity.player.EntityPlayer;
|
|
|
|
import appeng.api.features.IPlayerRegistry;
|
|
|
|
import appeng.core.WorldSettings;
|
|
|
|
|
|
|
|
public class PlayerRegistry implements IPlayerRegistry
|
|
|
|
{
|
|
|
|
|
|
|
|
@Override
|
2014-07-09 22:07:53 +02:00
|
|
|
public int getID(GameProfile username)
|
2014-01-27 05:00:36 +01:00
|
|
|
{
|
|
|
|
return WorldSettings.getInstance().getPlayerID( username );
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public int getID(EntityPlayer player)
|
|
|
|
{
|
2014-07-09 22:07:53 +02:00
|
|
|
return WorldSettings.getInstance().getPlayerID( player.getGameProfile() );
|
2014-01-27 05:00:36 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|