當前位置: 首頁>>代碼示例>>Java>>正文


Java PlayerInventory.drawInventory方法代碼示例

本文整理匯總了Java中com.bioxx.tfc.Core.Player.PlayerInventory.drawInventory方法的典型用法代碼示例。如果您正苦於以下問題:Java PlayerInventory.drawInventory方法的具體用法?Java PlayerInventory.drawInventory怎麽用?Java PlayerInventory.drawInventory使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在com.bioxx.tfc.Core.Player.PlayerInventory的用法示例。


在下文中一共展示了PlayerInventory.drawInventory方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;
    int v = WindowHeight;

    drawTexturedModalRect(w, h, 0, v, xSize, ySize);
    
    drawDie(w, h);

    drawCenteredString(StatCollector.translateToLocal("gui.Trussel.Title"), w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);
    this.fontRendererObj.drawString(StatCollector.translateToLocal("gui.Trussel.Name") + ":",  w + _nameLabelX, h + _nameLabelY, _colorDefaultText);
    this.fontRendererObj.drawString(_name,  w + _nameX, h + _nameY, _colorDefaultText);
    this.fontRendererObj.drawString(StatCollector.translateToLocal("gui.Trussel.Weight") + ":",  w + _weightLabelX, h + _weightLabelY, _colorDefaultText);
    this.fontRendererObj.drawString(_weight,  w + _weightX, h + _weightY, _colorDefaultText);
    this.fontRendererObj.drawString(StatCollector.translateToLocal("gui.Trussel.Die") + ":",  w + _dieLabelX, h + _dieLabelY, _colorDefaultText);

    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
    
    _copyButton.enabled = this.inventorySlots.getSlot(0).getStack() != null;
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:25,代碼來源:GuiTrussel.java

示例2: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;
    int v = 0;

    drawTexturedModalRect(w, h, 0, v, xSize, ySize);
    
    drawCenteredString(StatCollector.translateToLocal("gui.StallLimit.Title"), w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);
    drawRightAlignedString(StatCollector.translateToLocal("gui.StallLimit.Limit"), w + _limitLabelX, h + _limitLabelY, _limitLabelWidth, _colorDefaultText);
    
    _limitTextField.drawTextBox();
    
    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:19,代碼來源:GuiStallLimit.java

示例3: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    resetQuantities();
    
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;
    int v = _isOwnerMode ? 0: WindowHeight;

    drawTexturedModalRect(w, h, 0, v, xSize, ySize);
    
    String inventoryName = StatCollector.translateToLocal(_stall.getInventoryName());
    String title = !_stall.getIsOwnerSpecified() ? inventoryName: inventoryName + " (" + _stall.getOwnerUserName() + ")";

    drawCenteredString(title, w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);
    drawCenteredString(StatCollector.translateToLocal("gui.Stall.Prices"), w + _pricesTitleX, h + _pricesTitleY, _columnTitleWidth, _colorDefaultText);
    drawCenteredString(StatCollector.translateToLocal("gui.Stall.Goods"), w + _goodsTitleX, h + _goodsTitleY, _columnTitleWidth, _colorDefaultText);
    
    drawWarehouseText(w, h);
    drawQuantities(w, h);
    
    if(_isOwnerMode)
    {
        for(int i = 0; i < _stall.GoodsSlotIndexes.length; i++)
        {
            int limit = _stall.getLimitByGoodSlotIndex(_stall.GoodsSlotIndexes[i]);
            String limitText = limit > 0 ? String.valueOf(limit): StatCollector.translateToLocal("gui.Stall.NA");
            
            _limitButtons[i].setText(limitText, this.fontRendererObj);
        }
    }

    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:37,代碼來源:GuiStall.java

示例4: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;

    drawTexturedModalRect(w, h, 0, 0, xSize, ySize);
    
    String inventoryName = StatCollector.translateToLocal(_storageRack.getInventoryName());

    drawCenteredString(inventoryName, w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);

    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:17,代碼來源:GuiStorageRack.java

示例5: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;

    drawTexturedModalRect(w, h, 0, 0, xSize, ySize);
    
    String inventoryName = StatCollector.translateToLocal(_warehouse.getInventoryName());

    drawCenteredString(inventoryName, w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);
    drawCoords(w, h);
    
    _signButton.enabled = _warehouse.getStackInSlot(0) != null;

    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:20,代碼來源:GuiWarehouse.java

示例6: drawGuiContainerBackgroundLayer

import com.bioxx.tfc.Core.Player.PlayerInventory; //導入方法依賴的package包/類
@Override
protected void drawGuiContainerBackgroundLayer(float f, int mouseX, int mouseY)
{
    bindTexture(_texture);
    
    int w = (width - xSize) / 2;
    int h = (height - ySize) / 2;
    int v = 0;

    drawTexturedModalRect(w, h, 0, v, xSize, ySize);
    
    drawBar(w, h);

    drawCenteredString(StatCollector.translateToLocal("gui.AnvilDie.Title"), w + _titleX, h + _titleY, WindowWidth, _colorDefaultText);

    PlayerInventory.drawInventory(this, width, height, ySize - PlayerInventory.invYSize);
    
    _mintButton.enabled = _tileEntity.canMint();
}
 
開發者ID:Aleksey-Terzi,項目名稱:MerchantsTFC,代碼行數:20,代碼來源:GuiAnvilDie.java


注:本文中的com.bioxx.tfc.Core.Player.PlayerInventory.drawInventory方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。