@Override public final void initGui() { super.initGui(); if(PersistentVariableHelper.firstLoad) { PersistentVariableHelper.firstLoad = false; PersistentVariableHelper.saveSafe(); } String key = getNotesKey(); if(notes.containsKey(key)) note = notes.get(key); onInitGui(); putTutorialArrow(); }
@Override public void initGui() { super.initGui(); guiLeft = width / 2 - xSize / 2 + xCenterOffset; guiTop = height / 2 - ySize / 2 + yCenterOffset; right = width / 2 + xSize / 2 + xCenterOffset; bottom = height / 2 + ySize / 2 + yCenterOffset; xCenter = (right + guiLeft) / 2; yCenter = (bottom + guiTop) / 2; }
@Override public void initGui() { super.initGui(); guiLeft = (this.width - WIDTH - WIDTH) / 2; guiTop = (this.height - HEIGHT) / 2; }
@Override public void initGui() { super.initGui(); guiLeft = (this.width - WIDTH) / 2; guiTop = (this.height - HEIGHT) / 2; }
@Override public void initGui() { super.initGui(); this.guiLeft = (this.width - xSize) / 2; this.guiTop = (this.height - ySize) / 2; window.init(guiLeft, guiTop); }
@Override public void initGui() { super.initGui(); helper = newHelper(); }
@Override public void initGui() { super.initGui(); buttonList.clear(); title = I18n.translateToLocal("quark.config.title"); }
@Override public void initGui() { super.initGui(); guiX = (width - GUI_WIDTH) / 2; guiY = (height - GUI_HEIGHT) / 2; Keyboard.enableRepeatEvents(true); }
public void initGui() { Iterator<GuiButton> iterator = this.screen.buttonList.iterator(); while (iterator.hasNext()) { if (iterator.next() instanceof SurvivalTabGUI) { iterator.remove(); } } this.screen.initGui(); MinecraftForge.EVENT_BUS.post(new GuiScreenEvent.InitGuiEvent.Post(this.screen, this.screen.buttonList)); } }
public static void initGui() { if (getMinecraft().currentScreen != null) { getMinecraft().currentScreen.initGui(); } }
@Override public void initGui() { super.initGui(); int x = (this.width - SIZE_X) / 2; int y = (this.height - SIZE_Y) / 2; this.buttonList.add(this.nextPage = new PageButton(0, x + 235, y + 180, true)); this.buttonList.add(this.previousPage = new PageButton(1, x - 3, y + 180, false)); this.updateButtons(); }
@Override public void initGui() { super.initGui(); guiX = (width - GUI_WIDTH) / 2; guiY = 2; // Buttons for next / previous page of pages. buttonList.add(buttonPreviousPage = new ButtonChangePage(ID_BUTTON_PAGE_PREV, guiX + BUTTON_PAGE_CHANGE_PREV_X, guiY + BUTTON_PAGE_CHANGE_Y, PageChangeType.Previous)); buttonList.add(buttonNextPage = new ButtonChangePage(ID_BUTTON_PAGE_NEXT, guiX + BUTTON_PAGE_CHANGE_NEXT_X, guiY + BUTTON_PAGE_CHANGE_Y, PageChangeType.Next)); buttonList.add(buttonDeletePage = new ButtonDeletePage(ID_BUTTON_PAGE_DELETE, guiX + BUTTON_PAGE_DELETE_X, guiY + BUTTON_PAGE_DELETE_Y)); Keyboard.enableRepeatEvents(true); }
@Override public void initGui() { super.initGui(); this.buttonList.add(new GuiButton(0, (this.width - 150) / 2, this.height / 5 + 150, 150, 20, I18n.format("gui.cancel"))); this.buttonList.add(this.backward = new GuiButton(1, this.width / 2 - 105, this.height / 5 + 150, 20, 20, "<")); this.buttonList.add(this.forward = new GuiButton(2, this.width / 2 + 85, this.height / 5 + 150, 20, 20, ">")); this.page = 0; this.dinosaurs = new ArrayList<>(EntityHandler.getRegisteredDinosaurs()); Collections.sort(this.dinosaurs); this.pageCount = this.dinosaurs.size() / (this.columnsPerPage * this.rowsPerPage); this.enableDisablePages(); }
@Override public void initGui() { super.initGui(); buttonList.add(new GuiButton(BUTTON_FINISHED_ID, width / 2, height - 30, 150, 20, I18n.format("gui.done"))); gotoButton = new GuiButton(BUTTON_GOTO_ID, width / 2 - 150, height - 30, 150, 20, I18n.format("openeye.notes.goto_page")); gotoButton.enabled = false; buttonList.add(gotoButton); noteList = new GuiNotesList(this, mc, width, height, 10, height - 40, width, height, notes); }
@Override public void initGui() { super.initGui(); int i = 0; for (DinosaurEntity.Order order : DinosaurEntity.Order.values()) { GuiButton button = new GuiButton(i, this.width / 2 - 100, i * 30 + this.height / 4, I18n.translateToLocal("order." + order.name().toLowerCase(Locale.ENGLISH) + ".name")); button.enabled = order != this.entity.getOrder(); this.buttonList.add(button); i++; } }
@Override public void initGui() { super.initGui(); mc.player.openContainer = container; terminalGui = new WidgetTerminal(0, 0, 1, 1, () -> computer, 2, 2, 2, 2); terminalGui.setAllowFocusLoss(false); Keyboard.enableRepeatEvents(true); }
@Override public void onSizeChanged(int size) { RS.INSTANCE.network.sendToServer(new MessageWirelessFluidGridSettingsUpdate(getSortingDirection(), getSortingType(), getSearchBoxMode(), size, getTabSelected(), getTabPage())); this.size = size; if (Minecraft.getMinecraft().currentScreen != null) { Minecraft.getMinecraft().currentScreen.initGui(); } }
@Override public void onSizeChanged(int size) { RS.INSTANCE.network.sendToServer(new MessageGridSettingsUpdate(getViewType(), getSortingDirection(), getSortingType(), getSearchBoxMode(), size, getTabSelected(), getTabPage())); this.size = size; if (Minecraft.getMinecraft().currentScreen != null) { Minecraft.getMinecraft().currentScreen.initGui(); } }
@Override public void onSizeChanged(int size) { RS.INSTANCE.network.sendToServer(new MessageGridSettingsUpdate(getViewType(), getSortingDirection(), getSortingType(), getSearchBoxMode(), size, getTabSelected(), getTabPage())); this.size = size; if (Minecraft.getMinecraft().currentScreen != null) { Minecraft.getMinecraft().currentScreen.initGui(); } }
@Override public void initGui() { super.initGui(); addButton(new GuiButtonExt(0, width / 2 - 155, height - 30, 70, 20, I18n.format("gui.bloodmagic.toggle")){{enabled = false;}}); addButton(new GuiButtonExt(1, width / 2 - 75, height - 30, 70, 20, I18n.format("gui.bloodmagic.default"))); addButton(new GuiButtonExt(2, width / 2 + 5, height - 30, 70, 20, I18n.format("gui.bloodmagic.save"))); addButton(new GuiButtonExt(3, width / 2 + 90, height - 30, 70, 20, I18n.format("gui.bloodmagic.cancel"))); }