mirror of
https://github.com/GTNewHorizons/EnderIO.git
synced 2026-11-27 23:45:55 +00:00
Removed unused parts of TE API.
This commit is contained in:
1 parent
99a26b37dd
commit
9717f543a0
16 files changed
-471
No files matched your search
@@ -1,33 +0,0 @@
|
||||
package cofh.api.block;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
/**
|
||||
* Implement this interface on blocks which have some debug method which can be activated via a tool or other means.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IBlockDebug {
|
||||
|
||||
/**
|
||||
* This function debugs a block.
|
||||
*
|
||||
* @param world
|
||||
* Reference to the world.
|
||||
* @param x
|
||||
* X coordinate of the block.
|
||||
* @param y
|
||||
* Y coordinate of the block.
|
||||
* @param z
|
||||
* Z coordinate of the block.
|
||||
* @param side
|
||||
* The side of the block.
|
||||
* @param player
|
||||
* Player doing the debugging.
|
||||
*/
|
||||
public void debugBlock(IBlockAccess world, int x, int y, int z, ForgeDirection side, EntityPlayer player);
|
||||
|
||||
}
|
||||
@@ -1,39 +0,0 @@
|
||||
package cofh.api.block;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Implement this interface on blocks which can provide information about themselves.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IBlockInfo {
|
||||
|
||||
/**
|
||||
* This function appends information to a list provided to it.
|
||||
*
|
||||
* @param world
|
||||
* Reference to the world.
|
||||
* @param x
|
||||
* X coordinate of the block.
|
||||
* @param y
|
||||
* Y coordinate of the block.
|
||||
* @param z
|
||||
* Z coordinate of the block.
|
||||
* @param side
|
||||
* The side of the block that is being queried.
|
||||
* @param player
|
||||
* Player doing the querying - this can be NULL.
|
||||
* @param info
|
||||
* The list that the information should be appended to.
|
||||
* @param debug
|
||||
* If true, the Block should return "debug" information.
|
||||
*/
|
||||
public void getBlockInfo(IBlockAccess world, int x, int y, int z, ForgeDirection side, EntityPlayer player, List<String> info, boolean debug);
|
||||
|
||||
}
|
||||
@@ -1,25 +0,0 @@
|
||||
package cofh.api.block;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
/**
|
||||
* Implemented on Blocks which have some method of being instantly dismantled.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IDismantleable {
|
||||
|
||||
/**
|
||||
* Dismantles the block. If returnBlock is true, the drop(s) should be placed into the player's inventory.
|
||||
*/
|
||||
public ItemStack dismantleBlock(EntityPlayer player, World world, int x, int y, int z, boolean returnBlock);
|
||||
|
||||
/**
|
||||
* Return true if the block can be dismantled. The criteria for this is entirely up to the block.
|
||||
*/
|
||||
public boolean canDismantle(EntityPlayer player, World world, int x, int y, int z);
|
||||
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
package cofh.api.core;
|
||||
|
||||
/**
|
||||
* Interface which can be put on just about anything to allow for iteration during initialization.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IInitializer {
|
||||
|
||||
public boolean preInit();
|
||||
|
||||
public boolean initialize();
|
||||
|
||||
public boolean postInit();
|
||||
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
package cofh.api.core;
|
||||
|
||||
/**
|
||||
* Basic interface for the Cape and Skin Registries.
|
||||
*
|
||||
* @author Zeldo Kavira
|
||||
*
|
||||
*/
|
||||
public interface ISimpleRegistry {
|
||||
|
||||
/**
|
||||
* Register a new entry.
|
||||
*
|
||||
* @param playerName
|
||||
* The player to register.
|
||||
* @param URL
|
||||
* Location of the cape/skin.
|
||||
* @return True if registration was successful.
|
||||
*/
|
||||
public boolean register(String playerName, String URL);
|
||||
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
package cofh.api.core;
|
||||
|
||||
/**
|
||||
* Dummy class used to initialize Cape and Skin Registries to prevent accidental NPEs.
|
||||
*
|
||||
* @author Zeldo Kavira
|
||||
*
|
||||
*/
|
||||
public class NullSimpleRegistry implements ISimpleRegistry {
|
||||
|
||||
@Override
|
||||
public boolean register(String playerName, String URL) {
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
package cofh.api.core;
|
||||
|
||||
/**
|
||||
* Access to the Cape and Skin Registries of CoFH Core.
|
||||
*
|
||||
* @author Zeldo Kavira
|
||||
*
|
||||
*/
|
||||
public class RegistryAccess {
|
||||
|
||||
public static ISimpleRegistry capeRegistry = new NullSimpleRegistry();
|
||||
public static ISimpleRegistry skinRegistry = new NullSimpleRegistry();
|
||||
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
/**
|
||||
* Implement this interface on Tile Entities which can report information about their energy usage.
|
||||
*
|
||||
* This is used for reporting purposes - Energy transactions should be handled through IEnergyHandler!
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IEnergyInfo {
|
||||
|
||||
public int getEnergyPerTick();
|
||||
|
||||
public int getMaxEnergyPerTick();
|
||||
|
||||
public int getEnergy();
|
||||
|
||||
public int getMaxEnergy();
|
||||
|
||||
}
|
||||
@@ -1,39 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
/**
|
||||
* Implement this interface on Tile Entities which allow for reconfiguration of their facing.
|
||||
*
|
||||
* Coordination with the containing block is required.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IReconfigurableFacing {
|
||||
|
||||
/**
|
||||
* Returns the current facing of the block.
|
||||
*/
|
||||
public int getFacing();
|
||||
|
||||
/**
|
||||
* Returns whether or not the block's face can be aligned with the Y Axis.
|
||||
*/
|
||||
public boolean allowYAxisFacing();
|
||||
|
||||
/**
|
||||
* Attempt to rotate the block. Arbitrary based on implementation.
|
||||
*
|
||||
* @return True if rotation was successful, false otherwise.
|
||||
*/
|
||||
public boolean rotateBlock();
|
||||
|
||||
/**
|
||||
* Set the facing of the block.
|
||||
*
|
||||
* @param side
|
||||
* The side to set the facing to.
|
||||
* @return True if the facing was set, false otherwise.
|
||||
*/
|
||||
public boolean setFacing(int side);
|
||||
|
||||
}
|
||||
@@ -1,54 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
/**
|
||||
* Implement this interface on Tile Entities which allow for reconfiguration of their sides.
|
||||
*
|
||||
* Coordination with the containing block is required.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IReconfigurableSides {
|
||||
|
||||
/**
|
||||
* Decrement the config for a given side.
|
||||
*
|
||||
* @param side
|
||||
* The side to decrement.
|
||||
* @return True if config was changed, false otherwise.
|
||||
*/
|
||||
public boolean decrSide(int side);
|
||||
|
||||
/**
|
||||
* Increment the config for a given side.
|
||||
*
|
||||
* @param side
|
||||
* The side to decrement.
|
||||
* @return True if config was changed, false otherwise.
|
||||
*/
|
||||
public boolean incrSide(int side);
|
||||
|
||||
/**
|
||||
* Set the config for a given side.
|
||||
*
|
||||
* @param side
|
||||
* The side to set.
|
||||
* @param config
|
||||
* The config value to use.
|
||||
* @return True of config was set, false otherwise.
|
||||
*/
|
||||
public boolean setSide(int side, int config);
|
||||
|
||||
/**
|
||||
* Reset configs on all sides to their base values.
|
||||
*
|
||||
* @return True if reset was successful, false otherwise.
|
||||
*/
|
||||
public boolean resetSides();
|
||||
|
||||
/**
|
||||
* Returns the number of possible config settings for a given side.
|
||||
*/
|
||||
public int getNumConfig(int side);
|
||||
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
public interface ISecureTile {
|
||||
|
||||
public static enum AccessMode {
|
||||
PUBLIC, RESTRICTED, PRIVATE;
|
||||
|
||||
public boolean isPublic() {
|
||||
|
||||
return this == PUBLIC;
|
||||
}
|
||||
|
||||
public boolean isRestricted() {
|
||||
|
||||
return this == RESTRICTED;
|
||||
}
|
||||
|
||||
public boolean isPrivate() {
|
||||
|
||||
return this == PRIVATE;
|
||||
}
|
||||
|
||||
public static AccessMode stepForward(AccessMode curAccess) {
|
||||
|
||||
return curAccess == AccessMode.PUBLIC ? AccessMode.RESTRICTED : curAccess == AccessMode.PRIVATE ? AccessMode.PUBLIC : AccessMode.PRIVATE;
|
||||
}
|
||||
|
||||
public static AccessMode stepBackward(AccessMode curAccess) {
|
||||
|
||||
return curAccess == AccessMode.PUBLIC ? AccessMode.PRIVATE : curAccess == AccessMode.PRIVATE ? AccessMode.RESTRICTED : AccessMode.PUBLIC;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean setAccess(AccessMode access);
|
||||
|
||||
public AccessMode getAccess();
|
||||
|
||||
public boolean setOwnerName(String name);
|
||||
|
||||
public String getOwnerName();
|
||||
|
||||
public boolean canPlayerAccess(String name);
|
||||
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
/**
|
||||
* Implement this interface on Tile Entities which can change their block's texture based on the current render pass. The block must defer the call to its Tile
|
||||
* Entity.
|
||||
*
|
||||
* @author Zeldo Kavira
|
||||
*
|
||||
*/
|
||||
public interface ISidedBlockTexture {
|
||||
|
||||
public IIcon getBlockTexture(int side, int pass);
|
||||
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
package cofh.api.tileentity;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
||||
/**
|
||||
* Implement this interface on Tile Entities which can send state information through chat.
|
||||
*
|
||||
* @author Zeldo Kavira
|
||||
*
|
||||
*/
|
||||
public interface ITileInfo {
|
||||
|
||||
public List<String> getTileInfo();
|
||||
|
||||
public void sendTileInfoToPlayer(EntityPlayer player);
|
||||
|
||||
}
|
||||
@@ -1,50 +0,0 @@
|
||||
package cofh.api.transport;
|
||||
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
|
||||
public interface IEnderAttuned {
|
||||
|
||||
public enum EnderTypes {
|
||||
ITEM, FLUID, REDSTONE_FLUX
|
||||
}
|
||||
|
||||
String getOwnerString();
|
||||
|
||||
int getFrequency();
|
||||
|
||||
public boolean setFrequency(int frequency);
|
||||
|
||||
public boolean clearFrequency();
|
||||
|
||||
boolean canSendItems();
|
||||
|
||||
boolean canSendFluid();
|
||||
|
||||
boolean canSendEnergy();
|
||||
|
||||
boolean canReceiveItems();
|
||||
|
||||
boolean canReceiveFluid();
|
||||
|
||||
boolean canReceiveEnergy();
|
||||
|
||||
boolean currentlyValidToReceiveItems(IEnderAttuned asker);
|
||||
|
||||
boolean currentlyValidToReceiveFluid(IEnderAttuned asker);
|
||||
|
||||
boolean currentlyValidToReceiveEnergy(IEnderAttuned asker);
|
||||
|
||||
boolean currentlyValidToSendItems(IEnderAttuned asker);
|
||||
|
||||
boolean currentlyValidToSendFluid(IEnderAttuned asker);
|
||||
|
||||
boolean currentlyValidToSendEnergy(IEnderAttuned asker);
|
||||
|
||||
ItemStack receiveItem(ItemStack item);
|
||||
|
||||
FluidStack receiveFluid(FluidStack fluid, boolean doFill);
|
||||
|
||||
int receiveEnergy(int energy, boolean simulate);
|
||||
|
||||
}
|
||||
@@ -1,39 +0,0 @@
|
||||
package cofh.api.world;
|
||||
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.gen.feature.WorldGenerator;
|
||||
|
||||
/**
|
||||
* This interface should be implemented on classes which define a world feature to be generated in a {@link IFeatureHandler}. It is essentially a more robust
|
||||
* version of {@link WorldGenerator}, and may include one or more WorldGenerators should you wish.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IFeatureGenerator {
|
||||
|
||||
/**
|
||||
* Returns the name of the feature, used for displaying in the World.cfg file.
|
||||
*/
|
||||
public String getFeatureName();
|
||||
|
||||
/**
|
||||
* Generates the world feature.
|
||||
*
|
||||
* @param random
|
||||
* Random derived from the world seed.
|
||||
* @param chunkX
|
||||
* Minimum X chunk-coordinate of the chunk. (x16 for block coordinate)
|
||||
* @param chunkZ
|
||||
* Minimum Z chunk-coordinate of the chunk. (x16 for block coordinate)
|
||||
* @param world
|
||||
* The world to generate in.
|
||||
* @param newGen
|
||||
* True on initial generation, false on retrogen.
|
||||
* @return True if generation happened, false otherwise.
|
||||
*/
|
||||
public boolean generateFeature(Random random, int chunkX, int chunkZ, World world, boolean newGen);
|
||||
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
package cofh.api.world;
|
||||
|
||||
/**
|
||||
* Provides an interface to allow for the addition of Features to world generation.
|
||||
*
|
||||
* See {@link IFeatureGenerator}.
|
||||
*
|
||||
* @author King Lemming
|
||||
*
|
||||
*/
|
||||
public interface IFeatureHandler {
|
||||
|
||||
/**
|
||||
* Register a feature with an IFeatureHandler.
|
||||
*
|
||||
* @param feature
|
||||
* The feature to register.
|
||||
* @return True if the registration was successful, false if a feature with that name existed.
|
||||
*/
|
||||
public boolean registerFeature(IFeatureGenerator feature);
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user