Compare commits
21 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d11d6e754f | |||
| 887339f7b8 | |||
| a665200c31 | |||
| 6554e295d5 | |||
| 4eeb554dcb | |||
| 3eae4a7d19 | |||
| 6c91e852ec | |||
| 52f516299b | |||
| c74166b02a | |||
| 26e86a114c | |||
| fc834036a0 | |||
| f96f7d82c5 | |||
| c592f54a77 | |||
| 89609a83ea | |||
| e67969f52f | |||
| 32a0496bc2 | |||
| 6df311c11a | |||
| 2e23b92763 | |||
| 41a029ffb4 | |||
| 9c8f914f42 | |||
| d75cdc9696 |
@@ -26,3 +26,6 @@
|
|||||||
|
|
||||||
# Github specific files and directories
|
# Github specific files and directories
|
||||||
!.github/
|
!.github/
|
||||||
|
|
||||||
|
# Explicit ignores
|
||||||
|
Thumbs.db
|
||||||
@@ -103,7 +103,7 @@ Providing as many details as possible does help us to find and resolve the issue
|
|||||||
- Eclipse: execute `gradlew eclipse`
|
- Eclipse: execute `gradlew eclipse`
|
||||||
5. For add-on developer: Core-Mod Detection
|
5. For add-on developer: Core-Mod Detection
|
||||||
- In order to have FML detect AE from your dev environment, add the following VM Option to your run profile
|
- In order to have FML detect AE from your dev environment, add the following VM Option to your run profile
|
||||||
- `-Dfml.coreMods.load=appeng.transformer.AppEngCore`
|
- `-Dfml.coreMods.load=appeng.coremod.AppEngCore`
|
||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
||||||
|
|||||||
+22
-19
@@ -53,17 +53,22 @@ archivesBaseName = aebasename
|
|||||||
jar {
|
jar {
|
||||||
manifest {
|
manifest {
|
||||||
attributes 'FMLCorePluginContainsFMLMod': 'true'
|
attributes 'FMLCorePluginContainsFMLMod': 'true'
|
||||||
|
attributes 'FMLAT': 'appeng_at.cfg'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
from sourceSets.api.output
|
||||||
|
dependsOn apiClasses
|
||||||
|
|
||||||
// specify which files are really included, can control which APIs should be in
|
// specify which files are really included, can control which APIs should be in
|
||||||
include "appeng/**"
|
include "appeng/**"
|
||||||
include "assets/**"
|
include "assets/**"
|
||||||
include "mcmod.info"
|
include "mcmod.info"
|
||||||
include "pack.mcmeta"
|
include "pack.mcmeta"
|
||||||
|
include "META-INF/appeng_at.cfg"
|
||||||
}
|
}
|
||||||
|
|
||||||
minecraft {
|
minecraft {
|
||||||
coreMod = "appeng.transformer.AppEngCore"
|
coreMod = "appeng.coremod.AppEngCore"
|
||||||
|
|
||||||
version = minecraft_version + "-" + forge_version
|
version = minecraft_version + "-" + forge_version
|
||||||
|
|
||||||
@@ -81,26 +86,21 @@ minecraft {
|
|||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
main {
|
|
||||||
java {
|
|
||||||
srcDirs += 'src/api/java'
|
|
||||||
srcDirs += 'src/main/java/'
|
|
||||||
}
|
|
||||||
|
|
||||||
resources {
|
api
|
||||||
srcDir "src/main/resources/"
|
|
||||||
include "assets/appliedenergistics2/recipes/**/*.recipe",
|
// This source set will contain third party API code that we need to compile, but which is not shipped with the jar
|
||||||
"assets/appliedenergistics2/recipes/README.html",
|
thirdparty {
|
||||||
"assets/appliedenergistics2/lang/*.lang",
|
// Third Party APIs often need access to Minecraft classes (i.e. EnumFacing), so set this up here
|
||||||
"assets/appliedenergistics2/blockstates/**/*.json",
|
compileClasspath += configurations.forgeGradleMc + configurations.forgeGradleMcDeps
|
||||||
"assets/appliedenergistics2/models/**/*.json",
|
|
||||||
"assets/appliedenergistics2/textures/**/*.png",
|
|
||||||
"assets/appliedenergistics2/textures/**/*.mcmeta",
|
|
||||||
"assets/appliedenergistics2/meta/*",
|
|
||||||
"mcmod.info",
|
|
||||||
"pack.mcmeta"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
main
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
compile sourceSets.thirdparty.output
|
||||||
}
|
}
|
||||||
|
|
||||||
processResources
|
processResources
|
||||||
@@ -119,4 +119,7 @@ processResources
|
|||||||
from(sourceSets.main.resources.srcDirs) {
|
from(sourceSets.main.resources.srcDirs) {
|
||||||
exclude 'mcmod.info'
|
exclude 'mcmod.info'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// move access transformer to META-INF
|
||||||
|
rename '(.+_at.cfg)', 'META-INF/$1'
|
||||||
}
|
}
|
||||||
+5
-5
@@ -8,8 +8,8 @@ aebasename=appliedenergistics2
|
|||||||
# Versions #
|
# Versions #
|
||||||
#########################################################
|
#########################################################
|
||||||
minecraft_version=1.10.2
|
minecraft_version=1.10.2
|
||||||
mcp_mappings=snapshot_20161018
|
mcp_mappings=snapshot_20161111
|
||||||
forge_version=12.18.2.2104
|
forge_version=12.18.2.2139
|
||||||
|
|
||||||
#########################################################
|
#########################################################
|
||||||
# Installable #
|
# Installable #
|
||||||
@@ -19,6 +19,6 @@ waila_version=1.7.0-B3_1.9.4
|
|||||||
#########################################################
|
#########################################################
|
||||||
# Provided APIs #
|
# Provided APIs #
|
||||||
#########################################################
|
#########################################################
|
||||||
jei_version=3.12.7.312
|
jei_version=3.13.3.373
|
||||||
tesla_version=1.10.2-1.2.1.49
|
tesla_version=1.10.2-1.2.1.50
|
||||||
ic2_version=2.6.96-ex110
|
ic2_version=2.6.99-ex110
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ task apiJar(type: Jar) {
|
|||||||
from sourceSets.api.java
|
from sourceSets.api.java
|
||||||
include "appeng/api/**"
|
include "appeng/api/**"
|
||||||
|
|
||||||
from sourceSets.main.output
|
from sourceSets.api.output
|
||||||
include "appeng/api/**"
|
include "appeng/api/**"
|
||||||
|
|
||||||
classifier = 'api'
|
classifier = 'api'
|
||||||
|
|||||||
@@ -45,6 +45,6 @@ public class ItemCraftingStorage extends AEBaseItemBlock
|
|||||||
@Override
|
@Override
|
||||||
public boolean hasContainerItem( final ItemStack stack )
|
public boolean hasContainerItem( final ItemStack stack )
|
||||||
{
|
{
|
||||||
return AEConfig.instance.isFeatureEnabled( AEFeature.EnableDisassemblyCrafting );
|
return AEConfig.instance().isFeatureEnabled( AEFeature.ENABLE_DISASSEMBLY_CRAFTING );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ public class BlockCharger extends AEBaseTileBlock implements ICustomCollision
|
|||||||
@SideOnly( Side.CLIENT )
|
@SideOnly( Side.CLIENT )
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ public class BlockQuartzFixture extends AEBaseBlock implements IOrientableBlock,
|
|||||||
@SideOnly( Side.CLIENT )
|
@SideOnly( Side.CLIENT )
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ public class BlockQuartzGrowthAccelerator extends AEBaseTileBlock implements IOr
|
|||||||
@Override
|
@Override
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ public final class BlockVibrationChamber extends AEBaseTileBlock
|
|||||||
@Override
|
@Override
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ class BlockDefinitionBuilder implements IBlockBuilder
|
|||||||
@Override
|
@Override
|
||||||
public <T extends IBlockDefinition> T build()
|
public <T extends IBlockDefinition> T build()
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.areFeaturesEnabled( features ) )
|
if( !AEConfig.instance().areFeaturesEnabled( features ) )
|
||||||
{
|
{
|
||||||
return (T) new TileDefinition( registryName, null, null );
|
return (T) new TileDefinition( registryName, null, null );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ public class FeatureFactory
|
|||||||
|
|
||||||
public FeatureFactory()
|
public FeatureFactory()
|
||||||
{
|
{
|
||||||
this.defaultFeatures = new AEFeature[] { AEFeature.Core };
|
this.defaultFeatures = new AEFeature[] { AEFeature.CORE };
|
||||||
this.bootstrapComponents = new ArrayList<>();
|
this.bootstrapComponents = new ArrayList<>();
|
||||||
|
|
||||||
if( Platform.isClient() )
|
if( Platform.isClient() )
|
||||||
|
|||||||
@@ -147,7 +147,7 @@ class ItemDefinitionBuilder implements IItemBuilder
|
|||||||
@Override
|
@Override
|
||||||
public ItemDefinition build()
|
public ItemDefinition build()
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.areFeaturesEnabled( features ) )
|
if( !AEConfig.instance().areFeaturesEnabled( features ) )
|
||||||
{
|
{
|
||||||
return new ItemDefinition( registryName, null );
|
return new ItemDefinition( registryName, null );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -62,6 +62,7 @@ import appeng.core.CommonHelper;
|
|||||||
import appeng.core.sync.network.NetworkHandler;
|
import appeng.core.sync.network.NetworkHandler;
|
||||||
import appeng.core.sync.packets.PacketAssemblerAnimation;
|
import appeng.core.sync.packets.PacketAssemblerAnimation;
|
||||||
import appeng.core.sync.packets.PacketValueConfig;
|
import appeng.core.sync.packets.PacketValueConfig;
|
||||||
|
import appeng.coremod.MissingCoreMod;
|
||||||
import appeng.entity.EntityFloatingItem;
|
import appeng.entity.EntityFloatingItem;
|
||||||
import appeng.entity.EntityTinyTNTPrimed;
|
import appeng.entity.EntityTinyTNTPrimed;
|
||||||
import appeng.entity.RenderFloatingItem;
|
import appeng.entity.RenderFloatingItem;
|
||||||
@@ -70,7 +71,6 @@ import appeng.helpers.IMouseWheelItem;
|
|||||||
import appeng.hooks.TickHandler;
|
import appeng.hooks.TickHandler;
|
||||||
import appeng.hooks.TickHandler.PlayerColor;
|
import appeng.hooks.TickHandler.PlayerColor;
|
||||||
import appeng.server.ServerHelper;
|
import appeng.server.ServerHelper;
|
||||||
import appeng.transformer.MissingCoreMod;
|
|
||||||
import appeng.util.Platform;
|
import appeng.util.Platform;
|
||||||
|
|
||||||
|
|
||||||
@@ -149,7 +149,7 @@ public class ClientHelper extends ServerHelper
|
|||||||
@Override
|
@Override
|
||||||
public void spawnEffect( final EffectType effect, final World worldObj, final double posX, final double posY, final double posZ, final Object o )
|
public void spawnEffect( final EffectType effect, final World worldObj, final double posX, final double posY, final double posZ, final Object o )
|
||||||
{
|
{
|
||||||
if( AEConfig.instance.enableEffects )
|
if( AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
switch( effect )
|
switch( effect )
|
||||||
{
|
{
|
||||||
@@ -354,7 +354,7 @@ public class ClientHelper extends ServerHelper
|
|||||||
final ItemStack is = player.getHeldItem( hand );
|
final ItemStack is = player.getHeldItem( hand );
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "Item", me.getDwheel() > 0 ? "WheelUp" : "WheelDown" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "Item", me.getDwheel() > 0 ? "WheelUp" : "WheelDown" ) );
|
||||||
me.setCanceled( true );
|
me.setCanceled( true );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
|
|||||||
@@ -161,12 +161,6 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
{
|
{
|
||||||
super.drawScreen( mouseX, mouseY, btn );
|
super.drawScreen( mouseX, mouseY, btn );
|
||||||
|
|
||||||
final boolean hasClicked = Mouse.isButtonDown( 0 );
|
|
||||||
if( hasClicked && this.getScrollBar() != null )
|
|
||||||
{
|
|
||||||
this.getScrollBar().click( this, mouseX - this.guiLeft, mouseY - this.guiTop );
|
|
||||||
}
|
|
||||||
|
|
||||||
for( final Object c : this.buttonList )
|
for( final Object c : this.buttonList )
|
||||||
{
|
{
|
||||||
if( c instanceof ITooltip )
|
if( c instanceof ITooltip )
|
||||||
@@ -258,13 +252,15 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
{
|
{
|
||||||
if( fs.isEnabled() )
|
if( fs.isEnabled() )
|
||||||
{
|
{
|
||||||
this.drawTexturedModalRect( ox + fs.xDisplayPosition - 1, oy + fs.yDisplayPosition - 1, fs.getSourceX() - 1, fs.getSourceY() - 1, 18, 18 );
|
this.drawTexturedModalRect( ox + fs.xDisplayPosition - 1, oy + fs.yDisplayPosition - 1, fs.getSourceX() - 1, fs.getSourceY() - 1, 18,
|
||||||
|
18 );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
GlStateManager.color( 1.0F, 1.0F, 1.0F, 0.4F );
|
GlStateManager.color( 1.0F, 1.0F, 1.0F, 0.4F );
|
||||||
GlStateManager.enableBlend();
|
GlStateManager.enableBlend();
|
||||||
this.drawTexturedModalRect( ox + fs.xDisplayPosition - 1, oy + fs.yDisplayPosition - 1, fs.getSourceX() - 1, fs.getSourceY() - 1, 18, 18 );
|
this.drawTexturedModalRect( ox + fs.xDisplayPosition - 1, oy + fs.yDisplayPosition - 1, fs.getSourceX() - 1, fs.getSourceY() - 1, 18,
|
||||||
|
18 );
|
||||||
GlStateManager.color( 1.0F, 1.0F, 1.0F, 1.0F );
|
GlStateManager.color( 1.0F, 1.0F, 1.0F, 1.0F );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -290,6 +286,11 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( this.getScrollBar() != null )
|
||||||
|
{
|
||||||
|
this.getScrollBar().click( this, xCoord - this.guiLeft, yCoord - this.guiTop );
|
||||||
|
}
|
||||||
|
|
||||||
super.mouseClicked( xCoord, yCoord, btn );
|
super.mouseClicked( xCoord, yCoord, btn );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -299,6 +300,11 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
final Slot slot = this.getSlot( x, y );
|
final Slot slot = this.getSlot( x, y );
|
||||||
final ItemStack itemstack = this.mc.thePlayer.inventory.getItemStack();
|
final ItemStack itemstack = this.mc.thePlayer.inventory.getItemStack();
|
||||||
|
|
||||||
|
if( this.getScrollBar() != null )
|
||||||
|
{
|
||||||
|
this.getScrollBar().click( this, x - this.guiLeft, y - this.guiTop );
|
||||||
|
}
|
||||||
|
|
||||||
if( slot instanceof SlotFake && itemstack != null )
|
if( slot instanceof SlotFake && itemstack != null )
|
||||||
{
|
{
|
||||||
this.drag_click.add( slot );
|
this.drag_click.add( slot );
|
||||||
@@ -307,7 +313,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
for( final Slot dr : this.drag_click )
|
for( final Slot dr : this.drag_click )
|
||||||
{
|
{
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( c == 0 ? InventoryAction.PICKUP_OR_SET_DOWN : InventoryAction.PLACE_SINGLE, dr.slotNumber, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( c == 0 ? InventoryAction.PICKUP_OR_SET_DOWN : InventoryAction.PLACE_SINGLE, dr.slotNumber, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -333,7 +339,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
}
|
}
|
||||||
|
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( action, slotIdx, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( action, slotIdx, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -347,7 +353,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( ( (SlotPatternTerm) slot ).getRequest( isShiftKeyDown() ) );
|
NetworkHandler.instance().sendToServer( ( (SlotPatternTerm) slot ).getRequest( isShiftKeyDown() ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -373,7 +379,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
}
|
}
|
||||||
|
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( action, slotIdx, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( action, slotIdx, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -397,7 +403,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
|
|
||||||
( (AEBaseContainer) this.inventorySlots ).setTargetStack( stack );
|
( (AEBaseContainer) this.inventorySlots ).setTargetStack( stack );
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( InventoryAction.MOVE_REGION, slotNum, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( InventoryAction.MOVE_REGION, slotNum, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -431,7 +437,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
if( action != null )
|
if( action != null )
|
||||||
{
|
{
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( action, slot.getSlotIndex(), ( (SlotDisconnected) slot ).getSlot().getId() );
|
final PacketInventoryAction p = new PacketInventoryAction( action, slot.getSlotIndex(), ( (SlotDisconnected) slot ).getSlot().getId() );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
@@ -484,7 +490,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
{
|
{
|
||||||
( (AEBaseContainer) this.inventorySlots ).setTargetStack( stack );
|
( (AEBaseContainer) this.inventorySlots ).setTargetStack( stack );
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( action, this.getInventorySlots().size(), 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( action, this.getInventorySlots().size(), 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
@@ -515,7 +521,9 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
final List<Slot> slots = this.getInventorySlots();
|
final List<Slot> slots = this.getInventorySlots();
|
||||||
for( final Slot inventorySlot : slots )
|
for( final Slot inventorySlot : slots )
|
||||||
{
|
{
|
||||||
if( inventorySlot != null && inventorySlot.canTakeStack( this.mc.thePlayer ) && inventorySlot.getHasStack() && inventorySlot.inventory == slot.inventory && Container.canAddItemToSlot( inventorySlot, this.dbl_whichItem, true ) )
|
if( inventorySlot != null && inventorySlot.canTakeStack(
|
||||||
|
this.mc.thePlayer ) && inventorySlot.getHasStack() && inventorySlot.inventory == slot.inventory && Container.canAddItemToSlot(
|
||||||
|
inventorySlot, this.dbl_whichItem, true ) )
|
||||||
{
|
{
|
||||||
this.handleMouseClick( inventorySlot, inventorySlot.slotNumber, 1, clickType );
|
this.handleMouseClick( inventorySlot, inventorySlot.slotNumber, 1, clickType );
|
||||||
}
|
}
|
||||||
@@ -531,16 +539,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
@Override
|
@Override
|
||||||
protected boolean checkHotbarKeys( final int keyCode )
|
protected boolean checkHotbarKeys( final int keyCode )
|
||||||
{
|
{
|
||||||
final Slot theSlot;
|
final Slot theSlot = this.getSlotUnderMouse();
|
||||||
|
|
||||||
try
|
|
||||||
{
|
|
||||||
theSlot = ObfuscationReflectionHelper.getPrivateValue( GuiContainer.class, this, "theSlot", "field_147006_u", "f" );
|
|
||||||
}
|
|
||||||
catch( final Throwable t )
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
if( this.mc.thePlayer.inventory.getItemStack() == null && theSlot != null )
|
if( this.mc.thePlayer.inventory.getItemStack() == null && theSlot != null )
|
||||||
{
|
{
|
||||||
@@ -571,7 +570,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
{
|
{
|
||||||
if( s.getSlotIndex() == j && s.inventory == ( (AEBaseContainer) this.inventorySlots ).getPlayerInv() )
|
if( s.getSlotIndex() == j && s.inventory == ( (AEBaseContainer) this.inventorySlots ).getPlayerInv() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwapSlots( s.slotNumber, theSlot.slotNumber ) );
|
NetworkHandler.instance().sendToServer( new PacketSwapSlots( s.slotNumber, theSlot.slotNumber ) );
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -640,7 +639,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
for( int h = 0; h < times; h++ )
|
for( int h = 0; h < times; h++ )
|
||||||
{
|
{
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( direction, inventorySize, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( direction, inventorySize, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -693,7 +692,8 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
/**
|
/**
|
||||||
* This overrides the base-class method through some access transformer hackery...
|
* This overrides the base-class method through some access transformer hackery...
|
||||||
*/
|
*/
|
||||||
public void drawSlot( final Slot s )
|
@Override
|
||||||
|
public void drawSlot( Slot s )
|
||||||
{
|
{
|
||||||
if( s instanceof SlotME )
|
if( s instanceof SlotME )
|
||||||
{
|
{
|
||||||
@@ -712,7 +712,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
this.itemRender.zLevel = 0.0F;
|
this.itemRender.zLevel = 0.0F;
|
||||||
|
|
||||||
// Annoying but easier than trying to splice into render item
|
// Annoying but easier than trying to splice into render item
|
||||||
this.safeDrawSlot( new Size1Slot( s ) );
|
super.drawSlot( new Size1Slot( s ) );
|
||||||
|
|
||||||
stackSizeRenderer.renderStackSize( fontRendererObj, ( (SlotME) s ).getAEStack(), s.getStack(), s.xDisplayPosition, s.yDisplayPosition );
|
stackSizeRenderer.renderStackSize( fontRendererObj, ( (SlotME) s ).getAEStack(), s.getStack(), s.xDisplayPosition, s.yDisplayPosition );
|
||||||
|
|
||||||
@@ -759,11 +759,15 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
final float f1 = 0.00390625F;
|
final float f1 = 0.00390625F;
|
||||||
final float f = 0.00390625F;
|
final float f = 0.00390625F;
|
||||||
final float par6 = 16;
|
final float par6 = 16;
|
||||||
vb.pos( par1 + 0, par2 + par6, this.zLevel ).tex( ( par3 + 0 ) * f, ( par4 + par6 ) * f1 ).color( 1.0f, 1.0f, 1.0f, aes.getOpacityOfIcon() ).endVertex();
|
vb.pos( par1 + 0, par2 + par6, this.zLevel ).tex( ( par3 + 0 ) * f, ( par4 + par6 ) * f1 ).color( 1.0f, 1.0f, 1.0f,
|
||||||
|
aes.getOpacityOfIcon() ).endVertex();
|
||||||
final float par5 = 16;
|
final float par5 = 16;
|
||||||
vb.pos( par1 + par5, par2 + par6, this.zLevel ).tex( ( par3 + par5 ) * f, ( par4 + par6 ) * f1 ).color( 1.0f, 1.0f, 1.0f, aes.getOpacityOfIcon() ).endVertex();
|
vb.pos( par1 + par5, par2 + par6, this.zLevel ).tex( ( par3 + par5 ) * f, ( par4 + par6 ) * f1 ).color( 1.0f, 1.0f, 1.0f,
|
||||||
vb.pos( par1 + par5, par2 + 0, this.zLevel ).tex( ( par3 + par5 ) * f, ( par4 + 0 ) * f1 ).color( 1.0f, 1.0f, 1.0f, aes.getOpacityOfIcon() ).endVertex();
|
aes.getOpacityOfIcon() ).endVertex();
|
||||||
vb.pos( par1 + 0, par2 + 0, this.zLevel ).tex( ( par3 + 0 ) * f, ( par4 + 0 ) * f1 ).color( 1.0f, 1.0f, 1.0f, aes.getOpacityOfIcon() ).endVertex();
|
vb.pos( par1 + par5, par2 + 0, this.zLevel ).tex( ( par3 + par5 ) * f, ( par4 + 0 ) * f1 ).color( 1.0f, 1.0f, 1.0f,
|
||||||
|
aes.getOpacityOfIcon() ).endVertex();
|
||||||
|
vb.pos( par1 + 0, par2 + 0, this.zLevel ).tex( ( par3 + 0 ) * f, ( par4 + 0 ) * f1 ).color( 1.0f, 1.0f, 1.0f,
|
||||||
|
aes.getOpacityOfIcon() ).endVertex();
|
||||||
tessellator.draw();
|
tessellator.draw();
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -777,7 +781,8 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
{
|
{
|
||||||
if( ( (AppEngSlot) s ).getIsValid() == hasCalculatedValidness.NotAvailable )
|
if( ( (AppEngSlot) s ).getIsValid() == hasCalculatedValidness.NotAvailable )
|
||||||
{
|
{
|
||||||
boolean isValid = s.isItemValid( is ) || s instanceof SlotOutput || s instanceof AppEngCraftingSlot || s instanceof SlotDisabled || s instanceof SlotInaccessible || s instanceof SlotFake || s instanceof SlotRestrictedInput || s instanceof SlotDisconnected;
|
boolean isValid = s.isItemValid(
|
||||||
|
is ) || s instanceof SlotOutput || s instanceof AppEngCraftingSlot || s instanceof SlotDisabled || s instanceof SlotInaccessible || s instanceof SlotFake || s instanceof SlotRestrictedInput || s instanceof SlotDisconnected;
|
||||||
if( isValid && s instanceof SlotRestrictedInput )
|
if( isValid && s instanceof SlotRestrictedInput )
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
@@ -809,11 +814,11 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
if( s instanceof AppEngSlot )
|
if( s instanceof AppEngSlot )
|
||||||
{
|
{
|
||||||
( (AppEngSlot) s ).setDisplay( true );
|
( (AppEngSlot) s ).setDisplay( true );
|
||||||
this.safeDrawSlot( s );
|
super.drawSlot( s );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this.safeDrawSlot( s );
|
super.drawSlot( s );
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
@@ -824,7 +829,7 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// do the usual for non-ME Slots.
|
// do the usual for non-ME Slots.
|
||||||
this.safeDrawSlot( s );
|
super.drawSlot( s );
|
||||||
}
|
}
|
||||||
|
|
||||||
protected boolean isPowered()
|
protected boolean isPowered()
|
||||||
@@ -832,17 +837,6 @@ public abstract class AEBaseGui extends GuiContainer
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void safeDrawSlot( final Slot s )
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
GuiContainer.class.getDeclaredMethod( "func_146977_a_original", Slot.class ).invoke( this, s );
|
|
||||||
}
|
|
||||||
catch( final Exception err )
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public void bindTexture( final String file )
|
public void bindTexture( final String file )
|
||||||
{
|
{
|
||||||
final ResourceLocation loc = new ResourceLocation( AppEng.MOD_ID, "textures/" + file );
|
final ResourceLocation loc = new ResourceLocation( AppEng.MOD_ID, "textures/" + file );
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ public abstract class AEBaseMEGui extends AEBaseGui
|
|||||||
final Slot s = this.getSlot( mouseX, mouseY );
|
final Slot s = this.getSlot( mouseX, mouseY );
|
||||||
if( s instanceof SlotME )
|
if( s instanceof SlotME )
|
||||||
{
|
{
|
||||||
final int BigNumber = AEConfig.instance.useTerminalUseLargeFont() ? 999 : 9999;
|
final int BigNumber = AEConfig.instance().useTerminalUseLargeFont() ? 999 : 9999;
|
||||||
|
|
||||||
IAEItemStack myStack = null;
|
IAEItemStack myStack = null;
|
||||||
|
|
||||||
@@ -103,7 +103,7 @@ public abstract class AEBaseMEGui extends AEBaseGui
|
|||||||
final Slot s = this.getSlot( x, y );
|
final Slot s = this.getSlot( x, y );
|
||||||
if( s instanceof SlotME && stack != null )
|
if( s instanceof SlotME && stack != null )
|
||||||
{
|
{
|
||||||
final int BigNumber = AEConfig.instance.useTerminalUseLargeFont() ? 999 : 9999;
|
final int BigNumber = AEConfig.instance().useTerminalUseLargeFont() ? 999 : 9999;
|
||||||
|
|
||||||
IAEItemStack myStack = null;
|
IAEItemStack myStack = null;
|
||||||
|
|
||||||
|
|||||||
@@ -37,14 +37,14 @@ public class AEConfigGui extends GuiConfig
|
|||||||
|
|
||||||
public AEConfigGui( final GuiScreen parent )
|
public AEConfigGui( final GuiScreen parent )
|
||||||
{
|
{
|
||||||
super( parent, getConfigElements(), AppEng.MOD_ID, false, false, GuiConfig.getAbridgedConfigPath( AEConfig.instance.getFilePath() ) );
|
super( parent, getConfigElements(), AppEng.MOD_ID, false, false, GuiConfig.getAbridgedConfigPath( AEConfig.instance().getFilePath() ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
private static List<IConfigElement> getConfigElements()
|
private static List<IConfigElement> getConfigElements()
|
||||||
{
|
{
|
||||||
final List<IConfigElement> list = new ArrayList<IConfigElement>();
|
final List<IConfigElement> list = new ArrayList<IConfigElement>();
|
||||||
|
|
||||||
for( final String cat : AEConfig.instance.getCategoryNames() )
|
for( final String cat : AEConfig.instance().getCategoryNames() )
|
||||||
{
|
{
|
||||||
if( cat.equals( "versionchecker" ) )
|
if( cat.equals( "versionchecker" ) )
|
||||||
{
|
{
|
||||||
@@ -56,7 +56,7 @@ public class AEConfigGui extends GuiConfig
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
final ConfigCategory cc = AEConfig.instance.getCategory( cat );
|
final ConfigCategory cc = AEConfig.instance().getCategory( cat );
|
||||||
|
|
||||||
if( cc.isChild() )
|
if( cc.isChild() )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -176,15 +176,15 @@ public class GuiCellWorkbench extends GuiUpgradeable
|
|||||||
{
|
{
|
||||||
if( btn == this.copyMode )
|
if( btn == this.copyMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "CellWorkbench.Action", "CopyMode" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "CellWorkbench.Action", "CopyMode" ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.partition )
|
else if( btn == this.partition )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "CellWorkbench.Action", "Partition" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "CellWorkbench.Action", "Partition" ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.clear )
|
else if( btn == this.clear )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "CellWorkbench.Action", "Clear" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "CellWorkbench.Action", "Clear" ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.fuzzyMode )
|
else if( btn == this.fuzzyMode )
|
||||||
{
|
{
|
||||||
@@ -193,7 +193,7 @@ public class GuiCellWorkbench extends GuiUpgradeable
|
|||||||
FuzzyMode fz = (FuzzyMode) this.fuzzyMode.getCurrentValue();
|
FuzzyMode fz = (FuzzyMode) this.fuzzyMode.getCurrentValue();
|
||||||
fz = Platform.rotateEnum( fz, backwards, Settings.FUZZY_MODE.getPossibleValues() );
|
fz = Platform.rotateEnum( fz, backwards, Settings.FUZZY_MODE.getPossibleValues() );
|
||||||
|
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "CellWorkbench.Fuzzy", fz.name() ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "CellWorkbench.Fuzzy", fz.name() ) );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ public class GuiChest extends AEBaseGui
|
|||||||
|
|
||||||
if( par1GuiButton == this.priority )
|
if( par1GuiButton == this.priority )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ public class GuiCondenser extends AEBaseGui
|
|||||||
|
|
||||||
if( this.mode == btn )
|
if( this.mode == btn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( Settings.CONDENSER_OUTPUT, backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( Settings.CONDENSER_OUTPUT, backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -76,10 +76,10 @@ public class GuiCraftAmount extends AEBaseGui
|
|||||||
{
|
{
|
||||||
super.initGui();
|
super.initGui();
|
||||||
|
|
||||||
final int a = AEConfig.instance.craftItemsByStackAmounts( 0 );
|
final int a = AEConfig.instance().craftItemsByStackAmounts( 0 );
|
||||||
final int b = AEConfig.instance.craftItemsByStackAmounts( 1 );
|
final int b = AEConfig.instance().craftItemsByStackAmounts( 1 );
|
||||||
final int c = AEConfig.instance.craftItemsByStackAmounts( 2 );
|
final int c = AEConfig.instance().craftItemsByStackAmounts( 2 );
|
||||||
final int d = AEConfig.instance.craftItemsByStackAmounts( 3 );
|
final int d = AEConfig.instance().craftItemsByStackAmounts( 3 );
|
||||||
|
|
||||||
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 26, 22, 20, "+" + a ) );
|
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 26, 22, 20, "+" + a ) );
|
||||||
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 26, 28, 20, "+" + b ) );
|
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 26, 28, 20, "+" + b ) );
|
||||||
@@ -224,12 +224,12 @@ public class GuiCraftAmount extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.originalGuiBtn )
|
if( btn == this.originalGuiBtn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( this.originalGui ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( this.originalGui ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.next )
|
if( btn == this.next )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketCraftRequest( Integer.parseInt( this.amountToCraft.getText() ), isShiftKeyDown() ) );
|
NetworkHandler.instance().sendToServer( new PacketCraftRequest( Integer.parseInt( this.amountToCraft.getText() ), isShiftKeyDown() ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch( final NumberFormatException e )
|
catch( final NumberFormatException e )
|
||||||
|
|||||||
@@ -552,7 +552,7 @@ public class GuiCraftConfirm extends AEBaseGui
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "Terminal.Cpu", backwards ? "Prev" : "Next" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "Terminal.Cpu", backwards ? "Prev" : "Next" ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -562,14 +562,14 @@ public class GuiCraftConfirm extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.cancel )
|
if( btn == this.cancel )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( this.OriginalGui ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( this.OriginalGui ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.start )
|
if( btn == this.start )
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "Terminal.Start", "Start" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "Terminal.Start", "Start" ) );
|
||||||
}
|
}
|
||||||
catch( final Throwable e )
|
catch( final Throwable e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ public class GuiCraftingCPU extends AEBaseGui implements ISortSource
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "TileCrafting.Cancel", "Cancel" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "TileCrafting.Cancel", "Cancel" ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -248,7 +248,7 @@ public class GuiCraftingCPU extends AEBaseGui implements ISortSource
|
|||||||
scheduled = true;
|
scheduled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.useColoredCraftingStatus && ( active || scheduled ) )
|
if( AEConfig.instance().isUseColoredCraftingStatus() && ( active || scheduled ) )
|
||||||
{
|
{
|
||||||
final int bgColor = ( active ? AEColor.GREEN.blackVariant : AEColor.YELLOW.blackVariant ) | BACKGROUND_ALPHA;
|
final int bgColor = ( active ? AEColor.GREEN.blackVariant : AEColor.YELLOW.blackVariant ) | BACKGROUND_ALPHA;
|
||||||
final int startX = ( x * ( 1 + SECTION_LENGTH ) + ITEMSTACK_LEFT_OFFSET ) * 2;
|
final int startX = ( x * ( 1 + SECTION_LENGTH ) + ITEMSTACK_LEFT_OFFSET ) * 2;
|
||||||
|
|||||||
@@ -108,7 +108,7 @@ public class GuiCraftingStatus extends GuiCraftingCPU
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "Terminal.Cpu", backwards ? "Prev" : "Next" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "Terminal.Cpu", backwards ? "Prev" : "Next" ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -118,7 +118,7 @@ public class GuiCraftingStatus extends GuiCraftingCPU
|
|||||||
|
|
||||||
if( btn == this.originalGuiBtn )
|
if( btn == this.originalGuiBtn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( this.originalGui ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( this.originalGui ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ public class GuiCraftingTerm extends GuiMEMonitorable
|
|||||||
if( s != null )
|
if( s != null )
|
||||||
{
|
{
|
||||||
final PacketInventoryAction p = new PacketInventoryAction( InventoryAction.MOVE_REGION, s.slotNumber, 0 );
|
final PacketInventoryAction p = new PacketInventoryAction( InventoryAction.MOVE_REGION, s.slotNumber, 0 );
|
||||||
NetworkHandler.instance.sendToServer( p );
|
NetworkHandler.instance().sendToServer( p );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ public class GuiDrive extends AEBaseGui
|
|||||||
|
|
||||||
if( par1GuiButton == this.priority )
|
if( par1GuiButton == this.priority )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -96,11 +96,11 @@ public class GuiFormationPlane extends GuiUpgradeable
|
|||||||
|
|
||||||
if( btn == this.priority )
|
if( btn == this.priority )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.placeMode )
|
else if( btn == this.placeMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.placeMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.placeMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -113,12 +113,12 @@ public class GuiIOPort extends GuiUpgradeable
|
|||||||
|
|
||||||
if( btn == this.fullMode )
|
if( btn == this.fullMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.fullMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.fullMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.operationMode )
|
if( btn == this.operationMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.operationMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.operationMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -103,17 +103,17 @@ public class GuiInterface extends GuiUpgradeable
|
|||||||
|
|
||||||
if( btn == this.priority )
|
if( btn == this.priority )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.interfaceMode )
|
if( btn == this.interfaceMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( Settings.INTERFACE_TERMINAL, backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( Settings.INTERFACE_TERMINAL, backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.BlockMode )
|
if( btn == this.BlockMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.BlockMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.BlockMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -88,10 +88,10 @@ public class GuiLevelEmitter extends GuiUpgradeable
|
|||||||
this.fuzzyMode = new GuiImgButton( this.guiLeft - 18, this.guiTop + 48, Settings.FUZZY_MODE, FuzzyMode.IGNORE_ALL );
|
this.fuzzyMode = new GuiImgButton( this.guiLeft - 18, this.guiTop + 48, Settings.FUZZY_MODE, FuzzyMode.IGNORE_ALL );
|
||||||
this.craftingMode = new GuiImgButton( this.guiLeft - 18, this.guiTop + 48, Settings.CRAFT_VIA_REDSTONE, YesNo.NO );
|
this.craftingMode = new GuiImgButton( this.guiLeft - 18, this.guiTop + 48, Settings.CRAFT_VIA_REDSTONE, YesNo.NO );
|
||||||
|
|
||||||
final int a = AEConfig.instance.levelByStackAmounts( 0 );
|
final int a = AEConfig.instance().levelByStackAmounts( 0 );
|
||||||
final int b = AEConfig.instance.levelByStackAmounts( 1 );
|
final int b = AEConfig.instance().levelByStackAmounts( 1 );
|
||||||
final int c = AEConfig.instance.levelByStackAmounts( 2 );
|
final int c = AEConfig.instance().levelByStackAmounts( 2 );
|
||||||
final int d = AEConfig.instance.levelByStackAmounts( 3 );
|
final int d = AEConfig.instance().levelByStackAmounts( 3 );
|
||||||
|
|
||||||
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 17, 22, 20, "+" + a ) );
|
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 17, 22, 20, "+" + a ) );
|
||||||
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 17, 28, 20, "+" + b ) );
|
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 17, 28, 20, "+" + b ) );
|
||||||
@@ -175,12 +175,12 @@ public class GuiLevelEmitter extends GuiUpgradeable
|
|||||||
|
|
||||||
if( btn == this.craftingMode )
|
if( btn == this.craftingMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.craftingMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.craftingMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.levelMode )
|
if( btn == this.levelMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.levelMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.levelMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
final boolean isPlus = btn == this.plus1 || btn == this.plus10 || btn == this.plus100 || btn == this.plus1000;
|
final boolean isPlus = btn == this.plus1 || btn == this.plus10 || btn == this.plus100 || btn == this.plus1000;
|
||||||
@@ -224,7 +224,7 @@ public class GuiLevelEmitter extends GuiUpgradeable
|
|||||||
|
|
||||||
this.level.setText( Out = Long.toString( result ) );
|
this.level.setText( Out = Long.toString( result ) );
|
||||||
|
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "LevelEmitter.Value", Out ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "LevelEmitter.Value", Out ) );
|
||||||
}
|
}
|
||||||
catch( final NumberFormatException e )
|
catch( final NumberFormatException e )
|
||||||
{
|
{
|
||||||
@@ -265,7 +265,7 @@ public class GuiLevelEmitter extends GuiUpgradeable
|
|||||||
Out = "0";
|
Out = "0";
|
||||||
}
|
}
|
||||||
|
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "LevelEmitter.Value", Out ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "LevelEmitter.Value", Out ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -168,7 +168,7 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
{
|
{
|
||||||
if( btn == this.craftingStatusBtn )
|
if( btn == this.craftingStatusBtn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_CRAFTING_STATUS ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_CRAFTING_STATUS ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn instanceof GuiImgButton )
|
if( btn instanceof GuiImgButton )
|
||||||
@@ -183,17 +183,17 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
|
|
||||||
if( btn == this.terminalStyleBox )
|
if( btn == this.terminalStyleBox )
|
||||||
{
|
{
|
||||||
AEConfig.instance.settings.putSetting( iBtn.getSetting(), next );
|
AEConfig.instance().getConfigManager().putSetting( iBtn.getSetting(), next );
|
||||||
}
|
}
|
||||||
else if( btn == this.searchBoxSettings )
|
else if( btn == this.searchBoxSettings )
|
||||||
{
|
{
|
||||||
AEConfig.instance.settings.putSetting( iBtn.getSetting(), next );
|
AEConfig.instance().getConfigManager().putSetting( iBtn.getSetting(), next );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( iBtn.getSetting().name(), next.name() ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( iBtn.getSetting().name(), next.name() ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -223,7 +223,7 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
Keyboard.enableRepeatEvents( true );
|
Keyboard.enableRepeatEvents( true );
|
||||||
|
|
||||||
this.maxRows = this.getMaxRows();
|
this.maxRows = this.getMaxRows();
|
||||||
this.perRow = AEConfig.instance.getConfigManager().getSetting( Settings.TERMINAL_STYLE ) != TerminalStyle.FULL ? 9 : 9 + ( ( this.width - this.standardSize ) / 18 );
|
this.perRow = AEConfig.instance().getConfigManager().getSetting( Settings.TERMINAL_STYLE ) != TerminalStyle.FULL ? 9 : 9 + ( ( this.width - this.standardSize ) / 18 );
|
||||||
|
|
||||||
final int magicNumber = 114 + 1;
|
final int magicNumber = 114 + 1;
|
||||||
final int extraSpace = this.height - magicNumber - this.reservedSpace;
|
final int extraSpace = this.height - magicNumber - this.reservedSpace;
|
||||||
@@ -248,7 +248,7 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.getConfigManager().getSetting( Settings.TERMINAL_STYLE ) != TerminalStyle.FULL )
|
if( AEConfig.instance().getConfigManager().getSetting( Settings.TERMINAL_STYLE ) != TerminalStyle.FULL )
|
||||||
{
|
{
|
||||||
this.xSize = this.standardSize + ( ( this.perRow - 9 ) * 18 );
|
this.xSize = this.standardSize + ( ( this.perRow - 9 ) * 18 );
|
||||||
}
|
}
|
||||||
@@ -284,12 +284,12 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
this.buttonList.add( this.SortDirBox = new GuiImgButton( this.guiLeft - 18, offset, Settings.SORT_DIRECTION, this.configSrc.getSetting( Settings.SORT_DIRECTION ) ) );
|
this.buttonList.add( this.SortDirBox = new GuiImgButton( this.guiLeft - 18, offset, Settings.SORT_DIRECTION, this.configSrc.getSetting( Settings.SORT_DIRECTION ) ) );
|
||||||
offset += 20;
|
offset += 20;
|
||||||
|
|
||||||
this.buttonList.add( this.searchBoxSettings = new GuiImgButton( this.guiLeft - 18, offset, Settings.SEARCH_MODE, AEConfig.instance.settings.getSetting( Settings.SEARCH_MODE ) ) );
|
this.buttonList.add( this.searchBoxSettings = new GuiImgButton( this.guiLeft - 18, offset, Settings.SEARCH_MODE, AEConfig.instance().getConfigManager().getSetting( Settings.SEARCH_MODE ) ) );
|
||||||
offset += 20;
|
offset += 20;
|
||||||
|
|
||||||
if( !( this instanceof GuiMEPortableCell ) || this instanceof GuiWirelessTerm )
|
if( !( this instanceof GuiMEPortableCell ) || this instanceof GuiWirelessTerm )
|
||||||
{
|
{
|
||||||
this.buttonList.add( this.terminalStyleBox = new GuiImgButton( this.guiLeft - 18, offset, Settings.TERMINAL_STYLE, AEConfig.instance.settings.getSetting( Settings.TERMINAL_STYLE ) ) );
|
this.buttonList.add( this.terminalStyleBox = new GuiImgButton( this.guiLeft - 18, offset, Settings.TERMINAL_STYLE, AEConfig.instance().getConfigManager().getSetting( Settings.TERMINAL_STYLE ) ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
this.searchField = new MEGuiTextField( this.fontRendererObj, this.guiLeft + Math.max( 80, this.offsetX ), this.guiTop + 4, 90, 12 );
|
this.searchField = new MEGuiTextField( this.fontRendererObj, this.guiLeft + Math.max( 80, this.offsetX ), this.guiTop + 4, 90, 12 );
|
||||||
@@ -304,8 +304,8 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
this.craftingStatusBtn.setHideEdge( 13 );
|
this.craftingStatusBtn.setHideEdge( 13 );
|
||||||
}
|
}
|
||||||
|
|
||||||
// Enum setting = AEConfig.INSTANCE.getSetting( "Terminal", SearchBoxMode.class, SearchBoxMode.AUTOSEARCH );
|
// Enum setting = AEConfig.instance().getSetting( "Terminal", SearchBoxMode.class, SearchBoxMode.AUTOSEARCH );
|
||||||
final Enum setting = AEConfig.instance.settings.getSetting( Settings.SEARCH_MODE );
|
final Enum setting = AEConfig.instance().getConfigManager().getSetting( Settings.SEARCH_MODE );
|
||||||
this.searchField.setFocused( SearchBoxMode.AUTOSEARCH == setting || SearchBoxMode.JEI_AUTOSEARCH == setting );
|
this.searchField.setFocused( SearchBoxMode.AUTOSEARCH == setting || SearchBoxMode.JEI_AUTOSEARCH == setting );
|
||||||
|
|
||||||
if( this.isSubGui() )
|
if( this.isSubGui() )
|
||||||
@@ -354,7 +354,7 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
@Override
|
@Override
|
||||||
protected void mouseClicked( final int xCoord, final int yCoord, final int btn ) throws IOException
|
protected void mouseClicked( final int xCoord, final int yCoord, final int btn ) throws IOException
|
||||||
{
|
{
|
||||||
final Enum searchMode = AEConfig.instance.settings.getSetting( Settings.SEARCH_MODE );
|
final Enum searchMode = AEConfig.instance().getConfigManager().getSetting( Settings.SEARCH_MODE );
|
||||||
|
|
||||||
if( searchMode != SearchBoxMode.AUTOSEARCH && searchMode != SearchBoxMode.JEI_AUTOSEARCH )
|
if( searchMode != SearchBoxMode.AUTOSEARCH && searchMode != SearchBoxMode.JEI_AUTOSEARCH )
|
||||||
{
|
{
|
||||||
@@ -438,7 +438,7 @@ public class GuiMEMonitorable extends AEBaseMEGui implements ISortSource, IConfi
|
|||||||
|
|
||||||
int getMaxRows()
|
int getMaxRows()
|
||||||
{
|
{
|
||||||
return AEConfig.instance.getConfigManager().getSetting( Settings.TERMINAL_STYLE ) == TerminalStyle.SMALL ? 6 : Integer.MAX_VALUE;
|
return AEConfig.instance().getConfigManager().getSetting( Settings.TERMINAL_STYLE ) == TerminalStyle.SMALL ? 6 : Integer.MAX_VALUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void repositionSlot( final AppEngSlot s )
|
protected void repositionSlot( final AppEngSlot s )
|
||||||
|
|||||||
@@ -77,8 +77,8 @@ public class GuiNetworkStatus extends AEBaseGui implements ISortSource
|
|||||||
|
|
||||||
if( btn == this.units )
|
if( btn == this.units )
|
||||||
{
|
{
|
||||||
AEConfig.instance.nextPowerUnit( backwards );
|
AEConfig.instance().nextPowerUnit( backwards );
|
||||||
this.units.set( AEConfig.instance.selectedPowerUnit() );
|
this.units.set( AEConfig.instance().selectedPowerUnit() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -87,7 +87,7 @@ public class GuiNetworkStatus extends AEBaseGui implements ISortSource
|
|||||||
{
|
{
|
||||||
super.initGui();
|
super.initGui();
|
||||||
|
|
||||||
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance.selectedPowerUnit() );
|
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance().selectedPowerUnit() );
|
||||||
this.buttonList.add( this.units );
|
this.buttonList.add( this.units );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ public class GuiNetworkTool extends AEBaseGui
|
|||||||
{
|
{
|
||||||
if( btn == this.tFacades )
|
if( btn == this.tFacades )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "NetworkTool", "Toggle" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "NetworkTool", "Toggle" ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
|
|||||||
@@ -78,22 +78,22 @@ public class GuiPatternTerm extends GuiMEMonitorable
|
|||||||
|
|
||||||
if( this.tabCraftButton == btn || this.tabProcessButton == btn )
|
if( this.tabCraftButton == btn || this.tabProcessButton == btn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PatternTerminal.CraftMode", this.tabProcessButton == btn ? CRAFTMODE_CRFTING : CRAFTMODE_PROCESSING ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PatternTerminal.CraftMode", this.tabProcessButton == btn ? CRAFTMODE_CRFTING : CRAFTMODE_PROCESSING ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( this.encodeBtn == btn )
|
if( this.encodeBtn == btn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PatternTerminal.Encode", "1" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PatternTerminal.Encode", "1" ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( this.clearBtn == btn )
|
if( this.clearBtn == btn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PatternTerminal.Clear", "1" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PatternTerminal.Clear", "1" ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( this.substitutionsEnabledBtn == btn || this.substitutionsDisabledBtn == btn )
|
if( this.substitutionsEnabledBtn == btn || this.substitutionsDisabledBtn == btn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PatternTerminal.Substitute", this.substitutionsEnabledBtn == btn ? SUBSITUTION_DISABLE : SUBSITUTION_ENABLE ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PatternTerminal.Substitute", this.substitutionsEnabledBtn == btn ? SUBSITUTION_DISABLE : SUBSITUTION_ENABLE ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
|
|||||||
@@ -77,10 +77,10 @@ public class GuiPriority extends AEBaseGui
|
|||||||
{
|
{
|
||||||
super.initGui();
|
super.initGui();
|
||||||
|
|
||||||
final int a = AEConfig.instance.priorityByStacksAmounts( 0 );
|
final int a = AEConfig.instance().priorityByStacksAmounts( 0 );
|
||||||
final int b = AEConfig.instance.priorityByStacksAmounts( 1 );
|
final int b = AEConfig.instance().priorityByStacksAmounts( 1 );
|
||||||
final int c = AEConfig.instance.priorityByStacksAmounts( 2 );
|
final int c = AEConfig.instance().priorityByStacksAmounts( 2 );
|
||||||
final int d = AEConfig.instance.priorityByStacksAmounts( 3 );
|
final int d = AEConfig.instance().priorityByStacksAmounts( 3 );
|
||||||
|
|
||||||
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 32, 22, 20, "+" + a ) );
|
this.buttonList.add( this.plus1 = new GuiButton( 0, this.guiLeft + 20, this.guiTop + 32, 22, 20, "+" + a ) );
|
||||||
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 32, 28, 20, "+" + b ) );
|
this.buttonList.add( this.plus10 = new GuiButton( 0, this.guiLeft + 48, this.guiTop + 32, 28, 20, "+" + b ) );
|
||||||
@@ -170,7 +170,7 @@ public class GuiPriority extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.originalGuiBtn )
|
if( btn == this.originalGuiBtn )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( this.OriginalGui ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( this.OriginalGui ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
final boolean isPlus = btn == this.plus1 || btn == this.plus10 || btn == this.plus100 || btn == this.plus1000;
|
final boolean isPlus = btn == this.plus1 || btn == this.plus10 || btn == this.plus100 || btn == this.plus1000;
|
||||||
@@ -210,7 +210,7 @@ public class GuiPriority extends AEBaseGui
|
|||||||
|
|
||||||
this.priority.setText( out = Long.toString( result ) );
|
this.priority.setText( out = Long.toString( result ) );
|
||||||
|
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PriorityHost.Priority", out ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PriorityHost.Priority", out ) );
|
||||||
}
|
}
|
||||||
catch( final NumberFormatException e )
|
catch( final NumberFormatException e )
|
||||||
{
|
{
|
||||||
@@ -251,7 +251,7 @@ public class GuiPriority extends AEBaseGui
|
|||||||
out = "0";
|
out = "0";
|
||||||
}
|
}
|
||||||
|
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "PriorityHost.Priority", out ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "PriorityHost.Priority", out ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ public class GuiQuartzKnife extends AEBaseGui
|
|||||||
{
|
{
|
||||||
final String Out = this.name.getText();
|
final String Out = this.name.getText();
|
||||||
( (ContainerQuartzKnife) this.inventorySlots ).setName( Out );
|
( (ContainerQuartzKnife) this.inventorySlots ).setName( Out );
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "QuartzKnife.Name", Out ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "QuartzKnife.Name", Out ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ public class GuiSecurityStation extends GuiMEMonitorable
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "TileSecurityStation.ToggleOption", toggleSetting.name() ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "TileSecurityStation.ToggleOption", toggleSetting.name() ) );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -58,8 +58,8 @@ public class GuiSpatialIOPort extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.units )
|
if( btn == this.units )
|
||||||
{
|
{
|
||||||
AEConfig.instance.nextPowerUnit( backwards );
|
AEConfig.instance().nextPowerUnit( backwards );
|
||||||
this.units.set( AEConfig.instance.selectedPowerUnit() );
|
this.units.set( AEConfig.instance().selectedPowerUnit() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -68,7 +68,7 @@ public class GuiSpatialIOPort extends AEBaseGui
|
|||||||
{
|
{
|
||||||
super.initGui();
|
super.initGui();
|
||||||
|
|
||||||
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance.selectedPowerUnit() );
|
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance().selectedPowerUnit() );
|
||||||
this.buttonList.add( this.units );
|
this.buttonList.add( this.units );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -116,23 +116,23 @@ public class GuiStorageBus extends GuiUpgradeable
|
|||||||
{
|
{
|
||||||
if( btn == this.partition )
|
if( btn == this.partition )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "StorageBus.Action", "Partition" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "StorageBus.Action", "Partition" ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.clear )
|
else if( btn == this.clear )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketValueConfig( "StorageBus.Action", "Clear" ) );
|
NetworkHandler.instance().sendToServer( new PacketValueConfig( "StorageBus.Action", "Clear" ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.priority )
|
else if( btn == this.priority )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
NetworkHandler.instance().sendToServer( new PacketSwitchGuis( GuiBridge.GUI_PRIORITY ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.rwMode )
|
else if( btn == this.rwMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.rwMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.rwMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
else if( btn == this.storageFilter )
|
else if( btn == this.storageFilter )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.storageFilter.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.storageFilter.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
|
|||||||
@@ -182,22 +182,22 @@ public class GuiUpgradeable extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.redstoneMode )
|
if( btn == this.redstoneMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.redstoneMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.redstoneMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.craftMode )
|
if( btn == this.craftMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.craftMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.craftMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.fuzzyMode )
|
if( btn == this.fuzzyMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.fuzzyMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.fuzzyMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( btn == this.schedulingMode )
|
if( btn == this.schedulingMode )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketConfigButton( this.schedulingMode.getSetting(), backwards ) );
|
NetworkHandler.instance().sendToServer( new PacketConfigButton( this.schedulingMode.getSetting(), backwards ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,8 +56,8 @@ public class GuiWireless extends AEBaseGui
|
|||||||
|
|
||||||
if( btn == this.units )
|
if( btn == this.units )
|
||||||
{
|
{
|
||||||
AEConfig.instance.nextPowerUnit( backwards );
|
AEConfig.instance().nextPowerUnit( backwards );
|
||||||
this.units.set( AEConfig.instance.selectedPowerUnit() );
|
this.units.set( AEConfig.instance().selectedPowerUnit() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -66,7 +66,7 @@ public class GuiWireless extends AEBaseGui
|
|||||||
{
|
{
|
||||||
super.initGui();
|
super.initGui();
|
||||||
|
|
||||||
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance.selectedPowerUnit() );
|
this.units = new GuiImgButton( this.guiLeft - 18, this.guiTop + 8, Settings.POWER_UNITS, AEConfig.instance().selectedPowerUnit() );
|
||||||
this.buttonList.add( this.units );
|
this.buttonList.add( this.units );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -123,14 +123,14 @@ public class ItemRepo
|
|||||||
this.dsp.ensureCapacity( this.list.size() );
|
this.dsp.ensureCapacity( this.list.size() );
|
||||||
|
|
||||||
final Enum viewMode = this.sortSrc.getSortDisplay();
|
final Enum viewMode = this.sortSrc.getSortDisplay();
|
||||||
final Enum searchMode = AEConfig.instance.settings.getSetting( Settings.SEARCH_MODE );
|
final Enum searchMode = AEConfig.instance().getConfigManager().getSetting( Settings.SEARCH_MODE );
|
||||||
if( searchMode == SearchBoxMode.JEI_AUTOSEARCH || searchMode == SearchBoxMode.JEI_MANUAL_SEARCH )
|
if( searchMode == SearchBoxMode.JEI_AUTOSEARCH || searchMode == SearchBoxMode.JEI_MANUAL_SEARCH )
|
||||||
{
|
{
|
||||||
this.updateJEI( this.searchString );
|
this.updateJEI( this.searchString );
|
||||||
}
|
}
|
||||||
|
|
||||||
this.innerSearch = this.searchString;
|
this.innerSearch = this.searchString;
|
||||||
final boolean terminalSearchToolTips = AEConfig.instance.settings.getSetting( Settings.SEARCH_TOOLTIPS ) != YesNo.NO;
|
final boolean terminalSearchToolTips = AEConfig.instance().getConfigManager().getSetting( Settings.SEARCH_TOOLTIPS ) != YesNo.NO;
|
||||||
// boolean terminalSearchMods = Configuration.INSTANCE.settings.getSetting( Settings.SEARCH_MODS ) != YesNo.NO;
|
// boolean terminalSearchMods = Configuration.INSTANCE.settings.getSetting( Settings.SEARCH_MODS ) != YesNo.NO;
|
||||||
|
|
||||||
boolean searchMod = false;
|
boolean searchMod = false;
|
||||||
|
|||||||
@@ -46,16 +46,16 @@ public class StackSizeRenderer
|
|||||||
{
|
{
|
||||||
if( is != null )
|
if( is != null )
|
||||||
{
|
{
|
||||||
final float scaleFactor = AEConfig.instance.useTerminalUseLargeFont() ? 0.85f : 0.5f;
|
final float scaleFactor = AEConfig.instance().useTerminalUseLargeFont() ? 0.85f : 0.5f;
|
||||||
final float inverseScaleFactor = 1.0f / scaleFactor;
|
final float inverseScaleFactor = 1.0f / scaleFactor;
|
||||||
final int offset = AEConfig.instance.useTerminalUseLargeFont() ? 0 : -1;
|
final int offset = AEConfig.instance().useTerminalUseLargeFont() ? 0 : -1;
|
||||||
|
|
||||||
final boolean unicodeFlag = fontRenderer.getUnicodeFlag();
|
final boolean unicodeFlag = fontRenderer.getUnicodeFlag();
|
||||||
fontRenderer.setUnicodeFlag( false );
|
fontRenderer.setUnicodeFlag( false );
|
||||||
|
|
||||||
if( is.stackSize == 0 )
|
if( is.stackSize == 0 )
|
||||||
{
|
{
|
||||||
final String craftLabelText = AEConfig.instance.useTerminalUseLargeFont() ? GuiText.LargeFontCraft.getLocal() : GuiText.SmallFontCraft.getLocal();
|
final String craftLabelText = AEConfig.instance().useTerminalUseLargeFont() ? GuiText.LargeFontCraft.getLocal() : GuiText.SmallFontCraft.getLocal();
|
||||||
GlStateManager.disableLighting();
|
GlStateManager.disableLighting();
|
||||||
GlStateManager.disableDepth();
|
GlStateManager.disableDepth();
|
||||||
GlStateManager.disableBlend();
|
GlStateManager.disableBlend();
|
||||||
@@ -95,7 +95,7 @@ public class StackSizeRenderer
|
|||||||
|
|
||||||
private String getToBeRenderedStackSize( final long originalSize )
|
private String getToBeRenderedStackSize( final long originalSize )
|
||||||
{
|
{
|
||||||
if( AEConfig.instance.useTerminalUseLargeFont() )
|
if( AEConfig.instance().useTerminalUseLargeFont() )
|
||||||
{
|
{
|
||||||
return SLIM_CONVERTER.toSlimReadableForm( originalSize );
|
return SLIM_CONVERTER.toSlimReadableForm( originalSize );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -174,6 +174,9 @@ public class FacadeBuilder
|
|||||||
|
|
||||||
builder.setDrawFaces( EnumSet.allOf( EnumFacing.class ) );
|
builder.setDrawFaces( EnumSet.allOf( EnumFacing.class ) );
|
||||||
|
|
||||||
|
// Reset to no color multiplicator
|
||||||
|
builder.setColorRGB( 0xFFFFFF );
|
||||||
|
|
||||||
// We only render the stilt if we don't intersect with any part directly, and if there's no part on our side
|
// We only render the stilt if we don't intersect with any part directly, and if there's no part on our side
|
||||||
if( renderStilt && busBounds == null && layer == BlockRenderLayer.CUTOUT )
|
if( renderStilt && busBounds == null && layer == BlockRenderLayer.CUTOUT )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -265,7 +265,7 @@ public abstract class AEBaseContainer extends Container
|
|||||||
{
|
{
|
||||||
final PacketPartialItem ppi = new PacketPartialItem( page, miniPackets.size(), packet );
|
final PacketPartialItem ppi = new PacketPartialItem( page, miniPackets.size(), packet );
|
||||||
page++;
|
page++;
|
||||||
NetworkHandler.instance.sendToServer( ppi );
|
NetworkHandler.instance().sendToServer( ppi );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
@@ -1103,7 +1103,7 @@ public abstract class AEBaseContainer extends Container
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketInventoryAction( InventoryAction.UPDATE_HAND, 0, AEItemStack.create( p.inventory.getItemStack() ) ), p );
|
NetworkHandler.instance().sendTo( new PacketInventoryAction( InventoryAction.UPDATE_HAND, 0, AEItemStack.create( p.inventory.getItemStack() ) ), p );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -1172,7 +1172,7 @@ public abstract class AEBaseContainer extends Container
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketValueConfig( "CustomName", this.getCustomName() ), (EntityPlayerMP) this.getInventoryPlayer().player );
|
NetworkHandler.instance().sendTo( new PacketValueConfig( "CustomName", this.getCustomName() ), (EntityPlayerMP) this.getInventoryPlayer().player );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ public class SyncData
|
|||||||
{
|
{
|
||||||
if( o instanceof EntityPlayerMP )
|
if( o instanceof EntityPlayerMP )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketValueConfig( "SyncDat." + this.channel, (String) val ), (EntityPlayerMP) o );
|
NetworkHandler.instance().sendTo( new PacketValueConfig( "SyncDat." + this.channel, (String) val ), (EntityPlayerMP) o );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if( this.field.getType().isEnum() )
|
else if( this.field.getType().isEnum() )
|
||||||
@@ -97,7 +97,10 @@ public class SyncData
|
|||||||
}
|
}
|
||||||
else if( val instanceof Long || val.getClass() == long.class )
|
else if( val instanceof Long || val.getClass() == long.class )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketProgressBar( this.channel, (Long) val ), (EntityPlayerMP) o );
|
if( o instanceof EntityPlayerMP )
|
||||||
|
{
|
||||||
|
NetworkHandler.instance().sendTo( new PacketProgressBar( this.channel, (Long) val ), (EntityPlayerMP) o );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if( val instanceof Boolean || val.getClass() == boolean.class )
|
else if( val instanceof Boolean || val.getClass() == boolean.class )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -263,11 +263,11 @@ public class ContainerCraftConfirm extends AEBaseContainer
|
|||||||
{
|
{
|
||||||
if( g instanceof EntityPlayer )
|
if( g instanceof EntityPlayer )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( a, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( a, (EntityPlayerMP) g );
|
||||||
NetworkHandler.instance.sendTo( b, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( b, (EntityPlayerMP) g );
|
||||||
if( c != null )
|
if( c != null )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( c, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( c, (EntityPlayerMP) g );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -352,7 +352,7 @@ public class ContainerCraftConfirm extends AEBaseContainer
|
|||||||
this.setAutoStart( false );
|
this.setAutoStart( false );
|
||||||
if( g != null && originalGui != null && this.getOpenContext() != null )
|
if( g != null && originalGui != null && this.getOpenContext() != null )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketSwitchGuis( originalGui ), (EntityPlayerMP) this.getInventoryPlayer().player );
|
NetworkHandler.instance().sendTo( new PacketSwitchGuis( originalGui ), (EntityPlayerMP) this.getInventoryPlayer().player );
|
||||||
|
|
||||||
final TileEntity te = this.getOpenContext().getTile();
|
final TileEntity te = this.getOpenContext().getTile();
|
||||||
Platform.openGUI( this.getInventoryPlayer().player, te, this.getOpenContext().getSide(), originalGui );
|
Platform.openGUI( this.getInventoryPlayer().player, te, this.getOpenContext().getSide(), originalGui );
|
||||||
|
|||||||
@@ -117,7 +117,7 @@ public class ContainerCraftingCPU extends AEBaseContainer implements IMEMonitorH
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketValueConfig( "CraftingStatus", "Clear" ), (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( new PacketValueConfig( "CraftingStatus", "Clear" ), (EntityPlayerMP) g );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
@@ -208,17 +208,17 @@ public class ContainerCraftingCPU extends AEBaseContainer implements IMEMonitorH
|
|||||||
{
|
{
|
||||||
if( !a.isEmpty() )
|
if( !a.isEmpty() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( a, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( a, (EntityPlayerMP) g );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !b.isEmpty() )
|
if( !b.isEmpty() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( b, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( b, (EntityPlayerMP) g );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !c.isEmpty() )
|
if( !c.isEmpty() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( c, (EntityPlayerMP) g );
|
NetworkHandler.instance().sendTo( c, (EntityPlayerMP) g );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ public final class ContainerInterfaceTerminal extends AEBaseContainer
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketCompressedNBT( this.data ), (EntityPlayerMP) this.getPlayerInv().player );
|
NetworkHandler.instance().sendTo( new PacketCompressedNBT( this.data ), (EntityPlayerMP) this.getPlayerInv().player );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -186,15 +186,18 @@ public class ContainerMEMonitorable extends AEBaseContainer implements IConfigMa
|
|||||||
if( sideLocal != sideRemote )
|
if( sideLocal != sideRemote )
|
||||||
{
|
{
|
||||||
this.clientCM.putSetting( set, sideLocal );
|
this.clientCM.putSetting( set, sideLocal );
|
||||||
for( final Object crafter : this.listeners )
|
for( final IContainerListener crafter : this.listeners )
|
||||||
{
|
{
|
||||||
try
|
if( crafter instanceof EntityPlayerMP )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketValueConfig( set.name(), sideLocal.name() ), (EntityPlayerMP) crafter );
|
try
|
||||||
}
|
{
|
||||||
catch( final IOException e )
|
NetworkHandler.instance().sendTo( new PacketValueConfig( set.name(), sideLocal.name() ), (EntityPlayerMP) crafter );
|
||||||
{
|
}
|
||||||
AELog.debug( e );
|
catch( final IOException e )
|
||||||
|
{
|
||||||
|
AELog.debug( e );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -230,7 +233,7 @@ public class ContainerMEMonitorable extends AEBaseContainer implements IConfigMa
|
|||||||
{
|
{
|
||||||
if( c instanceof EntityPlayer )
|
if( c instanceof EntityPlayer )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( piu, (EntityPlayerMP) c );
|
NetworkHandler.instance().sendTo( piu, (EntityPlayerMP) c );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -258,6 +261,7 @@ public class ContainerMEMonitorable extends AEBaseContainer implements IConfigMa
|
|||||||
|
|
||||||
super.detectAndSendChanges();
|
super.detectAndSendChanges();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void updatePowerStatus()
|
protected void updatePowerStatus()
|
||||||
@@ -325,14 +329,14 @@ public class ContainerMEMonitorable extends AEBaseContainer implements IConfigMa
|
|||||||
}
|
}
|
||||||
catch( final BufferOverflowException boe )
|
catch( final BufferOverflowException boe )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( piu, (EntityPlayerMP) c );
|
NetworkHandler.instance().sendTo( piu, (EntityPlayerMP) c );
|
||||||
|
|
||||||
piu = new PacketMEInventoryUpdate();
|
piu = new PacketMEInventoryUpdate();
|
||||||
piu.appendItem( send );
|
piu.appendItem( send );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NetworkHandler.instance.sendTo( piu, (EntityPlayerMP) c );
|
NetworkHandler.instance().sendTo( piu, (EntityPlayerMP) c );
|
||||||
}
|
}
|
||||||
catch( final IOException e )
|
catch( final IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -137,7 +137,7 @@ public class ContainerNetworkStatus extends AEBaseContainer
|
|||||||
{
|
{
|
||||||
if( c instanceof EntityPlayer )
|
if( c instanceof EntityPlayer )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( piu, (EntityPlayerMP) c );
|
NetworkHandler.instance().sendTo( piu, (EntityPlayerMP) c );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -53,8 +53,8 @@ public class ContainerWireless extends AEBaseContainer
|
|||||||
{
|
{
|
||||||
final int boosters = this.boosterSlot.getStack() == null ? 0 : this.boosterSlot.getStack().stackSize;
|
final int boosters = this.boosterSlot.getStack() == null ? 0 : this.boosterSlot.getStack().stackSize;
|
||||||
|
|
||||||
this.setRange( (long) ( 10 * AEConfig.instance.wireless_getMaxRange( boosters ) ) );
|
this.setRange( (long) ( 10 * AEConfig.instance().wireless_getMaxRange( boosters ) ) );
|
||||||
this.setDrain( (long) ( 100 * AEConfig.instance.wireless_getPowerDrain( boosters ) ) );
|
this.setDrain( (long) ( 100 * AEConfig.instance().wireless_getPowerDrain( boosters ) ) );
|
||||||
|
|
||||||
super.detectAndSendChanges();
|
super.detectAndSendChanges();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ public class ContainerWirelessTerm extends ContainerMEPortableCell
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this.setPowerMultiplier( AEConfig.instance.wireless_getDrainRate( this.wirelessTerminalGUIObject.getRange() ) );
|
this.setPowerMultiplier( AEConfig.instance().wireless_getDrainRate( this.wirelessTerminalGUIObject.getRange() ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ import java.util.Arrays;
|
|||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.EnumSet;
|
import java.util.EnumSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.common.config.Configuration;
|
import net.minecraftforge.common.config.Configuration;
|
||||||
@@ -52,73 +53,95 @@ import appeng.util.Platform;
|
|||||||
public final class AEConfig extends Configuration implements IConfigurableObject, IConfigManagerHost
|
public final class AEConfig extends Configuration implements IConfigurableObject, IConfigManagerHost
|
||||||
{
|
{
|
||||||
|
|
||||||
public static final double TUNNEL_POWER_LOSS = 0.05;
|
|
||||||
public static final String VERSION = "@version@";
|
public static final String VERSION = "@version@";
|
||||||
public static final String CHANNEL = "@aechannel@";
|
public static final String CHANNEL = "@aechannel@";
|
||||||
public static final String PACKET_CHANNEL = "AE";
|
public static final String PACKET_CHANNEL = "AE";
|
||||||
public static AEConfig instance;
|
|
||||||
public final IConfigManager settings = new ConfigManager( this );
|
|
||||||
public final EnumSet<AEFeature> featureFlags = EnumSet.noneOf( AEFeature.class );
|
|
||||||
public final int[] craftByStacks = { 1, 10, 100, 1000 };
|
|
||||||
public final int[] priorityByStacks = { 1, 10, 100, 1000 };
|
|
||||||
public final int[] levelByStacks = { 1, 10, 100, 1000 };
|
|
||||||
private final double WirelessHighWirelessCount = 64;
|
|
||||||
private final File configFile;
|
|
||||||
public int storageBiomeID = -1;
|
|
||||||
public int storageProviderID = -1;
|
|
||||||
public int formationPlaneEntityLimit = 128;
|
|
||||||
public float spawnChargedChance = 0.92f;
|
|
||||||
public int quartzOresPerCluster = 4;
|
|
||||||
public int quartzOresClusterAmount = 15;
|
|
||||||
public final int chargedChange = 4;
|
|
||||||
public int minMeteoriteDistance = 707;
|
|
||||||
public int minMeteoriteDistanceSq = this.minMeteoriteDistance * this.minMeteoriteDistance;
|
|
||||||
public double spatialPowerExponent = 1.35;
|
|
||||||
public double spatialPowerMultiplier = 1250.0;
|
|
||||||
public String[] grinderOres = {
|
|
||||||
// Vanilla Items
|
|
||||||
"Obsidian", "Ender", "EnderPearl", "Coal", "Iron", "Gold", "Charcoal", "NetherQuartz",
|
|
||||||
// Common Mod Ores
|
|
||||||
"Copper", "Tin", "Silver", "Lead", "Bronze",
|
|
||||||
// AE
|
|
||||||
"CertusQuartz", "Wheat", "Fluix",
|
|
||||||
// Other Mod Ores
|
|
||||||
"Brass", "Platinum", "Nickel", "Invar", "Aluminium", "Electrum", "Osmium", "Zinc" };
|
|
||||||
public double oreDoublePercentage = 90.0;
|
|
||||||
public boolean enableEffects = true;
|
|
||||||
public boolean useLargeFonts = false;
|
|
||||||
public boolean useColoredCraftingStatus;
|
|
||||||
public boolean removeCrashingItemsOnLoad = false;
|
|
||||||
public int wirelessTerminalBattery = 1600000;
|
|
||||||
public int entropyManipulatorBattery = 200000;
|
|
||||||
public int matterCannonBattery = 200000;
|
|
||||||
public int portableCellBattery = 20000;
|
|
||||||
public int colorApplicatorBattery = 20000;
|
|
||||||
public int chargedStaffBattery = 8000;
|
|
||||||
public boolean disableColoredCableRecipesInJEI = true;
|
|
||||||
public boolean updatable = false;
|
|
||||||
public double meteoriteClusterChance = 0.1;
|
|
||||||
public double meteoriteSpawnChance = 0.3;
|
|
||||||
public int[] meteoriteDimensionWhitelist = { 0 };
|
|
||||||
public int craftingCalculationTimePerTick = 5;
|
|
||||||
PowerUnits selectedPowerUnit = PowerUnits.AE;
|
|
||||||
private double WirelessBaseCost = 8;
|
|
||||||
private double WirelessCostMultiplier = 1;
|
|
||||||
private double WirelessTerminalDrainMultiplier = 1;
|
|
||||||
private double WirelessBaseRange = 16;
|
|
||||||
private double WirelessBoosterRangeMultiplier = 1;
|
|
||||||
private double WirelessBoosterExp = 1.5;
|
|
||||||
|
|
||||||
public AEConfig( final File configFile )
|
// Config instance
|
||||||
|
private static AEConfig instance;
|
||||||
|
|
||||||
|
// Default Grindstone ores
|
||||||
|
private static final String[] ORES_VANILLA = { "Obsidian", "Ender", "EnderPearl", "Coal", "Iron", "Gold", "Charcoal", "NetherQuartz" };
|
||||||
|
private static final String[] ORES_AE = { "CertusQuartz", "Wheat", "Fluix" };
|
||||||
|
private static final String[] ORES_COMMON = { "Copper", "Tin", "Silver", "Lead", "Bronze" };
|
||||||
|
private static final String[] ORES_MISC = { "Brass", "Platinum", "Nickel", "Invar", "Aluminium", "Electrum", "Osmium", "Zinc" };
|
||||||
|
|
||||||
|
// Default Energy Conversion Rates
|
||||||
|
private static final double DEFAULT_IC2_EXCHANGE = 2.0;
|
||||||
|
private static final double DEFAULT_RF_EXCHANGE = 0.5;
|
||||||
|
|
||||||
|
private final IConfigManager settings = new ConfigManager( this );
|
||||||
|
|
||||||
|
private final EnumSet<AEFeature> featureFlags = EnumSet.noneOf( AEFeature.class );
|
||||||
|
private final File configFile;
|
||||||
|
private boolean updatable = false;
|
||||||
|
|
||||||
|
// Misc
|
||||||
|
private boolean removeCrashingItemsOnLoad = false;
|
||||||
|
private int formationPlaneEntityLimit = 128;
|
||||||
|
private boolean enableEffects = true;
|
||||||
|
private boolean useLargeFonts = false;
|
||||||
|
private boolean useColoredCraftingStatus;
|
||||||
|
private boolean disableColoredCableRecipesInJEI = true;
|
||||||
|
private int craftingCalculationTimePerTick = 5;
|
||||||
|
private PowerUnits selectedPowerUnit = PowerUnits.AE;
|
||||||
|
|
||||||
|
// GUI Buttons
|
||||||
|
private final int[] craftByStacks = { 1, 10, 100, 1000 };
|
||||||
|
private final int[] priorityByStacks = { 1, 10, 100, 1000 };
|
||||||
|
private final int[] levelByStacks = { 1, 10, 100, 1000 };
|
||||||
|
|
||||||
|
// Spatial IO/Dimension
|
||||||
|
private int storageBiomeID = -1;
|
||||||
|
private int storageProviderID = -1;
|
||||||
|
private double spatialPowerExponent = 1.35;
|
||||||
|
private double spatialPowerMultiplier = 1250.0;
|
||||||
|
|
||||||
|
// Grindstone
|
||||||
|
private String[] grinderOres = Stream.of( ORES_VANILLA, ORES_AE, ORES_COMMON, ORES_MISC ).flatMap( Stream::of ).toArray( String[]::new );
|
||||||
|
private double oreDoublePercentage = 90.0;
|
||||||
|
|
||||||
|
// Batteries
|
||||||
|
private int wirelessTerminalBattery = 1600000;
|
||||||
|
private int entropyManipulatorBattery = 200000;
|
||||||
|
private int matterCannonBattery = 200000;
|
||||||
|
private int portableCellBattery = 20000;
|
||||||
|
private int colorApplicatorBattery = 20000;
|
||||||
|
private int chargedStaffBattery = 8000;
|
||||||
|
|
||||||
|
// Certus quartz
|
||||||
|
private float spawnChargedChance = 0.92f;
|
||||||
|
private int quartzOresPerCluster = 4;
|
||||||
|
private int quartzOresClusterAmount = 15;
|
||||||
|
private int chargedChange = 4;
|
||||||
|
|
||||||
|
// Meteors
|
||||||
|
private int minMeteoriteDistance = 707;
|
||||||
|
private int minMeteoriteDistanceSq = this.minMeteoriteDistance * this.minMeteoriteDistance;
|
||||||
|
private double meteoriteClusterChance = 0.1;
|
||||||
|
private int meteoriteMaximumSpawnHeight = 180;
|
||||||
|
private int[] meteoriteDimensionWhitelist = { 0 };
|
||||||
|
|
||||||
|
// Wireless
|
||||||
|
private double wirelessBaseCost = 8;
|
||||||
|
private double wirelessCostMultiplier = 1;
|
||||||
|
private double wirelessTerminalDrainMultiplier = 1;
|
||||||
|
private double wirelessBaseRange = 16;
|
||||||
|
private double wirelessBoosterRangeMultiplier = 1;
|
||||||
|
private double wirelessBoosterExp = 1.5;
|
||||||
|
private double wirelessHighWirelessCount = 64;
|
||||||
|
|
||||||
|
// Tunnels
|
||||||
|
public static final double TUNNEL_POWER_LOSS = 0.05;
|
||||||
|
|
||||||
|
private AEConfig( final File configFile )
|
||||||
{
|
{
|
||||||
super( configFile );
|
super( configFile );
|
||||||
this.configFile = configFile;
|
this.configFile = configFile;
|
||||||
|
|
||||||
MinecraftForge.EVENT_BUS.register( this );
|
MinecraftForge.EVENT_BUS.register( this );
|
||||||
|
|
||||||
final double DEFAULT_IC2_EXCHANGE = 2.0;
|
|
||||||
PowerUnits.EU.conversionRatio = this.get( "PowerRatios", "IC2", DEFAULT_IC2_EXCHANGE ).getDouble( DEFAULT_IC2_EXCHANGE );
|
PowerUnits.EU.conversionRatio = this.get( "PowerRatios", "IC2", DEFAULT_IC2_EXCHANGE ).getDouble( DEFAULT_IC2_EXCHANGE );
|
||||||
final double DEFAULT_RF_EXCHANGE = 0.5;
|
|
||||||
PowerUnits.RF.conversionRatio = this.get( "PowerRatios", "Forge Energy", DEFAULT_RF_EXCHANGE ).getDouble( DEFAULT_RF_EXCHANGE );
|
PowerUnits.RF.conversionRatio = this.get( "PowerRatios", "Forge Energy", DEFAULT_RF_EXCHANGE ).getDouble( DEFAULT_RF_EXCHANGE );
|
||||||
|
|
||||||
final double usageEffective = this.get( "PowerRatios", "UsageMultiplier", 1.0 ).getDouble( 1.0 );
|
final double usageEffective = this.get( "PowerRatios", "UsageMultiplier", 1.0 ).getDouble( 1.0 );
|
||||||
@@ -127,7 +150,8 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
CondenserOutput.MATTER_BALLS.requiredPower = this.get( "Condenser", "MatterBalls", 256 ).getInt( 256 );
|
CondenserOutput.MATTER_BALLS.requiredPower = this.get( "Condenser", "MatterBalls", 256 ).getInt( 256 );
|
||||||
CondenserOutput.SINGULARITY.requiredPower = this.get( "Condenser", "Singularity", 256000 ).getInt( 256000 );
|
CondenserOutput.SINGULARITY.requiredPower = this.get( "Condenser", "Singularity", 256000 ).getInt( 256000 );
|
||||||
|
|
||||||
this.removeCrashingItemsOnLoad = this.get( "general", "removeCrashingItemsOnLoad", false, "Will auto-remove items that crash when being loaded from storage. This will destroy those items instead of crashing the game!" ).getBoolean();
|
this.removeCrashingItemsOnLoad = this.get( "general", "removeCrashingItemsOnLoad", false,
|
||||||
|
"Will auto-remove items that crash when being loaded from storage. This will destroy those items instead of crashing the game!" ).getBoolean();
|
||||||
|
|
||||||
this.grinderOres = this.get( "GrindStone", "grinderOres", this.grinderOres ).getStringList();
|
this.grinderOres = this.get( "GrindStone", "grinderOres", this.grinderOres ).getStringList();
|
||||||
this.oreDoublePercentage = this.get( "GrindStone", "oreDoublePercentage", this.oreDoublePercentage ).getDouble( this.oreDoublePercentage );
|
this.oreDoublePercentage = this.get( "GrindStone", "oreDoublePercentage", this.oreDoublePercentage ).getDouble( this.oreDoublePercentage );
|
||||||
@@ -136,10 +160,12 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
this.settings.registerSetting( Settings.TERMINAL_STYLE, TerminalStyle.TALL );
|
this.settings.registerSetting( Settings.TERMINAL_STYLE, TerminalStyle.TALL );
|
||||||
this.settings.registerSetting( Settings.SEARCH_MODE, SearchBoxMode.AUTOSEARCH );
|
this.settings.registerSetting( Settings.SEARCH_MODE, SearchBoxMode.AUTOSEARCH );
|
||||||
|
|
||||||
this.spawnChargedChance = (float) ( 1.0 - this.get( "worldGen", "spawnChargedChance", 1.0 - this.spawnChargedChance ).getDouble( 1.0 - this.spawnChargedChance ) );
|
this.spawnChargedChance = (float) ( 1.0 - this.get( "worldGen", "spawnChargedChance", 1.0 - this.spawnChargedChance ).getDouble(
|
||||||
|
1.0 - this.spawnChargedChance ) );
|
||||||
this.minMeteoriteDistance = this.get( "worldGen", "minMeteoriteDistance", this.minMeteoriteDistance ).getInt( this.minMeteoriteDistance );
|
this.minMeteoriteDistance = this.get( "worldGen", "minMeteoriteDistance", this.minMeteoriteDistance ).getInt( this.minMeteoriteDistance );
|
||||||
this.meteoriteClusterChance = this.get( "worldGen", "meteoriteClusterChance", this.meteoriteClusterChance ).getDouble( this.meteoriteClusterChance );
|
this.meteoriteClusterChance = this.get( "worldGen", "meteoriteClusterChance", this.meteoriteClusterChance ).getDouble( this.meteoriteClusterChance );
|
||||||
this.meteoriteSpawnChance = this.get( "worldGen", "meteoriteSpawnChance", this.meteoriteSpawnChance ).getDouble( this.meteoriteSpawnChance );
|
this.meteoriteMaximumSpawnHeight = this.get( "worldGen", "meteoriteMaximumSpawnHeight", this.meteoriteMaximumSpawnHeight ).getInt(
|
||||||
|
this.meteoriteMaximumSpawnHeight );
|
||||||
this.meteoriteDimensionWhitelist = this.get( "worldGen", "meteoriteDimensionWhitelist", this.meteoriteDimensionWhitelist ).getIntList();
|
this.meteoriteDimensionWhitelist = this.get( "worldGen", "meteoriteDimensionWhitelist", this.meteoriteDimensionWhitelist ).getIntList();
|
||||||
|
|
||||||
this.quartzOresPerCluster = this.get( "worldGen", "quartzOresPerCluster", this.quartzOresPerCluster ).getInt( this.quartzOresPerCluster );
|
this.quartzOresPerCluster = this.get( "worldGen", "quartzOresPerCluster", this.quartzOresPerCluster ).getInt( this.quartzOresPerCluster );
|
||||||
@@ -147,16 +173,20 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
|
|
||||||
this.minMeteoriteDistanceSq = this.minMeteoriteDistance * this.minMeteoriteDistance;
|
this.minMeteoriteDistanceSq = this.minMeteoriteDistance * this.minMeteoriteDistance;
|
||||||
|
|
||||||
this.addCustomCategoryComment( "wireless", "Range= WirelessBaseRange + WirelessBoosterRangeMultiplier * Math.pow( boosters, WirelessBoosterExp )\nPowerDrain= WirelessBaseCost + WirelessCostMultiplier * Math.pow( boosters, 1 + boosters / WirelessHighWirelessCount )" );
|
this.addCustomCategoryComment( "wireless",
|
||||||
|
"Range= wirelessBaseRange + wirelessBoosterRangeMultiplier * Math.pow( boosters, wirelessBoosterExp )\nPowerDrain= wirelessBaseCost + wirelessCostMultiplier * Math.pow( boosters, 1 + boosters / wirelessHighWirelessCount )" );
|
||||||
|
|
||||||
this.WirelessBaseCost = this.get( "wireless", "WirelessBaseCost", this.WirelessBaseCost ).getDouble( this.WirelessBaseCost );
|
this.wirelessBaseCost = this.get( "wireless", "wirelessBaseCost", this.wirelessBaseCost ).getDouble( this.wirelessBaseCost );
|
||||||
this.WirelessCostMultiplier = this.get( "wireless", "WirelessCostMultiplier", this.WirelessCostMultiplier ).getDouble( this.WirelessCostMultiplier );
|
this.wirelessCostMultiplier = this.get( "wireless", "wirelessCostMultiplier", this.wirelessCostMultiplier ).getDouble( this.wirelessCostMultiplier );
|
||||||
this.WirelessBaseRange = this.get( "wireless", "WirelessBaseRange", this.WirelessBaseRange ).getDouble( this.WirelessBaseRange );
|
this.wirelessBaseRange = this.get( "wireless", "wirelessBaseRange", this.wirelessBaseRange ).getDouble( this.wirelessBaseRange );
|
||||||
this.WirelessBoosterRangeMultiplier = this.get( "wireless", "WirelessBoosterRangeMultiplier", this.WirelessBoosterRangeMultiplier ).getDouble( this.WirelessBoosterRangeMultiplier );
|
this.wirelessBoosterRangeMultiplier = this.get( "wireless", "wirelessBoosterRangeMultiplier", this.wirelessBoosterRangeMultiplier ).getDouble(
|
||||||
this.WirelessBoosterExp = this.get( "wireless", "WirelessBoosterExp", this.WirelessBoosterExp ).getDouble( this.WirelessBoosterExp );
|
this.wirelessBoosterRangeMultiplier );
|
||||||
this.WirelessTerminalDrainMultiplier = this.get( "wireless", "WirelessTerminalDrainMultiplier", this.WirelessTerminalDrainMultiplier ).getDouble( this.WirelessTerminalDrainMultiplier );
|
this.wirelessBoosterExp = this.get( "wireless", "wirelessBoosterExp", this.wirelessBoosterExp ).getDouble( this.wirelessBoosterExp );
|
||||||
|
this.wirelessTerminalDrainMultiplier = this.get( "wireless", "wirelessTerminalDrainMultiplier", this.wirelessTerminalDrainMultiplier ).getDouble(
|
||||||
|
this.wirelessTerminalDrainMultiplier );
|
||||||
|
|
||||||
this.formationPlaneEntityLimit = this.get( "automation", "formationPlaneEntityLimit", this.formationPlaneEntityLimit ).getInt( this.formationPlaneEntityLimit );
|
this.formationPlaneEntityLimit = this.get( "automation", "formationPlaneEntityLimit", this.formationPlaneEntityLimit ).getInt(
|
||||||
|
this.formationPlaneEntityLimit );
|
||||||
|
|
||||||
this.wirelessTerminalBattery = this.get( "battery", "wirelessTerminal", this.wirelessTerminalBattery ).getInt( this.wirelessTerminalBattery );
|
this.wirelessTerminalBattery = this.get( "battery", "wirelessTerminal", this.wirelessTerminalBattery ).getInt( this.wirelessTerminalBattery );
|
||||||
this.chargedStaffBattery = this.get( "battery", "chargedStaff", this.chargedStaffBattery ).getInt( this.chargedStaffBattery );
|
this.chargedStaffBattery = this.get( "battery", "chargedStaff", this.chargedStaffBattery ).getInt( this.chargedStaffBattery );
|
||||||
@@ -171,7 +201,7 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
{
|
{
|
||||||
if( feature.isVisible() )
|
if( feature.isVisible() )
|
||||||
{
|
{
|
||||||
if( this.get( "Features." + feature.category, feature.name(), feature.defaultValue ).getBoolean( feature.defaultValue ) )
|
if( this.get( "Features." + feature.category(), feature.key(), feature.isEnabled() ).getBoolean( feature.isEnabled() ) )
|
||||||
{
|
{
|
||||||
this.featureFlags.add( feature );
|
this.featureFlags.add( feature );
|
||||||
}
|
}
|
||||||
@@ -188,13 +218,14 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
final List<String> version = Arrays.asList( "59.0.0", "59.0.1", "59.0.2" );
|
final List<String> version = Arrays.asList( "59.0.0", "59.0.1", "59.0.2" );
|
||||||
if( version.contains( imb.getVersion() ) )
|
if( version.contains( imb.getVersion() ) )
|
||||||
{
|
{
|
||||||
this.featureFlags.remove( AEFeature.AlphaPass );
|
this.featureFlags.remove( AEFeature.ALPHA_PASS );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
this.selectedPowerUnit = PowerUnits.valueOf( this.get( "Client", "PowerUnit", this.selectedPowerUnit.name(), this.getListComment( this.selectedPowerUnit ) ).getString() );
|
this.selectedPowerUnit = PowerUnits.valueOf(
|
||||||
|
this.get( "Client", "PowerUnit", this.selectedPowerUnit.name(), this.getListComment( this.selectedPowerUnit ) ).getString() );
|
||||||
}
|
}
|
||||||
catch( final Throwable t )
|
catch( final Throwable t )
|
||||||
{
|
{
|
||||||
@@ -206,22 +237,34 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
tr.Load( this );
|
tr.Load( this );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( this.isFeatureEnabled( AEFeature.SpatialIO ) )
|
if( this.isFeatureEnabled( AEFeature.SPATIAL_IO ) )
|
||||||
{
|
{
|
||||||
this.storageBiomeID = this.get( "spatialio", "storageBiomeID", this.storageBiomeID ).getInt( this.storageBiomeID );
|
this.storageBiomeID = this.get( "spatialio", "storageBiomeID", this.storageBiomeID ).getInt( this.storageBiomeID );
|
||||||
this.storageProviderID = this.get( "spatialio", "storageProviderID", this.storageProviderID ).getInt( this.storageProviderID );
|
this.storageProviderID = this.get( "spatialio", "storageProviderID", this.storageProviderID ).getInt( this.storageProviderID );
|
||||||
this.spatialPowerMultiplier = this.get( "spatialio", "spatialPowerMultiplier", this.spatialPowerMultiplier ).getDouble( this.spatialPowerMultiplier );
|
this.spatialPowerMultiplier = this.get( "spatialio", "spatialPowerMultiplier", this.spatialPowerMultiplier ).getDouble(
|
||||||
|
this.spatialPowerMultiplier );
|
||||||
this.spatialPowerExponent = this.get( "spatialio", "spatialPowerExponent", this.spatialPowerExponent ).getDouble( this.spatialPowerExponent );
|
this.spatialPowerExponent = this.get( "spatialio", "spatialPowerExponent", this.spatialPowerExponent ).getDouble( this.spatialPowerExponent );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( this.isFeatureEnabled( AEFeature.CraftingCPU ) )
|
if( this.isFeatureEnabled( AEFeature.CRAFTING_CPU ) )
|
||||||
{
|
{
|
||||||
this.craftingCalculationTimePerTick = this.get( "craftingCPU", "craftingCalculationTimePerTick", this.craftingCalculationTimePerTick ).getInt( this.craftingCalculationTimePerTick );
|
this.craftingCalculationTimePerTick = this.get( "craftingCPU", "craftingCalculationTimePerTick", this.craftingCalculationTimePerTick ).getInt(
|
||||||
|
this.craftingCalculationTimePerTick );
|
||||||
}
|
}
|
||||||
|
|
||||||
this.updatable = true;
|
this.updatable = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void init( final File configFile )
|
||||||
|
{
|
||||||
|
instance = new AEConfig( configFile );
|
||||||
|
}
|
||||||
|
|
||||||
|
public static AEConfig instance()
|
||||||
|
{
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
private void clientSync()
|
private void clientSync()
|
||||||
{
|
{
|
||||||
this.disableColoredCableRecipesInJEI = this.get( "Client", "disableColoredCableRecipesInJEI", true ).getBoolean( true );
|
this.disableColoredCableRecipesInJEI = this.get( "Client", "disableColoredCableRecipesInJEI", true ).getBoolean( true );
|
||||||
@@ -308,17 +351,17 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
|
|
||||||
public double wireless_getDrainRate( final double range )
|
public double wireless_getDrainRate( final double range )
|
||||||
{
|
{
|
||||||
return this.WirelessTerminalDrainMultiplier * range;
|
return this.wirelessTerminalDrainMultiplier * range;
|
||||||
}
|
}
|
||||||
|
|
||||||
public double wireless_getMaxRange( final int boosters )
|
public double wireless_getMaxRange( final int boosters )
|
||||||
{
|
{
|
||||||
return this.WirelessBaseRange + this.WirelessBoosterRangeMultiplier * Math.pow( boosters, this.WirelessBoosterExp );
|
return this.wirelessBaseRange + this.wirelessBoosterRangeMultiplier * Math.pow( boosters, this.wirelessBoosterExp );
|
||||||
}
|
}
|
||||||
|
|
||||||
public double wireless_getPowerDrain( final int boosters )
|
public double wireless_getPowerDrain( final int boosters )
|
||||||
{
|
{
|
||||||
return this.WirelessBaseCost + this.WirelessCostMultiplier * Math.pow( boosters, 1 + boosters / this.WirelessHighWirelessCount );
|
return this.wirelessBaseCost + this.wirelessCostMultiplier * Math.pow( boosters, 1 + boosters / this.wirelessHighWirelessCount );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -340,7 +383,7 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
@Override
|
@Override
|
||||||
public void save()
|
public void save()
|
||||||
{
|
{
|
||||||
if( this.isFeatureEnabled( AEFeature.SpatialIO ) )
|
if( this.isFeatureEnabled( AEFeature.SPATIAL_IO ) )
|
||||||
{
|
{
|
||||||
this.get( "spatialio", "storageBiomeID", this.storageBiomeID ).set( this.storageBiomeID );
|
this.get( "spatialio", "storageBiomeID", this.storageBiomeID ).set( this.storageBiomeID );
|
||||||
this.get( "spatialio", "storageProviderID", this.storageProviderID ).set( this.storageProviderID );
|
this.get( "spatialio", "storageProviderID", this.storageProviderID ).set( this.storageProviderID );
|
||||||
@@ -375,12 +418,13 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
|
|
||||||
public boolean useAEVersion( final MaterialType mt )
|
public boolean useAEVersion( final MaterialType mt )
|
||||||
{
|
{
|
||||||
if( this.isFeatureEnabled( AEFeature.WebsiteRecipes ) )
|
if( this.isFeatureEnabled( AEFeature.WEBSITE_RECIPES ) )
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.setCategoryComment( "OreCamouflage", "AE2 Automatically uses alternative ores present in your instance of MC to blend better with its surroundings, if you prefer you can disable this selectively using these flags; Its important to note, that some if these items even if enabled may not be craftable in game because other items are overriding their recipes." );
|
this.setCategoryComment( "OreCamouflage",
|
||||||
|
"AE2 Automatically uses alternative ores present in your instance of MC to blend better with its surroundings, if you prefer you can disable this selectively using these flags; Its important to note, that some if these items even if enabled may not be craftable in game because other items are overriding their recipes." );
|
||||||
final Property p = this.get( "OreCamouflage", mt.name(), true );
|
final Property p = this.get( "OreCamouflage", mt.name(), true );
|
||||||
p.setComment( "OreDictionary Names: " + mt.getOreName() );
|
p.setComment( "OreDictionary Names: " + mt.getOreName() );
|
||||||
|
|
||||||
@@ -506,4 +550,212 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
|||||||
this.selectedPowerUnit = Platform.rotateEnum( this.selectedPowerUnit, backwards, Settings.POWER_UNITS.getPossibleValues() );
|
this.selectedPowerUnit = Platform.rotateEnum( this.selectedPowerUnit, backwards, Settings.POWER_UNITS.getPossibleValues() );
|
||||||
this.save();
|
this.save();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Getters
|
||||||
|
public boolean isRemoveCrashingItemsOnLoad()
|
||||||
|
{
|
||||||
|
return removeCrashingItemsOnLoad;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getFormationPlaneEntityLimit()
|
||||||
|
{
|
||||||
|
return formationPlaneEntityLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isEnableEffects()
|
||||||
|
{
|
||||||
|
return enableEffects;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isUseLargeFonts()
|
||||||
|
{
|
||||||
|
return useLargeFonts;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isUseColoredCraftingStatus()
|
||||||
|
{
|
||||||
|
return useColoredCraftingStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isDisableColoredCableRecipesInJEI()
|
||||||
|
{
|
||||||
|
return disableColoredCableRecipesInJEI;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getCraftingCalculationTimePerTick()
|
||||||
|
{
|
||||||
|
return craftingCalculationTimePerTick;
|
||||||
|
}
|
||||||
|
|
||||||
|
public PowerUnits getSelectedPowerUnit()
|
||||||
|
{
|
||||||
|
return selectedPowerUnit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int[] getCraftByStacks()
|
||||||
|
{
|
||||||
|
return craftByStacks;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int[] getPriorityByStacks()
|
||||||
|
{
|
||||||
|
return priorityByStacks;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int[] getLevelByStacks()
|
||||||
|
{
|
||||||
|
return levelByStacks;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getStorageBiomeID()
|
||||||
|
{
|
||||||
|
return storageBiomeID;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getStorageProviderID()
|
||||||
|
{
|
||||||
|
return storageProviderID;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getSpatialPowerExponent()
|
||||||
|
{
|
||||||
|
return spatialPowerExponent;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getSpatialPowerMultiplier()
|
||||||
|
{
|
||||||
|
return spatialPowerMultiplier;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String[] getGrinderOres()
|
||||||
|
{
|
||||||
|
return grinderOres;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getOreDoublePercentage()
|
||||||
|
{
|
||||||
|
return oreDoublePercentage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getWirelessTerminalBattery()
|
||||||
|
{
|
||||||
|
return wirelessTerminalBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getEntropyManipulatorBattery()
|
||||||
|
{
|
||||||
|
return entropyManipulatorBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getMatterCannonBattery()
|
||||||
|
{
|
||||||
|
return matterCannonBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getPortableCellBattery()
|
||||||
|
{
|
||||||
|
return portableCellBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getColorApplicatorBattery()
|
||||||
|
{
|
||||||
|
return colorApplicatorBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getChargedStaffBattery()
|
||||||
|
{
|
||||||
|
return chargedStaffBattery;
|
||||||
|
}
|
||||||
|
|
||||||
|
public float getSpawnChargedChance()
|
||||||
|
{
|
||||||
|
return spawnChargedChance;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getQuartzOresPerCluster()
|
||||||
|
{
|
||||||
|
return quartzOresPerCluster;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getQuartzOresClusterAmount()
|
||||||
|
{
|
||||||
|
return quartzOresClusterAmount;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getChargedChange()
|
||||||
|
{
|
||||||
|
return chargedChange;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getMinMeteoriteDistance()
|
||||||
|
{
|
||||||
|
return minMeteoriteDistance;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getMinMeteoriteDistanceSq()
|
||||||
|
{
|
||||||
|
return minMeteoriteDistanceSq;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getMeteoriteClusterChance()
|
||||||
|
{
|
||||||
|
return meteoriteClusterChance;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getMeteoriteMaximumSpawnHeight()
|
||||||
|
{
|
||||||
|
return meteoriteMaximumSpawnHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int[] getMeteoriteDimensionWhitelist()
|
||||||
|
{
|
||||||
|
return meteoriteDimensionWhitelist;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessBaseCost()
|
||||||
|
{
|
||||||
|
return wirelessBaseCost;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessCostMultiplier()
|
||||||
|
{
|
||||||
|
return wirelessCostMultiplier;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessTerminalDrainMultiplier()
|
||||||
|
{
|
||||||
|
return wirelessTerminalDrainMultiplier;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessBaseRange()
|
||||||
|
{
|
||||||
|
return wirelessBaseRange;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessBoosterRangeMultiplier()
|
||||||
|
{
|
||||||
|
return wirelessBoosterRangeMultiplier;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessBoosterExp()
|
||||||
|
{
|
||||||
|
return wirelessBoosterExp;
|
||||||
|
}
|
||||||
|
|
||||||
|
public double getWirelessHighWirelessCount()
|
||||||
|
{
|
||||||
|
return wirelessHighWirelessCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Setters keep visibility as low as possible.
|
||||||
|
|
||||||
|
void setStorageBiomeID( int id )
|
||||||
|
{
|
||||||
|
this.storageBiomeID = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
void setStorageProviderID( int id )
|
||||||
|
{
|
||||||
|
this.storageProviderID = id;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static boolean isLogEnabled()
|
public static boolean isLogEnabled()
|
||||||
{
|
{
|
||||||
return AEConfig.instance == null || AEConfig.instance.isFeatureEnabled( AEFeature.Logging );
|
return AEConfig.instance() == null || AEConfig.instance().isFeatureEnabled( AEFeature.LOGGING );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -278,7 +278,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static boolean isDebugLogEnabled()
|
public static boolean isDebugLogEnabled()
|
||||||
{
|
{
|
||||||
return AEConfig.instance.isFeatureEnabled( AEFeature.DebugLogging );
|
return AEConfig.instance().isFeatureEnabled( AEFeature.DEBUG_LOGGING );
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
@@ -292,7 +292,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static void grinder( @Nonnull final String message )
|
public static void grinder( @Nonnull final String message )
|
||||||
{
|
{
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.GrinderLogging ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.GRINDER_LOGGING ) )
|
||||||
{
|
{
|
||||||
log( Level.DEBUG, "grinder: " + message );
|
log( Level.DEBUG, "grinder: " + message );
|
||||||
}
|
}
|
||||||
@@ -305,7 +305,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static void integration( @Nonnull final Throwable exception )
|
public static void integration( @Nonnull final Throwable exception )
|
||||||
{
|
{
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.IntegrationLogging ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.INTEGRATION_LOGGING ) )
|
||||||
{
|
{
|
||||||
debug( exception );
|
debug( exception );
|
||||||
}
|
}
|
||||||
@@ -322,7 +322,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static void blockUpdate( @Nonnull final BlockPos pos, @Nonnull final AEBaseTile aeBaseTile )
|
public static void blockUpdate( @Nonnull final BlockPos pos, @Nonnull final AEBaseTile aeBaseTile )
|
||||||
{
|
{
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.UpdateLogging ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.UPDATE_LOGGING ) )
|
||||||
{
|
{
|
||||||
info( BLOCK_UPDATE, aeBaseTile.getClass().getName(), pos );
|
info( BLOCK_UPDATE, aeBaseTile.getClass().getName(), pos );
|
||||||
}
|
}
|
||||||
@@ -337,7 +337,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static boolean isCraftingLogEnabled()
|
public static boolean isCraftingLogEnabled()
|
||||||
{
|
{
|
||||||
return AEConfig.instance.isFeatureEnabled( AEFeature.CraftingLog );
|
return AEConfig.instance().isFeatureEnabled( AEFeature.CRAFTING_LOG );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -366,7 +366,7 @@ public final class AELog
|
|||||||
*/
|
*/
|
||||||
public static boolean isCraftingDebugLogEnabled()
|
public static boolean isCraftingDebugLogEnabled()
|
||||||
{
|
{
|
||||||
return AEConfig.instance.isFeatureEnabled( AEFeature.CraftingLog ) && AEConfig.instance.isFeatureEnabled( AEFeature.DebugLogging );
|
return AEConfig.instance().isFeatureEnabled( AEFeature.CRAFTING_LOG ) && AEConfig.instance().isFeatureEnabled( AEFeature.DEBUG_LOGGING );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -78,10 +78,10 @@ public final class AppEng
|
|||||||
|
|
||||||
// depend on version of forge used for build.
|
// depend on version of forge used for build.
|
||||||
"after:appliedenergistics2-core;" + "required-after:Forge@[" // require forge.
|
"after:appliedenergistics2-core;" + "required-after:Forge@[" // require forge.
|
||||||
+ net.minecraftforge.common.ForgeVersion.majorVersion + '.' // majorVersion
|
+ net.minecraftforge.common.ForgeVersion.majorVersion + '.' // majorVersion
|
||||||
+ net.minecraftforge.common.ForgeVersion.minorVersion + '.' // minorVersion
|
+ net.minecraftforge.common.ForgeVersion.minorVersion + '.' // minorVersion
|
||||||
+ net.minecraftforge.common.ForgeVersion.revisionVersion + '.' // revisionVersion
|
+ net.minecraftforge.common.ForgeVersion.revisionVersion + '.' // revisionVersion
|
||||||
+ net.minecraftforge.common.ForgeVersion.buildVersion + ",)"; // buildVersion
|
+ net.minecraftforge.common.ForgeVersion.buildVersion + ",)"; // buildVersion
|
||||||
|
|
||||||
@Nonnull
|
@Nonnull
|
||||||
private static final AppEng INSTANCE = new AppEng();
|
private static final AppEng INSTANCE = new AppEng();
|
||||||
@@ -141,8 +141,9 @@ public final class AppEng
|
|||||||
final File recipeFile = new File( this.configDirectory, "CustomRecipes.cfg" );
|
final File recipeFile = new File( this.configDirectory, "CustomRecipes.cfg" );
|
||||||
final Configuration recipeConfiguration = new Configuration( recipeFile );
|
final Configuration recipeConfiguration = new Configuration( recipeFile );
|
||||||
|
|
||||||
AEConfig.instance = new AEConfig( configFile );
|
AEConfig.init( configFile );
|
||||||
FacadeConfig.instance = new FacadeConfig( facadeFile );
|
FacadeConfig.init( facadeFile );
|
||||||
|
|
||||||
final VersionCheckerConfig versionCheckerConfig = new VersionCheckerConfig( versionFile );
|
final VersionCheckerConfig versionCheckerConfig = new VersionCheckerConfig( versionFile );
|
||||||
this.customRecipeConfig = new CustomRecipeForgeConfiguration( recipeConfiguration );
|
this.customRecipeConfig = new CustomRecipeForgeConfiguration( recipeConfiguration );
|
||||||
this.exportConfig = new ForgeExportConfig( recipeConfiguration );
|
this.exportConfig = new ForgeExportConfig( recipeConfiguration );
|
||||||
@@ -150,7 +151,7 @@ public final class AppEng
|
|||||||
AELog.info( "Pre Initialization ( started )" );
|
AELog.info( "Pre Initialization ( started )" );
|
||||||
|
|
||||||
CreativeTab.init();
|
CreativeTab.init();
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.Facades ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.FACADES ) )
|
||||||
{
|
{
|
||||||
CreativeTabFacade.init();
|
CreativeTabFacade.init();
|
||||||
}
|
}
|
||||||
@@ -174,8 +175,7 @@ public final class AppEng
|
|||||||
|
|
||||||
// Instantiate all Plugins
|
// Instantiate all Plugins
|
||||||
List<Object> injectables = Lists.newArrayList(
|
List<Object> injectables = Lists.newArrayList(
|
||||||
AEApi.instance()
|
AEApi.instance() );
|
||||||
);
|
|
||||||
new PluginLoader().loadPlugins( injectables, event.getAsmData() );
|
new PluginLoader().loadPlugins( injectables, event.getAsmData() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -226,10 +226,10 @@ public final class AppEng
|
|||||||
FMLCommonHandler.instance().registerCrashCallable( new IntegrationCrashEnhancement() );
|
FMLCommonHandler.instance().registerCrashCallable( new IntegrationCrashEnhancement() );
|
||||||
|
|
||||||
CommonHelper.proxy.postInit();
|
CommonHelper.proxy.postInit();
|
||||||
AEConfig.instance.save();
|
AEConfig.instance().save();
|
||||||
|
|
||||||
NetworkRegistry.INSTANCE.registerGuiHandler( this, GuiBridge.GUI_Handler );
|
NetworkRegistry.INSTANCE.registerGuiHandler( this, GuiBridge.GUI_Handler );
|
||||||
NetworkHandler.instance = new NetworkHandler( "AE2" );
|
NetworkHandler.init( "AE2" );
|
||||||
|
|
||||||
AELog.info( "Post Initialization ( ended after " + start.elapsed( TimeUnit.MILLISECONDS ) + "ms )" );
|
AELog.info( "Post Initialization ( ended after " + start.elapsed( TimeUnit.MILLISECONDS ) + "ms )" );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ public final class CreativeTab extends CreativeTabs
|
|||||||
final IItems items = definitions.items();
|
final IItems items = definitions.items();
|
||||||
final IMaterials materials = definitions.materials();
|
final IMaterials materials = definitions.materials();
|
||||||
|
|
||||||
return this.findFirst( blocks.controller(), blocks.chest(), blocks.cellWorkbench(), blocks.fluixBlock(), items.cell1k(), items.networkTool(), materials.fluixCrystal(), materials.certusQuartzCrystal() );
|
return this.findFirst( blocks.controller(), blocks.chest(), blocks.cellWorkbench(), blocks.fluixBlock(), items.cell1k(), items.networkTool(), materials.fluixCrystal(), materials.certusQuartzCrystal(), materials.skyDust() );
|
||||||
}
|
}
|
||||||
|
|
||||||
private ItemStack findFirst( final IItemDefinition... choices )
|
private ItemStack findFirst( final IItemDefinition... choices )
|
||||||
|
|||||||
@@ -33,7 +33,8 @@ import net.minecraftforge.common.config.Configuration;
|
|||||||
public class FacadeConfig extends Configuration
|
public class FacadeConfig extends Configuration
|
||||||
{
|
{
|
||||||
|
|
||||||
public static FacadeConfig instance;
|
private static FacadeConfig instance;
|
||||||
|
|
||||||
private final Pattern replacementPattern;
|
private final Pattern replacementPattern;
|
||||||
|
|
||||||
public FacadeConfig( final File facadeFile )
|
public FacadeConfig( final File facadeFile )
|
||||||
@@ -42,6 +43,16 @@ public class FacadeConfig extends Configuration
|
|||||||
this.replacementPattern = Pattern.compile( "[^a-zA-Z0-9]" );
|
this.replacementPattern = Pattern.compile( "[^a-zA-Z0-9]" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void init( final File configFile )
|
||||||
|
{
|
||||||
|
instance = new FacadeConfig( configFile );
|
||||||
|
}
|
||||||
|
|
||||||
|
public static FacadeConfig instance()
|
||||||
|
{
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
public boolean checkEnabled( final Block id, final int metadata, final boolean automatic )
|
public boolean checkEnabled( final Block id, final int metadata, final boolean automatic )
|
||||||
{
|
{
|
||||||
if( id == null )
|
if( id == null )
|
||||||
|
|||||||
@@ -149,42 +149,42 @@ public final class Registration
|
|||||||
|
|
||||||
private void registerSpatial( final boolean force )
|
private void registerSpatial( final boolean force )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.isFeatureEnabled( AEFeature.SpatialIO ) )
|
if( !AEConfig.instance().isFeatureEnabled( AEFeature.SPATIAL_IO ) )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
final AEConfig config = AEConfig.instance;
|
final AEConfig config = AEConfig.instance();
|
||||||
|
|
||||||
if( this.storageBiome == null )
|
if( this.storageBiome == null )
|
||||||
{
|
{
|
||||||
if( force && config.storageBiomeID == -1 )
|
if( force && config.getStorageBiomeID() == -1 )
|
||||||
{
|
{
|
||||||
config.storageBiomeID = Platform.findEmpty( Biome.REGISTRY, 0, 256 );
|
config.setStorageBiomeID( Platform.findEmpty( Biome.REGISTRY, 0, 256 ) );
|
||||||
if( config.storageBiomeID == -1 )
|
if( config.getStorageBiomeID() == -1 )
|
||||||
{
|
{
|
||||||
throw new IllegalStateException( "Biome Array is full, please free up some Biome ID's or disable spatial." );
|
throw new IllegalStateException( "Biome Array is full, please free up some Biome ID's or disable spatial." );
|
||||||
}
|
}
|
||||||
|
|
||||||
this.storageBiome = new BiomeGenStorage();
|
this.storageBiome = new BiomeGenStorage();
|
||||||
Biome.registerBiome( config.storageBiomeID, "appliedenergistics2:storage_biome", this.storageBiome );
|
Biome.registerBiome( config.getStorageBiomeID(), "appliedenergistics2:storage_biome", this.storageBiome );
|
||||||
config.save();
|
config.save();
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !force && config.storageBiomeID != -1 )
|
if( !force && config.getStorageBiomeID() != -1 )
|
||||||
{
|
{
|
||||||
this.storageBiome = new BiomeGenStorage();
|
this.storageBiome = new BiomeGenStorage();
|
||||||
Biome.registerBiome( config.storageBiomeID, "appliedenergistics2:storage_biome", this.storageBiome );
|
Biome.registerBiome( config.getStorageBiomeID(), "appliedenergistics2:storage_biome", this.storageBiome );
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if( config.storageProviderID != -1 )
|
if( config.getStorageProviderID() != -1 )
|
||||||
{
|
{
|
||||||
storageDimensionType = DimensionType.register( "Storage Cell", "_cell", config.storageProviderID, StorageWorldProvider.class, false );
|
storageDimensionType = DimensionType.register( "Storage Cell", "_cell", config.getStorageProviderID(), StorageWorldProvider.class, false );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( config.storageProviderID == -1 && force )
|
if( config.getStorageProviderID() == -1 && force )
|
||||||
{
|
{
|
||||||
final Set<Integer> ids = new HashSet<>();
|
final Set<Integer> ids = new HashSet<>();
|
||||||
for( DimensionType type : DimensionType.values() )
|
for( DimensionType type : DimensionType.values() )
|
||||||
@@ -192,14 +192,14 @@ public final class Registration
|
|||||||
ids.add( type.getId() );
|
ids.add( type.getId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
config.storageProviderID = -11;
|
config.setStorageProviderID( -11 );
|
||||||
|
|
||||||
while( ids.contains( config.storageProviderID ) )
|
while( ids.contains( config.getStorageProviderID() ) )
|
||||||
{
|
{
|
||||||
config.storageProviderID--;
|
config.setStorageProviderID( config.getStorageProviderID() - 1 );
|
||||||
}
|
}
|
||||||
|
|
||||||
storageDimensionType = DimensionType.register( "Storage Cell", "_cell", config.storageProviderID, StorageWorldProvider.class, false );
|
storageDimensionType = DimensionType.register( "Storage Cell", "_cell", config.getStorageProviderID(), StorageWorldProvider.class, false );
|
||||||
|
|
||||||
config.save();
|
config.save();
|
||||||
}
|
}
|
||||||
@@ -264,10 +264,9 @@ public final class Registration
|
|||||||
|
|
||||||
MinecraftForge.EVENT_BUS.register( TickHandler.INSTANCE );
|
MinecraftForge.EVENT_BUS.register( TickHandler.INSTANCE );
|
||||||
|
|
||||||
|
|
||||||
MinecraftForge.EVENT_BUS.register( new PartPlacement() );
|
MinecraftForge.EVENT_BUS.register( new PartPlacement() );
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.ChestLoot ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.CHEST_LOOT ) )
|
||||||
{
|
{
|
||||||
MinecraftForge.EVENT_BUS.register( new ChestLoot() );
|
MinecraftForge.EVENT_BUS.register( new ChestLoot() );
|
||||||
}
|
}
|
||||||
@@ -285,8 +284,7 @@ public final class Registration
|
|||||||
registries.cell().addCellHandler( new BasicCellHandler() );
|
registries.cell().addCellHandler( new BasicCellHandler() );
|
||||||
registries.cell().addCellHandler( new CreativeCellHandler() );
|
registries.cell().addCellHandler( new CreativeCellHandler() );
|
||||||
|
|
||||||
api.definitions().materials().matterBall().maybeStack( 1 ).ifPresent( ammoStack ->
|
api.definitions().materials().matterBall().maybeStack( 1 ).ifPresent( ammoStack -> {
|
||||||
{
|
|
||||||
final double weight = 32;
|
final double weight = 32;
|
||||||
|
|
||||||
registries.matterCannon().registerAmmo( ammoStack, weight );
|
registries.matterCannon().registerAmmo( ammoStack, weight );
|
||||||
@@ -294,17 +292,17 @@ public final class Registration
|
|||||||
|
|
||||||
this.recipeHandler.injectRecipes();
|
this.recipeHandler.injectRecipes();
|
||||||
|
|
||||||
final PlayerStatsRegistration registration = new PlayerStatsRegistration( MinecraftForge.EVENT_BUS, AEConfig.instance );
|
final PlayerStatsRegistration registration = new PlayerStatsRegistration( MinecraftForge.EVENT_BUS, AEConfig.instance() );
|
||||||
registration.registerAchievementHandlers();
|
registration.registerAchievementHandlers();
|
||||||
registration.registerAchievements();
|
registration.registerAchievements();
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.EnableDisassemblyCrafting ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.ENABLE_DISASSEMBLY_CRAFTING ) )
|
||||||
{
|
{
|
||||||
GameRegistry.addRecipe( new DisassembleRecipe() );
|
GameRegistry.addRecipe( new DisassembleRecipe() );
|
||||||
RecipeSorter.register( "appliedenergistics2:disassemble", DisassembleRecipe.class, Category.SHAPELESS, "after:minecraft:shapeless" );
|
RecipeSorter.register( "appliedenergistics2:disassemble", DisassembleRecipe.class, Category.SHAPELESS, "after:minecraft:shapeless" );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.EnableFacadeCrafting ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.ENABLE_FACADE_CRAFTING ) )
|
||||||
{
|
{
|
||||||
definitions.items().facade().maybeItem().ifPresent( facadeItem -> {
|
definitions.items().facade().maybeItem().ifPresent( facadeItem -> {
|
||||||
GameRegistry.addRecipe( new FacadeRecipe( (ItemFacade) facadeItem ) );
|
GameRegistry.addRecipe( new FacadeRecipe( (ItemFacade) facadeItem ) );
|
||||||
@@ -398,24 +396,23 @@ public final class Registration
|
|||||||
// Inscriber
|
// Inscriber
|
||||||
Upgrades.SPEED.registerItem( blocks.inscriber(), 3 );
|
Upgrades.SPEED.registerItem( blocks.inscriber(), 3 );
|
||||||
|
|
||||||
items.wirelessTerminal().maybeItem().ifPresent( terminal ->
|
items.wirelessTerminal().maybeItem().ifPresent( terminal -> {
|
||||||
{
|
|
||||||
registries.wireless().registerWirelessHandler( (IWirelessTermHandler) terminal );
|
registries.wireless().registerWirelessHandler( (IWirelessTermHandler) terminal );
|
||||||
} );
|
} );
|
||||||
|
|
||||||
// add villager trading to black smiths for a few basic materials
|
// add villager trading to black smiths for a few basic materials
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.VillagerTrading ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.VILLAGER_TRADING ) )
|
||||||
{
|
{
|
||||||
// TODO: VILLAGER TRADING
|
// TODO: VILLAGER TRADING
|
||||||
// VillagerRegistry.instance().getRegisteredVillagers()..registerVillageTradeHandler( 3, new AETrading() );
|
// VillagerRegistry.instance().getRegisteredVillagers()..registerVillageTradeHandler( 3, new AETrading() );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.CertusQuartzWorldGen ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.CERTUS_QUARTZ_WORLD_GEN ) )
|
||||||
{
|
{
|
||||||
GameRegistry.registerWorldGenerator( new QuartzWorldGen(), 0 );
|
GameRegistry.registerWorldGenerator( new QuartzWorldGen(), 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.MeteoriteWorldGen ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.METEORITE_WORLD_GEN ) )
|
||||||
{
|
{
|
||||||
GameRegistry.registerWorldGenerator( new MeteoriteWorldGen(), 0 );
|
GameRegistry.registerWorldGenerator( new MeteoriteWorldGen(), 0 );
|
||||||
}
|
}
|
||||||
@@ -470,7 +467,7 @@ public final class Registration
|
|||||||
}
|
}
|
||||||
|
|
||||||
// whitelist from config
|
// whitelist from config
|
||||||
for( final int dimension : AEConfig.instance.meteoriteDimensionWhitelist )
|
for( final int dimension : AEConfig.instance().getMeteoriteDimensionWhitelist() )
|
||||||
{
|
{
|
||||||
registries.worldgen().enableWorldGenForDimension( WorldGenType.METEORITES, dimension );
|
registries.worldgen().enableWorldGenForDimension( WorldGenType.METEORITES, dimension );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -203,20 +203,22 @@ public final class ApiBlocks implements IBlocks
|
|||||||
{
|
{
|
||||||
// this.quartzOre = new BlockDefinition( "ore.quartz", new OreQuartz() );
|
// this.quartzOre = new BlockDefinition( "ore.quartz", new OreQuartz() );
|
||||||
this.quartzOre = registry.block( "quartz_ore", BlockQuartzOre::new )
|
this.quartzOre = registry.block( "quartz_ore", BlockQuartzOre::new )
|
||||||
|
.features( AEFeature.CERTUS_ORE )
|
||||||
.postInit( ( block, item ) ->
|
.postInit( ( block, item ) ->
|
||||||
{
|
{
|
||||||
OreDictionary.registerOre( "oreCertusQuartz", new ItemStack( block ) );
|
OreDictionary.registerOre( "oreCertusQuartz", new ItemStack( block ) );
|
||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
this.quartzOreCharged = registry.block( "charged_quartz_ore", BlockChargedQuartzOre::new )
|
this.quartzOreCharged = registry.block( "charged_quartz_ore", BlockChargedQuartzOre::new )
|
||||||
|
.features( AEFeature.CERTUS_ORE, AEFeature.CHARGED_CERTUS_ORE )
|
||||||
.postInit( ( block, item ) ->
|
.postInit( ( block, item ) ->
|
||||||
{
|
{
|
||||||
OreDictionary.registerOre( "oreCertusQuartz", new ItemStack( block ) );
|
OreDictionary.registerOre( "oreCertusQuartz", new ItemStack( block ) );
|
||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
this.matrixFrame = registry.block( "matrix_frame", BlockMatrixFrame::new ).features( AEFeature.SpatialIO ).build();
|
this.matrixFrame = registry.block( "matrix_frame", BlockMatrixFrame::new ).features( AEFeature.SPATIAL_IO ).build();
|
||||||
|
|
||||||
FeatureFactory deco = registry.features( AEFeature.DecorativeQuartzBlocks );
|
FeatureFactory deco = registry.features( AEFeature.DECORATIVE_QUARTZ_BLOCKS );
|
||||||
this.quartzBlock = deco.block( "quartz_block", BlockQuartz::new ).build();
|
this.quartzBlock = deco.block( "quartz_block", BlockQuartz::new ).build();
|
||||||
this.quartzPillar = deco.block( "quartz_pillar", BlockQuartzPillar::new ).build();
|
this.quartzPillar = deco.block( "quartz_pillar", BlockQuartzPillar::new ).build();
|
||||||
this.chiseledQuartzBlock = deco.block( "chiseled_quartz_block", BlockChiseledQuartz::new ).build();
|
this.chiseledQuartzBlock = deco.block( "chiseled_quartz_block", BlockChiseledQuartz::new ).build();
|
||||||
@@ -233,11 +235,11 @@ public final class ApiBlocks implements IBlocks
|
|||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
this.quartzVibrantGlass = deco.block( "quartz_vibrant_glass", BlockQuartzLamp::new )
|
this.quartzVibrantGlass = deco.block( "quartz_vibrant_glass", BlockQuartzLamp::new )
|
||||||
.addFeatures( AEFeature.DecorativeLights )
|
.addFeatures( AEFeature.DECORATIVE_LIGHTS )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
this.quartzFixture = registry.block( "quartz_fixture", BlockQuartzFixture::new )
|
this.quartzFixture = registry.block( "quartz_fixture", BlockQuartzFixture::new )
|
||||||
.features( AEFeature.DecorativeLights )
|
.features( AEFeature.DECORATIVE_LIGHTS )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
@@ -248,32 +250,33 @@ public final class ApiBlocks implements IBlocks
|
|||||||
this.skyStoneSmallBrick = deco.block( "sky_stone_small_brick", () -> new BlockSkyStone( SkystoneType.SMALL_BRICK ) ).build();
|
this.skyStoneSmallBrick = deco.block( "sky_stone_small_brick", () -> new BlockSkyStone( SkystoneType.SMALL_BRICK ) ).build();
|
||||||
|
|
||||||
this.skyStoneChest = registry.block( "sky_stone_chest", () -> new BlockSkyChest( SkyChestType.STONE ) )
|
this.skyStoneChest = registry.block( "sky_stone_chest", () -> new BlockSkyChest( SkyChestType.STONE ) )
|
||||||
.features( AEFeature.SkyStoneChests )
|
.features( AEFeature.SKY_STONE_CHESTS )
|
||||||
.rendering( new SkyChestRenderingCustomizer( SkyChestType.STONE ) )
|
.rendering( new SkyChestRenderingCustomizer( SkyChestType.STONE ) )
|
||||||
.build();
|
.build();
|
||||||
this.smoothSkyStoneChest = registry.block( "smooth_sky_stone_chest", () -> new BlockSkyChest( SkyChestType.BLOCK ) )
|
this.smoothSkyStoneChest = registry.block( "smooth_sky_stone_chest", () -> new BlockSkyChest( SkyChestType.BLOCK ) )
|
||||||
.features( AEFeature.SkyStoneChests )
|
.features( AEFeature.SKY_STONE_CHESTS )
|
||||||
.rendering( new SkyChestRenderingCustomizer( SkyChestType.BLOCK ) )
|
.rendering( new SkyChestRenderingCustomizer( SkyChestType.BLOCK ) )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
this.skyCompass = registry.block( "sky_compass", BlockSkyCompass::new )
|
this.skyCompass = registry.block( "sky_compass", BlockSkyCompass::new )
|
||||||
.features( AEFeature.MeteoriteCompass )
|
.features( AEFeature.METEORITE_COMPASS )
|
||||||
.rendering( new SkyCompassRendering() )
|
.rendering( new SkyCompassRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.grindstone = registry.block( "grindstone", BlockGrinder::new ).features( AEFeature.GrindStone ).build();
|
this.grindstone = registry.block( "grindstone", BlockGrinder::new ).features( AEFeature.GRIND_STONE ).build();
|
||||||
this.crank = registry.block( "crank", BlockCrank::new )
|
this.crank = registry.block( "crank", BlockCrank::new )
|
||||||
.features( AEFeature.GrindStone )
|
.features( AEFeature.GRIND_STONE )
|
||||||
.rendering( new CrankRendering() )
|
.rendering( new CrankRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.inscriber = registry.block( "inscriber", BlockInscriber::new )
|
this.inscriber = registry.block( "inscriber", BlockInscriber::new )
|
||||||
.features( AEFeature.Inscriber )
|
.features( AEFeature.INSCRIBER )
|
||||||
.rendering( new InscriberRendering() )
|
.rendering( new InscriberRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.wirelessAccessPoint = registry.block( "wireless_access_point", BlockWireless::new )
|
this.wirelessAccessPoint = registry.block( "wireless_access_point", BlockWireless::new )
|
||||||
.features( AEFeature.WirelessAccessTerminal )
|
.features( AEFeature.WIRELESS_ACCESS_TERMINAL )
|
||||||
.rendering( new WirelessRendering() )
|
.rendering( new WirelessRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.charger = registry.block( "charger", BlockCharger::new )
|
this.charger = registry.block( "charger", BlockCharger::new )
|
||||||
|
.features( AEFeature.CHARGER )
|
||||||
.rendering( new BlockRenderingCustomizer()
|
.rendering( new BlockRenderingCustomizer()
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
@@ -284,67 +287,71 @@ public final class ApiBlocks implements IBlocks
|
|||||||
}
|
}
|
||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
this.tinyTNT = registry.block( "tiny_tnt", BlockTinyTNT::new ).features( AEFeature.TinyTNT )
|
this.tinyTNT = registry.block( "tiny_tnt", BlockTinyTNT::new )
|
||||||
|
.features( AEFeature.TINY_TNT )
|
||||||
.postInit( ( block, item ) ->
|
.postInit( ( block, item ) ->
|
||||||
{
|
{
|
||||||
BlockDispenser.DISPENSE_BEHAVIOR_REGISTRY.putObject( item, new DispenserBehaviorTinyTNT() );
|
BlockDispenser.DISPENSE_BEHAVIOR_REGISTRY.putObject( item, new DispenserBehaviorTinyTNT() );
|
||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
this.securityStation = registry.block( "security_station", BlockSecurityStation::new )
|
this.securityStation = registry.block( "security_station", BlockSecurityStation::new )
|
||||||
.features( AEFeature.Security )
|
.features( AEFeature.SECURITY )
|
||||||
.rendering( new SecurityStationRendering() )
|
.rendering( new SecurityStationRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.quantumRing = registry.block( "quantum_ring", BlockQuantumRing::new )
|
this.quantumRing = registry.block( "quantum_ring", BlockQuantumRing::new )
|
||||||
.features( AEFeature.QuantumNetworkBridge )
|
.features( AEFeature.QUANTUM_NETWORK_BRIDGE )
|
||||||
.rendering( new QuantumBridgeRendering() )
|
.rendering( new QuantumBridgeRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.quantumLink = registry.block( "quantum_link", BlockQuantumLinkChamber::new )
|
this.quantumLink = registry.block( "quantum_link", BlockQuantumLinkChamber::new )
|
||||||
.features( AEFeature.QuantumNetworkBridge )
|
.features( AEFeature.QUANTUM_NETWORK_BRIDGE )
|
||||||
.rendering( new QuantumBridgeRendering() )
|
.rendering( new QuantumBridgeRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.spatialPylon = registry.block( "spatial_pylon", BlockSpatialPylon::new )
|
this.spatialPylon = registry.block( "spatial_pylon", BlockSpatialPylon::new )
|
||||||
.features( AEFeature.SpatialIO )
|
.features( AEFeature.SPATIAL_IO )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.rendering( new SpatialPylonRendering() )
|
.rendering( new SpatialPylonRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.spatialIOPort = registry.block( "spatial_io_port", BlockSpatialIOPort::new ).features( AEFeature.SpatialIO ).build();
|
this.spatialIOPort = registry.block( "spatial_io_port", BlockSpatialIOPort::new ).features( AEFeature.SPATIAL_IO ).build();
|
||||||
this.controller = registry.block( "controller", BlockController::new )
|
this.controller = registry.block( "controller", BlockController::new )
|
||||||
.features( AEFeature.Channels )
|
.features( AEFeature.CHANNELS )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.rendering( new ControllerRendering() )
|
.rendering( new ControllerRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.drive = registry.block( "drive", BlockDrive::new )
|
this.drive = registry.block( "drive", BlockDrive::new )
|
||||||
.features( AEFeature.StorageCells, AEFeature.MEDrive )
|
.features( AEFeature.STORAGE_CELLS, AEFeature.ME_DRIVE )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.rendering( new DriveRendering() )
|
.rendering( new DriveRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.chest = registry.block( "chest", BlockChest::new )
|
this.chest = registry.block( "chest", BlockChest::new )
|
||||||
.features( AEFeature.StorageCells, AEFeature.MEChest )
|
.features( AEFeature.STORAGE_CELLS, AEFeature.ME_CHEST )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.rendering( new ChestRendering() )
|
.rendering( new ChestRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.iface = registry.block( "interface", BlockInterface::new ).build();
|
this.iface = registry.block( "interface", BlockInterface::new ).features( AEFeature.INTERFACE ).build();
|
||||||
this.cellWorkbench = registry.block( "cell_workbench", BlockCellWorkbench::new ).features( AEFeature.StorageCells ).build();
|
this.cellWorkbench = registry.block( "cell_workbench", BlockCellWorkbench::new ).features( AEFeature.STORAGE_CELLS ).build();
|
||||||
this.iOPort = registry.block( "io_port", BlockIOPort::new ).features( AEFeature.StorageCells, AEFeature.IOPort ).build();
|
this.iOPort = registry.block( "io_port", BlockIOPort::new ).features( AEFeature.STORAGE_CELLS, AEFeature.IO_PORT ).build();
|
||||||
this.condenser = registry.block( "condenser", BlockCondenser::new ).build();
|
this.condenser = registry.block( "condenser", BlockCondenser::new ).features( AEFeature.CONDENSER ).build();
|
||||||
this.energyAcceptor = registry.block( "energy_acceptor", BlockEnergyAcceptor::new ).build();
|
this.energyAcceptor = registry.block( "energy_acceptor", BlockEnergyAcceptor::new ).features( AEFeature.ENERGY_ACCEPTOR ).build();
|
||||||
this.vibrationChamber = registry.block( "vibration_chamber", BlockVibrationChamber::new ).features( AEFeature.PowerGen ).build();
|
this.vibrationChamber = registry.block( "vibration_chamber", BlockVibrationChamber::new ).features( AEFeature.POWER_GEN ).build();
|
||||||
this.quartzGrowthAccelerator = registry.block( "quartz_growth_accelerator", BlockQuartzGrowthAccelerator::new ).build();
|
this.quartzGrowthAccelerator = registry.block( "quartz_growth_accelerator", BlockQuartzGrowthAccelerator::new )
|
||||||
|
.features( AEFeature.CRYSTAL_GROWTH_ACCELERATOR )
|
||||||
|
.build();
|
||||||
this.energyCell = registry.block( "energy_cell", BlockEnergyCell::new )
|
this.energyCell = registry.block( "energy_cell", BlockEnergyCell::new )
|
||||||
|
.features( AEFeature.ENERGY_CELLS )
|
||||||
.item( AEBaseItemBlockChargeable::new )
|
.item( AEBaseItemBlockChargeable::new )
|
||||||
.rendering( new BlockEnergyCellRendering( new ResourceLocation( AppEng.MOD_ID, "energy_cell" ) ) )
|
.rendering( new BlockEnergyCellRendering( new ResourceLocation( AppEng.MOD_ID, "energy_cell" ) ) )
|
||||||
.build();
|
.build();
|
||||||
this.energyCellDense = registry.block( "dense_energy_cell", BlockDenseEnergyCell::new )
|
this.energyCellDense = registry.block( "dense_energy_cell", BlockDenseEnergyCell::new )
|
||||||
.features( AEFeature.DenseEnergyCells )
|
.features( AEFeature.ENERGY_CELLS, AEFeature.DENSE_ENERGY_CELLS )
|
||||||
.item( AEBaseItemBlockChargeable::new )
|
.item( AEBaseItemBlockChargeable::new )
|
||||||
.rendering( new BlockEnergyCellRendering( new ResourceLocation( AppEng.MOD_ID, "dense_energy_cell" ) ) )
|
.rendering( new BlockEnergyCellRendering( new ResourceLocation( AppEng.MOD_ID, "dense_energy_cell" ) ) )
|
||||||
.build();
|
.build();
|
||||||
this.energyCellCreative = registry.block( "creative_energy_cell", BlockCreativeEnergyCell::new )
|
this.energyCellCreative = registry.block( "creative_energy_cell", BlockCreativeEnergyCell::new )
|
||||||
.features( AEFeature.Creative )
|
.features( AEFeature.CREATIVE )
|
||||||
.item( AEBaseItemBlockChargeable::new )
|
.item( AEBaseItemBlockChargeable::new )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
FeatureFactory crafting = registry.features( AEFeature.CraftingCPU );
|
FeatureFactory crafting = registry.features( AEFeature.CRAFTING_CPU );
|
||||||
this.craftingUnit = crafting.block( "crafting_unit", () -> new BlockCraftingUnit( CraftingUnitType.UNIT ) )
|
this.craftingUnit = crafting.block( "crafting_unit", () -> new BlockCraftingUnit( CraftingUnitType.UNIT ) )
|
||||||
.rendering( new CraftingCubeRendering( "crafting_unit", CraftingUnitType.UNIT ) )
|
.rendering( new CraftingCubeRendering( "crafting_unit", CraftingUnitType.UNIT ) )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
@@ -378,12 +385,13 @@ public final class ApiBlocks implements IBlocks
|
|||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
this.molecularAssembler = registry.block( "molecular_assembler", BlockMolecularAssembler::new ).features( AEFeature.MolecularAssembler ).build();
|
this.molecularAssembler = registry.block( "molecular_assembler", BlockMolecularAssembler::new ).features( AEFeature.MOLECULAR_ASSEMBLER ).build();
|
||||||
this.lightDetector = registry.block( "light_detector", BlockLightDetector::new ).features( AEFeature.LightDetector )
|
this.lightDetector = registry.block( "light_detector", BlockLightDetector::new )
|
||||||
|
.features( AEFeature.LIGHT_DETECTOR )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
this.paint = registry.block( "paint", BlockPaint::new )
|
this.paint = registry.block( "paint", BlockPaint::new )
|
||||||
.features( AEFeature.PaintBalls )
|
.features( AEFeature.PAINT_BALLS )
|
||||||
.rendering( new PaintRendering() )
|
.rendering( new PaintRendering() )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
@@ -398,7 +406,8 @@ public final class ApiBlocks implements IBlocks
|
|||||||
|
|
||||||
this.multiPart = registry.block( "cable_bus", BlockCableBus::new )
|
this.multiPart = registry.block( "cable_bus", BlockCableBus::new )
|
||||||
.rendering( new CableBusRendering( partModels ) )
|
.rendering( new CableBusRendering( partModels ) )
|
||||||
.postInit( (block, item) -> {
|
.postInit( ( block, item ) ->
|
||||||
|
{
|
||||||
( (BlockCableBus) block ).setupTile();
|
( (BlockCableBus) block ).setupTile();
|
||||||
} )
|
} )
|
||||||
.build();
|
.build();
|
||||||
@@ -413,19 +422,19 @@ public final class ApiBlocks implements IBlocks
|
|||||||
this.quartzPillarSlab = makeSlab( "quartz_pillar_slab", "quartz_pillar_double_slab", registry, this.quartzPillar() );
|
this.quartzPillarSlab = makeSlab( "quartz_pillar_slab", "quartz_pillar_double_slab", registry, this.quartzPillar() );
|
||||||
|
|
||||||
this.itemGen = registry.block( "debug_item_gen", BlockItemGen::new )
|
this.itemGen = registry.block( "debug_item_gen", BlockItemGen::new )
|
||||||
.features( AEFeature.UnsupportedDeveloperTools, AEFeature.Creative )
|
.features( AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
this.chunkLoader = registry.block( "debug_chunk_loader", BlockChunkloader::new )
|
this.chunkLoader = registry.block( "debug_chunk_loader", BlockChunkloader::new )
|
||||||
.features( AEFeature.UnsupportedDeveloperTools, AEFeature.Creative )
|
.features( AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
this.phantomNode = registry.block( "debug_phantom_node", BlockPhantomNode::new )
|
this.phantomNode = registry.block( "debug_phantom_node", BlockPhantomNode::new )
|
||||||
.features( AEFeature.UnsupportedDeveloperTools, AEFeature.Creative )
|
.features( AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
this.cubeGenerator = registry.block( "debug_cube_gen", BlockCubeGenerator::new )
|
this.cubeGenerator = registry.block( "debug_cube_gen", BlockCubeGenerator::new )
|
||||||
.features( AEFeature.UnsupportedDeveloperTools, AEFeature.Creative )
|
.features( AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE )
|
||||||
.useCustomItemModel()
|
.useCustomItemModel()
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@@ -440,7 +449,7 @@ public final class ApiBlocks implements IBlocks
|
|||||||
Block block = blockDef.maybeBlock().get();
|
Block block = blockDef.maybeBlock().get();
|
||||||
|
|
||||||
IBlockDefinition slabDef = registry.block( slabId, () -> new BlockSlabCommon.Half( block ) )
|
IBlockDefinition slabDef = registry.block( slabId, () -> new BlockSlabCommon.Half( block ) )
|
||||||
.features( AEFeature.DecorativeQuartzBlocks )
|
.features( AEFeature.DECORATIVE_QUARTZ_BLOCKS )
|
||||||
.disableItem()
|
.disableItem()
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
@@ -453,7 +462,7 @@ public final class ApiBlocks implements IBlocks
|
|||||||
|
|
||||||
// Reigster the double slab variant as well
|
// Reigster the double slab variant as well
|
||||||
IBlockDefinition doubleSlabDef = registry.block( doubleSlabId, () -> new BlockSlabCommon.Double( slabBlock, block ) )
|
IBlockDefinition doubleSlabDef = registry.block( doubleSlabId, () -> new BlockSlabCommon.Double( slabBlock, block ) )
|
||||||
.features( AEFeature.DecorativeQuartzBlocks )
|
.features( AEFeature.DECORATIVE_QUARTZ_BLOCKS )
|
||||||
.disableItem()
|
.disableItem()
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
@@ -463,7 +472,7 @@ public final class ApiBlocks implements IBlocks
|
|||||||
|
|
||||||
// Make the slab item
|
// Make the slab item
|
||||||
IItemDefinition itemDef = registry.item( slabId, () -> new ItemSlab( slabBlock, slabBlock, doubleSlabBlock ) )
|
IItemDefinition itemDef = registry.item( slabId, () -> new ItemSlab( slabBlock, slabBlock, doubleSlabBlock ) )
|
||||||
.features( AEFeature.DecorativeQuartzBlocks )
|
.features( AEFeature.DECORATIVE_QUARTZ_BLOCKS )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
Verify.verify( itemDef.maybeItem().isPresent() );
|
Verify.verify( itemDef.maybeItem().isPresent() );
|
||||||
@@ -475,7 +484,7 @@ public final class ApiBlocks implements IBlocks
|
|||||||
private static IBlockDefinition makeStairs( String registryName, FeatureFactory registry, IBlockDefinition block )
|
private static IBlockDefinition makeStairs( String registryName, FeatureFactory registry, IBlockDefinition block )
|
||||||
{
|
{
|
||||||
return registry.block( registryName, () -> new BlockStairCommon( block.maybeBlock().get(), block.identifier() ) )
|
return registry.block( registryName, () -> new BlockStairCommon( block.maybeBlock().get(), block.identifier() ) )
|
||||||
.features( AEFeature.DecorativeQuartzBlocks )
|
.features( AEFeature.DECORATIVE_QUARTZ_BLOCKS )
|
||||||
.rendering( new BlockRenderingCustomizer()
|
.rendering( new BlockRenderingCustomizer()
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -125,85 +125,113 @@ public final class ApiItems implements IItems
|
|||||||
|
|
||||||
public ApiItems( FeatureFactory registry )
|
public ApiItems( FeatureFactory registry )
|
||||||
{
|
{
|
||||||
FeatureFactory certusTools = registry.features( AEFeature.CertusQuartzTools );
|
FeatureFactory certusTools = registry.features( AEFeature.CERTUS_QUARTZ_TOOLS );
|
||||||
this.certusQuartzAxe = certusTools.item( "certus_quartz_axe", () -> new ToolQuartzAxe( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzAxe ).build();
|
this.certusQuartzAxe = certusTools.item( "certus_quartz_axe", () -> new ToolQuartzAxe( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
this.certusQuartzHoe = certusTools.item( "certus_quartz_hoe", () -> new ToolQuartzHoe( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzHoe ).build();
|
.addFeatures( AEFeature.QUARTZ_AXE )
|
||||||
this.certusQuartzShovel = certusTools.item( "certus_quartz_spade", () -> new ToolQuartzSpade( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzSpade ).build();
|
.build();
|
||||||
this.certusQuartzPick = certusTools.item( "certus_quartz_pickaxe", () -> new ToolQuartzPickaxe( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzPickaxe ).build();
|
this.certusQuartzHoe = certusTools.item( "certus_quartz_hoe", () -> new ToolQuartzHoe( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
this.certusQuartzSword = certusTools.item( "certus_quartz_sword", () -> new ToolQuartzSword( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzSword ).build();
|
.addFeatures( AEFeature.QUARTZ_HOE )
|
||||||
this.certusQuartzWrench = certusTools.item( "certus_quartz_wrench", ToolQuartzWrench::new ).addFeatures( AEFeature.QuartzWrench ).build();
|
.build();
|
||||||
this.certusQuartzKnife = certusTools.item( "certus_quartz_cutting_knife", () -> new ToolQuartzCuttingKnife( AEFeature.CertusQuartzTools ) ).addFeatures( AEFeature.QuartzKnife ).build();
|
this.certusQuartzShovel = certusTools.item( "certus_quartz_spade", () -> new ToolQuartzSpade( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_SPADE )
|
||||||
|
.build();
|
||||||
|
this.certusQuartzPick = certusTools.item( "certus_quartz_pickaxe", () -> new ToolQuartzPickaxe( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_PICKAXE )
|
||||||
|
.build();
|
||||||
|
this.certusQuartzSword = certusTools.item( "certus_quartz_sword", () -> new ToolQuartzSword( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_SWORD )
|
||||||
|
.build();
|
||||||
|
this.certusQuartzWrench = certusTools.item( "certus_quartz_wrench", ToolQuartzWrench::new ).addFeatures( AEFeature.QUARTZ_WRENCH ).build();
|
||||||
|
this.certusQuartzKnife = certusTools.item( "certus_quartz_cutting_knife", () -> new ToolQuartzCuttingKnife( AEFeature.CERTUS_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_KNIFE )
|
||||||
|
.build();
|
||||||
|
|
||||||
FeatureFactory netherTools = registry.features( AEFeature.NetherQuartzTools );
|
FeatureFactory netherTools = registry.features( AEFeature.NETHER_QUARTZ_TOOLS );
|
||||||
this.netherQuartzAxe = netherTools.item( "nether_quartz_axe", () -> new ToolQuartzAxe( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzAxe ).build();
|
this.netherQuartzAxe = netherTools.item( "nether_quartz_axe", () -> new ToolQuartzAxe( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
this.netherQuartzHoe = netherTools.item( "nether_quartz_hoe", () -> new ToolQuartzHoe( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzHoe ).build();
|
.addFeatures( AEFeature.QUARTZ_AXE )
|
||||||
this.netherQuartzShovel = netherTools.item( "nether_quartz_spade", () -> new ToolQuartzSpade( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzSpade ).build();
|
.build();
|
||||||
this.netherQuartzPick = netherTools.item( "nether_quartz_pickaxe", () -> new ToolQuartzPickaxe( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzPickaxe ).build();
|
this.netherQuartzHoe = netherTools.item( "nether_quartz_hoe", () -> new ToolQuartzHoe( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
this.netherQuartzSword = netherTools.item( "nether_quartz_sword", () -> new ToolQuartzSword( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzSword ).build();
|
.addFeatures( AEFeature.QUARTZ_HOE )
|
||||||
this.netherQuartzWrench = netherTools.item( "nether_quartz_wrench", ToolQuartzWrench::new ).addFeatures( AEFeature.QuartzWrench ).build();
|
.build();
|
||||||
this.netherQuartzKnife = netherTools.item( "nether_quartz_cutting_knife", () -> new ToolQuartzCuttingKnife( AEFeature.NetherQuartzTools ) ).addFeatures( AEFeature.QuartzKnife ).build();
|
this.netherQuartzShovel = netherTools.item( "nether_quartz_spade", () -> new ToolQuartzSpade( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_SPADE )
|
||||||
|
.build();
|
||||||
|
this.netherQuartzPick = netherTools.item( "nether_quartz_pickaxe", () -> new ToolQuartzPickaxe( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_PICKAXE )
|
||||||
|
.build();
|
||||||
|
this.netherQuartzSword = netherTools.item( "nether_quartz_sword", () -> new ToolQuartzSword( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_SWORD )
|
||||||
|
.build();
|
||||||
|
this.netherQuartzWrench = netherTools.item( "nether_quartz_wrench", ToolQuartzWrench::new ).addFeatures( AEFeature.QUARTZ_WRENCH ).build();
|
||||||
|
this.netherQuartzKnife = netherTools.item( "nether_quartz_cutting_knife", () -> new ToolQuartzCuttingKnife( AEFeature.NETHER_QUARTZ_TOOLS ) )
|
||||||
|
.addFeatures( AEFeature.QUARTZ_KNIFE )
|
||||||
|
.build();
|
||||||
|
|
||||||
FeatureFactory powerTools = registry.features( AEFeature.PoweredTools );
|
FeatureFactory powerTools = registry.features( AEFeature.POWERED_TOOLS );
|
||||||
this.entropyManipulator = powerTools.item( "entropy_manipulator", ToolEntropyManipulator::new )
|
this.entropyManipulator = powerTools.item( "entropy_manipulator", ToolEntropyManipulator::new )
|
||||||
.addFeatures( AEFeature.EntropyManipulator )
|
.addFeatures( AEFeature.ENTROPY_MANIPULATOR )
|
||||||
.dispenserBehavior( DispenserBlockTool::new )
|
.dispenserBehavior( DispenserBlockTool::new )
|
||||||
.build();
|
.build();
|
||||||
this.wirelessTerminal = powerTools.item( "wireless_terminal", ToolWirelessTerminal::new ).addFeatures( AEFeature.WirelessAccessTerminal ).build();
|
this.wirelessTerminal = powerTools.item( "wireless_terminal", ToolWirelessTerminal::new ).addFeatures( AEFeature.WIRELESS_ACCESS_TERMINAL ).build();
|
||||||
this.chargedStaff = powerTools.item( "charged_staff", ToolChargedStaff::new ).addFeatures( AEFeature.ChargedStaff ).build();
|
this.chargedStaff = powerTools.item( "charged_staff", ToolChargedStaff::new ).addFeatures( AEFeature.CHARGED_STAFF ).build();
|
||||||
this.massCannon = powerTools.item( "matter_cannon", ToolMatterCannon::new )
|
this.massCannon = powerTools.item( "matter_cannon", ToolMatterCannon::new )
|
||||||
.addFeatures( AEFeature.MatterCannon )
|
.addFeatures( AEFeature.MATTER_CANNON )
|
||||||
.dispenserBehavior( DispenserMatterCannon::new )
|
.dispenserBehavior( DispenserMatterCannon::new )
|
||||||
.build();
|
.build();
|
||||||
this.portableCell = powerTools.item( "portable_cell", ToolPortableCell::new ).addFeatures( AEFeature.PortableCell, AEFeature.StorageCells ).build();
|
this.portableCell = powerTools.item( "portable_cell", ToolPortableCell::new ).addFeatures( AEFeature.PORTABLE_CELL, AEFeature.STORAGE_CELLS ).build();
|
||||||
this.colorApplicator = powerTools.item( "color_applicator", ToolColorApplicator::new )
|
this.colorApplicator = powerTools.item( "color_applicator", ToolColorApplicator::new )
|
||||||
.addFeatures( AEFeature.ColorApplicator )
|
.addFeatures( AEFeature.COLOR_APPLICATOR )
|
||||||
.dispenserBehavior( DispenserBlockTool::new )
|
.dispenserBehavior( DispenserBlockTool::new )
|
||||||
.rendering( new ToolColorApplicatorRendering() )
|
.rendering( new ToolColorApplicatorRendering() )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
this.biometricCard = registry.item( "biometric_card", ToolBiometricCard::new )
|
this.biometricCard = registry.item( "biometric_card", ToolBiometricCard::new )
|
||||||
.rendering( new ToolBiometricCardRendering() )
|
.rendering( new ToolBiometricCardRendering() )
|
||||||
.features( AEFeature.Security ).build();
|
.features( AEFeature.SECURITY )
|
||||||
this.memoryCard = registry.item( "memory_card", ToolMemoryCard::new ).build();
|
.build();
|
||||||
this.networkTool = registry.item( "network_tool", ToolNetworkTool::new ).features( AEFeature.NetworkTool ).build();
|
this.memoryCard = registry.item( "memory_card", ToolMemoryCard::new ).features( AEFeature.MEMORY_CARD ).build();
|
||||||
|
this.networkTool = registry.item( "network_tool", ToolNetworkTool::new ).features( AEFeature.NETWORK_TOOL ).build();
|
||||||
|
|
||||||
this.cellCreative = registry.item( "creative_storage_cell", ItemCreativeStorageCell::new ).features( AEFeature.StorageCells, AEFeature.Creative ).build();
|
this.cellCreative = registry.item( "creative_storage_cell", ItemCreativeStorageCell::new )
|
||||||
this.viewCell = registry.item( "view_cell", ItemViewCell::new ).build();
|
.features( AEFeature.STORAGE_CELLS, AEFeature.CREATIVE )
|
||||||
|
.build();
|
||||||
|
this.viewCell = registry.item( "view_cell", ItemViewCell::new ).features( AEFeature.VIEW_CELL ).build();
|
||||||
|
|
||||||
FeatureFactory storageCells = registry.features( AEFeature.StorageCells );
|
FeatureFactory storageCells = registry.features( AEFeature.STORAGE_CELLS );
|
||||||
this.cell1k = storageCells.item( "storage_cell_1k", () -> new ItemBasicStorageCell( MaterialType.Cell1kPart, 1 ) ).build();
|
this.cell1k = storageCells.item( "storage_cell_1k", () -> new ItemBasicStorageCell( MaterialType.Cell1kPart, 1 ) ).build();
|
||||||
this.cell4k = storageCells.item( "storage_cell_4k", () -> new ItemBasicStorageCell( MaterialType.Cell4kPart, 4 ) ).build();
|
this.cell4k = storageCells.item( "storage_cell_4k", () -> new ItemBasicStorageCell( MaterialType.Cell4kPart, 4 ) ).build();
|
||||||
this.cell16k = storageCells.item( "storage_cell_16k", () -> new ItemBasicStorageCell( MaterialType.Cell16kPart, 16 ) ).build();
|
this.cell16k = storageCells.item( "storage_cell_16k", () -> new ItemBasicStorageCell( MaterialType.Cell16kPart, 16 ) ).build();
|
||||||
this.cell64k = storageCells.item( "storage_cell_64k", () -> new ItemBasicStorageCell( MaterialType.Cell64kPart, 64 ) ).build();
|
this.cell64k = storageCells.item( "storage_cell_64k", () -> new ItemBasicStorageCell( MaterialType.Cell64kPart, 64 ) ).build();
|
||||||
|
|
||||||
FeatureFactory spatialCells = registry.features( AEFeature.SpatialIO );
|
FeatureFactory spatialCells = registry.features( AEFeature.SPATIAL_IO );
|
||||||
this.spatialCell2 = spatialCells.item( "spatial_storage_cell_2_cubed", () -> new ItemSpatialStorageCell( 2 ) ).build();
|
this.spatialCell2 = spatialCells.item( "spatial_storage_cell_2_cubed", () -> new ItemSpatialStorageCell( 2 ) ).build();
|
||||||
this.spatialCell16 = spatialCells.item( "spatial_storage_cell_16_cubed", () -> new ItemSpatialStorageCell( 16 ) ).build();
|
this.spatialCell16 = spatialCells.item( "spatial_storage_cell_16_cubed", () -> new ItemSpatialStorageCell( 16 ) ).build();
|
||||||
this.spatialCell128 = spatialCells.item( "spatial_storage_cell_128_cubed", () -> new ItemSpatialStorageCell( 128 ) ).build();
|
this.spatialCell128 = spatialCells.item( "spatial_storage_cell_128_cubed", () -> new ItemSpatialStorageCell( 128 ) ).build();
|
||||||
|
|
||||||
this.facade = registry.item( "facade", ItemFacade::new )
|
this.facade = registry.item( "facade", ItemFacade::new )
|
||||||
.features( AEFeature.Facades )
|
.features( AEFeature.FACADES )
|
||||||
.creativeTab( CreativeTabFacade.instance )
|
.creativeTab( CreativeTabFacade.instance )
|
||||||
.rendering( new FacadeRendering() )
|
.rendering( new FacadeRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.crystalSeed = registry.item( "crystal_seed", ItemCrystalSeed::new )
|
this.crystalSeed = registry.item( "crystal_seed", ItemCrystalSeed::new )
|
||||||
|
.features( AEFeature.CRYSTAL_SEEDS )
|
||||||
.rendering( new ItemCrystalSeedRendering() )
|
.rendering( new ItemCrystalSeedRendering() )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
// rv1
|
// rv1
|
||||||
this.encodedPattern = registry.item( "encoded_pattern", ItemEncodedPattern::new )
|
this.encodedPattern = registry.item( "encoded_pattern", ItemEncodedPattern::new )
|
||||||
.features( AEFeature.Patterns )
|
.features( AEFeature.PATTERNS )
|
||||||
.rendering( new ItemEncodedPatternRendering() )
|
.rendering( new ItemEncodedPatternRendering() )
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
this.paintBall = registry.item( "paint_ball", ItemPaintBall::new )
|
this.paintBall = registry.item( "paint_ball", ItemPaintBall::new )
|
||||||
.features( AEFeature.PaintBalls )
|
.features( AEFeature.PAINT_BALLS )
|
||||||
.rendering( new ItemPaintBallRendering() )
|
.rendering( new ItemPaintBallRendering() )
|
||||||
.build();
|
.build();
|
||||||
this.coloredPaintBall = registry.colored( this.paintBall, 0 );
|
this.coloredPaintBall = registry.colored( this.paintBall, 0 );
|
||||||
this.coloredLumenPaintBall = registry.colored( this.paintBall, 20 );
|
this.coloredLumenPaintBall = registry.colored( this.paintBall, 20 );
|
||||||
|
|
||||||
FeatureFactory debugTools = registry.features( AEFeature.UnsupportedDeveloperTools, AEFeature.Creative );
|
FeatureFactory debugTools = registry.features( AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE );
|
||||||
this.toolEraser = debugTools.item( "debug_eraser", ToolEraser::new ).build();
|
this.toolEraser = debugTools.item( "debug_eraser", ToolEraser::new ).build();
|
||||||
this.toolMeteoritePlacer = debugTools.item( "debug_meteorite_placer", ToolMeteoritePlacer::new ).build();
|
this.toolMeteoritePlacer = debugTools.item( "debug_meteorite_placer", ToolMeteoritePlacer::new ).build();
|
||||||
this.toolDebugCard = debugTools.item( "debug_card", ToolDebugCard::new ).build();
|
this.toolDebugCard = debugTools.item( "debug_card", ToolDebugCard::new ).build();
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ public enum AEFeature
|
|||||||
// stuff that has no reason for ever being turned off, or that
|
// stuff that has no reason for ever being turned off, or that
|
||||||
// is just flat out required by tons of
|
// is just flat out required by tons of
|
||||||
// important stuff.
|
// important stuff.
|
||||||
Core( null )
|
CORE( "Core", null )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
public boolean isVisible()
|
public boolean isVisible()
|
||||||
@@ -33,124 +33,162 @@ public enum AEFeature
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
CertusQuartzWorldGen( Constants.CATEGORY_WORLD ),
|
CERTUS_QUARTZ_WORLD_GEN( "CertusQuartzWorldGen", Constants.CATEGORY_WORLD ),
|
||||||
MeteoriteWorldGen( Constants.CATEGORY_WORLD ),
|
METEORITE_WORLD_GEN( "MeteoriteWorldGen", Constants.CATEGORY_WORLD ),
|
||||||
DecorativeLights( Constants.CATEGORY_WORLD ),
|
DECORATIVE_LIGHTS( "DecorativeLights", Constants.CATEGORY_WORLD ),
|
||||||
DecorativeQuartzBlocks( Constants.CATEGORY_WORLD ),
|
DECORATIVE_QUARTZ_BLOCKS( "DecorativeQuartzBlocks", Constants.CATEGORY_WORLD ),
|
||||||
SkyStoneChests( Constants.CATEGORY_WORLD ),
|
SKY_STONE_CHESTS( "SkyStoneChests", Constants.CATEGORY_WORLD ),
|
||||||
SpawnPressesInMeteorites( Constants.CATEGORY_WORLD ),
|
SPAWN_PRESSES_IN_METEORITES( "SpawnPressesInMeteorites", Constants.CATEGORY_WORLD ),
|
||||||
GrindStone( Constants.CATEGORY_WORLD ),
|
GRIND_STONE( "GrindStone", Constants.CATEGORY_WORLD ),
|
||||||
Flour( Constants.CATEGORY_WORLD ),
|
FLOUR( "Flour", Constants.CATEGORY_WORLD ),
|
||||||
Inscriber( Constants.CATEGORY_WORLD ),
|
INSCRIBER( "Inscriber", Constants.CATEGORY_WORLD ),
|
||||||
ChestLoot( Constants.CATEGORY_WORLD ),
|
CHARGER( "Charger", Constants.CATEGORY_WORLD ),
|
||||||
VillagerTrading( Constants.CATEGORY_WORLD ),
|
CRYSTAL_GROWTH_ACCELERATOR( "CrystalGrowthAccelerator", Constants.CATEGORY_WORLD ),
|
||||||
TinyTNT( Constants.CATEGORY_WORLD ),
|
CHEST_LOOT( "ChestLoot", Constants.CATEGORY_WORLD ),
|
||||||
|
VILLAGER_TRADING( "VillagerTrading", Constants.CATEGORY_WORLD ),
|
||||||
|
TINY_TNT( "TinyTNT", Constants.CATEGORY_WORLD ),
|
||||||
|
CERTUS_ORE( "CertusOre", Constants.CATEGORY_WORLD ),
|
||||||
|
CHARGED_CERTUS_ORE( "ChargedCertusOre", Constants.CATEGORY_WORLD ),
|
||||||
|
|
||||||
PoweredTools( Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
POWERED_TOOLS( "PoweredTools", Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
||||||
CertusQuartzTools( Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
CERTUS_QUARTZ_TOOLS( "CertusQuartzTools", Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
||||||
NetherQuartzTools( Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
NETHER_QUARTZ_TOOLS( "NetherQuartzTools", Constants.CATEGORY_TOOLS_CLASSIFICATIONS ),
|
||||||
|
|
||||||
QuartzHoe( Constants.CATEGORY_TOOLS ),
|
QUARTZ_HOE( "QuartzHoe", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzSpade( Constants.CATEGORY_TOOLS ),
|
QUARTZ_SPADE( "QuartzSpade", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzSword( Constants.CATEGORY_TOOLS ),
|
QUARTZ_SWORD( "QuartzSword", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzPickaxe( Constants.CATEGORY_TOOLS ),
|
QUARTZ_PICKAXE( "QuartzPickaxe", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzAxe( Constants.CATEGORY_TOOLS ),
|
QUARTZ_AXE( "QuartzAxe", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzKnife( Constants.CATEGORY_TOOLS ),
|
QUARTZ_KNIFE( "QuartzKnife", Constants.CATEGORY_TOOLS ),
|
||||||
QuartzWrench( Constants.CATEGORY_TOOLS ),
|
QUARTZ_WRENCH( "QuartzWrench", Constants.CATEGORY_TOOLS ),
|
||||||
ChargedStaff( Constants.CATEGORY_TOOLS ),
|
CHARGED_STAFF( "ChargedStaff", Constants.CATEGORY_TOOLS ),
|
||||||
EntropyManipulator( Constants.CATEGORY_TOOLS ),
|
ENTROPY_MANIPULATOR( "EntropyManipulator", Constants.CATEGORY_TOOLS ),
|
||||||
MatterCannon( Constants.CATEGORY_TOOLS ),
|
MATTER_CANNON( "MatterCannon", Constants.CATEGORY_TOOLS ),
|
||||||
WirelessAccessTerminal( Constants.CATEGORY_TOOLS ),
|
WIRELESS_ACCESS_TERMINAL( "WirelessAccessTerminal", Constants.CATEGORY_TOOLS ),
|
||||||
ColorApplicator( Constants.CATEGORY_TOOLS ),
|
COLOR_APPLICATOR( "ColorApplicator", Constants.CATEGORY_TOOLS ),
|
||||||
MeteoriteCompass( Constants.CATEGORY_TOOLS ),
|
METEORITE_COMPASS( "MeteoriteCompass", Constants.CATEGORY_TOOLS ),
|
||||||
|
|
||||||
PowerGen( Constants.CATEGORY_NETWORK_FEATURES ),
|
POWER_GEN( "PowerGen", Constants.CATEGORY_NETWORK_FEATURES ),
|
||||||
Security( Constants.CATEGORY_NETWORK_FEATURES ),
|
SECURITY( "Security", Constants.CATEGORY_NETWORK_FEATURES ),
|
||||||
SpatialIO( Constants.CATEGORY_NETWORK_FEATURES ),
|
SPATIAL_IO( "SpatialIO", Constants.CATEGORY_NETWORK_FEATURES ),
|
||||||
QuantumNetworkBridge( Constants.CATEGORY_NETWORK_FEATURES ),
|
QUANTUM_NETWORK_BRIDGE( "QuantumNetworkBridge", Constants.CATEGORY_NETWORK_FEATURES ),
|
||||||
Channels( Constants.CATEGORY_NETWORK_FEATURES ),
|
CHANNELS( "Channels", Constants.CATEGORY_NETWORK_FEATURES ),
|
||||||
|
|
||||||
LevelEmitter( Constants.CATEGORY_NETWORK_BUSES ),
|
INTERFACE( "Interface", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
CraftingTerminal( Constants.CATEGORY_NETWORK_BUSES ),
|
LEVEL_EMITTER( "LevelEmitter", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
StorageMonitor( Constants.CATEGORY_NETWORK_BUSES ),
|
CRAFTING_TERMINAL( "CraftingTerminal", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
P2PTunnel( Constants.CATEGORY_NETWORK_BUSES ),
|
TERMINAL( "Terminal", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
FormationPlane( Constants.CATEGORY_NETWORK_BUSES ),
|
STORAGE_MONITOR( "StorageMonitor", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
AnnihilationPlane( Constants.CATEGORY_NETWORK_BUSES ),
|
P2P_TUNNEL( "P2PTunnel", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
IdentityAnnihilationPlane( Constants.CATEGORY_NETWORK_BUSES ),
|
FORMATION_PLANE( "FormationPlane", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
ImportBus( Constants.CATEGORY_NETWORK_BUSES ),
|
ANNIHILATION_PLANE( "AnnihilationPlane", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
ExportBus( Constants.CATEGORY_NETWORK_BUSES ),
|
IDENTITY_ANNIHILATION_PLANE( "IdentityAnnihilationPlane", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
StorageBus( Constants.CATEGORY_NETWORK_BUSES ),
|
IMPORT_BUS( "ImportBus", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
PartConversionMonitor( Constants.CATEGORY_NETWORK_BUSES ),
|
EXPORT_BUS( "ExportBus", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
STORAGE_BUS( "StorageBus", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
PART_CONVERSION_MONITOR( "PartConversionMonitor", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
TOGGLE_BUS( "ToggleBus", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
PANELS( "Panels", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
QUARTZ_FIBER( "QuartzFiber", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
CABLE_ANCHOR( "CableAnchor", Constants.CATEGORY_NETWORK_BUSES ),
|
||||||
|
|
||||||
PortableCell( Constants.CATEGORY_PORTABLE_CELL ),
|
PORTABLE_CELL( "PortableCell", Constants.CATEGORY_PORTABLE_CELL ),
|
||||||
|
|
||||||
StorageCells( Constants.CATEGORY_STORAGE ),
|
STORAGE_CELLS( "StorageCells", Constants.CATEGORY_STORAGE ),
|
||||||
MEChest( Constants.CATEGORY_STORAGE ),
|
ME_CHEST( "MEChest", Constants.CATEGORY_STORAGE ),
|
||||||
MEDrive( Constants.CATEGORY_STORAGE ),
|
ME_DRIVE( "MEDrive", Constants.CATEGORY_STORAGE ),
|
||||||
IOPort( Constants.CATEGORY_STORAGE ),
|
IO_PORT( "IOPort", Constants.CATEGORY_STORAGE ),
|
||||||
|
CONDENSER( "Condenser", Constants.CATEGORY_STORAGE ),
|
||||||
|
|
||||||
NetworkTool( Constants.CATEGORY_NETWORK_TOOL ),
|
NETWORK_TOOL( "NetworkTool", Constants.CATEGORY_NETWORK_TOOL ),
|
||||||
|
MEMORY_CARD( "MemoryCard", Constants.CATEGORY_NETWORK_TOOL ),
|
||||||
|
|
||||||
DenseEnergyCells( Constants.CATEGORY_HIGHER_CAPACITY ),
|
GLASS_CABLES( "GlassCables", Constants.CATEGORY_CABLES ),
|
||||||
DenseCables( Constants.CATEGORY_HIGHER_CAPACITY ),
|
COVERED_CABLES( "CoveredCables", Constants.CATEGORY_CABLES ),
|
||||||
|
SMART_CABLES( "SmartCables", Constants.CATEGORY_CABLES ),
|
||||||
|
|
||||||
P2PTunnelRF( Constants.CATEGORY_P2P_TUNNELS ),
|
ENERGY_CELLS( "EnergyCells", Constants.CATEGORY_ENERGY ),
|
||||||
P2PTunnelME( Constants.CATEGORY_P2P_TUNNELS ),
|
ENERGY_ACCEPTOR( "EnergyAcceptor", Constants.CATEGORY_ENERGY ),
|
||||||
P2PTunnelItems( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelRedstone( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelEU( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelLiquids( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelLight( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelOpenComputers( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
P2PTunnelPressure( Constants.CATEGORY_P2P_TUNNELS ),
|
|
||||||
|
|
||||||
MassCannonBlockDamage( Constants.CATEGORY_BLOCK_FEATURES ),
|
DENSE_ENERGY_CELLS( "DenseEnergyCells", Constants.CATEGORY_HIGHER_CAPACITY ),
|
||||||
TinyTNTBlockDamage( Constants.CATEGORY_BLOCK_FEATURES ),
|
DENSE_CABLES( "DenseCables", Constants.CATEGORY_HIGHER_CAPACITY ),
|
||||||
|
|
||||||
Facades( Constants.CATEGORY_FACADES ),
|
P2P_TUNNEL_RF( "P2PTunnelRF", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_ME( "P2PTunnelME", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_ITEMS( "P2PTunnelItems", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_REDSTONE( "P2PTunnelRedstone", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_EU( "P2PTunnelEU", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_LIQUIDS( "P2PTunnelLiquids", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_LIGHT( "P2PTunnelLight", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_OPEN_COMPUTERS( "P2PTunnelOpenComputers", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
P2P_TUNNEL_PRESSURE( "P2PTunnelPressure", Constants.CATEGORY_P2P_TUNNELS ),
|
||||||
|
|
||||||
UnsupportedDeveloperTools( Constants.CATEGORY_MISC, false ),
|
MASS_CANNON_BLOCK_DAMAGE( "MassCannonBlockDamage", Constants.CATEGORY_BLOCK_FEATURES ),
|
||||||
Creative( Constants.CATEGORY_MISC ),
|
TINY_TNT_BLOCK_DAMAGE( "TinyTNTBlockDamage", Constants.CATEGORY_BLOCK_FEATURES ),
|
||||||
GrinderLogging( Constants.CATEGORY_MISC, false ),
|
|
||||||
Logging( Constants.CATEGORY_MISC ),
|
|
||||||
IntegrationLogging( Constants.CATEGORY_MISC, false ),
|
|
||||||
WebsiteRecipes( Constants.CATEGORY_MISC, false ),
|
|
||||||
LogSecurityAudits( Constants.CATEGORY_MISC, false ),
|
|
||||||
Achievements( Constants.CATEGORY_MISC ),
|
|
||||||
UpdateLogging( Constants.CATEGORY_MISC, false ),
|
|
||||||
PacketLogging( Constants.CATEGORY_MISC, false ),
|
|
||||||
CraftingLog( Constants.CATEGORY_MISC, false ),
|
|
||||||
LightDetector( Constants.CATEGORY_MISC ),
|
|
||||||
DebugLogging( Constants.CATEGORY_MISC, false ),
|
|
||||||
|
|
||||||
EnableFacadeCrafting( Constants.CATEGORY_CRAFTING ),
|
FACADES( "Facades", Constants.CATEGORY_FACADES ),
|
||||||
InWorldSingularity( Constants.CATEGORY_CRAFTING ),
|
|
||||||
InWorldFluix( Constants.CATEGORY_CRAFTING ),
|
|
||||||
InWorldPurification( Constants.CATEGORY_CRAFTING ),
|
|
||||||
InterfaceTerminal( Constants.CATEGORY_CRAFTING ),
|
|
||||||
EnableDisassemblyCrafting( Constants.CATEGORY_CRAFTING ),
|
|
||||||
|
|
||||||
AlphaPass( Constants.CATEGORY_RENDERING ),
|
UNSUPPORTED_DEVELOPER_TOOLS( "UnsupportedDeveloperTools", Constants.CATEGORY_MISC, false ),
|
||||||
PaintBalls( Constants.CATEGORY_TOOLS ),
|
CREATIVE( "Creative", Constants.CATEGORY_MISC ),
|
||||||
|
GRINDER_LOGGING( "GrinderLogging", Constants.CATEGORY_MISC, false ),
|
||||||
|
LOGGING( "Logging", Constants.CATEGORY_MISC ),
|
||||||
|
INTEGRATION_LOGGING( "IntegrationLogging", Constants.CATEGORY_MISC, false ),
|
||||||
|
WEBSITE_RECIPES( "WebsiteRecipes", Constants.CATEGORY_MISC, false ),
|
||||||
|
LOG_SECURITY_AUDITS( "LogSecurityAudits", Constants.CATEGORY_MISC, false ),
|
||||||
|
ACHIEVEMENTS( "Achievements", Constants.CATEGORY_MISC ),
|
||||||
|
UPDATE_LOGGING( "UpdateLogging", Constants.CATEGORY_MISC, false ),
|
||||||
|
PACKET_LOGGING( "PacketLogging", Constants.CATEGORY_MISC, false ),
|
||||||
|
CRAFTING_LOG( "CraftingLog", Constants.CATEGORY_MISC, false ),
|
||||||
|
LIGHT_DETECTOR( "LightDetector", Constants.CATEGORY_MISC ),
|
||||||
|
DEBUG_LOGGING( "DebugLogging", Constants.CATEGORY_MISC, false ),
|
||||||
|
|
||||||
MolecularAssembler( Constants.CATEGORY_CRAFTING_FEATURES ),
|
ENABLE_FACADE_CRAFTING( "EnableFacadeCrafting", Constants.CATEGORY_CRAFTING ),
|
||||||
Patterns( Constants.CATEGORY_CRAFTING_FEATURES ),
|
IN_WORLD_SINGULARITY( "InWorldSingularity", Constants.CATEGORY_CRAFTING ),
|
||||||
CraftingCPU( Constants.CATEGORY_CRAFTING_FEATURES ),
|
IN_WORLD_FLUIX( "InWorldFluix", Constants.CATEGORY_CRAFTING ),
|
||||||
|
IN_WORLD_PURIFICATION( "InWorldPurification", Constants.CATEGORY_CRAFTING ),
|
||||||
|
INTERFACE_TERMINAL( "InterfaceTerminal", Constants.CATEGORY_CRAFTING ),
|
||||||
|
ENABLE_DISASSEMBLY_CRAFTING( "EnableDisassemblyCrafting", Constants.CATEGORY_CRAFTING ),
|
||||||
|
|
||||||
ChunkLoggerTrace( Constants.CATEGORY_COMMANDS, false );
|
ALPHA_PASS( "AlphaPass", Constants.CATEGORY_RENDERING ),
|
||||||
|
PAINT_BALLS( "PaintBalls", Constants.CATEGORY_TOOLS ),
|
||||||
|
|
||||||
public final String category;
|
MOLECULAR_ASSEMBLER( "MolecularAssembler", Constants.CATEGORY_CRAFTING_FEATURES ),
|
||||||
public final boolean defaultValue;
|
PATTERNS( "Patterns", Constants.CATEGORY_CRAFTING_FEATURES ),
|
||||||
|
CRAFTING_CPU( "CraftingCPU", Constants.CATEGORY_CRAFTING_FEATURES ),
|
||||||
|
|
||||||
AEFeature( final String cat )
|
BASIC_CARDS( "BasicCards", Constants.CATEGORY_UPGRADES ),
|
||||||
|
ADVANCED_CARDS( "AdvancedCards", Constants.CATEGORY_UPGRADES ),
|
||||||
|
VIEW_CELL( "ViewCell", Constants.CATEGORY_UPGRADES ),
|
||||||
|
|
||||||
|
PROCESSORS( "Processors", Constants.CATEGORY_MATERIALS ),
|
||||||
|
PRINTED_CIRCUITS( "PrintedCircuits", Constants.CATEGORY_MATERIALS ),
|
||||||
|
PRESSES( "Presses", Constants.CATEGORY_MATERIALS ),
|
||||||
|
CRYSTAL_SEEDS( "CrystalSeeds", Constants.CATEGORY_MATERIALS ),
|
||||||
|
PURE_CRYSTALS( "PureCrystals", Constants.CATEGORY_MATERIALS ),
|
||||||
|
CERTUS( "Certus", Constants.CATEGORY_MATERIALS ),
|
||||||
|
FLUIX( "Fluix", Constants.CATEGORY_MATERIALS ),
|
||||||
|
SILICON( "Silicon", Constants.CATEGORY_MATERIALS ),
|
||||||
|
DUSTS( "Dusts", Constants.CATEGORY_MATERIALS ),
|
||||||
|
NUGGETS( "Nuggets", Constants.CATEGORY_MATERIALS ),
|
||||||
|
MATTER_BALL( "MatterBall", Constants.CATEGORY_MATERIALS ),
|
||||||
|
CORES( "Cores", Constants.CATEGORY_MATERIALS ),
|
||||||
|
|
||||||
|
CHUNK_LOGGER_TRACE( "ChunkLoggerTrace", Constants.CATEGORY_COMMANDS, false );
|
||||||
|
|
||||||
|
private final String key;
|
||||||
|
private final String category;
|
||||||
|
private final boolean enabled;
|
||||||
|
|
||||||
|
AEFeature( final String key, final String cat )
|
||||||
{
|
{
|
||||||
this( cat, true );
|
this( key, cat, true );
|
||||||
}
|
}
|
||||||
|
|
||||||
AEFeature( final String cat, final boolean defaultValue )
|
AEFeature( final String key, final String cat, final boolean enabled )
|
||||||
{
|
{
|
||||||
|
this.key = key;
|
||||||
this.category = cat;
|
this.category = cat;
|
||||||
this.defaultValue = defaultValue;
|
this.enabled = enabled;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -163,6 +201,21 @@ public enum AEFeature
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String key()
|
||||||
|
{
|
||||||
|
return key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String category()
|
||||||
|
{
|
||||||
|
return category;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isEnabled()
|
||||||
|
{
|
||||||
|
return enabled;
|
||||||
|
}
|
||||||
|
|
||||||
private enum Constants
|
private enum Constants
|
||||||
{
|
{
|
||||||
;
|
;
|
||||||
@@ -177,6 +230,7 @@ public enum AEFeature
|
|||||||
private static final String CATEGORY_BLOCK_FEATURES = "BlockFeatures";
|
private static final String CATEGORY_BLOCK_FEATURES = "BlockFeatures";
|
||||||
private static final String CATEGORY_CRAFTING_FEATURES = "CraftingFeatures";
|
private static final String CATEGORY_CRAFTING_FEATURES = "CraftingFeatures";
|
||||||
private static final String CATEGORY_STORAGE = "Storage";
|
private static final String CATEGORY_STORAGE = "Storage";
|
||||||
|
private static final String CATEGORY_CABLES = "Cables";
|
||||||
private static final String CATEGORY_HIGHER_CAPACITY = "HigherCapacity";
|
private static final String CATEGORY_HIGHER_CAPACITY = "HigherCapacity";
|
||||||
private static final String CATEGORY_NETWORK_FEATURES = "NetworkFeatures";
|
private static final String CATEGORY_NETWORK_FEATURES = "NetworkFeatures";
|
||||||
private static final String CATEGORY_COMMANDS = "Commands";
|
private static final String CATEGORY_COMMANDS = "Commands";
|
||||||
@@ -184,5 +238,8 @@ public enum AEFeature
|
|||||||
private static final String CATEGORY_FACADES = "Facades";
|
private static final String CATEGORY_FACADES = "Facades";
|
||||||
private static final String CATEGORY_NETWORK_TOOL = "NetworkTool";
|
private static final String CATEGORY_NETWORK_TOOL = "NetworkTool";
|
||||||
private static final String CATEGORY_PORTABLE_CELL = "PortableCell";
|
private static final String CATEGORY_PORTABLE_CELL = "PortableCell";
|
||||||
|
private static final String CATEGORY_ENERGY = "Energy";
|
||||||
|
private static final String CATEGORY_UPGRADES = "Upgrades";
|
||||||
|
private static final String CATEGORY_MATERIALS = "Materials";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -30,12 +30,14 @@ import appeng.items.materials.MaterialType;
|
|||||||
public class MaterialStackSrc implements IStackSrc
|
public class MaterialStackSrc implements IStackSrc
|
||||||
{
|
{
|
||||||
private final MaterialType src;
|
private final MaterialType src;
|
||||||
|
private final boolean enabled;
|
||||||
|
|
||||||
public MaterialStackSrc( final MaterialType src )
|
public MaterialStackSrc( final MaterialType src, boolean enabled )
|
||||||
{
|
{
|
||||||
Preconditions.checkNotNull( src );
|
Preconditions.checkNotNull( src );
|
||||||
|
|
||||||
this.src = src;
|
this.src = src;
|
||||||
|
this.enabled = enabled;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -59,6 +61,6 @@ public class MaterialStackSrc implements IStackSrc
|
|||||||
@Override
|
@Override
|
||||||
public boolean isEnabled()
|
public boolean isEnabled()
|
||||||
{
|
{
|
||||||
return true;
|
return this.enabled;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -204,7 +204,7 @@ public final class GrinderRecipeManager implements IGrinderRegistry, IOreListene
|
|||||||
{
|
{
|
||||||
final ItemStack extra = is.copy();
|
final ItemStack extra = is.copy();
|
||||||
extra.stackSize = ratio - 1;
|
extra.stackSize = ratio - 1;
|
||||||
this.addRecipe( item, is, extra, (float) ( AEConfig.instance.oreDoublePercentage / 100.0 ), 8 );
|
this.addRecipe( item, is, extra, (float) ( AEConfig.instance().getOreDoublePercentage() / 100.0 ), 8 );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -256,7 +256,7 @@ public final class GrinderRecipeManager implements IGrinderRegistry, IOreListene
|
|||||||
{
|
{
|
||||||
final ItemStack extra = is.copy();
|
final ItemStack extra = is.copy();
|
||||||
extra.stackSize = ratio - 1;
|
extra.stackSize = ratio - 1;
|
||||||
this.addRecipe( d.getKey(), is, extra, (float) ( AEConfig.instance.oreDoublePercentage / 100.0 ), 8 );
|
this.addRecipe( d.getKey(), is, extra, (float) ( AEConfig.instance().getOreDoublePercentage() / 100.0 ), 8 );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -279,7 +279,7 @@ public final class GrinderRecipeManager implements IGrinderRegistry, IOreListene
|
|||||||
{
|
{
|
||||||
if( name.startsWith( "ore" ) || name.startsWith( "crystal" ) || name.startsWith( "gem" ) || name.startsWith( "ingot" ) || name.startsWith( "dust" ) )
|
if( name.startsWith( "ore" ) || name.startsWith( "crystal" ) || name.startsWith( "gem" ) || name.startsWith( "ingot" ) || name.startsWith( "dust" ) )
|
||||||
{
|
{
|
||||||
for( final String ore : AEConfig.instance.grinderOres )
|
for( final String ore : AEConfig.instance().getGrinderOres() )
|
||||||
{
|
{
|
||||||
if( name.equals( "ore" + ore ) )
|
if( name.equals( "ore" + ore ) )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ public class MatterCannonAmmoRegistry implements IOreListener, IMatterCannonAmmo
|
|||||||
this.considerItem( name, item, "Sodium", 22.9897 );
|
this.considerItem( name, item, "Sodium", 22.9897 );
|
||||||
this.considerItem( name, item, "Magnesium", 24.305 );
|
this.considerItem( name, item, "Magnesium", 24.305 );
|
||||||
this.considerItem( name, item, "Aluminum", 26.9815 );
|
this.considerItem( name, item, "Aluminum", 26.9815 );
|
||||||
this.considerItem( name, item, "Silicon", 28.0855 );
|
this.considerItem( name, item, "SILICON", 28.0855 );
|
||||||
this.considerItem( name, item, "Phosphorus", 30.9738 );
|
this.considerItem( name, item, "Phosphorus", 30.9738 );
|
||||||
this.considerItem( name, item, "Sulfur", 32.065 );
|
this.considerItem( name, item, "Sulfur", 32.065 );
|
||||||
this.considerItem( name, item, "Potassium", 39.0983 );
|
this.considerItem( name, item, "Potassium", 39.0983 );
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ import appeng.core.features.AEFeature;
|
|||||||
/**
|
/**
|
||||||
* Registers any items a player is picking up or is crafting.
|
* Registers any items a player is picking up or is crafting.
|
||||||
* Registered items are added to the player stats.
|
* Registered items are added to the player stats.
|
||||||
* This will only happen if the {@link AEFeature#Achievements} feature is enabled.
|
* This will only happen if the {@link AEFeature#ACHIEVEMENTS} feature is enabled.
|
||||||
*/
|
*/
|
||||||
public class PlayerStatsRegistration
|
public class PlayerStatsRegistration
|
||||||
{
|
{
|
||||||
@@ -43,7 +43,7 @@ public class PlayerStatsRegistration
|
|||||||
private final EventBus bus;
|
private final EventBus bus;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* is true if the {@link appeng.core.features.AEFeature#Achievements} is enabled in the
|
* is true if the {@link appeng.core.features.AEFeature#ACHIEVEMENTS} is enabled in the
|
||||||
*
|
*
|
||||||
* @param config
|
* @param config
|
||||||
*/
|
*/
|
||||||
@@ -55,12 +55,12 @@ public class PlayerStatsRegistration
|
|||||||
*
|
*
|
||||||
* @param bus {@see #bus}
|
* @param bus {@see #bus}
|
||||||
* @param config {@link appeng.core.AEConfig} which is used to determine if the
|
* @param config {@link appeng.core.AEConfig} which is used to determine if the
|
||||||
* {@link appeng.core.features.AEFeature#Achievements} is enabled
|
* {@link appeng.core.features.AEFeature#ACHIEVEMENTS} is enabled
|
||||||
*/
|
*/
|
||||||
public PlayerStatsRegistration( final EventBus bus, final AEConfig config )
|
public PlayerStatsRegistration( final EventBus bus, final AEConfig config )
|
||||||
{
|
{
|
||||||
this.bus = bus;
|
this.bus = bus;
|
||||||
this.isAchievementFeatureEnabled = config.isFeatureEnabled( AEFeature.Achievements );
|
this.isAchievementFeatureEnabled = config.isFeatureEnabled( AEFeature.ACHIEVEMENTS );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -71,9 +71,9 @@ public abstract class AppEngPacket implements Packet
|
|||||||
throw new IllegalArgumentException( "Sorry AE2 made a " + this.p.array().length + " byte packet by accident!" );
|
throw new IllegalArgumentException( "Sorry AE2 made a " + this.p.array().length + " byte packet by accident!" );
|
||||||
}
|
}
|
||||||
|
|
||||||
final FMLProxyPacket pp = new FMLProxyPacket( this.p, NetworkHandler.instance.getChannel() );
|
final FMLProxyPacket pp = new FMLProxyPacket( this.p, NetworkHandler.instance().getChannel() );
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.PacketLogging ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.PACKET_LOGGING ) )
|
||||||
{
|
{
|
||||||
AELog.info( this.getClass().getName() + " : " + pp.payload().readableBytes() );
|
AELog.info( this.getClass().getName() + " : " + pp.payload().readableBytes() );
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ import appeng.core.worlddata.WorldData;
|
|||||||
|
|
||||||
public class NetworkHandler
|
public class NetworkHandler
|
||||||
{
|
{
|
||||||
public static NetworkHandler instance;
|
private static NetworkHandler instance;
|
||||||
|
|
||||||
private final FMLEventChannel ec;
|
private final FMLEventChannel ec;
|
||||||
private final String myChannelName;
|
private final String myChannelName;
|
||||||
@@ -55,6 +55,16 @@ public class NetworkHandler
|
|||||||
this.serveHandler = this.createServerSide();
|
this.serveHandler = this.createServerSide();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void init( final String channelName )
|
||||||
|
{
|
||||||
|
instance = new NetworkHandler( channelName );
|
||||||
|
}
|
||||||
|
|
||||||
|
public static NetworkHandler instance()
|
||||||
|
{
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
private IPacketHandler createClientSide()
|
private IPacketHandler createClientSide()
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ public class PacketCompassRequest extends AppEngPacket implements ICompassCallba
|
|||||||
@Override
|
@Override
|
||||||
public void calculatedDirection( final boolean hasResult, final boolean spin, final double radians, final double dist )
|
public void calculatedDirection( final boolean hasResult, final boolean spin, final double radians, final double dist )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendTo( new PacketCompassResponse( this, hasResult, spin, radians ), (EntityPlayerMP) this.talkBackTo );
|
NetworkHandler.instance().sendTo( new PacketCompassResponse( this, hasResult, spin, radians ), (EntityPlayerMP) this.talkBackTo );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ public class PacketLightning extends AppEngPacket
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if( Platform.isClient() && AEConfig.instance.enableEffects )
|
if( Platform.isClient() && AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
final LightningFX fx = new LightningFX( ClientHelper.proxy.getWorld(), this.x, this.y, this.z, 0.0f, 0.0f, 0.0f );
|
final LightningFX fx = new LightningFX( ClientHelper.proxy.getWorld(), this.x, this.y, this.z, 0.0f, 0.0f, 0.0f );
|
||||||
Minecraft.getMinecraft().effectRenderer.addEffect( fx );
|
Minecraft.getMinecraft().effectRenderer.addEffect( fx );
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ final class DimensionData implements IWorldDimensionData, IOnWorldStartable, IOn
|
|||||||
this.storageCellDimensionIDs.add( newStorageCellID );
|
this.storageCellDimensionIDs.add( newStorageCellID );
|
||||||
DimensionManager.registerDimension( newStorageCellID, AppEng.instance().getRegistration().getStorageDimensionType() );
|
DimensionManager.registerDimension( newStorageCellID, AppEng.instance().getRegistration().getStorageDimensionType() );
|
||||||
|
|
||||||
NetworkHandler.instance.sendToAll( new PacketNewStorageDimension( newStorageCellID ) );
|
NetworkHandler.instance().sendToAll( new PacketNewStorageDimension( newStorageCellID ) );
|
||||||
|
|
||||||
final String[] values = new String[this.storageCellDimensionIDs.size()];
|
final String[] values = new String[this.storageCellDimensionIDs.size()];
|
||||||
|
|
||||||
@@ -164,7 +164,7 @@ final class DimensionData implements IWorldDimensionData, IOnWorldStartable, IOn
|
|||||||
{
|
{
|
||||||
for( final TickHandler.PlayerColor pc : TickHandler.INSTANCE.getPlayerColors().values() )
|
for( final TickHandler.PlayerColor pc : TickHandler.INSTANCE.getPlayerColors().values() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToAll( pc.getPacket() );
|
NetworkHandler.instance().sendToAll( pc.getPacket() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+4
-4
@@ -16,7 +16,7 @@
|
|||||||
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package appeng.transformer;
|
package appeng.coremod;
|
||||||
|
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
@@ -64,13 +64,13 @@ public final class AppEngCore extends DummyModContainer implements IFMLLoadingPl
|
|||||||
@Override
|
@Override
|
||||||
public String[] getASMTransformerClass()
|
public String[] getASMTransformerClass()
|
||||||
{
|
{
|
||||||
return new String[] { "appeng.transformer.asm.ASMIntegration" };
|
return new String[] { "appeng.coremod.asm.ASMIntegration" };
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getModContainerClass()
|
public String getModContainerClass()
|
||||||
{
|
{
|
||||||
return "appeng.transformer.AppEngCore";
|
return "appeng.coremod.AppEngCore";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@@ -89,7 +89,7 @@ public final class AppEngCore extends DummyModContainer implements IFMLLoadingPl
|
|||||||
@Override
|
@Override
|
||||||
public String getAccessTransformerClass()
|
public String getAccessTransformerClass()
|
||||||
{
|
{
|
||||||
return "appeng.transformer.asm.ASMTweaker";
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
+2
-2
@@ -16,7 +16,7 @@
|
|||||||
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package appeng.transformer;
|
package appeng.coremod;
|
||||||
|
|
||||||
|
|
||||||
import net.minecraft.client.gui.FontRenderer;
|
import net.minecraft.client.gui.FontRenderer;
|
||||||
@@ -68,7 +68,7 @@ public final class MissingCoreMod extends CustomModLoadingErrorDisplayException
|
|||||||
this.drawCenteredString( fontRenderer, "In a developer environment add the following too your args,", errorScreen.width / 2, offset, COLOR_WHITE );
|
this.drawCenteredString( fontRenderer, "In a developer environment add the following too your args,", errorScreen.width / 2, offset, COLOR_WHITE );
|
||||||
|
|
||||||
offset += SCREEN_OFFSET;
|
offset += SCREEN_OFFSET;
|
||||||
this.drawCenteredString( fontRenderer, "-Dfml.coreMods.load=appeng.transformer.AppEngCore", errorScreen.width / 2, offset, SHADOW_WHITE );
|
this.drawCenteredString( fontRenderer, "-Dfml.coreMods.load=appeng.coremod.AppEngCore", errorScreen.width / 2, offset, SHADOW_WHITE );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
+1
-1
@@ -16,7 +16,7 @@
|
|||||||
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package appeng.transformer.annotations;
|
package appeng.coremod.annotations;
|
||||||
|
|
||||||
|
|
||||||
import java.lang.annotation.ElementType;
|
import java.lang.annotation.ElementType;
|
||||||
+3
-3
@@ -16,7 +16,7 @@
|
|||||||
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
* along with Applied Energistics 2. If not, see <http://www.gnu.org/licenses/lgpl>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package appeng.transformer.asm;
|
package appeng.coremod.asm;
|
||||||
|
|
||||||
|
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
@@ -34,10 +34,10 @@ import org.objectweb.asm.tree.MethodNode;
|
|||||||
import net.minecraft.launchwrapper.IClassTransformer;
|
import net.minecraft.launchwrapper.IClassTransformer;
|
||||||
import net.minecraftforge.fml.relauncher.FMLRelaunchLog;
|
import net.minecraftforge.fml.relauncher.FMLRelaunchLog;
|
||||||
|
|
||||||
|
import appeng.coremod.annotations.Integration;
|
||||||
import appeng.helpers.Reflected;
|
import appeng.helpers.Reflected;
|
||||||
import appeng.integration.IntegrationRegistry;
|
import appeng.integration.IntegrationRegistry;
|
||||||
import appeng.integration.IntegrationType;
|
import appeng.integration.IntegrationType;
|
||||||
import appeng.transformer.annotations.Integration;
|
|
||||||
|
|
||||||
|
|
||||||
@Reflected
|
@Reflected
|
||||||
@@ -71,7 +71,7 @@ public final class ASMIntegration implements IClassTransformer
|
|||||||
@Override
|
@Override
|
||||||
public byte[] transform( final String name, final String transformedName, final byte[] basicClass )
|
public byte[] transform( final String name, final String transformedName, final byte[] basicClass )
|
||||||
{
|
{
|
||||||
if( basicClass == null || transformedName.startsWith( "appeng.transformer" ) )
|
if( basicClass == null || transformedName.startsWith( "appeng.coremod" ) )
|
||||||
{
|
{
|
||||||
return basicClass;
|
return basicClass;
|
||||||
}
|
}
|
||||||
@@ -64,7 +64,7 @@ public final class BlockChargedQuartzOre extends BlockQuartzOre
|
|||||||
@SideOnly( Side.CLIENT )
|
@SideOnly( Side.CLIENT )
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ public class BlockQuartzLamp extends BlockQuartzGlass
|
|||||||
@SideOnly( Side.CLIENT )
|
@SideOnly( Side.CLIENT )
|
||||||
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
public void randomDisplayTick( final IBlockState state, final World w, final BlockPos pos, final Random r )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.enableEffects )
|
if( !AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -64,12 +64,12 @@ public final class EntityChargedQuartz extends AEBaseEntityItem
|
|||||||
{
|
{
|
||||||
super.onUpdate();
|
super.onUpdate();
|
||||||
|
|
||||||
if( !AEConfig.instance.isFeatureEnabled( AEFeature.InWorldFluix ) )
|
if( !AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_FLUIX ) )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( Platform.isClient() && this.delay > 30 && AEConfig.instance.enableEffects )
|
if( Platform.isClient() && this.delay > 30 && AEConfig.instance().isEnableEffects() )
|
||||||
{
|
{
|
||||||
CommonHelper.proxy.spawnEffect( EffectType.Lightning, this.worldObj, this.posX, this.posY, this.posZ, null );
|
CommonHelper.proxy.spawnEffect( EffectType.Lightning, this.worldObj, this.posX, this.posY, this.posZ, null );
|
||||||
this.delay = 0;
|
this.delay = 0;
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ public final class EntityGrowingCrystal extends EntityItem
|
|||||||
{
|
{
|
||||||
super.onUpdate();
|
super.onUpdate();
|
||||||
|
|
||||||
if( !AEConfig.instance.isFeatureEnabled( AEFeature.InWorldPurification ) )
|
if( !AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_PURIFICATION ) )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ public final class EntitySingularity extends AEBaseEntityItem
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !AEConfig.instance.isFeatureEnabled( AEFeature.InWorldSingularity ) )
|
if( !AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_SINGULARITY ) )
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -141,7 +141,7 @@ public final class EntityTinyTNTPrimed extends EntityTNTPrimed implements IEntit
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.TinyTNTBlockDamage ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.TINY_TNT_BLOCK_DAMAGE ) )
|
||||||
{
|
{
|
||||||
this.posY -= 0.25;
|
this.posY -= 0.25;
|
||||||
final Explosion ex = new Explosion( this.worldObj, this, this.posX, this.posY, this.posZ, 0.2f, false, false );
|
final Explosion ex = new Explosion( this.worldObj, this, this.posX, this.posY, this.posZ, 0.2f, false, false );
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ public class CompassManager
|
|||||||
|
|
||||||
private void requestUpdate( final CompassRequest r )
|
private void requestUpdate( final CompassRequest r )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketCompassRequest( r.attunement, r.cx, r.cz, r.cdy ) );
|
NetworkHandler.instance().sendToServer( new PacketCompassRequest( r.attunement, r.cx, r.cz, r.cdy ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
private static class CompassRequest
|
private static class CompassRequest
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ public class TickHandler
|
|||||||
final Collection<CraftingJob> jobSet = this.craftingJobs.get( wte.world );
|
final Collection<CraftingJob> jobSet = this.craftingJobs.get( wte.world );
|
||||||
if( !jobSet.isEmpty() )
|
if( !jobSet.isEmpty() )
|
||||||
{
|
{
|
||||||
final int simTime = Math.max( 1, AEConfig.instance.craftingCalculationTimePerTick / jobSet.size() );
|
final int simTime = Math.max( 1, AEConfig.instance().getCraftingCalculationTimePerTick() / jobSet.size() );
|
||||||
final Iterator<CraftingJob> i = jobSet.iterator();
|
final Iterator<CraftingJob> i = jobSet.iterator();
|
||||||
while( i.hasNext() )
|
while( i.hasNext() )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -80,8 +80,8 @@ final class IntegrationNode
|
|||||||
final ModAPIManager apiManager = ModAPIManager.INSTANCE;
|
final ModAPIManager apiManager = ModAPIManager.INSTANCE;
|
||||||
boolean enabled = this.modID == null || Loader.isModLoaded( this.modID ) || apiManager.hasAPI( this.modID );
|
boolean enabled = this.modID == null || Loader.isModLoaded( this.modID ) || apiManager.hasAPI( this.modID );
|
||||||
|
|
||||||
AEConfig.instance.addCustomCategoryComment( "ModIntegration", "Valid Values are 'AUTO', 'ON', or 'OFF' - defaults to 'AUTO' ; Suggested that you leave this alone unless your experiencing an issue, or wish to disable the integration for a reason." );
|
AEConfig.instance().addCustomCategoryComment( "ModIntegration", "Valid Values are 'AUTO', 'ON', or 'OFF' - defaults to 'AUTO' ; Suggested that you leave this alone unless your experiencing an issue, or wish to disable the integration for a reason." );
|
||||||
final String mode = AEConfig.instance.get( "ModIntegration", this.displayName.replace( " ", "" ), "AUTO" ).getString();
|
final String mode = AEConfig.instance().get( "ModIntegration", this.displayName.replace( " ", "" ), "AUTO" ).getString();
|
||||||
|
|
||||||
if( mode.toUpperCase().equals( "ON" ) )
|
if( mode.toUpperCase().equals( "ON" ) )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ public class JEIPlugin extends BlankModPlugin
|
|||||||
IMaterials materials = definitions.materials();
|
IMaterials materials = definitions.materials();
|
||||||
|
|
||||||
final String message;
|
final String message;
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.CertusQuartzWorldGen ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.CERTUS_QUARTZ_WORLD_GEN ) )
|
||||||
{
|
{
|
||||||
message = GuiText.ChargedQuartz.getLocal() + "\n\n" + GuiText.ChargedQuartzFind.getLocal();
|
message = GuiText.ChargedQuartz.getLocal() + "\n\n" + GuiText.ChargedQuartzFind.getLocal();
|
||||||
}
|
}
|
||||||
@@ -89,24 +89,24 @@ public class JEIPlugin extends BlankModPlugin
|
|||||||
}
|
}
|
||||||
addDescription( registry, materials.certusQuartzCrystalCharged(), message );
|
addDescription( registry, materials.certusQuartzCrystalCharged(), message );
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.MeteoriteWorldGen ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.METEORITE_WORLD_GEN ) )
|
||||||
{
|
{
|
||||||
addDescription( registry, materials.logicProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
addDescription( registry, materials.logicProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
||||||
addDescription( registry, materials.calcProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
addDescription( registry, materials.calcProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
||||||
addDescription( registry, materials.engProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
addDescription( registry, materials.engProcessorPress(), GuiText.inWorldCraftingPresses.getLocal() );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.InWorldFluix ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_FLUIX ) )
|
||||||
{
|
{
|
||||||
addDescription( registry, materials.fluixCrystal(), GuiText.inWorldFluix.getLocal() );
|
addDescription( registry, materials.fluixCrystal(), GuiText.inWorldFluix.getLocal() );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.InWorldSingularity ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_SINGULARITY ) )
|
||||||
{
|
{
|
||||||
addDescription( registry, materials.qESingularity(), GuiText.inWorldSingularity.getLocal() );
|
addDescription( registry, materials.qESingularity(), GuiText.inWorldSingularity.getLocal() );
|
||||||
}
|
}
|
||||||
|
|
||||||
if( AEConfig.instance.isFeatureEnabled( AEFeature.InWorldPurification ) )
|
if( AEConfig.instance().isFeatureEnabled( AEFeature.IN_WORLD_PURIFICATION ) )
|
||||||
{
|
{
|
||||||
addDescription( registry, materials.purifiedCertusQuartzCrystal(), GuiText.inWorldPurificationCertus.getLocal() );
|
addDescription( registry, materials.purifiedCertusQuartzCrystal(), GuiText.inWorldPurificationCertus.getLocal() );
|
||||||
addDescription( registry, materials.purifiedNetherQuartzCrystal(), GuiText.inWorldPurificationNether.getLocal() );
|
addDescription( registry, materials.purifiedNetherQuartzCrystal(), GuiText.inWorldPurificationNether.getLocal() );
|
||||||
|
|||||||
@@ -131,7 +131,7 @@ class RecipeTransferHandler<T extends Container> implements IRecipeTransferHandl
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketJEIRecipe( recipe ) );
|
NetworkHandler.instance().sendToServer( new PacketJEIRecipe( recipe ) );
|
||||||
}
|
}
|
||||||
catch( IOException e )
|
catch( IOException e )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ class ShapedRecipeWrapper extends BlankRecipeWrapper implements IShapedCraftingR
|
|||||||
@Override
|
@Override
|
||||||
public void getIngredients( IIngredients ingredients )
|
public void getIngredients( IIngredients ingredients )
|
||||||
{
|
{
|
||||||
final boolean useSingleItems = AEConfig.instance.disableColoredCableRecipesInJEI();
|
final boolean useSingleItems = AEConfig.instance().disableColoredCableRecipesInJEI();
|
||||||
|
|
||||||
Object[] items = recipe.getIngredients();
|
Object[] items = recipe.getIngredients();
|
||||||
int width = recipe.getWidth();
|
int width = recipe.getWidth();
|
||||||
|
|||||||
@@ -172,10 +172,10 @@ public final class ItemMaterial extends AEBaseItem implements IStorageComponent,
|
|||||||
|
|
||||||
for( final AEFeature f : mat.getFeature() )
|
for( final AEFeature f : mat.getFeature() )
|
||||||
{
|
{
|
||||||
enabled = enabled && AEConfig.instance.isFeatureEnabled( f );
|
enabled = enabled && AEConfig.instance().isFeatureEnabled( f );
|
||||||
}
|
}
|
||||||
|
|
||||||
mat.setStackSrc( new MaterialStackSrc( mat ) );
|
mat.setStackSrc( new MaterialStackSrc( mat, enabled ) );
|
||||||
|
|
||||||
if( enabled )
|
if( enabled )
|
||||||
{
|
{
|
||||||
@@ -228,7 +228,7 @@ public final class ItemMaterial extends AEBaseItem implements IStorageComponent,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( replacement == null || AEConfig.instance.useAEVersion( mt ) )
|
if( replacement == null || AEConfig.instance().useAEVersion( mt ) )
|
||||||
{
|
{
|
||||||
// continue using the AE2 item.
|
// continue using the AE2 item.
|
||||||
for( final String name : names )
|
for( final String name : names )
|
||||||
@@ -339,7 +339,8 @@ public final class ItemMaterial extends AEBaseItem implements IStorageComponent,
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
eqi = droppedEntity.getConstructor( World.class, double.class, double.class, double.class, ItemStack.class ).newInstance( w, location.posX, location.posY, location.posZ, itemstack );
|
eqi = droppedEntity.getConstructor( World.class, double.class, double.class, double.class, ItemStack.class ).newInstance( w, location.posX,
|
||||||
|
location.posY, location.posZ, itemstack );
|
||||||
}
|
}
|
||||||
catch( final Throwable t )
|
catch( final Throwable t )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ package appeng.items.materials;
|
|||||||
|
|
||||||
|
|
||||||
import java.util.EnumSet;
|
import java.util.EnumSet;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
@@ -38,85 +39,85 @@ import appeng.entity.EntitySingularity;
|
|||||||
|
|
||||||
public enum MaterialType
|
public enum MaterialType
|
||||||
{
|
{
|
||||||
InvalidType( -1, "material_invalid_type", AEFeature.Core ),
|
InvalidType( -1, "material_invalid_type" ),
|
||||||
|
|
||||||
CertusQuartzCrystal( 0, "material_certus_quartz_crystal", AEFeature.Core, "crystalCertusQuartz" ),
|
CertusQuartzCrystal( 0, "material_certus_quartz_crystal", EnumSet.of( AEFeature.CERTUS ), "crystalCertusQuartz" ),
|
||||||
CertusQuartzCrystalCharged( 1, "material_certus_quartz_crystal_charged", AEFeature.Core, EntityChargedQuartz.class ),
|
CertusQuartzCrystalCharged( 1, "material_certus_quartz_crystal_charged", EnumSet.of( AEFeature.CERTUS ), EntityChargedQuartz.class ),
|
||||||
|
|
||||||
CertusQuartzDust( 2, "material_certus_quartz_dust", AEFeature.Core, "dustCertusQuartz" ),
|
CertusQuartzDust( 2, "material_certus_quartz_dust", EnumSet.of( AEFeature.DUSTS, AEFeature.CERTUS ), "dustCertusQuartz" ),
|
||||||
NetherQuartzDust( 3, "material_nether_quartz_dust", AEFeature.Core, "dustNetherQuartz" ),
|
NetherQuartzDust( 3, "material_nether_quartz_dust", EnumSet.of( AEFeature.DUSTS ), "dustNetherQuartz" ),
|
||||||
Flour( 4, "material_flour", AEFeature.Flour, "dustWheat" ),
|
Flour( 4, "material_flour", EnumSet.of( AEFeature.FLOUR ), "dustWheat" ),
|
||||||
GoldDust( 51, "material_gold_dust", AEFeature.Core, "dustGold" ),
|
GoldDust( 51, "material_gold_dust", EnumSet.of( AEFeature.DUSTS ), "dustGold" ),
|
||||||
IronDust( 49, "material_iron_dust", AEFeature.Core, "dustIron" ),
|
IronDust( 49, "material_iron_dust", EnumSet.of( AEFeature.DUSTS ), "dustIron" ),
|
||||||
IronNugget( 50, "material_iron_nugget", AEFeature.Core, "nuggetIron" ),
|
IronNugget( 50, "material_iron_nugget", EnumSet.of( AEFeature.NUGGETS ), "nuggetIron" ),
|
||||||
|
|
||||||
Silicon( 5, "material_silicon", AEFeature.Core, "itemSilicon" ),
|
Silicon( 5, "material_silicon", EnumSet.of( AEFeature.SILICON ), "itemSilicon" ),
|
||||||
MatterBall( 6, "material_matter_ball" ),
|
MatterBall( 6, "material_matter_ball", EnumSet.of( AEFeature.MATTER_BALL ) ),
|
||||||
|
|
||||||
FluixCrystal( 7, "material_fluix_crystal", AEFeature.Core, "crystalFluix" ),
|
FluixCrystal( 7, "material_fluix_crystal", EnumSet.of( AEFeature.FLUIX ), "crystalFluix" ),
|
||||||
FluixDust( 8, "material_fluix_dust", AEFeature.Core, "dustFluix" ),
|
FluixDust( 8, "material_fluix_dust", EnumSet.of( AEFeature.FLUIX, AEFeature.DUSTS ), "dustFluix" ),
|
||||||
FluixPearl( 9, "material_fluix_pearl", AEFeature.Core, "pearlFluix" ),
|
FluixPearl( 9, "material_fluix_pearl", EnumSet.of( AEFeature.FLUIX ), "pearlFluix" ),
|
||||||
|
|
||||||
PurifiedCertusQuartzCrystal( 10, "material_purified_certus_quartz_crystal" ),
|
PurifiedCertusQuartzCrystal( 10, "material_purified_certus_quartz_crystal", EnumSet.of( AEFeature.CERTUS, AEFeature.PURE_CRYSTALS ) ),
|
||||||
PurifiedNetherQuartzCrystal( 11, "material_purified_nether_quartz_crystal" ),
|
PurifiedNetherQuartzCrystal( 11, "material_purified_nether_quartz_crystal", EnumSet.of( AEFeature.PURE_CRYSTALS ) ),
|
||||||
PurifiedFluixCrystal( 12, "material_purified_fluix_crystal" ),
|
PurifiedFluixCrystal( 12, "material_purified_fluix_crystal", EnumSet.of( AEFeature.FLUIX, AEFeature.PURE_CRYSTALS ) ),
|
||||||
|
|
||||||
CalcProcessorPress( 13, "material_calc_processor_press" ),
|
CalcProcessorPress( 13, "material_calc_processor_press", EnumSet.of( AEFeature.PRESSES ) ),
|
||||||
EngProcessorPress( 14, "material_eng_processor_press" ),
|
EngProcessorPress( 14, "material_eng_processor_press", EnumSet.of( AEFeature.PRESSES ) ),
|
||||||
LogicProcessorPress( 15, "material_logic_processor_press" ),
|
LogicProcessorPress( 15, "material_logic_processor_press", EnumSet.of( AEFeature.PRESSES ) ),
|
||||||
|
|
||||||
CalcProcessorPrint( 16, "material_calc_processor_print" ),
|
CalcProcessorPrint( 16, "material_calc_processor_print", EnumSet.of( AEFeature.PRINTED_CIRCUITS ) ),
|
||||||
EngProcessorPrint( 17, "material_eng_processor_print" ),
|
EngProcessorPrint( 17, "material_eng_processor_print", EnumSet.of( AEFeature.PRINTED_CIRCUITS ) ),
|
||||||
LogicProcessorPrint( 18, "material_logic_processor_print" ),
|
LogicProcessorPrint( 18, "material_logic_processor_print", EnumSet.of( AEFeature.PRINTED_CIRCUITS ) ),
|
||||||
|
|
||||||
SiliconPress( 19, "material_silicon_press" ),
|
SiliconPress( 19, "material_silicon_press", EnumSet.of( AEFeature.PRESSES ) ),
|
||||||
SiliconPrint( 20, "material_silicon_print" ),
|
SiliconPrint( 20, "material_silicon_print", EnumSet.of( AEFeature.PRINTED_CIRCUITS ) ),
|
||||||
|
|
||||||
NamePress( 21, "material_name_press" ),
|
NamePress( 21, "material_name_press", EnumSet.of( AEFeature.PRESSES ) ),
|
||||||
|
|
||||||
LogicProcessor( 22, "material_logic_processor" ),
|
LogicProcessor( 22, "material_logic_processor", EnumSet.of( AEFeature.PROCESSORS ) ),
|
||||||
CalcProcessor( 23, "material_calc_processor" ),
|
CalcProcessor( 23, "material_calc_processor", EnumSet.of( AEFeature.PROCESSORS ) ),
|
||||||
EngProcessor( 24, "material_eng_processor" ),
|
EngProcessor( 24, "material_eng_processor", EnumSet.of( AEFeature.PROCESSORS ) ),
|
||||||
|
|
||||||
// Basic Cards
|
// Basic Cards
|
||||||
BasicCard( 25, "material_basic_card" ),
|
BasicCard( 25, "material_basic_card", EnumSet.of( AEFeature.BASIC_CARDS ) ),
|
||||||
CardRedstone( 26, "material_card_redstone" ),
|
CardRedstone( 26, "material_card_redstone", EnumSet.of( AEFeature.BASIC_CARDS ) ),
|
||||||
CardCapacity( 27, "material_card_capacity" ),
|
CardCapacity( 27, "material_card_capacity", EnumSet.of( AEFeature.BASIC_CARDS ) ),
|
||||||
|
|
||||||
// Adv Cards
|
// Adv Cards
|
||||||
AdvCard( 28, "material_adv_card" ),
|
AdvCard( 28, "material_adv_card", EnumSet.of( AEFeature.ADVANCED_CARDS ) ),
|
||||||
CardFuzzy( 29, "material_card_fuzzy" ),
|
CardFuzzy( 29, "material_card_fuzzy", EnumSet.of( AEFeature.ADVANCED_CARDS ) ),
|
||||||
CardSpeed( 30, "material_card_speed" ),
|
CardSpeed( 30, "material_card_speed", EnumSet.of( AEFeature.ADVANCED_CARDS ) ),
|
||||||
CardInverter( 31, "material_card_inverter" ),
|
CardInverter( 31, "material_card_inverter", EnumSet.of( AEFeature.ADVANCED_CARDS ) ),
|
||||||
|
|
||||||
Cell2SpatialPart( 32, "material_cell2_spatial_part", AEFeature.SpatialIO ),
|
Cell2SpatialPart( 32, "material_cell2_spatial_part", EnumSet.of( AEFeature.SPATIAL_IO ) ),
|
||||||
Cell16SpatialPart( 33, "material_cell16_spatial_part", AEFeature.SpatialIO ),
|
Cell16SpatialPart( 33, "material_cell16_spatial_part", EnumSet.of( AEFeature.SPATIAL_IO ) ),
|
||||||
Cell128SpatialPart( 34, "material_cell128_spatial_part", AEFeature.SpatialIO ),
|
Cell128SpatialPart( 34, "material_cell128_spatial_part", EnumSet.of( AEFeature.SPATIAL_IO ) ),
|
||||||
|
|
||||||
Cell1kPart( 35, "material_cell1k_part", AEFeature.StorageCells ),
|
Cell1kPart( 35, "material_cell1k_part", EnumSet.of( AEFeature.STORAGE_CELLS ) ),
|
||||||
Cell4kPart( 36, "material_cell4k_part", AEFeature.StorageCells ),
|
Cell4kPart( 36, "material_cell4k_part", EnumSet.of( AEFeature.STORAGE_CELLS ) ),
|
||||||
Cell16kPart( 37, "material_cell16k_part", AEFeature.StorageCells ),
|
Cell16kPart( 37, "material_cell16k_part", EnumSet.of( AEFeature.STORAGE_CELLS ) ),
|
||||||
Cell64kPart( 38, "material_cell64k_part", AEFeature.StorageCells ),
|
Cell64kPart( 38, "material_cell64k_part", EnumSet.of( AEFeature.STORAGE_CELLS ) ),
|
||||||
EmptyStorageCell( 39, "material_empty_storage_cell", AEFeature.StorageCells ),
|
EmptyStorageCell( 39, "material_empty_storage_cell", EnumSet.of( AEFeature.STORAGE_CELLS ) ),
|
||||||
|
|
||||||
WoodenGear( 40, "material_wooden_gear", AEFeature.GrindStone, "gearWood" ),
|
WoodenGear( 40, "material_wooden_gear", EnumSet.of( AEFeature.GRIND_STONE ), "gearWood" ),
|
||||||
|
|
||||||
Wireless( 41, "material_wireless", AEFeature.WirelessAccessTerminal ),
|
Wireless( 41, "material_wireless", EnumSet.of( AEFeature.WIRELESS_ACCESS_TERMINAL ) ),
|
||||||
WirelessBooster( 42, "material_wireless_booster", AEFeature.WirelessAccessTerminal ),
|
WirelessBooster( 42, "material_wireless_booster", EnumSet.of( AEFeature.WIRELESS_ACCESS_TERMINAL ) ),
|
||||||
|
|
||||||
FormationCore( 43, "material_formation_core" ),
|
FormationCore( 43, "material_formation_core", EnumSet.of( AEFeature.CORES ) ),
|
||||||
AnnihilationCore( 44, "material_annihilation_core" ),
|
AnnihilationCore( 44, "material_annihilation_core", EnumSet.of( AEFeature.CORES ) ),
|
||||||
|
|
||||||
SkyDust( 45, "material_sky_dust", AEFeature.Core ),
|
SkyDust( 45, "material_sky_dust", EnumSet.of( AEFeature.DUSTS ) ),
|
||||||
|
|
||||||
EnderDust( 46, "material_ender_dust", AEFeature.QuantumNetworkBridge, "dustEnder,dustEnderPearl", EntitySingularity.class ),
|
EnderDust( 46, "material_ender_dust", EnumSet.of( AEFeature.QUANTUM_NETWORK_BRIDGE ), "dustEnder,dustEnderPearl", EntitySingularity.class ),
|
||||||
Singularity( 47, "material_singularity", AEFeature.QuantumNetworkBridge, EntitySingularity.class ),
|
Singularity( 47, "material_singularity", EnumSet.of( AEFeature.QUANTUM_NETWORK_BRIDGE ), EntitySingularity.class ),
|
||||||
QESingularity( 48, "material_qesingularity", AEFeature.QuantumNetworkBridge, EntitySingularity.class ),
|
QESingularity( 48, "material_qesingularity", EnumSet.of( AEFeature.QUANTUM_NETWORK_BRIDGE ), EntitySingularity.class ),
|
||||||
|
|
||||||
BlankPattern( 52, "material_blank_pattern" ),
|
BlankPattern( 52, "material_blank_pattern", EnumSet.of( AEFeature.PATTERNS ) ),
|
||||||
CardCrafting( 53, "material_card_crafting" );
|
CardCrafting( 53, "material_card_crafting", EnumSet.of( AEFeature.ADVANCED_CARDS, AEFeature.CRAFTING_CPU ) );
|
||||||
|
|
||||||
private final EnumSet<AEFeature> features;
|
private final Set<AEFeature> features;
|
||||||
private final ModelResourceLocation model;
|
private final ModelResourceLocation model;
|
||||||
private Item itemInstance;
|
private Item itemInstance;
|
||||||
private int damageValue;
|
private int damageValue;
|
||||||
@@ -128,35 +129,37 @@ public enum MaterialType
|
|||||||
|
|
||||||
MaterialType( final int metaValue, String modelName )
|
MaterialType( final int metaValue, String modelName )
|
||||||
{
|
{
|
||||||
this( metaValue, modelName, AEFeature.Core );
|
this( metaValue, modelName, EnumSet.of( AEFeature.CORE ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
MaterialType( final int metaValue, String modelName, final AEFeature part )
|
MaterialType( final int metaValue, String modelName, final Set<AEFeature> features )
|
||||||
{
|
{
|
||||||
this.setDamageValue( metaValue );
|
this.setDamageValue( metaValue );
|
||||||
this.features = EnumSet.of( part );
|
this.features = features;
|
||||||
this.model = new ModelResourceLocation( new ResourceLocation( AppEng.MOD_ID, modelName ), "inventory" );
|
this.model = new ModelResourceLocation( new ResourceLocation( AppEng.MOD_ID, modelName ), "inventory" );
|
||||||
}
|
}
|
||||||
|
|
||||||
MaterialType( final int metaValue, String modelName, final AEFeature part, final Class<? extends Entity> c )
|
MaterialType( final int metaValue, String modelName, final Set<AEFeature> features, final Class<? extends Entity> c )
|
||||||
{
|
{
|
||||||
this( metaValue, modelName, part );
|
this( metaValue, modelName, features );
|
||||||
this.droppedEntity = c;
|
this.droppedEntity = c;
|
||||||
|
|
||||||
EntityRegistry.registerModEntity( this.droppedEntity, this.droppedEntity.getSimpleName(), EntityIds.get( this.droppedEntity ), AppEng.instance(), 16, 4, true );
|
EntityRegistry.registerModEntity( this.droppedEntity, this.droppedEntity.getSimpleName(), EntityIds.get( this.droppedEntity ), AppEng.instance(), 16, 4,
|
||||||
|
true );
|
||||||
}
|
}
|
||||||
|
|
||||||
MaterialType( final int metaValue, String modelName, final AEFeature part, final String oreDictionary, final Class<? extends Entity> c )
|
MaterialType( final int metaValue, String modelName, final Set<AEFeature> features, final String oreDictionary, final Class<? extends Entity> c )
|
||||||
{
|
{
|
||||||
this( metaValue, modelName, part );
|
this( metaValue, modelName, features );
|
||||||
this.oreName = oreDictionary;
|
this.oreName = oreDictionary;
|
||||||
this.droppedEntity = c;
|
this.droppedEntity = c;
|
||||||
EntityRegistry.registerModEntity( this.droppedEntity, this.droppedEntity.getSimpleName(), EntityIds.get( this.droppedEntity ), AppEng.instance(), 16, 4, true );
|
EntityRegistry.registerModEntity( this.droppedEntity, this.droppedEntity.getSimpleName(), EntityIds.get( this.droppedEntity ), AppEng.instance(), 16, 4,
|
||||||
|
true );
|
||||||
}
|
}
|
||||||
|
|
||||||
MaterialType( final int metaValue, String modelName, final AEFeature part, final String oreDictionary )
|
MaterialType( final int metaValue, String modelName, final Set<AEFeature> features, final String oreDictionary )
|
||||||
{
|
{
|
||||||
this( metaValue, modelName, part );
|
this( metaValue, modelName, features );
|
||||||
this.oreName = oreDictionary;
|
this.oreName = oreDictionary;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -165,7 +168,7 @@ public enum MaterialType
|
|||||||
return new ItemStack( this.getItemInstance(), size, this.getDamageValue() );
|
return new ItemStack( this.getItemInstance(), size, this.getDamageValue() );
|
||||||
}
|
}
|
||||||
|
|
||||||
EnumSet<AEFeature> getFeature()
|
Set<AEFeature> getFeature()
|
||||||
{
|
{
|
||||||
return this.features;
|
return this.features;
|
||||||
}
|
}
|
||||||
@@ -225,7 +228,8 @@ public enum MaterialType
|
|||||||
this.stackSrc = stackSrc;
|
this.stackSrc = stackSrc;
|
||||||
}
|
}
|
||||||
|
|
||||||
public ModelResourceLocation getModel() {
|
public ModelResourceLocation getModel()
|
||||||
|
{
|
||||||
return model;
|
return model;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -133,9 +133,9 @@ public class ItemFacade extends AEBaseItem implements IFacadeItem, IAlphaPassIte
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( FacadeConfig.instance.hasChanged() )
|
if( FacadeConfig.instance().hasChanged() )
|
||||||
{
|
{
|
||||||
FacadeConfig.instance.save();
|
FacadeConfig.instance().save();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -183,7 +183,7 @@ public class ItemFacade extends AEBaseItem implements IFacadeItem, IAlphaPassIte
|
|||||||
}
|
}
|
||||||
|
|
||||||
final boolean defaultValue = ( b.isFullyOpaque( blockState ) && hasSimpleModel( blockState ) && !b.getTickRandomly() && !hasTile && !disableOre ) || enableGlass;
|
final boolean defaultValue = ( b.isFullyOpaque( blockState ) && hasSimpleModel( blockState ) && !b.getTickRandomly() && !hasTile && !disableOre ) || enableGlass;
|
||||||
if( FacadeConfig.instance.checkEnabled( b, metadata, defaultValue ) )
|
if( FacadeConfig.instance().checkEnabled( b, metadata, defaultValue ) )
|
||||||
{
|
{
|
||||||
if( returnItem )
|
if( returnItem )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -79,9 +79,9 @@ import appeng.util.Platform;
|
|||||||
|
|
||||||
public enum PartType
|
public enum PartType
|
||||||
{
|
{
|
||||||
InvalidType( -1, "invalid" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), null ),
|
InvalidType( -1, "invalid", EnumSet.of( AEFeature.CORE ), EnumSet.noneOf( IntegrationType.class ), null ),
|
||||||
|
|
||||||
CableGlass( 0, "cable_glass" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartCableGlass.class )
|
CableGlass( 0, "cable_glass", EnumSet.of( AEFeature.GLASS_CABLES ), EnumSet.noneOf( IntegrationType.class ), PartCableGlass.class )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
public boolean isCable()
|
public boolean isCable()
|
||||||
@@ -95,11 +95,11 @@ public enum PartType
|
|||||||
{
|
{
|
||||||
return Arrays.stream( AEColor.values() )
|
return Arrays.stream( AEColor.values() )
|
||||||
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
||||||
.collect( Collectors.toList());
|
.collect( Collectors.toList() );
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
CableCovered( 20, "cable_covered" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartCableCovered.class )
|
CableCovered( 20, "cable_covered", EnumSet.of( AEFeature.COVERED_CABLES ), EnumSet.noneOf( IntegrationType.class ), PartCableCovered.class )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
public boolean isCable()
|
public boolean isCable()
|
||||||
@@ -113,11 +113,11 @@ public enum PartType
|
|||||||
{
|
{
|
||||||
return Arrays.stream( AEColor.values() )
|
return Arrays.stream( AEColor.values() )
|
||||||
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
||||||
.collect( Collectors.toList());
|
.collect( Collectors.toList() );
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
CableSmart( 40, "cable_smart" , EnumSet.of( AEFeature.Channels ), EnumSet.noneOf( IntegrationType.class ), PartCableSmart.class )
|
CableSmart( 40, "cable_smart", EnumSet.of( AEFeature.CHANNELS, AEFeature.SMART_CABLES ), EnumSet.noneOf( IntegrationType.class ), PartCableSmart.class )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
public boolean isCable()
|
public boolean isCable()
|
||||||
@@ -131,11 +131,11 @@ public enum PartType
|
|||||||
{
|
{
|
||||||
return Arrays.stream( AEColor.values() )
|
return Arrays.stream( AEColor.values() )
|
||||||
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
||||||
.collect( Collectors.toList());
|
.collect( Collectors.toList() );
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
CableDense( 60, "cable_dense" , EnumSet.of( AEFeature.Channels ), EnumSet.noneOf( IntegrationType.class ), PartDenseCable.class )
|
CableDense( 60, "cable_dense", EnumSet.of( AEFeature.CHANNELS, AEFeature.DENSE_CABLES ), EnumSet.noneOf( IntegrationType.class ), PartDenseCable.class )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
public boolean isCable()
|
public boolean isCable()
|
||||||
@@ -149,51 +149,56 @@ public enum PartType
|
|||||||
{
|
{
|
||||||
return Arrays.stream( AEColor.values() )
|
return Arrays.stream( AEColor.values() )
|
||||||
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
.map( color -> modelFromBaseName( baseName + "_" + color.name().toLowerCase() ) )
|
||||||
.collect( Collectors.toList());
|
.collect( Collectors.toList() );
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
ToggleBus( 80, "toggle_bus" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartToggleBus.class ),
|
ToggleBus( 80, "toggle_bus", EnumSet.of( AEFeature.TOGGLE_BUS ), EnumSet.noneOf( IntegrationType.class ), PartToggleBus.class ),
|
||||||
|
|
||||||
InvertedToggleBus( 100, "inverted_toggle_bus" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartInvertedToggleBus.class ),
|
InvertedToggleBus( 100, "inverted_toggle_bus", EnumSet.of( AEFeature.TOGGLE_BUS ), EnumSet.noneOf( IntegrationType.class ), PartInvertedToggleBus.class ),
|
||||||
|
|
||||||
CableAnchor( 120, "cable_anchor" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartCableAnchor.class ),
|
CableAnchor( 120, "cable_anchor", EnumSet.of( AEFeature.CABLE_ANCHOR ), EnumSet.noneOf( IntegrationType.class ), PartCableAnchor.class ),
|
||||||
|
|
||||||
QuartzFiber( 140, "quartz_fiber" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartQuartzFiber.class ),
|
QuartzFiber( 140, "quartz_fiber", EnumSet.of( AEFeature.QUARTZ_FIBER ), EnumSet.noneOf( IntegrationType.class ), PartQuartzFiber.class ),
|
||||||
|
|
||||||
Monitor( 160, "monitor" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartPanel.class ),
|
Monitor( 160, "monitor", EnumSet.of( AEFeature.PANELS ), EnumSet.noneOf( IntegrationType.class ), PartPanel.class ),
|
||||||
|
|
||||||
SemiDarkMonitor( 180, "semi_dark_monitor" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartSemiDarkPanel.class ),
|
SemiDarkMonitor( 180, "semi_dark_monitor", EnumSet.of( AEFeature.PANELS ), EnumSet.noneOf( IntegrationType.class ), PartSemiDarkPanel.class ),
|
||||||
|
|
||||||
DarkMonitor( 200, "dark_monitor" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartDarkPanel.class ),
|
DarkMonitor( 200, "dark_monitor", EnumSet.of( AEFeature.PANELS ), EnumSet.noneOf( IntegrationType.class ), PartDarkPanel.class ),
|
||||||
|
|
||||||
StorageBus( 220, "storage_bus" , EnumSet.of( AEFeature.StorageBus ), EnumSet.noneOf( IntegrationType.class ), PartStorageBus.class ),
|
StorageBus( 220, "storage_bus", EnumSet.of( AEFeature.STORAGE_BUS ), EnumSet.noneOf( IntegrationType.class ), PartStorageBus.class ),
|
||||||
|
|
||||||
ImportBus( 240, "import_bus" , EnumSet.of( AEFeature.ImportBus ), EnumSet.noneOf( IntegrationType.class ), PartImportBus.class ),
|
ImportBus( 240, "import_bus", EnumSet.of( AEFeature.IMPORT_BUS ), EnumSet.noneOf( IntegrationType.class ), PartImportBus.class ),
|
||||||
|
|
||||||
ExportBus( 260, "export_bus" , EnumSet.of( AEFeature.ExportBus ), EnumSet.noneOf( IntegrationType.class ), PartExportBus.class ),
|
ExportBus( 260, "export_bus", EnumSet.of( AEFeature.EXPORT_BUS ), EnumSet.noneOf( IntegrationType.class ), PartExportBus.class ),
|
||||||
|
|
||||||
LevelEmitter( 280, "level_emitter" , EnumSet.of( AEFeature.LevelEmitter ), EnumSet.noneOf( IntegrationType.class ), PartLevelEmitter.class ),
|
LevelEmitter( 280, "level_emitter", EnumSet.of( AEFeature.LEVEL_EMITTER ), EnumSet.noneOf( IntegrationType.class ), PartLevelEmitter.class ),
|
||||||
|
|
||||||
AnnihilationPlane( 300, "annihilation_plane" , EnumSet.of( AEFeature.AnnihilationPlane ), EnumSet.noneOf( IntegrationType.class ), PartAnnihilationPlane.class ),
|
AnnihilationPlane( 300, "annihilation_plane", EnumSet.of( AEFeature.ANNIHILATION_PLANE ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartAnnihilationPlane.class ),
|
||||||
|
|
||||||
IdentityAnnihilationPlane( 301, "identity_annihilation_plane" , EnumSet.of( AEFeature.AnnihilationPlane, AEFeature.IdentityAnnihilationPlane ), EnumSet.noneOf( IntegrationType.class ), PartIdentityAnnihilationPlane.class ),
|
IdentityAnnihilationPlane( 301, "identity_annihilation_plane", EnumSet.of( AEFeature.ANNIHILATION_PLANE, AEFeature.IDENTITY_ANNIHILATION_PLANE ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartIdentityAnnihilationPlane.class ),
|
||||||
|
|
||||||
FormationPlane( 320, "formation_plane" , EnumSet.of( AEFeature.FormationPlane ), EnumSet.noneOf( IntegrationType.class ), PartFormationPlane.class ),
|
FormationPlane( 320, "formation_plane", EnumSet.of( AEFeature.FORMATION_PLANE ), EnumSet.noneOf( IntegrationType.class ), PartFormationPlane.class ),
|
||||||
|
|
||||||
PatternTerminal( 340, "pattern_terminal" , EnumSet.of( AEFeature.Patterns ), EnumSet.noneOf( IntegrationType.class ), PartPatternTerminal.class ),
|
PatternTerminal( 340, "pattern_terminal", EnumSet.of( AEFeature.PATTERNS ), EnumSet.noneOf( IntegrationType.class ), PartPatternTerminal.class ),
|
||||||
|
|
||||||
CraftingTerminal( 360, "crafting_terminal" , EnumSet.of( AEFeature.CraftingTerminal ), EnumSet.noneOf( IntegrationType.class ), PartCraftingTerminal.class ),
|
CraftingTerminal( 360, "crafting_terminal", EnumSet.of( AEFeature.CRAFTING_TERMINAL ), EnumSet.noneOf( IntegrationType.class ), PartCraftingTerminal.class ),
|
||||||
|
|
||||||
Terminal( 380, "terminal" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartTerminal.class ),
|
Terminal( 380, "terminal", EnumSet.of( AEFeature.TERMINAL ), EnumSet.noneOf( IntegrationType.class ), PartTerminal.class ),
|
||||||
|
|
||||||
StorageMonitor( 400, "storage_monitor" , EnumSet.of( AEFeature.StorageMonitor ), EnumSet.noneOf( IntegrationType.class ), PartStorageMonitor.class ),
|
StorageMonitor( 400, "storage_monitor", EnumSet.of( AEFeature.STORAGE_MONITOR ), EnumSet.noneOf( IntegrationType.class ), PartStorageMonitor.class ),
|
||||||
|
|
||||||
ConversionMonitor( 420, "conversion_monitor" , EnumSet.of( AEFeature.PartConversionMonitor ), EnumSet.noneOf( IntegrationType.class ), PartConversionMonitor.class ),
|
ConversionMonitor( 420, "conversion_monitor", EnumSet.of( AEFeature.PART_CONVERSION_MONITOR ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartConversionMonitor.class ),
|
||||||
|
|
||||||
Interface( 440, "interface" , EnumSet.of( AEFeature.Core ), EnumSet.noneOf( IntegrationType.class ), PartInterface.class ),
|
Interface( 440, "interface", EnumSet.of( AEFeature.INTERFACE ), EnumSet.noneOf( IntegrationType.class ), PartInterface.class ),
|
||||||
|
|
||||||
P2PTunnelME( 460, "p2p_tunnel_me" , EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelME ), EnumSet.noneOf( IntegrationType.class ), PartP2PTunnelME.class, GuiText.METunnel ) {
|
P2PTunnelME( 460, "p2p_tunnel_me", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_ME ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartP2PTunnelME.class, GuiText.METunnel )
|
||||||
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
@@ -201,7 +206,9 @@ public enum PartType
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
P2PTunnelRedstone( 461, "p2p_tunnel_redstone" , EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelRedstone ), EnumSet.noneOf( IntegrationType.class ), PartP2PRedstone.class, GuiText.RedstoneTunnel ) {
|
P2PTunnelRedstone( 461, "p2p_tunnel_redstone", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_REDSTONE ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartP2PRedstone.class, GuiText.RedstoneTunnel )
|
||||||
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
@@ -209,7 +216,9 @@ public enum PartType
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
P2PTunnelItems( 462, "p2p_tunnel_items" , EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelItems ), EnumSet.noneOf( IntegrationType.class ), PartP2PItems.class, GuiText.ItemTunnel ) {
|
P2PTunnelItems( 462, "p2p_tunnel_items", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_ITEMS ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartP2PItems.class, GuiText.ItemTunnel )
|
||||||
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
@@ -217,7 +226,9 @@ public enum PartType
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
P2PTunnelLiquids( 463, "p2p_tunnel_liquids" , EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelLiquids ), EnumSet.noneOf( IntegrationType.class ), PartP2PLiquids.class, GuiText.FluidTunnel ) {
|
P2PTunnelLiquids( 463, "p2p_tunnel_liquids", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_LIQUIDS ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartP2PLiquids.class, GuiText.FluidTunnel )
|
||||||
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
@@ -225,20 +236,22 @@ public enum PartType
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
P2PTunnelEU( 465, "p2p_tunnel_ic2", EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelEU ), EnumSet.of( IntegrationType.IC2 ),
|
P2PTunnelEU( 465, "p2p_tunnel_ic2", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_EU ), EnumSet
|
||||||
PartP2PIC2Power.class, GuiText.EUTunnel )
|
.of( IntegrationType.IC2 ), PartP2PIC2Power.class, GuiText.EUTunnel )
|
||||||
{
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
return "P2PTunnel";
|
return "P2PTunnel";
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
// P2PTunnelRF( 466, EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelRF ), EnumSet.of( IntegrationType.RF ),
|
// P2PTunnelRF( 466, EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelRF ), EnumSet.of( IntegrationType.RF ),
|
||||||
// PartP2PRFPower.class, GuiText.RFTunnel ),
|
// PartP2PRFPower.class, GuiText.RFTunnel ),
|
||||||
|
|
||||||
P2PTunnelLight( 467, "p2p_tunnel_light" , EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelLight ), EnumSet.noneOf( IntegrationType.class ), PartP2PLight.class, GuiText.LightTunnel ) {
|
P2PTunnelLight( 467, "p2p_tunnel_light", EnumSet.of( AEFeature.P2P_TUNNEL, AEFeature.P2P_TUNNEL_LIGHT ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartP2PLight.class, GuiText.LightTunnel )
|
||||||
|
{
|
||||||
@Override
|
@Override
|
||||||
String getUnlocalizedName()
|
String getUnlocalizedName()
|
||||||
{
|
{
|
||||||
@@ -249,7 +262,8 @@ public enum PartType
|
|||||||
// P2PTunnelOpenComputers( 468, EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelOpenComputers ), EnumSet.of(
|
// P2PTunnelOpenComputers( 468, EnumSet.of( AEFeature.P2PTunnel, AEFeature.P2PTunnelOpenComputers ), EnumSet.of(
|
||||||
// IntegrationType.OpenComputers ), PartP2POpenComputers.class, GuiText.OCTunnel ),
|
// IntegrationType.OpenComputers ), PartP2POpenComputers.class, GuiText.OCTunnel ),
|
||||||
|
|
||||||
InterfaceTerminal( 480, "interface_terminal" , EnumSet.of( AEFeature.InterfaceTerminal ), EnumSet.noneOf( IntegrationType.class ), PartInterfaceTerminal.class );
|
InterfaceTerminal( 480, "interface_terminal", EnumSet.of( AEFeature.INTERFACE_TERMINAL ), EnumSet
|
||||||
|
.noneOf( IntegrationType.class ), PartInterfaceTerminal.class );
|
||||||
|
|
||||||
private final int baseDamage;
|
private final int baseDamage;
|
||||||
private final Set<AEFeature> features;
|
private final Set<AEFeature> features;
|
||||||
@@ -276,8 +290,8 @@ public enum PartType
|
|||||||
this.extraName = en;
|
this.extraName = en;
|
||||||
|
|
||||||
// The part is enabled if all features + integrations it needs are enabled
|
// The part is enabled if all features + integrations it needs are enabled
|
||||||
this.enabled = features.stream().allMatch( AEConfig.instance::isFeatureEnabled )
|
this.enabled = features.stream().allMatch( AEConfig.instance()::isFeatureEnabled ) && integrations.stream()
|
||||||
&& integrations.stream().allMatch( IntegrationRegistry.INSTANCE::isEnabled );
|
.allMatch( IntegrationRegistry.INSTANCE::isEnabled );
|
||||||
|
|
||||||
if( enabled )
|
if( enabled )
|
||||||
{
|
{
|
||||||
@@ -348,7 +362,8 @@ public enum PartType
|
|||||||
return this.myPart;
|
return this.myPart;
|
||||||
}
|
}
|
||||||
|
|
||||||
String getUnlocalizedName() {
|
String getUnlocalizedName()
|
||||||
|
{
|
||||||
return name();
|
return name();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -378,5 +393,4 @@ public enum PartType
|
|||||||
return models;
|
return models;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -296,6 +296,6 @@ public final class ItemBasicStorageCell extends AEBaseItem implements IStorageCe
|
|||||||
@Override
|
@Override
|
||||||
public boolean hasContainerItem( final ItemStack stack )
|
public boolean hasContainerItem( final ItemStack stack )
|
||||||
{
|
{
|
||||||
return AEConfig.instance.isFeatureEnabled( AEFeature.EnableDisassemblyCrafting );
|
return AEConfig.instance().isFeatureEnabled( AEFeature.ENABLE_DISASSEMBLY_CRAFTING );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -98,15 +98,21 @@ public class ToolNetworkTool extends AEBaseItem implements IGuiItem, IAEWrench /
|
|||||||
{
|
{
|
||||||
final RayTraceResult mop = new RayTraceResult( new Vec3d( hitX, hitY, hitZ ), side, pos );
|
final RayTraceResult mop = new RayTraceResult( new Vec3d( hitX, hitY, hitZ ), side, pos );
|
||||||
final TileEntity te = world.getTileEntity( pos );
|
final TileEntity te = world.getTileEntity( pos );
|
||||||
|
|
||||||
if( te instanceof IPartHost )
|
if( te instanceof IPartHost )
|
||||||
{
|
{
|
||||||
final SelectedPart part = ( (IPartHost) te ).selectPart( mop.hitVec );
|
final SelectedPart part = ( (IPartHost) te ).selectPart( mop.hitVec );
|
||||||
if( part.part != null )
|
|
||||||
|
if( part.part != null || part.facade != null )
|
||||||
{
|
{
|
||||||
if( part.part instanceof INetworkToolAgent && !( (INetworkToolAgent) part.part ).showNetworkInfo( mop ) )
|
if( part.part instanceof INetworkToolAgent && !( (INetworkToolAgent) part.part ).showNetworkInfo( mop ) )
|
||||||
{
|
{
|
||||||
return EnumActionResult.FAIL;
|
return EnumActionResult.FAIL;
|
||||||
}
|
}
|
||||||
|
else if( player.isSneaking() )
|
||||||
|
{
|
||||||
|
return EnumActionResult.PASS;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if( te instanceof INetworkToolAgent && !( (INetworkToolAgent) te ).showNetworkInfo( mop ) )
|
else if( te instanceof INetworkToolAgent && !( (INetworkToolAgent) te ).showNetworkInfo( mop ) )
|
||||||
@@ -116,8 +122,9 @@ public class ToolNetworkTool extends AEBaseItem implements IGuiItem, IAEWrench /
|
|||||||
|
|
||||||
if( Platform.isClient() )
|
if( Platform.isClient() )
|
||||||
{
|
{
|
||||||
NetworkHandler.instance.sendToServer( new PacketClick( pos, side, hitX, hitY, hitZ, hand ) );
|
NetworkHandler.instance().sendToServer( new PacketClick( pos, side, hitX, hitY, hitZ, hand ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
return EnumActionResult.SUCCESS;
|
return EnumActionResult.SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ public class ToolChargedStaff extends AEBasePoweredItem
|
|||||||
|
|
||||||
public ToolChargedStaff()
|
public ToolChargedStaff()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.chargedStaffBattery );
|
super( AEConfig.instance().getChargedStaffBattery() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -100,7 +100,7 @@ public class ToolColorApplicator extends AEBasePoweredItem implements IStorageCe
|
|||||||
|
|
||||||
public ToolColorApplicator()
|
public ToolColorApplicator()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.colorApplicatorBattery );
|
super( AEConfig.instance().getColorApplicatorBattery() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ public class ToolEntropyManipulator extends AEBasePoweredItem implements IBlockT
|
|||||||
|
|
||||||
public ToolEntropyManipulator()
|
public ToolEntropyManipulator()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.entropyManipulatorBattery );
|
super( AEConfig.instance().getEntropyManipulatorBattery() );
|
||||||
|
|
||||||
this.heatUp = new HashMap<InWorldToolOperationIngredient, InWorldToolOperationResult>();
|
this.heatUp = new HashMap<InWorldToolOperationIngredient, InWorldToolOperationResult>();
|
||||||
this.coolDown = new HashMap<InWorldToolOperationIngredient, InWorldToolOperationResult>();
|
this.coolDown = new HashMap<InWorldToolOperationIngredient, InWorldToolOperationResult>();
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ public class ToolMatterCannon extends AEBasePoweredItem implements IStorageCell
|
|||||||
|
|
||||||
public ToolMatterCannon()
|
public ToolMatterCannon()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.matterCannonBattery );
|
super( AEConfig.instance().getMatterCannonBattery() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -271,7 +271,7 @@ public class ToolMatterCannon extends AEBasePoweredItem implements IStorageCell
|
|||||||
}
|
}
|
||||||
|
|
||||||
pos.entityHit.attackEntityFrom( DamageSource.causePlayerDamage( p ), 0 );
|
pos.entityHit.attackEntityFrom( DamageSource.causePlayerDamage( p ), 0 );
|
||||||
NetworkHandler.instance.sendToAll( marker.getPacket() );
|
NetworkHandler.instance().sendToAll( marker.getPacket() );
|
||||||
}
|
}
|
||||||
else if( pos.typeOfHit == RayTraceResult.Type.BLOCK )
|
else if( pos.typeOfHit == RayTraceResult.Type.BLOCK )
|
||||||
{
|
{
|
||||||
@@ -401,7 +401,7 @@ public class ToolMatterCannon extends AEBasePoweredItem implements IStorageCell
|
|||||||
}
|
}
|
||||||
else if( pos.typeOfHit == RayTraceResult.Type.BLOCK )
|
else if( pos.typeOfHit == RayTraceResult.Type.BLOCK )
|
||||||
{
|
{
|
||||||
if( !AEConfig.instance.isFeatureEnabled( AEFeature.MassCannonBlockDamage ) )
|
if( !AEConfig.instance().isFeatureEnabled( AEFeature.MASS_CANNON_BLOCK_DAMAGE ) )
|
||||||
{
|
{
|
||||||
penetration = 0;
|
penetration = 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ public class ToolPortableCell extends AEBasePoweredItem implements IStorageCell,
|
|||||||
{
|
{
|
||||||
public ToolPortableCell()
|
public ToolPortableCell()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.portableCellBattery );
|
super( AEConfig.instance().getPortableCellBattery() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ public class ToolWirelessTerminal extends AEBasePoweredItem implements IWireless
|
|||||||
|
|
||||||
public ToolWirelessTerminal()
|
public ToolWirelessTerminal()
|
||||||
{
|
{
|
||||||
super( AEConfig.instance.wirelessTerminalBattery );
|
super( AEConfig.instance().getWirelessTerminalBattery() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
package appeng.items.tools.powered.powersink;
|
package appeng.items.tools.powered.powersink;
|
||||||
|
|
||||||
|
|
||||||
public abstract class AEBasePoweredItem extends AERootPoweredItem
|
public abstract class AEBasePoweredItem extends RedstoneFlux
|
||||||
{
|
{
|
||||||
public AEBasePoweredItem( final double powerCapacity )
|
public AEBasePoweredItem( final double powerCapacity )
|
||||||
{
|
{
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user