Merge branch 'rv1' of https://bitbucket.org/AlgorithmX2/appliedenergistics2 into rv1
This commit is contained in:
@@ -709,14 +709,14 @@ public class BaseBlockRender
|
|||||||
double maxY = (forward.offsetY > 0 ? 1 : 0) + mapFaceUV( west.offsetY, u2 ) + mapFaceUV( up.offsetY, v2 );
|
double maxY = (forward.offsetY > 0 ? 1 : 0) + mapFaceUV( west.offsetY, u2 ) + mapFaceUV( up.offsetY, v2 );
|
||||||
double maxZ = (forward.offsetZ > 0 ? 1 : 0) + mapFaceUV( west.offsetZ, u2 ) + mapFaceUV( up.offsetZ, v2 );
|
double maxZ = (forward.offsetZ > 0 ? 1 : 0) + mapFaceUV( west.offsetZ, u2 ) + mapFaceUV( up.offsetZ, v2 );
|
||||||
|
|
||||||
renderer.renderMinX = Math.max( 0.0, Math.min( minX, maxX ) - 0.001 );
|
renderer.renderMinX = Math.max( 0.0, Math.min( minX, maxX ) - (forward.offsetX != 0 ? 0 : 0.001) );
|
||||||
renderer.renderMaxX = Math.min( 1.0, Math.max( minX, maxX ) + 0.001 );
|
renderer.renderMaxX = Math.min( 1.0, Math.max( minX, maxX ) + (forward.offsetX != 0 ? 0 : 0.001) );
|
||||||
|
|
||||||
renderer.renderMinY = Math.max( 0.0, Math.min( minY, maxY ) - 0.001 );
|
renderer.renderMinY = Math.max( 0.0, Math.min( minY, maxY ) - (forward.offsetY != 0 ? 0 : 0.001) );
|
||||||
renderer.renderMaxY = Math.min( 1.0, Math.max( minY, maxY ) + 0.001 );
|
renderer.renderMaxY = Math.min( 1.0, Math.max( minY, maxY ) + (forward.offsetY != 0 ? 0 : 0.001) );
|
||||||
|
|
||||||
renderer.renderMinZ = Math.max( 0.0, Math.min( minZ, maxZ ) - 0.001 );
|
renderer.renderMinZ = Math.max( 0.0, Math.min( minZ, maxZ ) - (forward.offsetZ != 0 ? 0 : 0.001) );
|
||||||
renderer.renderMaxZ = Math.min( 1.0, Math.max( minZ, maxZ ) + 0.001 );
|
renderer.renderMaxZ = Math.min( 1.0, Math.max( minZ, maxZ ) + (forward.offsetZ != 0 ? 0 : 0.001) );
|
||||||
}
|
}
|
||||||
|
|
||||||
private double mapFaceUV(int offset, int uv)
|
private double mapFaceUV(int offset, int uv)
|
||||||
|
|||||||
@@ -566,9 +566,6 @@ public class Registration
|
|||||||
|
|
||||||
AEApi.instance().registries().matterCannon().registerAmmo( AEApi.instance().materials().materialMatterBall.stack( 1 ), 32.0 );
|
AEApi.instance().registries().matterCannon().registerAmmo( AEApi.instance().materials().materialMatterBall.stack( 1 ), 32.0 );
|
||||||
|
|
||||||
// default settings..
|
|
||||||
((P2PTunnelRegistry) AEApi.instance().registries().p2pTunnel()).configure();
|
|
||||||
|
|
||||||
recipeHandler.injectRecipes();
|
recipeHandler.injectRecipes();
|
||||||
|
|
||||||
if ( AEConfig.instance.isFeatureEnabled( AEFeature.enableDisassemblyCrafting ) )
|
if ( AEConfig.instance.isFeatureEnabled( AEFeature.enableDisassemblyCrafting ) )
|
||||||
@@ -582,6 +579,9 @@ public class Registration
|
|||||||
{
|
{
|
||||||
registerSpatial( true );
|
registerSpatial( true );
|
||||||
|
|
||||||
|
// default settings..
|
||||||
|
((P2PTunnelRegistry) AEApi.instance().registries().p2pTunnel()).configure();
|
||||||
|
|
||||||
// add to localizaiton..
|
// add to localizaiton..
|
||||||
PlayerMessages.values();
|
PlayerMessages.values();
|
||||||
GuiText.values();
|
GuiText.values();
|
||||||
|
|||||||
@@ -53,6 +53,7 @@ public class P2PTunnelRegistry implements IP2PTunnelRegistry
|
|||||||
addNewAttunement( new ItemStack( Blocks.redstone_wire ), TunnelType.REDSTONE );
|
addNewAttunement( new ItemStack( Blocks.redstone_wire ), TunnelType.REDSTONE );
|
||||||
addNewAttunement( new ItemStack( Blocks.redstone_block ), TunnelType.REDSTONE );
|
addNewAttunement( new ItemStack( Blocks.redstone_block ), TunnelType.REDSTONE );
|
||||||
addNewAttunement( new ItemStack( Blocks.lever ), TunnelType.REDSTONE );
|
addNewAttunement( new ItemStack( Blocks.lever ), TunnelType.REDSTONE );
|
||||||
|
addNewAttunement( getModItem( "EnderIO", "itemRedstoneConduit", OreDictionary.WILDCARD_VALUE ), TunnelType.REDSTONE );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* attune based on lots of random item related stuff
|
* attune based on lots of random item related stuff
|
||||||
@@ -69,6 +70,8 @@ public class P2PTunnelRegistry implements IP2PTunnelRegistry
|
|||||||
addNewAttunement( new ItemStack( Blocks.chest ), TunnelType.ITEM );
|
addNewAttunement( new ItemStack( Blocks.chest ), TunnelType.ITEM );
|
||||||
addNewAttunement( new ItemStack( Blocks.trapped_chest ), TunnelType.ITEM );
|
addNewAttunement( new ItemStack( Blocks.trapped_chest ), TunnelType.ITEM );
|
||||||
addNewAttunement( getModItem( "ExtraUtilities", "extractor_base", 0 ), TunnelType.ITEM );
|
addNewAttunement( getModItem( "ExtraUtilities", "extractor_base", 0 ), TunnelType.ITEM );
|
||||||
|
addNewAttunement( getModItem( "Mekanism", "PartTransmitter", 9 ), TunnelType.ITEM );
|
||||||
|
addNewAttunement( getModItem( "EnderIO", "itemItemConduit", OreDictionary.WILDCARD_VALUE ), TunnelType.ITEM );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* attune based on lots of random item related stuff
|
* attune based on lots of random item related stuff
|
||||||
@@ -77,7 +80,11 @@ public class P2PTunnelRegistry implements IP2PTunnelRegistry
|
|||||||
addNewAttunement( new ItemStack( Items.lava_bucket ), TunnelType.FLUID );
|
addNewAttunement( new ItemStack( Items.lava_bucket ), TunnelType.FLUID );
|
||||||
addNewAttunement( new ItemStack( Items.milk_bucket ), TunnelType.FLUID );
|
addNewAttunement( new ItemStack( Items.milk_bucket ), TunnelType.FLUID );
|
||||||
addNewAttunement( new ItemStack( Items.water_bucket ), TunnelType.FLUID );
|
addNewAttunement( new ItemStack( Items.water_bucket ), TunnelType.FLUID );
|
||||||
|
addNewAttunement( getModItem( "Mekanism", "MachineBlock2", 11 ), TunnelType.FLUID );
|
||||||
|
addNewAttunement( getModItem( "Mekanism", "PartTransmitter", 4 ), TunnelType.FLUID );
|
||||||
addNewAttunement( getModItem( "ExtraUtilities", "extractor_base", 6 ), TunnelType.FLUID );
|
addNewAttunement( getModItem( "ExtraUtilities", "extractor_base", 6 ), TunnelType.FLUID );
|
||||||
|
addNewAttunement( getModItem( "ExtraUtilities", "drum", OreDictionary.WILDCARD_VALUE ), TunnelType.FLUID );
|
||||||
|
addNewAttunement( getModItem( "EnderIO", "itemLiquidConduit", OreDictionary.WILDCARD_VALUE ), TunnelType.FLUID );
|
||||||
|
|
||||||
for (AEColor c : AEColor.values())
|
for (AEColor c : AEColor.values())
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -367,6 +367,31 @@ public class FacadePart implements IFacadePart, IBoxProvider
|
|||||||
out.remove( ForgeDirection.NORTH );
|
out.remove( ForgeDirection.NORTH );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* if ( out.contains( ForgeDirection.EAST ) && (side.offsetZ != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.EAST ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.EAST ); }
|
||||||
|
*
|
||||||
|
* if ( out.contains( ForgeDirection.WEST ) && (side.offsetZ != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.WEST ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.WEST ); }
|
||||||
|
*
|
||||||
|
* if ( out.contains( ForgeDirection.NORTH ) && (side.offsetY != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.NORTH ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.NORTH ); }
|
||||||
|
*
|
||||||
|
* if ( out.contains( ForgeDirection.SOUTH ) && (side.offsetY != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.SOUTH ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.SOUTH ); }
|
||||||
|
*
|
||||||
|
* if ( out.contains( ForgeDirection.EAST ) && (side.offsetY != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.EAST ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.EAST ); }
|
||||||
|
*
|
||||||
|
* if ( out.contains( ForgeDirection.WEST ) && (side.offsetY != 0) ) { IFacadePart fp = fc.getFacade(
|
||||||
|
* ForgeDirection.WEST ); if ( fp != null && (fp.isTransparent() == facade.isTransparent()) ) out.remove(
|
||||||
|
* ForgeDirection.WEST ); }
|
||||||
|
*/
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+3
-3
@@ -88,9 +88,9 @@ public class FMPEvent
|
|||||||
&& block.onBlockActivated( world, hit.blockX, hit.blockY, hit.blockZ, player, hit.sideHit, (float) f.x, (float) f.y, (float) f.z ) )
|
&& block.onBlockActivated( world, hit.blockX, hit.blockY, hit.blockZ, player, hit.sideHit, (float) f.x, (float) f.y, (float) f.z ) )
|
||||||
{
|
{
|
||||||
player.swingItem();
|
player.swingItem();
|
||||||
PacketCustom.sendToServer(new C08PacketPlayerBlockPlacement( hit.blockX, hit.blockY, hit.blockZ, hit.sideHit, player.inventory.getCurrentItem(), (float) f.x,
|
PacketCustom.sendToServer( new C08PacketPlayerBlockPlacement( hit.blockX, hit.blockY, hit.blockZ, hit.sideHit, player.inventory
|
||||||
(float) f.y, (float) f.z ) );
|
.getCurrentItem(), (float) f.x, (float) f.y, (float) f.z ) );
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+16
-15
@@ -4,7 +4,6 @@ import net.minecraft.item.ItemStack;
|
|||||||
import net.minecraftforge.oredict.OreDictionary;
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
import appeng.api.AEApi;
|
import appeng.api.AEApi;
|
||||||
import appeng.api.config.TunnelType;
|
import appeng.api.config.TunnelType;
|
||||||
import appeng.api.features.IP2PTunnelRegistry;
|
|
||||||
import appeng.integration.BaseModule;
|
import appeng.integration.BaseModule;
|
||||||
import appeng.integration.IIntegrationModule;
|
import appeng.integration.IIntegrationModule;
|
||||||
import cpw.mods.fml.common.registry.GameRegistry;
|
import cpw.mods.fml.common.registry.GameRegistry;
|
||||||
@@ -22,30 +21,32 @@ public class RF extends BaseModule implements IIntegrationModule
|
|||||||
@Override
|
@Override
|
||||||
public void Init()
|
public void Init()
|
||||||
{
|
{
|
||||||
IP2PTunnelRegistry reg = AEApi.instance().registries().p2pTunnel();
|
|
||||||
|
|
||||||
ItemStack energyPipe = GameRegistry.findItemStack( "ExtraUtilities", "extractor_base", 1 );
|
|
||||||
if ( energyPipe != null )
|
|
||||||
{
|
|
||||||
energyPipe.setItemDamage( 12 );
|
|
||||||
reg.addNewAttunement( energyPipe, TunnelType.RF_POWER );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ItemStack energyConduit = GameRegistry.findItemStack( "EnderIO", "itemPowerConduit", 1 );
|
void RFStack(String mod, String name, int dmg)
|
||||||
if ( energyConduit != null )
|
|
||||||
{
|
{
|
||||||
energyConduit.setItemDamage( OreDictionary.WILDCARD_VALUE );
|
ItemStack modItem = GameRegistry.findItemStack( mod, name, 1 );
|
||||||
reg.addNewAttunement( energyConduit, TunnelType.RF_POWER );
|
if ( modItem != null )
|
||||||
|
{
|
||||||
|
modItem.setItemDamage( dmg );
|
||||||
|
AEApi.instance().registries().p2pTunnel().addNewAttunement( modItem, TunnelType.RF_POWER );
|
||||||
}
|
}
|
||||||
|
|
||||||
reg.addNewAttunement( GameRegistry.findItemStack( "EnderIO", "blockCapacitorBank", 1 ), TunnelType.RF_POWER );
|
|
||||||
reg.addNewAttunement( GameRegistry.findItemStack( "EnderIO", "blockPowerMonitor", 1 ), TunnelType.RF_POWER );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void PostInit()
|
public void PostInit()
|
||||||
{
|
{
|
||||||
|
RFStack( "ExtraUtilities", "extractor_base", 12 );
|
||||||
|
RFStack( "ExtraUtilities", "pipes", 11 );
|
||||||
|
RFStack( "ExtraUtilities", "pipes", 14 );
|
||||||
|
RFStack( "ExtraUtilities", "generator", OreDictionary.WILDCARD_VALUE );
|
||||||
|
|
||||||
|
RFStack( "ThermalExpansion", "Cell", OreDictionary.WILDCARD_VALUE );
|
||||||
|
RFStack( "ThermalExpansion", "Dynamo", OreDictionary.WILDCARD_VALUE );
|
||||||
|
|
||||||
|
RFStack( "EnderIO", "itemPowerConduit", OreDictionary.WILDCARD_VALUE );
|
||||||
|
RFStack( "EnderIO", "blockCapacitorBank", 0 );
|
||||||
|
RFStack( "EnderIO", "blockPowerMonitor", 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -70,6 +70,9 @@ public class PartP2PTunnel<T extends PartP2PTunnel> extends PartBasicState
|
|||||||
{
|
{
|
||||||
ItemStack is = player.inventory.getCurrentItem();
|
ItemStack is = player.inventory.getCurrentItem();
|
||||||
|
|
||||||
|
// UniqueIdentifier id = GameRegistry.findUniqueIdentifierFor( is.getItem() );
|
||||||
|
// AELog.info( "ID:" + id.toString() + " : " + is.getItemDamage() );
|
||||||
|
|
||||||
TunnelType tt = AEApi.instance().registries().p2pTunnel().getTunnelTypeByItem( is );
|
TunnelType tt = AEApi.instance().registries().p2pTunnel().getTunnelTypeByItem( is );
|
||||||
if ( is != null && is.getItem() instanceof IMemoryCard )
|
if ( is != null && is.getItem() instanceof IMemoryCard )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ import appeng.api.config.PowerMultiplier;
|
|||||||
import appeng.api.config.PowerUnits;
|
import appeng.api.config.PowerUnits;
|
||||||
import appeng.api.implementations.items.IAEItemPowerStorage;
|
import appeng.api.implementations.items.IAEItemPowerStorage;
|
||||||
import appeng.api.implementations.tiles.ICrankable;
|
import appeng.api.implementations.tiles.ICrankable;
|
||||||
import appeng.api.networking.GridFlags;
|
|
||||||
import appeng.api.storage.data.IAEItemStack;
|
import appeng.api.storage.data.IAEItemStack;
|
||||||
import appeng.api.util.AECableType;
|
import appeng.api.util.AECableType;
|
||||||
import appeng.me.GridAccessException;
|
import appeng.me.GridAccessException;
|
||||||
@@ -141,7 +140,7 @@ public class TileCharger extends AENetworkPowerTile implements ICrankable
|
|||||||
|
|
||||||
public TileCharger() {
|
public TileCharger() {
|
||||||
gridProxy.setValidSides( EnumSet.noneOf( ForgeDirection.class ) );
|
gridProxy.setValidSides( EnumSet.noneOf( ForgeDirection.class ) );
|
||||||
gridProxy.setFlags( GridFlags.CANNOT_CARRY );
|
gridProxy.setFlags();
|
||||||
internalMaxPower = 1500;
|
internalMaxPower = 1500;
|
||||||
gridProxy.setIdlePowerUsage( 0 );
|
gridProxy.setIdlePowerUsage( 0 );
|
||||||
addNewHandler( new TileChargerHandler() );
|
addNewHandler( new TileChargerHandler() );
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ import java.util.EnumSet;
|
|||||||
|
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
import appeng.api.implementations.IPowerChannelState;
|
import appeng.api.implementations.IPowerChannelState;
|
||||||
import appeng.api.networking.GridFlags;
|
|
||||||
import appeng.api.networking.events.MENetworkEventSubscribe;
|
import appeng.api.networking.events.MENetworkEventSubscribe;
|
||||||
import appeng.api.networking.events.MENetworkPowerStatusChange;
|
import appeng.api.networking.events.MENetworkPowerStatusChange;
|
||||||
import appeng.api.util.AECableType;
|
import appeng.api.util.AECableType;
|
||||||
@@ -66,7 +65,7 @@ public class TileQuartzGrowthAccelerator extends AENetworkTile implements IPower
|
|||||||
|
|
||||||
public TileQuartzGrowthAccelerator() {
|
public TileQuartzGrowthAccelerator() {
|
||||||
gridProxy.setValidSides( EnumSet.noneOf( ForgeDirection.class ) );
|
gridProxy.setValidSides( EnumSet.noneOf( ForgeDirection.class ) );
|
||||||
gridProxy.setFlags( GridFlags.CANNOT_CARRY );
|
gridProxy.setFlags();
|
||||||
gridProxy.setIdlePowerUsage( 8 );
|
gridProxy.setIdlePowerUsage( 8 );
|
||||||
addNewHandler( new TileChargerHandler() );
|
addNewHandler( new TileChargerHandler() );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,7 +10,6 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||||||
import net.minecraft.tileentity.TileEntityFurnace;
|
import net.minecraft.tileentity.TileEntityFurnace;
|
||||||
import net.minecraftforge.common.util.ForgeDirection;
|
import net.minecraftforge.common.util.ForgeDirection;
|
||||||
import appeng.api.config.Actionable;
|
import appeng.api.config.Actionable;
|
||||||
import appeng.api.networking.GridFlags;
|
|
||||||
import appeng.api.networking.IGridNode;
|
import appeng.api.networking.IGridNode;
|
||||||
import appeng.api.networking.energy.IEnergyGrid;
|
import appeng.api.networking.energy.IEnergyGrid;
|
||||||
import appeng.api.networking.ticking.IGridTickable;
|
import appeng.api.networking.ticking.IGridTickable;
|
||||||
@@ -88,7 +87,7 @@ public class TileVibrationChamber extends AENetworkInvTile implements IGridTicka
|
|||||||
|
|
||||||
public TileVibrationChamber() {
|
public TileVibrationChamber() {
|
||||||
gridProxy.setIdlePowerUsage( 0 );
|
gridProxy.setIdlePowerUsage( 0 );
|
||||||
gridProxy.setFlags( GridFlags.CANNOT_CARRY );
|
gridProxy.setFlags();
|
||||||
addNewHandler( new TileVibrationChamberHandler() );
|
addNewHandler( new TileVibrationChamberHandler() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user