@Environment(value=CLIENT) public class SpectatorHud extends DrawableHelper implements SpectatorMenuCloseCallback
Modifier and Type | Field and Description |
---|---|
private MinecraftClient |
client |
private long |
lastInteractionTime |
static Identifier |
SPECTATOR_TEX |
private SpectatorMenu |
spectatorMenu |
private static Identifier |
WIDGETS_TEX |
BACKGROUND_TEXTURE, GUI_ICONS_TEXTURE, STATS_ICON_TEXTURE
Constructor and Description |
---|
SpectatorHud(MinecraftClient client) |
Modifier and Type | Method and Description |
---|---|
void |
close(SpectatorMenu menu) |
void |
cycleSlot(double offset) |
private float |
getSpectatorMenuHeight() |
boolean |
isOpen() |
void |
render() |
void |
render(float tickDelta) |
private void |
renderSpectatorCommand(int slot,
int x,
float y,
float alpha,
SpectatorMenuCommand command) |
protected void |
renderSpectatorMenu(float height,
int x,
int int2,
SpectatorMenuState state) |
void |
selectSlot(int slot) |
void |
useSelectedCommand() |
drawCenteredString, drawHorizontalLine, drawSprite, drawString, drawTexture, drawTexture, drawTexture, drawTexture, drawTexturedQuad, drawVerticalLine, fill, fill, fillGradient, getZOffset, setZOffset
private static final Identifier WIDGETS_TEX
public static final Identifier SPECTATOR_TEX
private final MinecraftClient client
private long lastInteractionTime
private SpectatorMenu spectatorMenu
public SpectatorHud(MinecraftClient client)
public void selectSlot(int slot)
private float getSpectatorMenuHeight()
public void render(float tickDelta)
protected void renderSpectatorMenu(float height, int x, int int2, SpectatorMenuState state)
private void renderSpectatorCommand(int slot, int x, float y, float alpha, SpectatorMenuCommand command)
public void render()
public void close(SpectatorMenu menu)
close
in interface SpectatorMenuCloseCallback
public boolean isOpen()
public void cycleSlot(double offset)
public void useSelectedCommand()