electrodynamics/archive/java/dark/lib/interfaces/IReadOut.java
2014-01-11 17:44:07 +08:00

37 lines
924 B
Java

package dark.lib.interfaces;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraftforge.common.ForgeDirection;
/**
* Simple way to control the read-out display over several tools when they are used on the
* tileEntity
*
* @author DarkGuardsman
*/
public interface IReadOut
{
/**
* Grabs the message displayed to the user on right click of the machine with the given tool
*
* @param user
* @param side - may not work correctly yet but should give you a side
* @return - a string to be displayed to the player for a reading. automatically adds ReadOut:
* to the beginning
*/
public String getMeterReading(EntityPlayer user, ForgeDirection side, EnumTools tool);
public static enum EnumTools
{
PIPE_GUAGE(), MULTI_METER();
public static EnumTools get(int meta)
{
if (meta < EnumTools.values().length)
{
return EnumTools.values()[meta];
}
return null;
}
}
}