Post-Rename Formatting Fixes
This commit is contained in:
@@ -86,7 +86,7 @@ public class FeatureFactory {
|
||||
}
|
||||
|
||||
public <T extends AEBaseTileEntity> TileEntityBuilder<T> tileEntity(String id, Class<T> teClass,
|
||||
Function<TileEntityType<T>, T> factory) {
|
||||
Function<TileEntityType<T>, T> factory) {
|
||||
return new TileEntityBuilder<>(this, id, teClass, factory).features(this.defaultFeatures);
|
||||
}
|
||||
|
||||
|
||||
@@ -60,8 +60,8 @@ import net.minecraftforge.fml.client.gui.GuiUtils;
|
||||
import appeng.api.storage.data.IAEFluidStack;
|
||||
import appeng.api.storage.data.IAEItemStack;
|
||||
import appeng.client.gui.widgets.CustomSlotWidget;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.gui.widgets.ITooltip;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.me.InternalSlotME;
|
||||
import appeng.client.me.SlotDisconnected;
|
||||
import appeng.client.me.SlotME;
|
||||
@@ -70,10 +70,10 @@ import appeng.container.AEBaseContainer;
|
||||
import appeng.container.slot.AppEngCraftingSlot;
|
||||
import appeng.container.slot.AppEngSlot;
|
||||
import appeng.container.slot.AppEngSlot.CalculatedValidity;
|
||||
import appeng.container.slot.IOptionalSlot;
|
||||
import appeng.container.slot.CraftingTermSlot;
|
||||
import appeng.container.slot.DisabledSlot;
|
||||
import appeng.container.slot.FakeSlot;
|
||||
import appeng.container.slot.IOptionalSlot;
|
||||
import appeng.container.slot.InaccessibleSlot;
|
||||
import appeng.container.slot.OutputSlot;
|
||||
import appeng.container.slot.PatternTermSlot;
|
||||
|
||||
@@ -98,8 +98,8 @@ final class AESubScreen {
|
||||
label = previousContainerIcon.getDisplayName().getString();
|
||||
}
|
||||
ItemRenderer itemRenderer = gui.getMinecraft().getItemRenderer();
|
||||
TabButton button = new TabButton(gui.getGuiLeft() + x, gui.getGuiTop() + y, previousContainerIcon,
|
||||
label, itemRenderer, btn -> goBack());
|
||||
TabButton button = new TabButton(gui.getGuiLeft() + x, gui.getGuiTop() + y, previousContainerIcon, label,
|
||||
itemRenderer, btn -> goBack());
|
||||
buttonAdder.accept(button);
|
||||
return button;
|
||||
}
|
||||
|
||||
@@ -42,7 +42,8 @@ public class CellWorkbenchScreen extends UpgradeableScreen<CellWorkbenchContaine
|
||||
|
||||
private ToggleButton copyMode;
|
||||
|
||||
public CellWorkbenchScreen(CellWorkbenchContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public CellWorkbenchScreen(CellWorkbenchContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 251;
|
||||
}
|
||||
@@ -51,12 +52,11 @@ public class CellWorkbenchScreen extends UpgradeableScreen<CellWorkbenchContaine
|
||||
protected void addButtons() {
|
||||
this.fuzzyMode = this.addButton(new SettingToggleButton<>(this.guiLeft - 18, this.guiTop + 68,
|
||||
Settings.FUZZY_MODE, FuzzyMode.IGNORE_ALL, this::toggleFuzzyMode));
|
||||
this.addButton(new ActionButton(this.guiLeft - 18, this.guiTop + 28, ActionItems.WRENCH,
|
||||
act1 -> action("Partition")));
|
||||
this.addButton(
|
||||
new ActionButton(this.guiLeft - 18, this.guiTop + 8, ActionItems.CLOSE, act -> action("Clear")));
|
||||
this.copyMode = this.addButton(new ToggleButton(this.guiLeft - 18, this.guiTop + 48, 11 * 16 + 5,
|
||||
12 * 16 + 5, GuiText.CopyMode.getLocal(), GuiText.CopyModeDesc.getLocal(), act -> action("CopyMode")));
|
||||
new ActionButton(this.guiLeft - 18, this.guiTop + 28, ActionItems.WRENCH, act1 -> action("Partition")));
|
||||
this.addButton(new ActionButton(this.guiLeft - 18, this.guiTop + 8, ActionItems.CLOSE, act -> action("Clear")));
|
||||
this.copyMode = this.addButton(new ToggleButton(this.guiLeft - 18, this.guiTop + 48, 11 * 16 + 5, 12 * 16 + 5,
|
||||
GuiText.CopyMode.getLocal(), GuiText.CopyModeDesc.getLocal(), act -> action("CopyMode")));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -48,8 +48,8 @@ public class CondenserScreen extends AEBaseScreen<CondenserContainer> {
|
||||
this.mode = new ServerSettingToggleButton<>(128 + this.guiLeft, 52 + this.guiTop, Settings.CONDENSER_OUTPUT,
|
||||
this.container.getOutput());
|
||||
|
||||
this.addButton(new ProgressBar(this.container, "guis/condenser.png", 120 + this.guiLeft, 25 + this.guiTop,
|
||||
178, 25, 6, 18, Direction.VERTICAL, GuiText.StoredEnergy.getLocal()));
|
||||
this.addButton(new ProgressBar(this.container, "guis/condenser.png", 120 + this.guiLeft, 25 + this.guiTop, 178,
|
||||
25, 6, 18, Direction.VERTICAL, GuiText.StoredEnergy.getLocal()));
|
||||
this.addButton(this.mode);
|
||||
}
|
||||
|
||||
|
||||
@@ -43,8 +43,8 @@ import appeng.api.storage.data.IAEItemStack;
|
||||
import appeng.api.storage.data.IItemList;
|
||||
import appeng.api.util.AEColor;
|
||||
import appeng.client.gui.AEBaseScreen;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.gui.widgets.ISortSource;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.container.implementations.CraftingCPUContainer;
|
||||
import appeng.core.AEConfig;
|
||||
import appeng.core.localization.GuiText;
|
||||
|
||||
@@ -37,7 +37,8 @@ public class CraftingStatusScreen extends CraftingCPUScreen<CraftingStatusContai
|
||||
|
||||
private Button selectCPU;
|
||||
|
||||
public CraftingStatusScreen(CraftingStatusContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public CraftingStatusScreen(CraftingStatusContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.subGui = new AESubScreen(this, container.getTarget());
|
||||
}
|
||||
|
||||
@@ -55,8 +55,8 @@ public class CraftingTermScreen extends MEMonitorableScreen<CraftingTermContaine
|
||||
@Override
|
||||
public void init() {
|
||||
super.init();
|
||||
ActionButton clearBtn = this.addButton(new ActionButton(this.guiLeft + 92, this.guiTop + this.ySize - 156,
|
||||
ActionItems.STASH, btn -> clear()));
|
||||
ActionButton clearBtn = this.addButton(
|
||||
new ActionButton(this.guiLeft + 92, this.guiTop + this.ySize - 156, ActionItems.STASH, btn -> clear()));
|
||||
clearBtn.setHalfSize(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,8 @@ public class FormationPlaneScreen extends UpgradeableScreen<FormationPlaneContai
|
||||
|
||||
private SettingToggleButton<YesNo> placeMode;
|
||||
|
||||
public FormationPlaneScreen(FormationPlaneContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public FormationPlaneScreen(FormationPlaneContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 251;
|
||||
}
|
||||
|
||||
@@ -46,8 +46,7 @@ public class InscriberScreen extends AEBaseScreen<InscriberContainer> {
|
||||
public void init() {
|
||||
super.init();
|
||||
|
||||
this.pb = new ProgressBar(this.container, "guis/inscriber.png", 135, 39, 135, 177, 6, 18,
|
||||
Direction.VERTICAL);
|
||||
this.pb = new ProgressBar(this.container, "guis/inscriber.png", 135, 39, 135, 177, 6, 18, Direction.VERTICAL);
|
||||
this.addButton(this.pb);
|
||||
}
|
||||
|
||||
|
||||
@@ -49,8 +49,7 @@ public class InterfaceScreen extends UpgradeableScreen<InterfaceContainer> {
|
||||
this.addButton(new TabButton(this.guiLeft + 154, this.guiTop, 2 + 4 * 16, GuiText.Priority.getLocal(),
|
||||
this.itemRenderer, btn -> openPriorityGui()));
|
||||
|
||||
this.blockMode = new ServerSettingToggleButton<>(this.guiLeft - 18, this.guiTop + 8, Settings.BLOCK,
|
||||
YesNo.NO);
|
||||
this.blockMode = new ServerSettingToggleButton<>(this.guiLeft - 18, this.guiTop + 8, Settings.BLOCK, YesNo.NO);
|
||||
this.addButton(this.blockMode);
|
||||
|
||||
this.interfaceMode = new ToggleButton(this.guiLeft - 18, this.guiTop + 26, 84, 85,
|
||||
|
||||
@@ -44,8 +44,8 @@ import appeng.api.AEApi;
|
||||
import appeng.api.storage.channels.IItemStorageChannel;
|
||||
import appeng.client.ActionKey;
|
||||
import appeng.client.gui.AEBaseScreen;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.gui.widgets.AETextField;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.me.ClientDCInternalInv;
|
||||
import appeng.client.me.SlotDisconnected;
|
||||
import appeng.container.implementations.InterfaceTerminalContainer;
|
||||
@@ -68,7 +68,7 @@ public class InterfaceTerminalScreen extends AEBaseScreen<InterfaceTerminalConta
|
||||
private AETextField searchField;
|
||||
|
||||
public InterfaceTerminalScreen(InterfaceTerminalContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
final Scrollbar scrollbar = new Scrollbar();
|
||||
this.setScrollBar(scrollbar);
|
||||
|
||||
@@ -49,8 +49,8 @@ import appeng.core.AEConfig;
|
||||
import appeng.core.AppEng;
|
||||
import appeng.core.localization.GuiText;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
import appeng.helpers.WirelessTerminalGuiObject;
|
||||
import appeng.integration.abstraction.JEIFacade;
|
||||
import appeng.parts.reporting.AbstractTerminalPart;
|
||||
@@ -211,8 +211,8 @@ public class MEMonitorableScreen<T extends MEMonitorableContainer> extends AEBas
|
||||
offset += 20;
|
||||
|
||||
if (!(this instanceof MEPortableCellScreen) || this instanceof WirelessTermScreen) {
|
||||
this.addButton(new SettingToggleButton<>(this.guiLeft - 18, offset, Settings.TERMINAL_STYLE,
|
||||
terminalStyle, this::toggleTerminalStyle));
|
||||
this.addButton(new SettingToggleButton<>(this.guiLeft - 18, offset, Settings.TERMINAL_STYLE, terminalStyle,
|
||||
this::toggleTerminalStyle));
|
||||
}
|
||||
|
||||
this.searchField = new AETextField(this.font, this.guiLeft + Math.max(80, this.offsetX), this.guiTop + 4, 90,
|
||||
|
||||
@@ -25,7 +25,8 @@ import appeng.container.implementations.MEPortableCellContainer;
|
||||
|
||||
public class MEPortableCellScreen extends MEMonitorableScreen<MEPortableCellContainer> {
|
||||
|
||||
public MEPortableCellScreen(MEPortableCellContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public MEPortableCellScreen(MEPortableCellContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ public class MolecularAssemblerScreen extends UpgradeableScreen<MolecularAssembl
|
||||
private ProgressBar pb;
|
||||
|
||||
public MolecularAssemblerScreen(MolecularAssemblerContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 197;
|
||||
}
|
||||
|
||||
@@ -34,8 +34,8 @@ import appeng.api.config.ViewItems;
|
||||
import appeng.api.storage.data.IAEItemStack;
|
||||
import appeng.client.gui.AEBaseScreen;
|
||||
import appeng.client.gui.widgets.CommonButtons;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.gui.widgets.ISortSource;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.me.ItemRepo;
|
||||
import appeng.client.me.SlotME;
|
||||
import appeng.container.implementations.NetworkStatusContainer;
|
||||
@@ -48,7 +48,8 @@ public class NetworkStatusScreen extends AEBaseScreen<NetworkStatusContainer> im
|
||||
private final int rows = 4;
|
||||
private int tooltip = -1;
|
||||
|
||||
public NetworkStatusScreen(NetworkStatusContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public NetworkStatusScreen(NetworkStatusContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
final Scrollbar scrollbar = new Scrollbar();
|
||||
|
||||
|
||||
@@ -77,8 +77,8 @@ public class PatternTermScreen extends MEMonitorableScreen<PatternTermContainer>
|
||||
this.substitutionsDisabledBtn.setHalfSize(true);
|
||||
this.addButton(this.substitutionsDisabledBtn);
|
||||
|
||||
ActionButton clearBtn = new ActionButton(this.guiLeft + 74, this.guiTop + this.ySize - 163,
|
||||
ActionItems.CLOSE, act -> clear());
|
||||
ActionButton clearBtn = new ActionButton(this.guiLeft + 74, this.guiTop + this.ySize - 163, ActionItems.CLOSE,
|
||||
act -> clear());
|
||||
clearBtn.setHalfSize(true);
|
||||
this.addButton(clearBtn);
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ public class SecurityStationScreen extends MEMonitorableScreen<SecurityStationCo
|
||||
private ToggleButton security;
|
||||
|
||||
public SecurityStationScreen(SecurityStationContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.setCustomSortOrder(false);
|
||||
this.setReservedSpace(33);
|
||||
|
||||
@@ -30,7 +30,8 @@ import appeng.util.Platform;
|
||||
|
||||
public class SpatialIOPortScreen extends AEBaseScreen<SpatialIOPortContainer> {
|
||||
|
||||
public SpatialIOPortScreen(SpatialIOPortContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public SpatialIOPortScreen(SpatialIOPortContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 199;
|
||||
}
|
||||
|
||||
@@ -34,8 +34,8 @@ import appeng.container.implementations.PriorityContainer;
|
||||
import appeng.container.implementations.StorageBusContainer;
|
||||
import appeng.core.localization.GuiText;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
|
||||
public class StorageBusScreen extends UpgradeableScreen<StorageBusContainer> {
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public class VibrationChamberScreen extends AEBaseScreen<VibrationChamberContain
|
||||
private ProgressBar pb;
|
||||
|
||||
public VibrationChamberScreen(VibrationChamberContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 166;
|
||||
}
|
||||
|
||||
@@ -26,7 +26,8 @@ import appeng.container.implementations.MEPortableCellContainer;
|
||||
// FIXME: Extended from GuiPortableCell before... Why?
|
||||
public class WirelessTermScreen extends MEMonitorableScreen<MEPortableCellContainer> {
|
||||
|
||||
public WirelessTermScreen(MEPortableCellContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public WirelessTermScreen(MEPortableCellContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
}
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ public class AETextField extends TextFieldWidget {
|
||||
* @param height absolute height
|
||||
*/
|
||||
public AETextField(final FontRenderer fontRenderer, final int xPos, final int yPos, final int width,
|
||||
final int height) {
|
||||
final int height) {
|
||||
super(fontRenderer, xPos + PADDING, yPos + PADDING, width - 2 * PADDING - (int) fontRenderer.getCharWidth('_'),
|
||||
height - 2 * PADDING, "");
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class NumberBox extends TextFieldWidget {
|
||||
private final Class type;
|
||||
|
||||
public NumberBox(final FontRenderer fontRenderer, final int x, final int y, final int width, final int height,
|
||||
final Class type) {
|
||||
final Class type) {
|
||||
super(fontRenderer, x, y, width, height, "0");
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@@ -37,12 +37,12 @@ public class ProgressBar extends Widget implements ITooltip {
|
||||
private String fullMsg;
|
||||
|
||||
public ProgressBar(final IProgressProvider source, final String texture, final int posX, final int posY,
|
||||
final int u, final int y, final int width, final int height, final Direction dir) {
|
||||
final int u, final int y, final int width, final int height, final Direction dir) {
|
||||
this(source, texture, posX, posY, u, y, width, height, dir, null);
|
||||
}
|
||||
|
||||
public ProgressBar(final IProgressProvider source, final String texture, final int posX, final int posY,
|
||||
final int u, final int y, final int width, final int height, final Direction dir, final String title) {
|
||||
final int u, final int y, final int width, final int height, final Direction dir, final String title) {
|
||||
super(posX, posY, width, height, "");
|
||||
this.source = source;
|
||||
this.texture = new ResourceLocation("appliedenergistics2", "textures/" + texture);
|
||||
|
||||
@@ -65,12 +65,12 @@ public class SettingToggleButton<T extends Enum<T>> extends IconButton {
|
||||
}
|
||||
|
||||
public SettingToggleButton(final int x, final int y, final Settings setting, final T val,
|
||||
IHandler<SettingToggleButton<T>> onPress) {
|
||||
IHandler<SettingToggleButton<T>> onPress) {
|
||||
this(x, y, setting, val, t -> true, onPress);
|
||||
}
|
||||
|
||||
public SettingToggleButton(final int x, final int y, final Settings setting, final T val,
|
||||
Predicate<T> isValidValue, IHandler<SettingToggleButton<T>> onPress) {
|
||||
public SettingToggleButton(final int x, final int y, final Settings setting, final T val, Predicate<T> isValidValue,
|
||||
IHandler<SettingToggleButton<T>> onPress) {
|
||||
super(x, y, SettingToggleButton::onPress);
|
||||
this.onPress = onPress;
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public class TabButton extends Button implements ITooltip {
|
||||
private ItemStack myItem;
|
||||
|
||||
public TabButton(final int x, final int y, final int ico, final String message, final ItemRenderer ir,
|
||||
IPressable onPress) {
|
||||
IPressable onPress) {
|
||||
super(x, y, 22, 22, message, onPress);
|
||||
|
||||
this.myIcon = ico;
|
||||
@@ -53,7 +53,7 @@ public class TabButton extends Button implements ITooltip {
|
||||
* @param ir renderer
|
||||
*/
|
||||
public TabButton(final int x, final int y, final ItemStack ico, final String message, final ItemRenderer ir,
|
||||
IPressable onPress) {
|
||||
IPressable onPress) {
|
||||
super(x, y, 22, 22, message, onPress);
|
||||
this.myItem = ico;
|
||||
this.itemRenderer = ir;
|
||||
|
||||
@@ -41,7 +41,7 @@ public class ToggleButton extends Button implements ITooltip {
|
||||
private boolean isActive;
|
||||
|
||||
public ToggleButton(final int x, final int y, final int on, final int off, final String displayName,
|
||||
final String displayHint, IPressable onPress) {
|
||||
final String displayHint, IPressable onPress) {
|
||||
super(x, y, 16, 16, "", onPress);
|
||||
this.iconIdxOn = on;
|
||||
this.iconIdxOff = off;
|
||||
|
||||
@@ -43,7 +43,7 @@ public class CraftingMonitorTESR extends TileEntityRenderer<CraftingMonitorTileE
|
||||
|
||||
@Override
|
||||
public void render(CraftingMonitorTileEntity te, float partialTicks, MatrixStack matrixStack,
|
||||
IRenderTypeBuffer buffers, int combinedLight, int combinedOverlay) {
|
||||
IRenderTypeBuffer buffers, int combinedLight, int combinedOverlay) {
|
||||
|
||||
Direction facing = te.getForward();
|
||||
|
||||
|
||||
@@ -52,8 +52,8 @@ import net.minecraftforge.client.model.data.ModelDataMap;
|
||||
import net.minecraftforge.client.model.data.ModelProperty;
|
||||
import net.minecraftforge.client.model.pipeline.BakedQuadBuilder;
|
||||
|
||||
import appeng.decorative.solid.QuartzGlassBlock;
|
||||
import appeng.decorative.solid.GlassState;
|
||||
import appeng.decorative.solid.QuartzGlassBlock;
|
||||
|
||||
class GlassBakedModel implements IDynamicBakedModel {
|
||||
|
||||
|
||||
@@ -115,7 +115,8 @@ class SpatialPylonBakedModel implements IDynamicBakedModel {
|
||||
this.textures.get(getTextureTypeFromSideOutside(flags, ori, Direction.WEST)));
|
||||
builder.addCube(0, 0, 0, 16, 16, 16);
|
||||
|
||||
if ((flags & SpatialPylonTileEntity.DISPLAY_POWERED_ENABLED) == SpatialPylonTileEntity.DISPLAY_POWERED_ENABLED) {
|
||||
if ((flags
|
||||
& SpatialPylonTileEntity.DISPLAY_POWERED_ENABLED) == SpatialPylonTileEntity.DISPLAY_POWERED_ENABLED) {
|
||||
builder.setRenderFullBright(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -48,8 +48,8 @@ public class CrankTESR extends TileEntityRenderer<CrankTileEntity> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(CrankTileEntity te, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers, int combinedLightIn,
|
||||
int combinedOverlayIn) {
|
||||
public void render(CrankTileEntity te, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers,
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
|
||||
// Apply GL transformations relative to the center of the block: 1) TE rotation
|
||||
// and 2) crank rotation
|
||||
|
||||
@@ -69,7 +69,7 @@ public class DriveLedTileEntityRenderer extends TileEntityRenderer<DriveTileEnti
|
||||
|
||||
@Override
|
||||
public void render(DriveTileEntity drive, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers,
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
|
||||
if (drive.getCellCount() != 10) {
|
||||
throw new IllegalStateException("Expected drive to have 10 slots");
|
||||
|
||||
@@ -44,7 +44,7 @@ public final class InscriberTESR extends TileEntityRenderer<InscriberTileEntity>
|
||||
|
||||
@Override
|
||||
public void render(InscriberTileEntity tile, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers,
|
||||
int combinedLight, int combinedOverlay) {
|
||||
int combinedLight, int combinedOverlay) {
|
||||
|
||||
// render inscriber
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@ public class SkyChestTESR extends TileEntityRenderer<SkyChestTileEntity> {
|
||||
|
||||
@Override
|
||||
public void render(SkyChestTileEntity tileEntityIn, float partialTicks, MatrixStack matrixStackIn,
|
||||
IRenderTypeBuffer bufferIn, int combinedLightIn, int combinedOverlayIn) {
|
||||
IRenderTypeBuffer bufferIn, int combinedLightIn, int combinedOverlayIn) {
|
||||
matrixStackIn.push();
|
||||
float f = tileEntityIn.getForward().getHorizontalAngle();
|
||||
matrixStackIn.translate(0.5D, 0.5D, 0.5D);
|
||||
|
||||
@@ -49,7 +49,7 @@ public class SkyCompassTESR extends TileEntityRenderer<SkyCompassTileEntity> {
|
||||
|
||||
@Override
|
||||
public void render(SkyCompassTileEntity te, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers,
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
|
||||
if (blockRenderer == null) {
|
||||
blockRenderer = Minecraft.getInstance().getBlockRendererDispatcher();
|
||||
|
||||
@@ -65,9 +65,9 @@ import appeng.container.slot.PlayerHotBarSlot;
|
||||
import appeng.container.slot.PlayerInvSlot;
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.InventoryActionPacket;
|
||||
import appeng.core.sync.packets.TargetItemStackPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.helpers.ICustomNameObject;
|
||||
import appeng.helpers.InventoryAction;
|
||||
import appeng.me.helpers.PlayerSource;
|
||||
@@ -97,12 +97,12 @@ public abstract class AEBaseContainer extends Container {
|
||||
private List<Slot> playerInventorySlots = null;
|
||||
|
||||
public AEBaseContainer(ContainerType<?> containerType, int id, final PlayerInventory ip, final TileEntity myTile,
|
||||
final IPart myPart) {
|
||||
final IPart myPart) {
|
||||
this(containerType, id, ip, myTile, myPart, null);
|
||||
}
|
||||
|
||||
public AEBaseContainer(ContainerType<?> containerType, int id, final PlayerInventory ip, final TileEntity myTile,
|
||||
final IPart myPart, final IGuiItemObject gio) {
|
||||
final IPart myPart, final IGuiItemObject gio) {
|
||||
super(containerType, id);
|
||||
this.invPlayer = ip;
|
||||
this.tileEntity = myTile;
|
||||
|
||||
@@ -30,8 +30,8 @@ import net.minecraft.util.text.ITextComponent;
|
||||
import appeng.container.AEBaseContainer;
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.ProgressBarPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.ProgressBarPacket;
|
||||
|
||||
/**
|
||||
* This class is responsible for synchronizing Container-fields from server to
|
||||
|
||||
@@ -44,8 +44,8 @@ import appeng.api.storage.data.IAEStack;
|
||||
import appeng.api.storage.data.IItemList;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.OptionalRestrictedInputSlot;
|
||||
import appeng.container.slot.FakeTypeOnlySlot;
|
||||
import appeng.container.slot.OptionalRestrictedInputSlot;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
import appeng.tile.misc.CellWorkbenchTileEntity;
|
||||
import appeng.util.EnumCycler;
|
||||
|
||||
@@ -33,8 +33,8 @@ public class ChestContainer extends AEBaseContainer {
|
||||
|
||||
public static ContainerType<ChestContainer> TYPE;
|
||||
|
||||
private static final ContainerHelper<ChestContainer, ChestTileEntity> helper = new ContainerHelper<>(ChestContainer::new,
|
||||
ChestTileEntity.class, SecurityPermissions.BUILD);
|
||||
private static final ContainerHelper<ChestContainer, ChestTileEntity> helper = new ContainerHelper<>(
|
||||
ChestContainer::new, ChestTileEntity.class, SecurityPermissions.BUILD);
|
||||
|
||||
public ChestContainer(int id, final PlayerInventory ip, final ChestTileEntity chest) {
|
||||
super(TYPE, id, ip, chest, null);
|
||||
|
||||
@@ -44,8 +44,8 @@ import appeng.container.AEBaseContainer;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.MEInventoryUpdatePacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.MEInventoryUpdatePacket;
|
||||
import appeng.helpers.ICustomNameObject;
|
||||
import appeng.me.cluster.IAEMultiBlock;
|
||||
import appeng.me.cluster.implementations.CraftingCPUCluster;
|
||||
|
||||
@@ -32,8 +32,8 @@ public class DriveContainer extends AEBaseContainer {
|
||||
|
||||
public static ContainerType<DriveContainer> TYPE;
|
||||
|
||||
private static final ContainerHelper<DriveContainer, DriveTileEntity> helper = new ContainerHelper<>(DriveContainer::new,
|
||||
DriveTileEntity.class);
|
||||
private static final ContainerHelper<DriveContainer, DriveTileEntity> helper = new ContainerHelper<>(
|
||||
DriveContainer::new, DriveTileEntity.class);
|
||||
|
||||
public static DriveContainer fromNetwork(int windowId, PlayerInventory inv, PacketBuffer buf) {
|
||||
return helper.fromNetwork(windowId, inv, buf);
|
||||
|
||||
@@ -31,8 +31,8 @@ import appeng.api.config.Upgrades;
|
||||
import appeng.api.config.YesNo;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.OptionalTypeOnlyFakeSlot;
|
||||
import appeng.container.slot.FakeTypeOnlySlot;
|
||||
import appeng.container.slot.OptionalTypeOnlyFakeSlot;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
import appeng.parts.automation.FormationPlanePart;
|
||||
import appeng.util.Platform;
|
||||
|
||||
@@ -68,8 +68,8 @@ import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.MEInventoryUpdatePacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.MEInventoryUpdatePacket;
|
||||
import appeng.me.helpers.ChannelPowerSrc;
|
||||
import appeng.util.ConfigManager;
|
||||
import appeng.util.IConfigManagerHost;
|
||||
@@ -110,7 +110,7 @@ public class MEMonitorableContainer extends AEBaseContainer
|
||||
}
|
||||
|
||||
public MEMonitorableContainer(ContainerType<?> containerType, int id, PlayerInventory ip,
|
||||
final ITerminalHost monitorable, final boolean bindInventory) {
|
||||
final ITerminalHost monitorable, final boolean bindInventory) {
|
||||
super(containerType, id, ip, monitorable instanceof TileEntity ? (TileEntity) monitorable : null,
|
||||
monitorable instanceof IPart ? (IPart) monitorable : null,
|
||||
monitorable instanceof IGuiItemObject ? (IGuiItemObject) monitorable : null);
|
||||
|
||||
@@ -56,7 +56,7 @@ public class MEPortableCellContainer extends MEMonitorableContainer {
|
||||
}
|
||||
|
||||
protected MEPortableCellContainer(ContainerType<? extends MEPortableCellContainer> type, int id,
|
||||
final PlayerInventory ip, final IPortableCell monitorable) {
|
||||
final PlayerInventory ip, final IPortableCell monitorable) {
|
||||
super(type, id, ip, monitorable, false);
|
||||
if (monitorable instanceof IInventorySlotAware) {
|
||||
final int slotIndex = ((IInventorySlotAware) monitorable).getInventorySlot();
|
||||
|
||||
@@ -54,9 +54,9 @@ import appeng.api.storage.data.IItemList;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.ContainerNull;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.FakeCraftingMatrixSlot;
|
||||
import appeng.container.slot.IOptionalSlotHost;
|
||||
import appeng.container.slot.OptionalFakeSlot;
|
||||
import appeng.container.slot.FakeCraftingMatrixSlot;
|
||||
import appeng.container.slot.PatternOutputsSlot;
|
||||
import appeng.container.slot.PatternTermSlot;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
|
||||
@@ -40,8 +40,8 @@ import appeng.api.storage.data.IAEItemStack;
|
||||
import appeng.api.storage.data.IItemList;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.OptionalTypeOnlyFakeSlot;
|
||||
import appeng.container.slot.FakeTypeOnlySlot;
|
||||
import appeng.container.slot.OptionalTypeOnlyFakeSlot;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
import appeng.parts.misc.StorageBusPart;
|
||||
import appeng.util.Platform;
|
||||
|
||||
@@ -43,10 +43,10 @@ import appeng.api.util.IConfigManager;
|
||||
import appeng.container.AEBaseContainer;
|
||||
import appeng.container.ContainerLocator;
|
||||
import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.slot.FakeTypeOnlySlot;
|
||||
import appeng.container.slot.IOptionalSlotHost;
|
||||
import appeng.container.slot.OptionalFakeSlot;
|
||||
import appeng.container.slot.OptionalTypeOnlyFakeSlot;
|
||||
import appeng.container.slot.FakeTypeOnlySlot;
|
||||
import appeng.container.slot.RestrictedInputSlot;
|
||||
import appeng.items.contents.NetworkToolViewer;
|
||||
import appeng.items.tools.NetworkToolItem;
|
||||
@@ -85,7 +85,7 @@ public class UpgradeableContainer extends AEBaseContainer implements IOptionalSl
|
||||
}
|
||||
|
||||
public UpgradeableContainer(ContainerType<?> containerType, int id, final PlayerInventory ip,
|
||||
final IUpgradeableHost te) {
|
||||
final IUpgradeableHost te) {
|
||||
super(containerType, id, ip, (TileEntity) (te instanceof TileEntity ? te : null),
|
||||
(IPart) (te instanceof IPart ? te : null));
|
||||
this.upgradeable = te;
|
||||
|
||||
@@ -52,7 +52,8 @@ public class VibrationChamberContainer extends AEBaseContainer implements IProgr
|
||||
@GuiSync(1)
|
||||
public int remainingBurnTime = 0;
|
||||
|
||||
public VibrationChamberContainer(int id, final PlayerInventory ip, final VibrationChamberTileEntity vibrationChamber) {
|
||||
public VibrationChamberContainer(int id, final PlayerInventory ip,
|
||||
final VibrationChamberTileEntity vibrationChamber) {
|
||||
super(TYPE, id, ip, vibrationChamber, null);
|
||||
this.vibrationChamber = vibrationChamber;
|
||||
|
||||
|
||||
@@ -23,9 +23,8 @@ import appeng.client.gui.widgets.ProgressBar;
|
||||
/**
|
||||
* This interface provides the data for anything simulating a progress.
|
||||
*
|
||||
* Its main use is in combination with the
|
||||
* {@link ProgressBar}, which ensures to scale it
|
||||
* to a percentage of 0 to 100.
|
||||
* Its main use is in combination with the {@link ProgressBar}, which ensures to
|
||||
* scale it to a percentage of 0 to 100.
|
||||
*/
|
||||
public interface IProgressProvider {
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ public class CraftingMatrixSlot extends AppEngSlot {
|
||||
private final IInventory wrappedInventory;
|
||||
|
||||
public CraftingMatrixSlot(final AEBaseContainer c, final IItemHandler par1iInventory, final int par2,
|
||||
final int par3, final int par4) {
|
||||
final int par3, final int par4) {
|
||||
super(par1iInventory, par2, par3, par4);
|
||||
this.c = c;
|
||||
this.wrappedInventory = new WrapperInvItemHandler(par1iInventory);
|
||||
|
||||
@@ -66,8 +66,8 @@ public class CraftingTermSlot extends AppEngCraftingSlot {
|
||||
private final IContainerCraftingPacket container;
|
||||
|
||||
public CraftingTermSlot(final PlayerEntity player, final IActionSource mySrc, final IEnergySource energySrc,
|
||||
final IStorageMonitorable storage, final IItemHandler cMatrix, final IItemHandler secondMatrix,
|
||||
final IItemHandler output, final int x, final int y, final IContainerCraftingPacket ccp) {
|
||||
final IStorageMonitorable storage, final IItemHandler cMatrix, final IItemHandler secondMatrix,
|
||||
final IItemHandler output, final int x, final int y, final IContainerCraftingPacket ccp) {
|
||||
super(player, cMatrix, output, 0, x, y);
|
||||
this.energySrc = energySrc;
|
||||
this.storage = storage;
|
||||
|
||||
@@ -28,7 +28,7 @@ public class MolecularAssemblerPatternSlot extends AppEngSlot {
|
||||
private final MolecularAssemblerContainer mac;
|
||||
|
||||
public MolecularAssemblerPatternSlot(final MolecularAssemblerContainer mac, final IItemHandler i, final int slotIdx,
|
||||
final int x, final int y) {
|
||||
final int x, final int y) {
|
||||
super(i, slotIdx, x, y);
|
||||
this.mac = mac;
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ public class OptionalFakeSlot extends FakeSlot implements IOptionalSlot {
|
||||
private boolean renderDisabled = true;
|
||||
|
||||
public OptionalFakeSlot(final IItemHandler inv, final IOptionalSlotHost containerBus, final int idx, final int x,
|
||||
final int y, final int offX, final int offY, final int groupNum) {
|
||||
final int y, final int offX, final int offY, final int groupNum) {
|
||||
super(inv, idx, x + offX * 18, y + offY * 18);
|
||||
this.srcX = x;
|
||||
this.srcY = y;
|
||||
|
||||
@@ -26,7 +26,7 @@ public class OptionalNormalSlot extends AppEngSlot implements IOptionalSlot {
|
||||
private final IOptionalSlotHost host;
|
||||
|
||||
public OptionalNormalSlot(final IItemHandler inv, final IOptionalSlotHost containerBus, final int slot,
|
||||
final int xPos, final int yPos, final int groupNum) {
|
||||
final int xPos, final int yPos, final int groupNum) {
|
||||
super(inv, slot, xPos, yPos);
|
||||
this.groupNum = groupNum;
|
||||
this.host = containerBus;
|
||||
|
||||
@@ -27,7 +27,7 @@ public class OptionalRestrictedInputSlot extends RestrictedInputSlot {
|
||||
private final IOptionalSlotHost host;
|
||||
|
||||
public OptionalRestrictedInputSlot(final PlacableItemType valid, final IItemHandler i, final IOptionalSlotHost host,
|
||||
final int slotIndex, final int x, final int y, final int grpNum, final PlayerInventory invPlayer) {
|
||||
final int slotIndex, final int x, final int y, final int grpNum, final PlayerInventory invPlayer) {
|
||||
super(valid, i, slotIndex, x, y, invPlayer);
|
||||
this.groupNum = grpNum;
|
||||
this.host = host;
|
||||
|
||||
@@ -24,7 +24,7 @@ import net.minecraftforge.items.IItemHandler;
|
||||
public class OptionalTypeOnlyFakeSlot extends OptionalFakeSlot {
|
||||
|
||||
public OptionalTypeOnlyFakeSlot(final IItemHandler inv, final IOptionalSlotHost containerBus, final int idx,
|
||||
final int x, final int y, final int offX, final int offY, final int groupNum) {
|
||||
final int x, final int y, final int offX, final int offY, final int groupNum) {
|
||||
super(inv, containerBus, idx, x, y, offX, offY, groupNum);
|
||||
}
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ import net.minecraftforge.items.IItemHandler;
|
||||
public class PatternOutputsSlot extends OptionalFakeSlot {
|
||||
|
||||
public PatternOutputsSlot(final IItemHandler inv, final IOptionalSlotHost containerBus, final int idx, final int x,
|
||||
final int y, final int offX, final int offY, final int groupNum) {
|
||||
final int y, final int offX, final int offY, final int groupNum) {
|
||||
super(inv, containerBus, idx, x, y, offX, offY, groupNum);
|
||||
}
|
||||
|
||||
|
||||
@@ -37,9 +37,9 @@ public class PatternTermSlot extends CraftingTermSlot {
|
||||
private final IOptionalSlotHost host;
|
||||
|
||||
public PatternTermSlot(final PlayerEntity player, final IActionSource mySrc, final IEnergySource energySrc,
|
||||
final IStorageMonitorable storage, final IItemHandler cMatrix, final IItemHandler secondMatrix,
|
||||
final IItemHandler output, final int x, final int y, final IOptionalSlotHost h, final int groupNumber,
|
||||
final IContainerCraftingPacket c) {
|
||||
final IStorageMonitorable storage, final IItemHandler cMatrix, final IItemHandler secondMatrix,
|
||||
final IItemHandler output, final int x, final int y, final IOptionalSlotHost h, final int groupNumber,
|
||||
final IContainerCraftingPacket c) {
|
||||
super(player, mySrc, energySrc, storage, cMatrix, secondMatrix, output, x, y, c);
|
||||
|
||||
this.host = h;
|
||||
|
||||
@@ -71,7 +71,7 @@ public class RestrictedInputSlot extends AppEngSlot {
|
||||
private int stackLimit = -1;
|
||||
|
||||
public RestrictedInputSlot(final PlacableItemType valid, final IItemHandler i, final int slotIndex, final int x,
|
||||
final int y, final PlayerInventory p) {
|
||||
final int y, final PlayerInventory p) {
|
||||
super(i, slotIndex, x, y);
|
||||
this.which = valid;
|
||||
this.setIIcon(valid.IIcon);
|
||||
|
||||
@@ -325,7 +325,7 @@ final class Registration {
|
||||
}
|
||||
|
||||
private <T extends AEBaseContainer> ContainerType<T> registerContainer(IForgeRegistry<ContainerType<?>> registry,
|
||||
String id, IContainerFactory<T> factory, ContainerOpener.Opener<T> opener) {
|
||||
String id, IContainerFactory<T> factory, ContainerOpener.Opener<T> opener) {
|
||||
ContainerType<T> type = IForgeContainerType.create(factory);
|
||||
type.setRegistryName(AppEng.MOD_ID, id);
|
||||
registry.register(type);
|
||||
|
||||
@@ -40,50 +40,50 @@ import appeng.block.AEBaseBlockItemChargeable;
|
||||
import appeng.block.crafting.AbstractCraftingUnitBlock.CraftingUnitType;
|
||||
import appeng.block.crafting.CraftingMonitorBlock;
|
||||
import appeng.block.crafting.CraftingStorageBlock;
|
||||
import appeng.block.crafting.MolecularAssemblerBlock;
|
||||
import appeng.block.crafting.CraftingUnitBlock;
|
||||
import appeng.block.crafting.CraftingStorageItem;
|
||||
import appeng.block.crafting.CraftingUnitBlock;
|
||||
import appeng.block.crafting.MolecularAssemblerBlock;
|
||||
import appeng.block.grindstone.CrankBlock;
|
||||
import appeng.block.grindstone.GrinderBlock;
|
||||
import appeng.block.misc.CellWorkbenchBlock;
|
||||
import appeng.block.misc.ChargerBlock;
|
||||
import appeng.block.misc.CondenserBlock;
|
||||
import appeng.block.misc.InscriberBlock;
|
||||
import appeng.block.misc.InscriberRendering;
|
||||
import appeng.block.misc.InterfaceBlock;
|
||||
import appeng.block.misc.LightDetectorBlock;
|
||||
import appeng.block.misc.QuartzFixtureBlock;
|
||||
import appeng.block.misc.QuartzGrowthAcceleratorBlock;
|
||||
import appeng.block.misc.SecurityStationBlock;
|
||||
import appeng.block.misc.SecurityStationRendering;
|
||||
import appeng.block.misc.SkyCompassBlock;
|
||||
import appeng.block.misc.SkyCompassRendering;
|
||||
import appeng.block.misc.TinyTNTBlock;
|
||||
import appeng.block.misc.VibrationChamberBlock;
|
||||
import appeng.block.misc.InscriberRendering;
|
||||
import appeng.block.misc.SecurityStationRendering;
|
||||
import appeng.block.misc.SkyCompassRendering;
|
||||
import appeng.block.networking.CableBusBlock;
|
||||
import appeng.block.networking.CableBusRendering;
|
||||
import appeng.block.networking.ControllerBlock;
|
||||
import appeng.block.networking.ControllerRendering;
|
||||
import appeng.block.networking.CreativeEnergyCellBlock;
|
||||
import appeng.block.networking.DenseEnergyCellBlock;
|
||||
import appeng.block.networking.EnergyAcceptorBlock;
|
||||
import appeng.block.networking.EnergyCellBlock;
|
||||
import appeng.block.networking.WirelessBlock;
|
||||
import appeng.block.networking.CableBusRendering;
|
||||
import appeng.block.networking.ControllerRendering;
|
||||
import appeng.block.networking.WirelessRendering;
|
||||
import appeng.block.paint.PaintSplotchesBlock;
|
||||
import appeng.block.paint.PaintSplotchesRendering;
|
||||
import appeng.block.qnb.QuantumBridgeRendering;
|
||||
import appeng.block.qnb.QuantumLinkChamberBlock;
|
||||
import appeng.block.qnb.QuantumRingBlock;
|
||||
import appeng.block.qnb.QuantumBridgeRendering;
|
||||
import appeng.block.spatial.MatrixFrameBlock;
|
||||
import appeng.block.spatial.SpatialIOPortBlock;
|
||||
import appeng.block.spatial.SpatialPylonBlock;
|
||||
import appeng.block.storage.ChestBlock;
|
||||
import appeng.block.storage.ChestRendering;
|
||||
import appeng.block.storage.DriveBlock;
|
||||
import appeng.block.storage.DriveRendering;
|
||||
import appeng.block.storage.IOPortBlock;
|
||||
import appeng.block.storage.SkyChestBlock;
|
||||
import appeng.block.storage.ChestRendering;
|
||||
import appeng.block.storage.DriveRendering;
|
||||
import appeng.bootstrap.BlockRenderingCustomizer;
|
||||
import appeng.bootstrap.FeatureFactory;
|
||||
import appeng.bootstrap.IBlockRendering;
|
||||
@@ -101,14 +101,14 @@ import appeng.client.render.tesr.CrankTESR;
|
||||
import appeng.client.render.tesr.DriveLedTileEntityRenderer;
|
||||
import appeng.client.render.tesr.SkyChestTESR;
|
||||
import appeng.debug.ChunkLoaderBlock;
|
||||
import appeng.debug.CubeGeneratorBlock;
|
||||
import appeng.debug.EnergyGeneratorBlock;
|
||||
import appeng.debug.ItemGenBlock;
|
||||
import appeng.debug.PhantomNodeBlock;
|
||||
import appeng.debug.ChunkLoaderTileEntity;
|
||||
import appeng.debug.CubeGeneratorBlock;
|
||||
import appeng.debug.CubeGeneratorTileEntity;
|
||||
import appeng.debug.EnergyGeneratorBlock;
|
||||
import appeng.debug.EnergyGeneratorTileEntity;
|
||||
import appeng.debug.ItemGenBlock;
|
||||
import appeng.debug.ItemGenTileEntity;
|
||||
import appeng.debug.PhantomNodeBlock;
|
||||
import appeng.debug.PhantomNodeTileEntity;
|
||||
import appeng.decorative.AEDecorativeBlock;
|
||||
import appeng.decorative.solid.ChargedQuartzOreBlock;
|
||||
@@ -122,10 +122,10 @@ import appeng.entity.TinyTNTPrimedEntity;
|
||||
import appeng.fluids.block.FluidInterfaceBlock;
|
||||
import appeng.fluids.tile.FluidInterfaceTileEntity;
|
||||
import appeng.hooks.TinyTNTDispenseItemBehavior;
|
||||
import appeng.tile.crafting.MolecularAssemblerRenderer;
|
||||
import appeng.tile.crafting.CraftingMonitorTileEntity;
|
||||
import appeng.tile.crafting.CraftingStorageTileEntity;
|
||||
import appeng.tile.crafting.CraftingTileEntity;
|
||||
import appeng.tile.crafting.MolecularAssemblerRenderer;
|
||||
import appeng.tile.crafting.MolecularAssemblerTileEntity;
|
||||
import appeng.tile.grindstone.CrankTileEntity;
|
||||
import appeng.tile.grindstone.GrinderTileEntity;
|
||||
@@ -313,7 +313,8 @@ public final class ApiBlocks implements IBlocks {
|
||||
|
||||
Block.Properties skyStoneChestProps = defaultProps(Material.ROCK).hardnessAndResistance(50, 150).notSolid();
|
||||
|
||||
TileEntityDefinition skyChestTile = registry.tileEntity("sky_chest", SkyChestTileEntity.class, SkyChestTileEntity::new)
|
||||
TileEntityDefinition skyChestTile = registry
|
||||
.tileEntity("sky_chest", SkyChestTileEntity.class, SkyChestTileEntity::new)
|
||||
.rendering(new TileEntityRenderingCustomizer<SkyChestTileEntity>() {
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@@ -337,7 +338,8 @@ public final class ApiBlocks implements IBlocks {
|
||||
this.grindstone = registry
|
||||
.block("grindstone", () -> new GrinderBlock(defaultProps(Material.ROCK).hardnessAndResistance(3.2f)))
|
||||
.features(AEFeature.GRIND_STONE)
|
||||
.tileEntity(registry.tileEntity("grindstone", GrinderTileEntity.class, GrinderTileEntity::new).build()).build();
|
||||
.tileEntity(registry.tileEntity("grindstone", GrinderTileEntity.class, GrinderTileEntity::new).build())
|
||||
.build();
|
||||
this.crank = registry
|
||||
.block("crank",
|
||||
() -> new CrankBlock(
|
||||
@@ -359,7 +361,8 @@ public final class ApiBlocks implements IBlocks {
|
||||
.build();
|
||||
this.wirelessAccessPoint = registry.block("wireless_access_point", WirelessBlock::new)
|
||||
.features(AEFeature.WIRELESS_ACCESS_TERMINAL)
|
||||
.tileEntity(registry.tileEntity("wireless_access_point", WirelessTileEntity.class, WirelessTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("wireless_access_point", WirelessTileEntity.class, WirelessTileEntity::new).build())
|
||||
.rendering(new WirelessRendering()).build();
|
||||
this.charger = registry.block("charger", ChargerBlock::new).features(AEFeature.CHARGER)
|
||||
.tileEntity(registry.tileEntity("charger", ChargerTileEntity.class, ChargerTileEntity::new)
|
||||
@@ -385,8 +388,10 @@ public final class ApiBlocks implements IBlocks {
|
||||
.registerDispenseBehavior(item, new TinyTNTDispenseItemBehavior()))
|
||||
.build();
|
||||
this.securityStation = registry.block("security_station", SecurityStationBlock::new)
|
||||
.features(AEFeature.SECURITY).tileEntity(registry
|
||||
.tileEntity("security_station", SecurityStationTileEntity.class, SecurityStationTileEntity::new).build())
|
||||
.features(AEFeature.SECURITY)
|
||||
.tileEntity(registry
|
||||
.tileEntity("security_station", SecurityStationTileEntity.class, SecurityStationTileEntity::new)
|
||||
.build())
|
||||
.rendering(new SecurityStationRendering()).build();
|
||||
|
||||
TileEntityDefinition quantumRingTile = registry
|
||||
@@ -398,14 +403,17 @@ public final class ApiBlocks implements IBlocks {
|
||||
.features(AEFeature.QUANTUM_NETWORK_BRIDGE).tileEntity(quantumRingTile)
|
||||
.rendering(new QuantumBridgeRendering()).build();
|
||||
this.spatialPylon = registry.block("spatial_pylon", SpatialPylonBlock::new).features(AEFeature.SPATIAL_IO)
|
||||
.tileEntity(registry.tileEntity("spatial_pylon", SpatialPylonTileEntity.class, SpatialPylonTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("spatial_pylon", SpatialPylonTileEntity.class, SpatialPylonTileEntity::new).build())
|
||||
.rendering(new SpatialPylonRendering()).build();
|
||||
this.spatialIOPort = registry.block("spatial_io_port", SpatialIOPortBlock::new).features(AEFeature.SPATIAL_IO)
|
||||
.tileEntity(
|
||||
registry.tileEntity("spatial_io_port", SpatialIOPortTileEntity.class, SpatialIOPortTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("spatial_io_port", SpatialIOPortTileEntity.class, SpatialIOPortTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.controller = registry.block("controller", ControllerBlock::new).features(AEFeature.CHANNELS)
|
||||
.tileEntity(registry.tileEntity("controller", ControllerTileEntity.class, ControllerTileEntity::new).build())
|
||||
this.controller = registry
|
||||
.block("controller", ControllerBlock::new).features(AEFeature.CHANNELS).tileEntity(registry
|
||||
.tileEntity("controller", ControllerTileEntity.class, ControllerTileEntity::new).build())
|
||||
.rendering(new ControllerRendering()).build();
|
||||
this.drive = registry.block("drive", DriveBlock::new).features(AEFeature.STORAGE_CELLS, AEFeature.ME_DRIVE)
|
||||
.tileEntity(registry.tileEntity("drive", DriveTileEntity.class, DriveTileEntity::new)
|
||||
@@ -421,46 +429,53 @@ public final class ApiBlocks implements IBlocks {
|
||||
.tileEntity(registry.tileEntity("chest", ChestTileEntity.class, ChestTileEntity::new).build())
|
||||
.rendering(new ChestRendering()).build();
|
||||
this.iface = registry.block("interface", InterfaceBlock::new).features(AEFeature.INTERFACE)
|
||||
.tileEntity(registry.tileEntity("interface", InterfaceTileEntity.class, InterfaceTileEntity::new).build()).build();
|
||||
.tileEntity(
|
||||
registry.tileEntity("interface", InterfaceTileEntity.class, InterfaceTileEntity::new).build())
|
||||
.build();
|
||||
this.fluidIface = registry.block("fluid_interface", FluidInterfaceBlock::new)
|
||||
.features(AEFeature.FLUID_INTERFACE).tileEntity(registry
|
||||
.tileEntity("fluid_interface", FluidInterfaceTileEntity.class, FluidInterfaceTileEntity::new).build())
|
||||
.features(AEFeature.FLUID_INTERFACE)
|
||||
.tileEntity(registry
|
||||
.tileEntity("fluid_interface", FluidInterfaceTileEntity.class, FluidInterfaceTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.cellWorkbench = registry.block("cell_workbench", CellWorkbenchBlock::new).features(AEFeature.STORAGE_CELLS)
|
||||
.tileEntity(
|
||||
registry.tileEntity("cell_workbench", CellWorkbenchTileEntity.class, CellWorkbenchTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("cell_workbench", CellWorkbenchTileEntity.class, CellWorkbenchTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.iOPort = registry.block("io_port", IOPortBlock::new).features(AEFeature.STORAGE_CELLS, AEFeature.IO_PORT)
|
||||
.tileEntity(registry.tileEntity("io_port", IOPortTileEntity.class, IOPortTileEntity::new).build()).build();
|
||||
.tileEntity(registry.tileEntity("io_port", IOPortTileEntity.class, IOPortTileEntity::new).build())
|
||||
.build();
|
||||
this.condenser = registry.block("condenser", CondenserBlock::new).features(AEFeature.CONDENSER)
|
||||
.tileEntity(registry.tileEntity("condenser", CondenserTileEntity.class, CondenserTileEntity::new).build()).build();
|
||||
.tileEntity(
|
||||
registry.tileEntity("condenser", CondenserTileEntity.class, CondenserTileEntity::new).build())
|
||||
.build();
|
||||
this.energyAcceptor = registry.block("energy_acceptor", EnergyAcceptorBlock::new)
|
||||
.features(AEFeature.ENERGY_ACCEPTOR).tileEntity(registry
|
||||
.tileEntity("energy_acceptor", EnergyAcceptorTileEntity.class, EnergyAcceptorTileEntity::new).build())
|
||||
.features(AEFeature.ENERGY_ACCEPTOR)
|
||||
.tileEntity(registry
|
||||
.tileEntity("energy_acceptor", EnergyAcceptorTileEntity.class, EnergyAcceptorTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.vibrationChamber = registry.block("vibration_chamber", VibrationChamberBlock::new)
|
||||
.features(AEFeature.POWER_GEN)
|
||||
.tileEntity(registry
|
||||
.tileEntity("vibration_chamber", VibrationChamberTileEntity.class, VibrationChamberTileEntity::new).build())
|
||||
.features(AEFeature.POWER_GEN).tileEntity(registry.tileEntity("vibration_chamber",
|
||||
VibrationChamberTileEntity.class, VibrationChamberTileEntity::new).build())
|
||||
.build();
|
||||
this.quartzGrowthAccelerator = registry.block("quartz_growth_accelerator", QuartzGrowthAcceleratorBlock::new)
|
||||
.tileEntity(registry.tileEntity("quartz_growth_accelerator", QuartzGrowthAcceleratorTileEntity.class,
|
||||
QuartzGrowthAcceleratorTileEntity::new).build())
|
||||
.features(AEFeature.CRYSTAL_GROWTH_ACCELERATOR).build();
|
||||
this.energyCell = registry.block("energy_cell", EnergyCellBlock::new).features(AEFeature.ENERGY_CELLS)
|
||||
.item(AEBaseBlockItemChargeable::new)
|
||||
.tileEntity(registry.tileEntity("energy_cell", EnergyCellTileEntity.class, EnergyCellTileEntity::new).build())
|
||||
.item(AEBaseBlockItemChargeable::new).tileEntity(registry
|
||||
.tileEntity("energy_cell", EnergyCellTileEntity.class, EnergyCellTileEntity::new).build())
|
||||
.build();
|
||||
this.energyCellDense = registry.block("dense_energy_cell", DenseEnergyCellBlock::new)
|
||||
.features(AEFeature.ENERGY_CELLS, AEFeature.DENSE_ENERGY_CELLS).item(AEBaseBlockItemChargeable::new)
|
||||
.tileEntity(registry
|
||||
.tileEntity("dense_energy_cell", DenseEnergyCellTileEntity.class, DenseEnergyCellTileEntity::new).build())
|
||||
.tileEntity(registry.tileEntity("dense_energy_cell", DenseEnergyCellTileEntity.class,
|
||||
DenseEnergyCellTileEntity::new).build())
|
||||
.build();
|
||||
this.energyCellCreative = registry.block("creative_energy_cell", CreativeEnergyCellBlock::new)
|
||||
.features(AEFeature.CREATIVE)
|
||||
.tileEntity(registry
|
||||
.tileEntity("creative_energy_cell", CreativeEnergyCellTileEntity.class, CreativeEnergyCellTileEntity::new)
|
||||
.build())
|
||||
.features(AEFeature.CREATIVE).tileEntity(registry.tileEntity("creative_energy_cell",
|
||||
CreativeEnergyCellTileEntity.class, CreativeEnergyCellTileEntity::new).build())
|
||||
.build();
|
||||
|
||||
TileEntityDefinition craftingUnit = registry
|
||||
@@ -477,7 +492,8 @@ public final class ApiBlocks implements IBlocks {
|
||||
.rendering(new CraftingCubeRendering()).tileEntity(craftingUnit).build();
|
||||
|
||||
TileEntityDefinition craftingStorage = registry
|
||||
.tileEntity("crafting_storage", CraftingStorageTileEntity.class, CraftingStorageTileEntity::new).build();
|
||||
.tileEntity("crafting_storage", CraftingStorageTileEntity.class, CraftingStorageTileEntity::new)
|
||||
.build();
|
||||
this.craftingStorage1k = crafting
|
||||
.block("1k_crafting_storage",
|
||||
() -> new CraftingStorageBlock(craftingBlockProps, CraftingUnitType.STORAGE_1K))
|
||||
@@ -533,7 +549,8 @@ public final class ApiBlocks implements IBlocks {
|
||||
}
|
||||
})
|
||||
.tileEntity(registry
|
||||
.tileEntity("molecular_assembler", MolecularAssemblerTileEntity.class, MolecularAssemblerTileEntity::new)
|
||||
.tileEntity("molecular_assembler", MolecularAssemblerTileEntity.class,
|
||||
MolecularAssemblerTileEntity::new)
|
||||
.rendering(new TileEntityRenderingCustomizer<MolecularAssemblerTileEntity>() {
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@@ -545,8 +562,9 @@ public final class ApiBlocks implements IBlocks {
|
||||
|
||||
this.lightDetector = registry.block("light_detector", LightDetectorBlock::new)
|
||||
.features(AEFeature.LIGHT_DETECTOR)
|
||||
.tileEntity(
|
||||
registry.tileEntity("light_detector", LightDetectorTileEntity.class, LightDetectorTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("light_detector", LightDetectorTileEntity.class, LightDetectorTileEntity::new)
|
||||
.build())
|
||||
.rendering(new BlockRenderingCustomizer() {
|
||||
@Override
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
@@ -554,8 +572,9 @@ public final class ApiBlocks implements IBlocks {
|
||||
rendering.renderType(RenderType.getCutout());
|
||||
}
|
||||
}).build();
|
||||
this.paint = registry.block("paint", PaintSplotchesBlock::new).features(AEFeature.PAINT_BALLS)
|
||||
.tileEntity(registry.tileEntity("paint", PaintSplotchesTileEntity.class, PaintSplotchesTileEntity::new).build())
|
||||
this.paint = registry
|
||||
.block("paint", PaintSplotchesBlock::new).features(AEFeature.PAINT_BALLS).tileEntity(registry
|
||||
.tileEntity("paint", PaintSplotchesTileEntity.class, PaintSplotchesTileEntity::new).build())
|
||||
.rendering(new PaintSplotchesRendering()).build();
|
||||
|
||||
this.skyStoneStairs = deco
|
||||
@@ -623,25 +642,32 @@ public final class ApiBlocks implements IBlocks {
|
||||
|
||||
this.itemGen = registry.block("debug_item_gen", ItemGenBlock::new)
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE)
|
||||
.tileEntity(registry.tileEntity("debug_item_gen", ItemGenTileEntity.class, ItemGenTileEntity::new).build()).build();
|
||||
.tileEntity(
|
||||
registry.tileEntity("debug_item_gen", ItemGenTileEntity.class, ItemGenTileEntity::new).build())
|
||||
.build();
|
||||
this.chunkLoader = registry.block("debug_chunk_loader", ChunkLoaderBlock::new)
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE)
|
||||
.tileEntity(
|
||||
registry.tileEntity("debug_chunk_loader", ChunkLoaderTileEntity.class, ChunkLoaderTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("debug_chunk_loader", ChunkLoaderTileEntity.class, ChunkLoaderTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.phantomNode = registry.block("debug_phantom_node", PhantomNodeBlock::new)
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE)
|
||||
.tileEntity(
|
||||
registry.tileEntity("debug_phantom_node", PhantomNodeTileEntity.class, PhantomNodeTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("debug_phantom_node", PhantomNodeTileEntity.class, PhantomNodeTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.cubeGenerator = registry.block("debug_cube_gen", CubeGeneratorBlock::new)
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE)
|
||||
.tileEntity(
|
||||
registry.tileEntity("debug_cube_gen", CubeGeneratorTileEntity.class, CubeGeneratorTileEntity::new).build())
|
||||
.tileEntity(registry
|
||||
.tileEntity("debug_cube_gen", CubeGeneratorTileEntity.class, CubeGeneratorTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
this.energyGenerator = registry.block("debug_energy_gen", EnergyGeneratorBlock::new)
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE).tileEntity(registry
|
||||
.tileEntity("debug_energy_gen", EnergyGeneratorTileEntity.class, EnergyGeneratorTileEntity::new).build())
|
||||
.features(AEFeature.UNSUPPORTED_DEVELOPER_TOOLS, AEFeature.CREATIVE)
|
||||
.tileEntity(registry
|
||||
.tileEntity("debug_energy_gen", EnergyGeneratorTileEntity.class, EnergyGeneratorTileEntity::new)
|
||||
.build())
|
||||
.build();
|
||||
}
|
||||
|
||||
|
||||
@@ -59,17 +59,17 @@ import appeng.parts.misc.InvertedToggleBusPart;
|
||||
import appeng.parts.misc.StorageBusPart;
|
||||
import appeng.parts.misc.ToggleBusPart;
|
||||
import appeng.parts.networking.CoveredCablePart;
|
||||
import appeng.parts.networking.GlassCablePart;
|
||||
import appeng.parts.networking.SmartCablePart;
|
||||
import appeng.parts.networking.CoveredDenseCablePart;
|
||||
import appeng.parts.networking.SmartDenseCablePart;
|
||||
import appeng.parts.networking.GlassCablePart;
|
||||
import appeng.parts.networking.QuartzFiberPart;
|
||||
import appeng.parts.networking.SmartCablePart;
|
||||
import appeng.parts.networking.SmartDenseCablePart;
|
||||
import appeng.parts.p2p.FEP2PTunnelPart;
|
||||
import appeng.parts.p2p.FluidP2PTunnelPart;
|
||||
import appeng.parts.p2p.ItemP2PTunnelPart;
|
||||
import appeng.parts.p2p.LightP2PTunnelPart;
|
||||
import appeng.parts.p2p.RedstoneP2PTunnelPart;
|
||||
import appeng.parts.p2p.MEP2PTunnelPart;
|
||||
import appeng.parts.p2p.RedstoneP2PTunnelPart;
|
||||
import appeng.parts.reporting.ConversionMonitorPart;
|
||||
import appeng.parts.reporting.CraftingTerminalPart;
|
||||
import appeng.parts.reporting.DarkPanelPart;
|
||||
@@ -186,11 +186,13 @@ public final class ApiParts implements IParts {
|
||||
this.p2PTunnelRedstone = createPart(registry, "redstone_p2p_tunnel", PartType.P2P_TUNNEL_REDSTONE,
|
||||
RedstoneP2PTunnelPart::new);
|
||||
this.p2PTunnelItems = createPart(registry, "item_p2p_tunnel", PartType.P2P_TUNNEL_ITEM, ItemP2PTunnelPart::new);
|
||||
this.p2PTunnelFluids = createPart(registry, "fluid_p2p_tunnel", PartType.P2P_TUNNEL_FLUID, FluidP2PTunnelPart::new);
|
||||
this.p2PTunnelFluids = createPart(registry, "fluid_p2p_tunnel", PartType.P2P_TUNNEL_FLUID,
|
||||
FluidP2PTunnelPart::new);
|
||||
this.p2PTunnelEU = null; // FIXME createPart( "ic2_p2p_tunnel", PartType.P2P_TUNNEL_IC2,
|
||||
// PartP2PIC2Power::new);
|
||||
this.p2PTunnelFE = createPart(registry, "fe_p2p_tunnel", PartType.P2P_TUNNEL_FE, FEP2PTunnelPart::new);
|
||||
this.p2PTunnelLight = createPart(registry, "light_p2p_tunnel", PartType.P2P_TUNNEL_LIGHT, LightP2PTunnelPart::new);
|
||||
this.p2PTunnelLight = createPart(registry, "light_p2p_tunnel", PartType.P2P_TUNNEL_LIGHT,
|
||||
LightP2PTunnelPart::new);
|
||||
this.interfaceTerminal = createPart(registry, "interface_terminal", PartType.INTERFACE_TERMINAL,
|
||||
InterfaceTerminalPart::new);
|
||||
this.fluidTerminal = createPart(registry, "fluid_terminal", PartType.FLUID_TERMINAL, FluidTerminalPart::new);
|
||||
|
||||
@@ -40,7 +40,7 @@ public abstract class BasePacket {
|
||||
}
|
||||
|
||||
public final int getPacketID() {
|
||||
return PacketHandlerBase.PacketTypes.getID(this.getClass()).ordinal();
|
||||
return BasePacketHandler.PacketTypes.getID(this.getClass()).ordinal();
|
||||
}
|
||||
|
||||
public void clientPacketData(final INetworkInfo network, final PlayerEntity player) {
|
||||
|
||||
+3
-2
@@ -22,10 +22,11 @@ import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
|
||||
import appeng.core.sync.packets.*;
|
||||
import net.minecraft.network.PacketBuffer;
|
||||
|
||||
public class PacketHandlerBase {
|
||||
import appeng.core.sync.packets.*;
|
||||
|
||||
public class BasePacketHandler {
|
||||
private static final Map<Class<? extends BasePacket>, PacketTypes> REVERSE_LOOKUP = new HashMap<>();
|
||||
|
||||
public enum PacketTypes {
|
||||
@@ -25,9 +25,9 @@ import net.minecraft.network.PacketBuffer;
|
||||
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.BasePacket;
|
||||
import appeng.core.sync.PacketHandlerBase;
|
||||
import appeng.core.sync.BasePacketHandler;
|
||||
|
||||
public class ClientPacketHandler extends PacketHandlerBase implements IPacketHandler {
|
||||
public class ClientPacketHandler extends BasePacketHandler implements IPacketHandler {
|
||||
|
||||
@Override
|
||||
public void onPacketData(final INetworkInfo manager, final INetHandler handler, final PacketBuffer packet,
|
||||
|
||||
@@ -24,9 +24,9 @@ import net.minecraft.network.PacketBuffer;
|
||||
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.BasePacket;
|
||||
import appeng.core.sync.PacketHandlerBase;
|
||||
import appeng.core.sync.BasePacketHandler;
|
||||
|
||||
public final class ServerPacketHandler extends PacketHandlerBase implements IPacketHandler {
|
||||
public final class ServerPacketHandler extends BasePacketHandler implements IPacketHandler {
|
||||
|
||||
@Override
|
||||
public void onPacketData(final INetworkInfo manager, final INetHandler handler, final PacketBuffer packet,
|
||||
|
||||
@@ -61,7 +61,7 @@ public class BlockTransitionEffectPacket extends BasePacket {
|
||||
}
|
||||
|
||||
public BlockTransitionEffectPacket(BlockPos pos, BlockState blockState, AEPartLocation direction,
|
||||
SoundMode soundMode) {
|
||||
SoundMode soundMode) {
|
||||
this.pos = pos;
|
||||
this.blockState = blockState;
|
||||
this.direction = direction;
|
||||
|
||||
@@ -86,12 +86,12 @@ public class ClickPacket extends BasePacket {
|
||||
}
|
||||
|
||||
private ClickPacket(final BlockPos pos, final Direction side, final float hitX, final float hitY, final float hitZ,
|
||||
final Hand hand) {
|
||||
final Hand hand) {
|
||||
this(pos, side, hitX, hitY, hitZ, hand, false);
|
||||
}
|
||||
|
||||
public ClickPacket(final BlockPos pos, final Direction side, final float hitX, final float hitY, final float hitZ,
|
||||
final Hand hand, boolean leftClick) {
|
||||
final Hand hand, boolean leftClick) {
|
||||
|
||||
final PacketBuffer data = new PacketBuffer(Unpooled.buffer());
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ public class CompassResponsePacket extends BasePacket {
|
||||
|
||||
// api
|
||||
public CompassResponsePacket(final CompassRequestPacket req, final boolean hasResult, final boolean spin,
|
||||
final double radians) {
|
||||
final double radians) {
|
||||
|
||||
final PacketBuffer data = new PacketBuffer(Unpooled.buffer());
|
||||
|
||||
|
||||
@@ -18,8 +18,6 @@
|
||||
|
||||
package appeng.core.sync.packets;
|
||||
|
||||
import appeng.client.gui.implementations.CraftingCPUScreen;
|
||||
import appeng.core.sync.BasePacket;
|
||||
import io.netty.buffer.Unpooled;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
@@ -34,6 +32,7 @@ import appeng.api.config.FuzzyMode;
|
||||
import appeng.api.config.Settings;
|
||||
import appeng.api.util.IConfigManager;
|
||||
import appeng.api.util.IConfigurableObject;
|
||||
import appeng.client.gui.implementations.CraftingCPUScreen;
|
||||
import appeng.container.AEBaseContainer;
|
||||
import appeng.container.implementations.CellWorkbenchContainer;
|
||||
import appeng.container.implementations.CraftConfirmContainer;
|
||||
@@ -46,6 +45,7 @@ import appeng.container.implementations.PriorityContainer;
|
||||
import appeng.container.implementations.QuartzKnifeContainer;
|
||||
import appeng.container.implementations.SecurityStationContainer;
|
||||
import appeng.container.implementations.StorageBusContainer;
|
||||
import appeng.core.sync.BasePacket;
|
||||
import appeng.core.sync.network.INetworkInfo;
|
||||
import appeng.fluids.container.FluidLevelEmitterContainer;
|
||||
import appeng.fluids.container.FluidStorageBusContainer;
|
||||
|
||||
@@ -52,7 +52,7 @@ public class MatterCannonPacket extends BasePacket {
|
||||
|
||||
// api
|
||||
public MatterCannonPacket(final double x, final double y, final double z, final float dx, final float dy,
|
||||
final float dz, final byte len) {
|
||||
final float dz, final byte len) {
|
||||
final float dl = dx * dx + dy * dy + dz * dz;
|
||||
final float dlz = (float) Math.sqrt(dl);
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ public abstract class AEBaseItemEntity extends ItemEntity {
|
||||
}
|
||||
|
||||
protected AEBaseItemEntity(EntityType<? extends AEBaseItemEntity> entityType, final World world, final double x,
|
||||
final double y, final double z, final ItemStack stack) {
|
||||
final double y, final double z, final ItemStack stack) {
|
||||
this(entityType, world);
|
||||
this.setPosition(x, y, z);
|
||||
this.rotationYaw = this.rand.nextFloat() * 360.0F;
|
||||
|
||||
@@ -58,7 +58,7 @@ public final class TinyTNTPrimedEntity extends TNTEntity implements IEntityAddit
|
||||
}
|
||||
|
||||
public TinyTNTPrimedEntity(final World w, final double x, final double y, final double z,
|
||||
final LivingEntity igniter) {
|
||||
final LivingEntity igniter) {
|
||||
super(w, x, y, z, igniter);
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ public class TinyTNTPrimedRenderer extends EntityRenderer<TinyTNTPrimedEntity> {
|
||||
|
||||
@Override
|
||||
public void render(TinyTNTPrimedEntity tnt, float entityYaw, float partialTicks, MatrixStack mStack,
|
||||
IRenderTypeBuffer buffers, int packedLight) {
|
||||
IRenderTypeBuffer buffers, int packedLight) {
|
||||
final BlockRendererDispatcher blockrendererdispatcher = Minecraft.getInstance().getBlockRendererDispatcher();
|
||||
mStack.push();
|
||||
mStack.translate(0, 0.25F, 0);
|
||||
|
||||
@@ -17,7 +17,7 @@ import appeng.fluids.util.IAEFluidTank;
|
||||
|
||||
public class FluidFormationPlaneScreen extends UpgradeableScreen<FluidFormationPlaneContainer> {
|
||||
public FluidFormationPlaneScreen(FluidFormationPlaneContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 251;
|
||||
}
|
||||
|
||||
@@ -35,7 +35,8 @@ import appeng.fluids.helper.DualityFluidInterface;
|
||||
import appeng.fluids.util.IAEFluidTank;
|
||||
|
||||
public class FluidInterfaceScreen extends UpgradeableScreen<FluidInterfaceContainer> {
|
||||
public FluidInterfaceScreen(FluidInterfaceContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public FluidInterfaceScreen(FluidInterfaceContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 231;
|
||||
}
|
||||
@@ -54,8 +55,8 @@ public class FluidInterfaceScreen extends UpgradeableScreen<FluidInterfaceContai
|
||||
this.guiSlots.add(new FluidSlotWidget(configFluids, i, i, 35 + 18 * i, 35));
|
||||
}
|
||||
|
||||
this.addButton(new TabButton(this.getGuiLeft() + 154, this.getGuiTop(), 2 + 4 * 16,
|
||||
GuiText.Priority.getLocal(), this.itemRenderer, btn -> openPriorityGui()));
|
||||
this.addButton(new TabButton(this.getGuiLeft() + 154, this.getGuiTop(), 2 + 4 * 16, GuiText.Priority.getLocal(),
|
||||
this.itemRenderer, btn -> openPriorityGui()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -22,7 +22,7 @@ public class FluidLevelEmitterScreen extends UpgradeableScreen<FluidLevelEmitter
|
||||
private NumberBox level;
|
||||
|
||||
public FluidLevelEmitterScreen(FluidLevelEmitterContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
}
|
||||
|
||||
|
||||
@@ -34,8 +34,8 @@ import appeng.client.gui.widgets.TabButton;
|
||||
import appeng.container.implementations.PriorityContainer;
|
||||
import appeng.core.localization.GuiText;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.SwitchGuisPacket;
|
||||
import appeng.fluids.client.gui.widgets.FluidSlotWidget;
|
||||
import appeng.fluids.client.gui.widgets.OptionalFluidSlotWidget;
|
||||
import appeng.fluids.container.FluidStorageBusContainer;
|
||||
@@ -51,7 +51,7 @@ public class FluidStorageBusScreen extends UpgradeableScreen<FluidStorageBusCont
|
||||
private SettingToggleButton<StorageFilter> storageFilter;
|
||||
|
||||
public FluidStorageBusScreen(FluidStorageBusContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.ySize = 251;
|
||||
}
|
||||
@@ -88,8 +88,8 @@ public class FluidStorageBusScreen extends UpgradeableScreen<FluidStorageBusCont
|
||||
this.fuzzyMode = new ServerSettingToggleButton<>(this.guiLeft - 18, this.guiTop + 88, Settings.FUZZY_MODE,
|
||||
FuzzyMode.IGNORE_ALL);
|
||||
|
||||
addButton(this.addButton(new TabButton(this.guiLeft + 154, this.guiTop, 2 + 4 * 16,
|
||||
GuiText.Priority.getLocal(), this.itemRenderer, btn -> openPriorityGui())));
|
||||
addButton(this.addButton(new TabButton(this.guiLeft + 154, this.guiTop, 2 + 4 * 16, GuiText.Priority.getLocal(),
|
||||
this.itemRenderer, btn -> openPriorityGui())));
|
||||
|
||||
this.addButton(this.storageFilter);
|
||||
this.addButton(this.fuzzyMode);
|
||||
|
||||
@@ -41,10 +41,10 @@ import appeng.api.storage.data.IAEFluidStack;
|
||||
import appeng.api.util.IConfigManager;
|
||||
import appeng.client.ActionKey;
|
||||
import appeng.client.gui.AEBaseMEScreen;
|
||||
import appeng.client.gui.widgets.AETextField;
|
||||
import appeng.client.gui.widgets.ISortSource;
|
||||
import appeng.client.gui.widgets.Scrollbar;
|
||||
import appeng.client.gui.widgets.SettingToggleButton;
|
||||
import appeng.client.gui.widgets.ISortSource;
|
||||
import appeng.client.gui.widgets.AETextField;
|
||||
import appeng.client.me.FluidRepo;
|
||||
import appeng.client.me.InternalFluidSlotME;
|
||||
import appeng.client.me.SlotFluidME;
|
||||
@@ -52,8 +52,8 @@ import appeng.core.AELog;
|
||||
import appeng.core.AppEng;
|
||||
import appeng.core.localization.GuiText;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.InventoryActionPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.InventoryActionPacket;
|
||||
import appeng.fluids.container.FluidTerminalContainer;
|
||||
import appeng.fluids.container.slots.IMEFluidSlot;
|
||||
import appeng.helpers.InventoryAction;
|
||||
@@ -65,7 +65,8 @@ import appeng.util.Platform;
|
||||
* @version rv6 - 12/05/2018
|
||||
* @since rv6 12/05/2018
|
||||
*/
|
||||
public class FluidTerminalScreen extends AEBaseMEScreen<FluidTerminalContainer> implements ISortSource, IConfigManagerHost {
|
||||
public class FluidTerminalScreen extends AEBaseMEScreen<FluidTerminalContainer>
|
||||
implements ISortSource, IConfigManagerHost {
|
||||
private final List<SlotFluidME> meFluidSlots = new LinkedList<>();
|
||||
private final FluidRepo repo;
|
||||
private final IConfigManager configSrc;
|
||||
@@ -79,7 +80,8 @@ public class FluidTerminalScreen extends AEBaseMEScreen<FluidTerminalContainer>
|
||||
private SettingToggleButton<SortOrder> sortByBox;
|
||||
private SettingToggleButton<SortDir> sortDirBox;
|
||||
|
||||
public FluidTerminalScreen(FluidTerminalContainer container, PlayerInventory playerInventory, ITextComponent title) {
|
||||
public FluidTerminalScreen(FluidTerminalContainer container, PlayerInventory playerInventory,
|
||||
ITextComponent title) {
|
||||
super(container, playerInventory, title);
|
||||
this.xSize = 185;
|
||||
this.ySize = 222;
|
||||
@@ -108,8 +110,8 @@ public class FluidTerminalScreen extends AEBaseMEScreen<FluidTerminalContainer>
|
||||
getSortBy(), Platform::isSortOrderAvailable, this::toggleServerSetting));
|
||||
offset += 20;
|
||||
|
||||
this.sortDirBox = this.addButton(new SettingToggleButton<>(this.guiLeft - 18, offset,
|
||||
Settings.SORT_DIRECTION, getSortDir(), this::toggleServerSetting));
|
||||
this.sortDirBox = this.addButton(new SettingToggleButton<>(this.guiLeft - 18, offset, Settings.SORT_DIRECTION,
|
||||
getSortDir(), this::toggleServerSetting));
|
||||
|
||||
for (int y = 0; y < ROWS; y++) {
|
||||
for (int x = 0; x < COLS; x++) {
|
||||
|
||||
@@ -16,7 +16,7 @@ public class OptionalFluidSlotWidget extends FluidSlotWidget {
|
||||
private final int srcY;
|
||||
|
||||
public OptionalFluidSlotWidget(IAEFluidTank fluids, final IOptionalSlotHost containerBus, int slot, int id,
|
||||
int groupNum, int x, int y, int xoffs, int yoffs) {
|
||||
int groupNum, int x, int y, int xoffs, int yoffs) {
|
||||
super(fluids, slot, id, x + xoffs * 18, y + yoffs * 18);
|
||||
this.containerBus = containerBus;
|
||||
this.groupNum = groupNum;
|
||||
|
||||
@@ -67,9 +67,9 @@ import appeng.container.guisync.GuiSync;
|
||||
import appeng.container.implementations.ContainerHelper;
|
||||
import appeng.core.AELog;
|
||||
import appeng.core.sync.network.NetworkHandler;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.core.sync.packets.MEFluidInventoryUpdatePacket;
|
||||
import appeng.core.sync.packets.TargetFluidStackPacket;
|
||||
import appeng.core.sync.packets.ConfigValuePacket;
|
||||
import appeng.fluids.util.AEFluidStack;
|
||||
import appeng.helpers.InventoryAction;
|
||||
import appeng.me.helpers.ChannelPowerSrc;
|
||||
|
||||
@@ -51,7 +51,8 @@ import appeng.fluids.helper.IFluidInterfaceHost;
|
||||
import appeng.helpers.IPriorityHost;
|
||||
import appeng.tile.grid.AENetworkTileEntity;
|
||||
|
||||
public class FluidInterfaceTileEntity extends AENetworkTileEntity implements IGridTickable, IFluidInterfaceHost, IPriorityHost {
|
||||
public class FluidInterfaceTileEntity extends AENetworkTileEntity
|
||||
implements IGridTickable, IFluidInterfaceHost, IPriorityHost {
|
||||
private final DualityFluidInterface duality = new DualityFluidInterface(this.getProxy(), this);
|
||||
|
||||
public FluidInterfaceTileEntity(TileEntityType<?> tileEntityTypeIn) {
|
||||
|
||||
@@ -35,8 +35,8 @@ import appeng.tile.misc.ChargerTileEntity;
|
||||
public class ChargerInfoProvider implements ITileProbInfoProvider {
|
||||
|
||||
@Override
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player, World world,
|
||||
BlockState blockState, IProbeHitData data) {
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player,
|
||||
World world, BlockState blockState, IProbeHitData data) {
|
||||
if (tile instanceof ChargerTileEntity) {
|
||||
final ChargerTileEntity charger = (ChargerTileEntity) tile;
|
||||
final IItemHandler chargerInventory = charger.getInternalInventory();
|
||||
|
||||
+2
-2
@@ -36,8 +36,8 @@ import appeng.tile.crafting.CraftingMonitorTileEntity;
|
||||
public class CraftingMonitorInfoProvider implements ITileProbInfoProvider {
|
||||
|
||||
@Override
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player, World world,
|
||||
BlockState blockState, IProbeHitData data) {
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player,
|
||||
World world, BlockState blockState, IProbeHitData data) {
|
||||
if (tile instanceof CraftingMonitorTileEntity) {
|
||||
final CraftingMonitorTileEntity monitor = (CraftingMonitorTileEntity) tile;
|
||||
final IAEItemStack displayStack = monitor.getJobProgress();
|
||||
|
||||
+1
-1
@@ -41,5 +41,5 @@ public interface ITileProbInfoProvider {
|
||||
* World, IBlockState, IProbeHitData)
|
||||
*/
|
||||
void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player, World world,
|
||||
BlockState blockState, IProbeHitData data);
|
||||
BlockState blockState, IProbeHitData data);
|
||||
}
|
||||
|
||||
+2
-2
@@ -33,8 +33,8 @@ import appeng.tile.AEBaseTileEntity;
|
||||
public class PowerStateInfoProvider implements ITileProbInfoProvider {
|
||||
|
||||
@Override
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player, World world,
|
||||
BlockState blockState, IProbeHitData data) {
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player,
|
||||
World world, BlockState blockState, IProbeHitData data) {
|
||||
if (tile instanceof IPowerChannelState) {
|
||||
final IPowerChannelState state = (IPowerChannelState) tile;
|
||||
|
||||
|
||||
+2
-2
@@ -34,8 +34,8 @@ import appeng.util.Platform;
|
||||
public class PowerStorageInfoProvider implements ITileProbInfoProvider {
|
||||
|
||||
@Override
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player, World world,
|
||||
BlockState blockState, IProbeHitData data) {
|
||||
public void addProbeInfo(AEBaseTileEntity tile, ProbeMode mode, IProbeInfo probeInfo, PlayerEntity player,
|
||||
World world, BlockState blockState, IProbeHitData data) {
|
||||
if (tile instanceof IAEPowerStorage) {
|
||||
final IAEPowerStorage storage = (IAEPowerStorage) tile;
|
||||
final double maxPower = storage.getAEMaxPower();
|
||||
|
||||
@@ -47,17 +47,17 @@ import appeng.parts.misc.InvertedToggleBusPart;
|
||||
import appeng.parts.misc.StorageBusPart;
|
||||
import appeng.parts.misc.ToggleBusPart;
|
||||
import appeng.parts.networking.CoveredCablePart;
|
||||
import appeng.parts.networking.GlassCablePart;
|
||||
import appeng.parts.networking.SmartCablePart;
|
||||
import appeng.parts.networking.CoveredDenseCablePart;
|
||||
import appeng.parts.networking.SmartDenseCablePart;
|
||||
import appeng.parts.networking.GlassCablePart;
|
||||
import appeng.parts.networking.QuartzFiberPart;
|
||||
import appeng.parts.networking.SmartCablePart;
|
||||
import appeng.parts.networking.SmartDenseCablePart;
|
||||
import appeng.parts.p2p.FEP2PTunnelPart;
|
||||
import appeng.parts.p2p.FluidP2PTunnelPart;
|
||||
import appeng.parts.p2p.ItemP2PTunnelPart;
|
||||
import appeng.parts.p2p.LightP2PTunnelPart;
|
||||
import appeng.parts.p2p.RedstoneP2PTunnelPart;
|
||||
import appeng.parts.p2p.MEP2PTunnelPart;
|
||||
import appeng.parts.p2p.RedstoneP2PTunnelPart;
|
||||
import appeng.parts.reporting.ConversionMonitorPart;
|
||||
import appeng.parts.reporting.CraftingTerminalPart;
|
||||
import appeng.parts.reporting.DarkPanelPart;
|
||||
|
||||
+1
-1
@@ -36,8 +36,8 @@ import appeng.api.networking.events.MENetworkPowerStatusChange;
|
||||
import appeng.api.networking.ticking.ITickManager;
|
||||
import appeng.core.AELog;
|
||||
import appeng.me.cache.helpers.TunnelCollection;
|
||||
import appeng.parts.p2p.P2PTunnelPart;
|
||||
import appeng.parts.p2p.MEP2PTunnelPart;
|
||||
import appeng.parts.p2p.P2PTunnelPart;
|
||||
|
||||
public class P2PCache implements IGridCache {
|
||||
private static final TunnelCollection<P2PTunnelPart> NULL_COLLECTION = new TunnelCollection<P2PTunnelPart>(null,
|
||||
|
||||
@@ -68,7 +68,7 @@ public class MolecularAssemblerRenderer extends TileEntityRenderer<MolecularAsse
|
||||
|
||||
@Override
|
||||
public void render(MolecularAssemblerTileEntity molecularAssembler, float partialTicks, MatrixStack ms,
|
||||
IRenderTypeBuffer bufferIn, int combinedLightIn, int combinedOverlayIn) {
|
||||
IRenderTypeBuffer bufferIn, int combinedLightIn, int combinedOverlayIn) {
|
||||
|
||||
AssemblerAnimationStatus status = molecularAssembler.getAnimationStatus();
|
||||
if (status != null) {
|
||||
@@ -105,8 +105,8 @@ public class MolecularAssemblerRenderer extends TileEntityRenderer<MolecularAsse
|
||||
lightsModel, 1, 1, 1, combinedLightIn, combinedOverlayIn, EmptyModelData.INSTANCE);
|
||||
}
|
||||
|
||||
private void renderStatus(MolecularAssemblerTileEntity molecularAssembler, MatrixStack ms, IRenderTypeBuffer bufferIn,
|
||||
int combinedLightIn, AssemblerAnimationStatus status) {
|
||||
private void renderStatus(MolecularAssemblerTileEntity molecularAssembler, MatrixStack ms,
|
||||
IRenderTypeBuffer bufferIn, int combinedLightIn, AssemblerAnimationStatus status) {
|
||||
double centerX = molecularAssembler.getPos().getX() + 0.5f;
|
||||
double centerY = molecularAssembler.getPos().getY() + 0.5f;
|
||||
double centerZ = molecularAssembler.getPos().getZ() + 0.5f;
|
||||
|
||||
@@ -42,7 +42,8 @@ import appeng.util.helpers.ItemHandlerUtil;
|
||||
import appeng.util.inv.IAEAppEngInventory;
|
||||
import appeng.util.inv.InvOperation;
|
||||
|
||||
public class CellWorkbenchTileEntity extends AEBaseTileEntity implements IUpgradeableHost, IAEAppEngInventory, IConfigManagerHost {
|
||||
public class CellWorkbenchTileEntity extends AEBaseTileEntity
|
||||
implements IUpgradeableHost, IAEAppEngInventory, IConfigManagerHost {
|
||||
|
||||
private final AppEngInternalInventory cell = new AppEngInternalInventory(this, 1);
|
||||
private final AppEngInternalAEInventory config = new AppEngInternalAEInventory(this, 63);
|
||||
|
||||
@@ -73,7 +73,8 @@ import appeng.util.item.AEItemStack;
|
||||
* @version rv2
|
||||
* @since rv0
|
||||
*/
|
||||
public class InscriberTileEntity extends AENetworkPowerTileEntity implements IGridTickable, IUpgradeableHost, IConfigManagerHost {
|
||||
public class InscriberTileEntity extends AENetworkPowerTileEntity
|
||||
implements IGridTickable, IUpgradeableHost, IConfigManagerHost {
|
||||
private final int maxProcessingTime = 100;
|
||||
|
||||
private final IConfigManager settings;
|
||||
@@ -414,7 +415,8 @@ public class InscriberTileEntity extends AENetworkPowerTileEntity implements IGr
|
||||
return false;
|
||||
}
|
||||
|
||||
return inv == InscriberTileEntity.this.topItemHandler || inv == InscriberTileEntity.this.bottomItemHandler || slot == 1;
|
||||
return inv == InscriberTileEntity.this.topItemHandler || inv == InscriberTileEntity.this.bottomItemHandler
|
||||
|| slot == 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -80,8 +80,8 @@ import appeng.util.inv.IAEAppEngInventory;
|
||||
import appeng.util.inv.InvOperation;
|
||||
import appeng.util.item.AEItemStack;
|
||||
|
||||
public class SecurityStationTileEntity extends AENetworkTileEntity implements ITerminalHost, IAEAppEngInventory, ILocatable,
|
||||
IConfigManagerHost, ISecurityProvider, IColorableTile {
|
||||
public class SecurityStationTileEntity extends AENetworkTileEntity implements ITerminalHost, IAEAppEngInventory,
|
||||
ILocatable, IConfigManagerHost, ISecurityProvider, IColorableTile {
|
||||
|
||||
private static int difference = 0;
|
||||
private final AppEngInternalInventory configSlot = new AppEngInternalInventory(this, 1);
|
||||
|
||||
@@ -35,7 +35,7 @@ public class CableBusTESR extends TileEntityRenderer<CableBusTileEntity> {
|
||||
|
||||
@Override
|
||||
public void render(CableBusTileEntity te, float partialTicks, MatrixStack ms, IRenderTypeBuffer buffers,
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
int combinedLightIn, int combinedOverlayIn) {
|
||||
if (!te.getCableBus().isRequiresDynamicRender()) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -41,7 +41,8 @@ import appeng.api.networking.events.MENetworkPowerStorage.PowerEventType;
|
||||
import appeng.capabilities.Capabilities;
|
||||
import appeng.tile.AEBaseInvTileEntity;
|
||||
|
||||
public abstract class AEBasePoweredTileEntity extends AEBaseInvTileEntity implements IAEPowerStorage, IExternalPowerSink {
|
||||
public abstract class AEBasePoweredTileEntity extends AEBaseInvTileEntity
|
||||
implements IAEPowerStorage, IExternalPowerSink {
|
||||
|
||||
// values that determine general function, are set by inheriting classes if
|
||||
// needed. These should generally remain static.
|
||||
|
||||
@@ -588,7 +588,8 @@ public class ChestTileEntity extends AENetworkPowerTileEntity
|
||||
@Override
|
||||
public boolean isValid(final Object verificationToken) {
|
||||
ChestTileEntity.this.updateHandler();
|
||||
if (ChestTileEntity.this.cellHandler != null && this.chan == ChestTileEntity.this.cellHandler.getChannel()) {
|
||||
if (ChestTileEntity.this.cellHandler != null
|
||||
&& this.chan == ChestTileEntity.this.cellHandler.getChannel()) {
|
||||
return verificationToken == ChestTileEntity.this.cellHandler;
|
||||
}
|
||||
return false;
|
||||
@@ -704,8 +705,8 @@ public class ChestTileEntity extends AENetworkPowerTileEntity
|
||||
private class FluidHandler implements IFluidHandler, IFluidTank {
|
||||
|
||||
private boolean canAcceptLiquids() {
|
||||
return ChestTileEntity.this.cellHandler != null && ChestTileEntity.this.cellHandler.getChannel() == AEApi.instance()
|
||||
.storage().getStorageChannel(IFluidStorageChannel.class);
|
||||
return ChestTileEntity.this.cellHandler != null && ChestTileEntity.this.cellHandler.getChannel() == AEApi
|
||||
.instance().storage().getStorageChannel(IFluidStorageChannel.class);
|
||||
}
|
||||
|
||||
@Nonnull
|
||||
@@ -754,8 +755,9 @@ public class ChestTileEntity extends AENetworkPowerTileEntity
|
||||
public int fill(FluidStack resource, FluidAction action) {
|
||||
ChestTileEntity.this.updateHandler();
|
||||
if (canAcceptLiquids()) {
|
||||
final IAEFluidStack results = Platform.poweredInsert(ChestTileEntity.this, ChestTileEntity.this.cellHandler,
|
||||
AEFluidStack.fromFluidStack(resource), ChestTileEntity.this.mySrc,
|
||||
final IAEFluidStack results = Platform.poweredInsert(ChestTileEntity.this,
|
||||
ChestTileEntity.this.cellHandler, AEFluidStack.fromFluidStack(resource),
|
||||
ChestTileEntity.this.mySrc,
|
||||
action == FluidAction.EXECUTE ? Actionable.MODULATE : Actionable.SIMULATE);
|
||||
|
||||
if (results == null) {
|
||||
@@ -789,8 +791,8 @@ public class ChestTileEntity extends AENetworkPowerTileEntity
|
||||
public boolean allowInsert(IItemHandler inv, int slot, ItemStack stack) {
|
||||
if (ChestTileEntity.this.isPowered()) {
|
||||
ChestTileEntity.this.updateHandler();
|
||||
return ChestTileEntity.this.cellHandler != null && ChestTileEntity.this.cellHandler.getChannel() == AEApi.instance()
|
||||
.storage().getStorageChannel(IItemStorageChannel.class);
|
||||
return ChestTileEntity.this.cellHandler != null && ChestTileEntity.this.cellHandler
|
||||
.getChannel() == AEApi.instance().storage().getStorageChannel(IItemStorageChannel.class);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -22,7 +22,6 @@ import java.util.IdentityHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import appeng.tile.grid.AENetworkInvTileEntity;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundNBT;
|
||||
@@ -62,6 +61,7 @@ import appeng.me.GridAccessException;
|
||||
import appeng.me.helpers.MachineSource;
|
||||
import appeng.parts.automation.BlockUpgradeInventory;
|
||||
import appeng.parts.automation.UpgradeInventory;
|
||||
import appeng.tile.grid.AENetworkInvTileEntity;
|
||||
import appeng.tile.inventory.AppEngInternalInventory;
|
||||
import appeng.util.ConfigManager;
|
||||
import appeng.util.IConfigManagerHost;
|
||||
@@ -74,7 +74,8 @@ import appeng.util.inv.WrapperChainedItemHandler;
|
||||
import appeng.util.inv.WrapperFilteredItemHandler;
|
||||
import appeng.util.inv.filter.AEItemFilters;
|
||||
|
||||
public class IOPortTileEntity extends AENetworkInvTileEntity implements IUpgradeableHost, IConfigManagerHost, IGridTickable {
|
||||
public class IOPortTileEntity extends AENetworkInvTileEntity
|
||||
implements IUpgradeableHost, IConfigManagerHost, IGridTickable {
|
||||
private static final int NUMBER_OF_CELL_SLOTS = 6;
|
||||
private static final int NUMBER_OF_UPGRADE_SLOTS = 3;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user