public class ReadBookScreen extends Screen
Modifier and Type | Class and Description |
---|---|
static interface |
ReadBookScreen.IBookInfo |
static class |
ReadBookScreen.UnwrittenBookInfo |
static class |
ReadBookScreen.WrittenBookInfo |
Modifier and Type | Field and Description |
---|---|
static ResourceLocation |
BOOK_TEXTURES |
private ReadBookScreen.IBookInfo |
bookInfo |
private ChangePageButton |
buttonNextPage |
private ChangePageButton |
buttonPreviousPage |
private int |
cachedPage |
private java.util.List<ITextComponent> |
cachedPageLines |
private int |
currPage |
static ReadBookScreen.IBookInfo |
EMPTY_BOOK |
private boolean |
pageTurnSounds |
buttons, children, font, height, itemRenderer, minecraft, passEvents, title, width
BACKGROUND_LOCATION, GUI_ICONS_LOCATION, STATS_ICON_LOCATION
Modifier | Constructor and Description |
---|---|
|
ReadBookScreen() |
|
ReadBookScreen(ReadBookScreen.IBookInfo bookInfoIn) |
private |
ReadBookScreen(ReadBookScreen.IBookInfo bookInfoIn,
boolean pageTurnSoundsIn) |
Modifier and Type | Method and Description |
---|---|
protected void |
addChangePageButtons() |
protected void |
addDoneButton() |
ITextComponent |
func_214154_c(double p_214154_1_,
double p_214154_3_) |
void |
func_214155_a(ReadBookScreen.IBookInfo p_214155_1_) |
private int |
func_214156_a(java.lang.String p_214156_1_) |
private int |
getPageCount() |
boolean |
handleComponentClicked(ITextComponent p_handleComponentClicked_1_) |
protected void |
init() |
boolean |
keyPressed(int p_keyPressed_1_,
int p_keyPressed_2_,
int p_keyPressed_3_) |
boolean |
mouseClicked(double p_mouseClicked_1_,
double p_mouseClicked_3_,
int p_mouseClicked_5_) |
static java.util.List<java.lang.String> |
nbtPagesToStrings(CompoundNBT p_214157_0_) |
protected void |
nextPage() |
protected void |
previousPage() |
void |
render(int p_render_1_,
int p_render_2_,
float p_render_3_) |
boolean |
showPage(int pageNum) |
protected boolean |
showPage2(int pageNum) |
private void |
updateButtons() |
addButton, children, getMinecraft, getNarrationMessage, getTitle, getTooltipFromItem, hasAltDown, hasControlDown, hasShiftDown, init, insertText, isCopy, isCut, isMouseOver, isPaste, isPauseScreen, isSelectAll, isValidCharacterForName, onClose, removed, renderBackground, renderBackground, renderComponentHoverEffect, renderDirtBackground, renderTooltip, renderTooltip, renderTooltip, renderTooltip, resize, sendMessage, sendMessage, setSize, shouldCloseOnEsc, tick, wrapScreenError
getFocused, isDragging, setDragging, setFocused
blit, blit, blit, blit, blit, drawCenteredString, drawRightAlignedString, drawString, fill, fill, fillGradient, getBlitOffset, hLine, innerBlit, setBlitOffset, vLine
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
changeFocus, charTyped, func_212932_b, getEventListenerForPos, keyReleased, mouseDragged, mouseReleased, mouseScrolled, setFocusedDefault
mouseMoved
public static final ReadBookScreen.IBookInfo EMPTY_BOOK
public static final ResourceLocation BOOK_TEXTURES
private ReadBookScreen.IBookInfo bookInfo
private int currPage
private java.util.List<ITextComponent> cachedPageLines
private int cachedPage
private ChangePageButton buttonNextPage
private ChangePageButton buttonPreviousPage
private final boolean pageTurnSounds
public ReadBookScreen(ReadBookScreen.IBookInfo bookInfoIn)
public ReadBookScreen()
private ReadBookScreen(ReadBookScreen.IBookInfo bookInfoIn, boolean pageTurnSoundsIn)
public void func_214155_a(ReadBookScreen.IBookInfo p_214155_1_)
public boolean showPage(int pageNum)
protected boolean showPage2(int pageNum)
protected void addDoneButton()
protected void addChangePageButtons()
private int getPageCount()
protected void previousPage()
protected void nextPage()
private void updateButtons()
public boolean keyPressed(int p_keyPressed_1_, int p_keyPressed_2_, int p_keyPressed_3_)
keyPressed
in interface IGuiEventListener
keyPressed
in interface INestedGuiEventHandler
keyPressed
in class Screen
public void render(int p_render_1_, int p_render_2_, float p_render_3_)
render
in interface IRenderable
render
in class Screen
private int func_214156_a(java.lang.String p_214156_1_)
public boolean mouseClicked(double p_mouseClicked_1_, double p_mouseClicked_3_, int p_mouseClicked_5_)
public boolean handleComponentClicked(ITextComponent p_handleComponentClicked_1_)
handleComponentClicked
in class Screen
@Nullable public ITextComponent func_214154_c(double p_214154_1_, double p_214154_3_)
public static java.util.List<java.lang.String> nbtPagesToStrings(CompoundNBT p_214157_0_)