reformatted all src files (#141)

This commit is contained in:
YoungOnion
2022-09-17 05:08:02 -06:00
committed by GitHub
parent 3328bfcda2
commit 9011273229
1056 changed files with 88127 additions and 110597 deletions
@@ -19,11 +19,6 @@
package appeng.client.gui.implementations;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.inventory.Container;
import net.minecraft.inventory.Slot;
import appeng.api.config.ActionItems;
import appeng.api.config.Settings;
import appeng.api.storage.ITerminalHost;
@@ -34,62 +29,56 @@ import appeng.core.localization.GuiText;
import appeng.core.sync.network.NetworkHandler;
import appeng.core.sync.packets.PacketInventoryAction;
import appeng.helpers.InventoryAction;
import net.minecraft.client.gui.GuiButton;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.inventory.Container;
import net.minecraft.inventory.Slot;
public class GuiCraftingTerm extends GuiMEMonitorable
{
public class GuiCraftingTerm extends GuiMEMonitorable {
private GuiImgButton clearBtn;
private GuiImgButton clearBtn;
public GuiCraftingTerm( final InventoryPlayer inventoryPlayer, final ITerminalHost te )
{
super( inventoryPlayer, te, new ContainerCraftingTerm( inventoryPlayer, te ) );
this.setReservedSpace( 73 );
}
public GuiCraftingTerm(final InventoryPlayer inventoryPlayer, final ITerminalHost te) {
super(inventoryPlayer, te, new ContainerCraftingTerm(inventoryPlayer, te));
this.setReservedSpace(73);
}
@Override
protected void actionPerformed( final GuiButton btn )
{
super.actionPerformed( btn );
@Override
protected void actionPerformed(final GuiButton btn) {
super.actionPerformed(btn);
if( this.clearBtn == btn )
{
Slot s = null;
final Container c = this.inventorySlots;
for( final Object j : c.inventorySlots )
{
if( j instanceof SlotCraftingMatrix )
{
s = (Slot) j;
}
}
if (this.clearBtn == btn) {
Slot s = null;
final Container c = this.inventorySlots;
for (final Object j : c.inventorySlots) {
if (j instanceof SlotCraftingMatrix) {
s = (Slot) j;
}
}
if( s != null )
{
final PacketInventoryAction p = new PacketInventoryAction( InventoryAction.MOVE_REGION, s.slotNumber, 0 );
NetworkHandler.instance().sendToServer( p );
}
}
}
if (s != null) {
final PacketInventoryAction p = new PacketInventoryAction(InventoryAction.MOVE_REGION, s.slotNumber, 0);
NetworkHandler.instance().sendToServer(p);
}
}
}
@Override
public void initGui()
{
super.initGui();
this.buttonList.add( this.clearBtn = new GuiImgButton( this.guiLeft + 92, this.guiTop + this.ySize - 156, Settings.ACTIONS, ActionItems.STASH ) );
this.clearBtn.setHalfSize( true );
}
@Override
public void initGui() {
super.initGui();
this.buttonList.add(this.clearBtn = new GuiImgButton(this.guiLeft + 92, this.guiTop + this.ySize - 156, Settings.ACTIONS, ActionItems.STASH));
this.clearBtn.setHalfSize(true);
}
@Override
public void drawFG( final int offsetX, final int offsetY, final int mouseX, final int mouseY )
{
super.drawFG( offsetX, offsetY, mouseX, mouseY );
this.fontRenderer.drawString( GuiText.CraftingTerminal.getLocal(), 8, this.ySize - 96 + 1 - this.getReservedSpace(), 4210752 );
}
@Override
public void drawFG(final int offsetX, final int offsetY, final int mouseX, final int mouseY) {
super.drawFG(offsetX, offsetY, mouseX, mouseY);
this.fontRenderer.drawString(GuiText.CraftingTerminal.getLocal(), 8, this.ySize - 96 + 1 - this.getReservedSpace(), 4210752);
}
@Override
protected String getBackground()
{
return "guis/crafting.png";
}
@Override
protected String getBackground() {
return "guis/crafting.png";
}
}