@Environment(value=CLIENT) public class AdvancementTab extends DrawableHelper
Modifier and Type | Field and Description |
---|---|
private float |
alpha |
private MinecraftClient |
client |
private AdvancementDisplay |
display |
private ItemStack |
icon |
private int |
index |
private boolean |
initialized |
private int |
maxPanX |
private int |
maxPanY |
private int |
minPanX |
private int |
minPanY |
private double |
originX |
private double |
originY |
private Advancement |
root |
private AdvancementWidget |
rootWidget |
private AdvancementsScreen |
screen |
private Text |
title |
private AdvancementTabType |
type |
private Map<Advancement,AdvancementWidget> |
widgets |
GUI_ICONS_TEXTURE, OPTIONS_BACKGROUND_TEXTURE, STATS_ICON_TEXTURE
Constructor and Description |
---|
AdvancementTab(MinecraftClient client,
AdvancementsScreen screen,
AdvancementTabType type,
int index,
Advancement root,
AdvancementDisplay display) |
Modifier and Type | Method and Description |
---|---|
void |
addAdvancement(Advancement advancement) |
private void |
addWidget(AdvancementWidget widget,
Advancement advancement) |
static AdvancementTab |
create(MinecraftClient minecraft,
AdvancementsScreen screen,
int index,
Advancement root) |
void |
drawBackground(MatrixStack matrixStack,
int int2,
int int3,
boolean bool) |
void |
drawIcon(int x,
int y,
ItemRenderer itemRenderer) |
void |
drawWidgetTooltip(MatrixStack matrixStack,
int int2,
int int3,
int int4,
int int5) |
Advancement |
getRoot() |
AdvancementsScreen |
getScreen() |
Text |
getTitle() |
AdvancementWidget |
getWidget(Advancement advancement) |
boolean |
isClickOnTab(int screenX,
int screenY,
double mouseX,
double mouseY) |
void |
move(double offsetX,
double offsetY) |
void |
render(MatrixStack matrixStack) |
drawCenteredString, drawCenteredText, drawHorizontalLine, drawSprite, drawStringWithShadow, drawTexture, drawTexture, drawTexture, drawTexture, drawTextWithShadow, drawVerticalLine, fill, fillGradient, fillGradient, getZOffset, method_29343, setZOffset
private final MinecraftClient client
private final AdvancementsScreen screen
private final AdvancementTabType type
private final int index
private final Advancement root
private final AdvancementDisplay display
private final ItemStack icon
private final Text title
private final AdvancementWidget rootWidget
private final Map<Advancement,AdvancementWidget> widgets
private double originX
private double originY
private int minPanX
private int minPanY
private int maxPanX
private int maxPanY
private float alpha
private boolean initialized
public AdvancementTab(MinecraftClient client, AdvancementsScreen screen, AdvancementTabType type, int index, Advancement root, AdvancementDisplay display)
public Advancement getRoot()
public Text getTitle()
public void drawBackground(MatrixStack matrixStack, int int2, int int3, boolean bool)
public void drawIcon(int x, int y, ItemRenderer itemRenderer)
public void render(MatrixStack matrixStack)
public void drawWidgetTooltip(MatrixStack matrixStack, int int2, int int3, int int4, int int5)
public boolean isClickOnTab(int screenX, int screenY, double mouseX, double mouseY)
@Nullable public static AdvancementTab create(MinecraftClient minecraft, AdvancementsScreen screen, int index, Advancement root)
public void move(double offsetX, double offsetY)
public void addAdvancement(Advancement advancement)
private void addWidget(AdvancementWidget widget, Advancement advancement)
@Nullable public AdvancementWidget getWidget(Advancement advancement)
public AdvancementsScreen getScreen()