initial commit
This commit is contained in:
parent
3c9ee26b06
commit
22186c33b9
1458 changed files with 282792 additions and 0 deletions
50
java/src/game/gui/GuiBrewing.java
Executable file
50
java/src/game/gui/GuiBrewing.java
Executable file
|
@ -0,0 +1,50 @@
|
|||
package game.gui;
|
||||
|
||||
import game.inventory.ContainerBrewingStand;
|
||||
import game.inventory.IInventory;
|
||||
import game.inventory.InventoryPlayer;
|
||||
|
||||
|
||||
public class GuiBrewing extends GuiContainer
|
||||
{
|
||||
// private static final String brewingStandGuiTextures = "textures/gui/brewing_stand.png";
|
||||
|
||||
/** The player inventory bound to this GUI. */
|
||||
private final InventoryPlayer playerInventory;
|
||||
private IInventory tileBrewingStand;
|
||||
|
||||
public GuiBrewing(InventoryPlayer playerInv, IInventory p_i45506_2_)
|
||||
{
|
||||
super(new ContainerBrewingStand(playerInv, p_i45506_2_));
|
||||
this.playerInventory = playerInv;
|
||||
this.tileBrewingStand = p_i45506_2_;
|
||||
}
|
||||
|
||||
/**
|
||||
* Draw the foreground layer for the GuiContainer (everything in front of the items). Args : mouseX, mouseY
|
||||
*/
|
||||
public void drawGuiContainerForegroundLayer()
|
||||
{
|
||||
String s = this.tileBrewingStand.getCommandName();
|
||||
this.drawString(s, 8, 6);
|
||||
this.drawString(this.playerInventory.getCommandName(), 8, this.ySize - 96 + 2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Args : renderPartialTicks, mouseX, mouseY
|
||||
*/
|
||||
public void drawGuiContainerBackgroundLayer()
|
||||
{
|
||||
int k = this.tileBrewingStand.getField(0);
|
||||
|
||||
if (k > 0)
|
||||
{
|
||||
int l = (int)(28.0F * (1.0F - (float)k / 400.0F));
|
||||
|
||||
if (l > 0)
|
||||
{
|
||||
this.rect(97, 16, 9, l, 0xffff20);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue