Compare commits

..

12 Commits

Author SHA1 Message Date
thatsIch 9d52e85afa Merge pull request #1083 from thatsIch/b-1076-nei-crash
Fixes #1076 Crash on shift clicking a recipe from NEI
2015-03-24 16:54:08 +01:00
thatsIch 3745e6ce8d Fixes #1076 Crash on shift clicking a recipe from NEI 2015-03-24 13:42:32 +01:00
thatsIch a4c38263d1 Merge pull request #1082 from thatsIch/e-integration-name
Renamed Integration class to upper case
2015-03-24 13:18:14 +01:00
thatsIch c1a7a35192 Renamed Integration class to upper case 2015-03-24 13:17:01 +01:00
thatsIch eb98ec891b Merge pull request #1066 from thatsIch/e-remove-deprecated-access
Removes deprecated method access of LocatableRegistry and getPickBlock
2015-03-24 12:47:55 +01:00
thatsIch 69a5507f96 Merge pull request #1064 from thatsIch/e-updated-public-dependencies
Updated public dependencies
2015-03-24 12:47:18 +01:00
thatsIch f138a68f3e Merge pull request #1071 from downslope7/grid-connection-exists-coords
Add coords to duplicate connection GridException.
2015-03-22 07:48:23 +01:00
downslope7 30191eb5ba Add coords to duplicate connection GridException.
This exception isn't caught and crashes the server. Added block coordinates to aid in diagnostics.
2015-03-21 20:05:08 -05:00
thatsIch 4552394f6e Removes deprecated method access of LocatableRegistry and getPickBlock 2015-03-21 16:03:26 +01:00
thatsIch 9c3d3db3fb Updated public dependencies
- FMP
- CCL
- WAILA
- BC
2015-03-21 11:51:11 +01:00
thatsIch 9c1c9056f1 Merge pull request #1063 from KamranMackey/rv2
Fixed a couple typos in en_US.lang.
2015-03-21 11:41:06 +01:00
Kamran Mackey b5582688a3 Fixed a couple typos in en_US.lang. 2015-03-21 03:57:41 -06:00
27 changed files with 82 additions and 73 deletions
+4 -4
View File
@@ -14,12 +14,12 @@ forge_version=10.13.2.1291
# APIs used for development #
#########################################################
cb_minecraft_version=1.7.10
fmp_version=1.1.1.321
code_chicken_lib_version=1.1.1.110
fmp_version=1.1.1.324
code_chicken_lib_version=1.1.3.127
code_chicken_core_version=1.0.4.35
nei_version=1.0.4.90
waila_version=1.5.9_1.7.10
bc_version=6.4.2
waila_version=1.5.10_1.7.10
bc_version=6.4.3
#########################################################
# API Stubs #
@@ -49,7 +49,7 @@ public interface IMEInventory<StackType extends IAEStack>
* @param src action source
* @return returns the number of items not added.
*/
public StackType injectItems(StackType input, Actionable type, BaseActionSource src);
StackType injectItems( StackType input, Actionable type, BaseActionSource src );
/**
* Extract the specified item from the ME Inventory
@@ -60,7 +60,7 @@ public interface IMEInventory<StackType extends IAEStack>
* simulate, or perform action?
* @return returns the number of items extracted, null
*/
public StackType extractItems(StackType request, Actionable mode, BaseActionSource src);
StackType extractItems( StackType request, Actionable mode, BaseActionSource src );
/**
* request a full report of all available items, storage.
@@ -69,11 +69,11 @@ public interface IMEInventory<StackType extends IAEStack>
* the IItemList the results will be written too
* @return returns same list that was passed in, is passed out
*/
public IItemList<StackType> getAvailableItems(IItemList<StackType> out);
IItemList<StackType> getAvailableItems( IItemList<StackType> out );
/**
* @return the type of channel your handler should be part of
*/
public StorageChannel getChannel();
StorageChannel getChannel();
}
@@ -30,12 +30,12 @@ import appeng.api.storage.data.IItemList;
public interface IMEMonitor<T extends IAEStack> extends IMEInventoryHandler<T>, IBaseMonitor<T>
{
@Override
@Deprecated
/**
* This method is discouraged when accessing data via a IMEMonitor
*/
public IItemList<T> getAvailableItems(IItemList out);
@Override
@Deprecated
IItemList<T> getAvailableItems( IItemList out );
/**
* Get access to the full item list of the network, preferred over {@link IMEInventory} .getAvailableItems(...)
@@ -70,8 +70,8 @@ import appeng.parts.NullCableBusContainer;
import appeng.tile.AEBaseTile;
import appeng.tile.networking.TileCableBus;
import appeng.tile.networking.TileCableBusTESR;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.Method;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.Method;
import appeng.util.Platform;
@Interface(iface = "powercrystals.minefactoryreloaded.api.rednet.connectivity.IRedNetConnection", iname = "MFR")
@@ -25,6 +25,7 @@ import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
@@ -163,10 +164,11 @@ public class BlockSkyStone extends AEBaseBlock implements IOrientableBlock
}
@Override
public ItemStack getPickBlock(MovingObjectPosition target, World world, int x, int y, int z)
public ItemStack getPickBlock( MovingObjectPosition target, World world, int x, int y, int z, EntityPlayer player )
{
ItemStack is = super.getPickBlock( target, world, x, y, z );
final ItemStack is = super.getPickBlock( target, world, x, y, z, player );
is.setItemDamage( world.getBlockMetadata( x, y, z ) );
return is;
}
@@ -87,10 +87,11 @@ public class BlockSkyChest extends AEBaseBlock implements ICustomCollision
}
@Override
public ItemStack getPickBlock(MovingObjectPosition target, World world, int x, int y, int z)
public ItemStack getPickBlock( MovingObjectPosition target, World world, int x, int y, int z, EntityPlayer player )
{
ItemStack is = super.getPickBlock( target, world, x, y, z );
final ItemStack is = super.getPickBlock( target, world, x, y, z, player );
is.setItemDamage( world.getBlockMetadata( x, y, z ) );
return is;
}
@@ -63,6 +63,7 @@ public final class LocatableRegistry implements ILocatableRegistry
* Find a locate-able object by its serial.
*/
@Override
@Deprecated
public Object findLocatableBySerial( long ser )
{
return this.set.get( ser );
@@ -202,7 +202,7 @@ public class PacketNEIRecipe extends AppEngPacket
{
// check if the item in slot y matches the required item.
playerItemStack = playerInventory.getStackInSlot( i );
if ( playerItemStack != null && playerItemStack.getItem() == this.recipe[x][y].getItem() )
if ( playerItemStack != null && this.recipe[x][y] != null && playerItemStack.getItem() == this.recipe[x][y].getItem() )
{
if ( realForFake == Actionable.SIMULATE )
{
@@ -1080,7 +1080,7 @@ public class DualityInterface implements IGridTickable, IStorageMonitorable, IIn
{
if ( mop.blockX == te.xCoord && mop.blockY == te.yCoord && mop.blockZ == te.zCoord )
{
ItemStack g = blk.getPickBlock( mop, w, te.xCoord, te.yCoord, te.zCoord );
ItemStack g = blk.getPickBlock( mop, w, te.xCoord, te.yCoord, te.zCoord, null );
if ( g != null )
what = g;
}
@@ -27,6 +27,7 @@ import appeng.api.AEApi;
import appeng.api.config.AccessRestriction;
import appeng.api.config.Actionable;
import appeng.api.config.PowerMultiplier;
import appeng.api.features.ILocatable;
import appeng.api.features.IWirelessTermHandler;
import appeng.api.implementations.guiobjects.IPortableCell;
import appeng.api.implementations.tiles.IWirelessAccessPoint;
@@ -76,12 +77,12 @@ public class WirelessTerminalGuiObject implements IPortableCell, IActionHost
this.myPlayer = ep;
this.wth = wh;
Object obj = null;
ILocatable obj = null;
try
{
long encKey = Long.parseLong( this.encryptionKey );
obj = AEApi.instance().registries().locatable().findLocatableBySerial( encKey );
obj = AEApi.instance().registries().locatable().getLocatableBy( encKey );
}
catch (NumberFormatException err)
{
@@ -50,7 +50,7 @@ import appeng.core.sync.network.NetworkHandler;
import appeng.core.sync.packets.PacketClick;
import appeng.items.AEBaseItem;
import appeng.items.contents.NetworkToolViewer;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
import appeng.util.Platform;
@@ -29,9 +29,9 @@ import ic2.api.item.IElectricItemManager;
import ic2.api.item.ISpecialElectricItem;
import appeng.api.config.PowerUnits;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.InterfaceList;
import appeng.transformer.annotations.integration.Method;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.InterfaceList;
import appeng.transformer.annotations.Integration.Method;
@InterfaceList( value = { @Interface( iface = "ic2.api.item.ISpecialElectricItem", iname = "IC2" ),
@@ -26,7 +26,7 @@ import net.minecraft.item.ItemStack;
import cofh.api.energy.IEnergyContainerItem;
import appeng.api.config.PowerUnits;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
@Interface( iface = "cofh.api.energy.IEnergyContainerItem", iname = "RFItem" )
@@ -35,7 +35,7 @@ import appeng.api.implementations.items.IAEWrench;
import appeng.api.util.DimensionalCoord;
import appeng.core.features.AEFeature;
import appeng.items.AEBaseItem;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
import appeng.util.Platform;
+5 -1
View File
@@ -77,8 +77,12 @@ public class GridConnection implements IGridConnection, IPathItem
throw new GridException( "Connection Forged Between null entities." );
if ( a.hasConnection( b ) || b.hasConnection( a ) )
throw new GridException( "Connection already exists." );
{
final String aCoords = a.getGridBlock().getLocation().toString();
final String bCoords = b.getGridBlock().getLocation().toString();
throw new GridException( String.format( "Connection already exists between node at [%s] and node at [%s].", aCoords, bCoords ) );
}
this.sideA = a;
this.fromAtoB = fromAtoB;
this.sideB = b;
@@ -81,7 +81,7 @@ public class QuantumCluster implements ILocatable, IAECluster
public boolean canUseNode(long qe)
{
QuantumCluster qc = (QuantumCluster) AEApi.instance().registries().locatable().findLocatableBySerial( qe );
QuantumCluster qc = (QuantumCluster) AEApi.instance().registries().locatable().getLocatableBy( qe );
if ( qc != null )
{
World theWorld = qc.getCenter().getWorldObj();
@@ -147,7 +147,7 @@ public class QuantumCluster implements ILocatable, IAECluster
}
}
Object myOtherSide = this.otherSide == 0 ? null : AEApi.instance().registries().locatable().findLocatableBySerial( this.otherSide );
ILocatable myOtherSide = this.otherSide == 0 ? null : AEApi.instance().registries().locatable().getLocatableBy( this.otherSide );
boolean shutdown = false;
@@ -82,8 +82,8 @@ import appeng.me.storage.MEMonitorIInventory;
import appeng.parts.automation.PartUpgradeable;
import appeng.tile.inventory.AppEngInternalAEInventory;
import appeng.tile.inventory.InvOperation;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.Method;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.Method;
import appeng.util.Platform;
import appeng.util.prioitylist.FuzzyPriorityList;
import appeng.util.prioitylist.PrecisePriorityList;
@@ -36,8 +36,8 @@ import appeng.core.AppEng;
import appeng.integration.IntegrationType;
import appeng.me.GridAccessException;
import appeng.me.cache.helpers.TunnelCollection;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.InterfaceList;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.InterfaceList;
import appeng.util.Platform;
@InterfaceList(value = { @Interface(iface = "ic2.api.energy.tile.IEnergySink", iname = "IC2"),
@@ -53,8 +53,8 @@ import appeng.integration.abstraction.IBC;
import appeng.me.GridAccessException;
import appeng.me.cache.helpers.TunnelCollection;
import appeng.tile.inventory.AppEngNullInventory;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.Method;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.Method;
import appeng.util.Platform;
import appeng.util.inv.WrapperBCPipe;
import appeng.util.inv.WrapperChainedInventory;
@@ -38,8 +38,8 @@ import appeng.core.AppEng;
import appeng.integration.IntegrationType;
import appeng.integration.modules.helpers.NullRFHandler;
import appeng.me.GridAccessException;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.InterfaceList;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.InterfaceList;
import appeng.util.Platform;
+1 -1
View File
@@ -29,7 +29,7 @@ import appeng.api.config.PowerUnits;
import appeng.core.AppEng;
import appeng.integration.IntegrationType;
import appeng.integration.abstraction.IIC2;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
import appeng.util.Platform;
@Interface(iname = "IC2", iface = "ic2.api.energy.tile.IEnergySink")
@@ -23,7 +23,7 @@ import net.minecraftforge.common.util.ForgeDirection;
import mekanism.api.energy.IStrictEnergyAcceptor;
import appeng.api.config.PowerUnits;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
@Interface(iname = "Mekanism", iface = "mekanism.api.energy.IStrictEnergyAcceptor")
public abstract class MekJoules extends RedstoneFlux implements IStrictEnergyAcceptor {
@@ -24,7 +24,7 @@ import net.minecraftforge.common.util.ForgeDirection;
import cofh.api.energy.IEnergyReceiver;
import appeng.api.config.PowerUnits;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.Integration.Interface;
@Interface( iname = "RF", iface = "cofh.api.energy.IEnergyReceiver" )
@@ -25,8 +25,8 @@ import Reika.RotaryCraft.API.ShaftPowerReceiver;
import appeng.api.config.PowerUnits;
import appeng.tile.TileEvent;
import appeng.tile.events.TileEventType;
import appeng.transformer.annotations.integration.Interface;
import appeng.transformer.annotations.integration.Method;
import appeng.transformer.annotations.Integration.Interface;
import appeng.transformer.annotations.Integration.Method;
import appeng.util.Platform;
@Interface(iname = "RotaryCraft", iface = "Reika.RotaryCraft.API.ShaftPowerReceiver")
@@ -18,36 +18,35 @@
package appeng.transformer.annotations;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
public @interface integration {
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
public @interface InterfaceList {
public Interface[] value();
public @interface Integration
{
@Retention( RetentionPolicy.RUNTIME )
@Target( ElementType.TYPE )
@interface InterfaceList
{
Interface[] value();
}
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
public @interface Interface {
public String iface();
public String iname();
@Retention( RetentionPolicy.RUNTIME )
@Target( ElementType.TYPE )
@interface Interface
{
String iface();
String iname();
}
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface Method {
public String iname();
@Retention( RetentionPolicy.RUNTIME )
@Target( ElementType.METHOD )
@interface Method
{
String iname();
}
}
@@ -36,7 +36,7 @@ import cpw.mods.fml.relauncher.FMLRelaunchLog;
import appeng.integration.IntegrationRegistry;
import appeng.integration.IntegrationType;
import appeng.transformer.annotations.integration;
import appeng.transformer.annotations.Integration;
public class ASMIntegration implements IClassTransformer
@@ -105,16 +105,16 @@ public class ASMIntegration implements IClassTransformer
{
for ( AnnotationNode an : classNode.visibleAnnotations )
{
if ( this.hasAnnotation( an, integration.Interface.class ) )
if ( this.hasAnnotation( an, Integration.Interface.class ) )
{
if ( this.stripInterface( classNode, integration.Interface.class, an ) )
if ( this.stripInterface( classNode, Integration.Interface.class, an ) )
changed = true;
}
else if ( this.hasAnnotation( an, integration.InterfaceList.class ) )
else if ( this.hasAnnotation( an, Integration.InterfaceList.class ) )
{
for ( Object o : ( ( List ) an.values.get( 1 ) ) )
{
if ( this.stripInterface( classNode, integration.InterfaceList.class, ( AnnotationNode ) o ) )
if ( this.stripInterface( classNode, Integration.InterfaceList.class, ( AnnotationNode ) o ) )
changed = true;
}
}
@@ -130,9 +130,9 @@ public class ASMIntegration implements IClassTransformer
{
for ( AnnotationNode an : mn.visibleAnnotations )
{
if ( this.hasAnnotation( an, integration.Method.class ) )
if ( this.hasAnnotation( an, Integration.Method.class ) )
{
if ( this.stripMethod( classNode, mn, i, integration.Method.class, an ) )
if ( this.stripMethod( classNode, mn, i, Integration.Method.class, an ) )
changed = true;
}
}
@@ -467,6 +467,7 @@ commands.ae2.ChunkLoggerOn=Chunk Logging is now on
commands.ae2.ChunkLoggerOff=Chunk Logging is now off
commands.ae2.Supporters=Displays a list of AE2 Supporters
// Achievements
achievement.ae2.Compass=Meteorite Hunter
achievement.ae2.Compass.desc=Craft a Meteorite Compass
achievement.ae2.Presses=Unknown Technology
@@ -494,13 +495,13 @@ achievement.ae2.CrystalGrowthAccelerator.desc=Craft a Crystal Growth Accelerator
achievement.ae2.GlassCable=Fluix Energy Connection
achievement.ae2.GlassCable.desc=Craft ME Glass Cable
achievement.ae2.Networking1=Network Apprentice
achievement.ae2.Networking1.desc=Reach 8 channel using devices on a network.
achievement.ae2.Networking1.desc=Reach 8 channels using devices on a network.
achievement.ae2.Controller=Networking Switchboard
achievement.ae2.Controller.desc=Craft a Controller
achievement.ae2.Networking2=Network Engineer
achievement.ae2.Networking2.desc=Reach 128 channel using devices on a network.
achievement.ae2.Networking2.desc=Reach 128 channels using devices on a network.
achievement.ae2.Networking3=Network Administrator
achievement.ae2.Networking3.desc=Reach 2048 channel using devices on a network.
achievement.ae2.Networking3.desc=Reach 2048 channels using devices on a network.
achievement.ae2.P2P=Point to Point Networking
achievement.ae2.P2P.desc=Craft a P2P Tunnel
achievement.ae2.Recursive=Recursive Networking