Contents
Class BenchWindow
java.lang.Object
com.hypixel.hytale.server.core.entity.entities.player.windows.Window
com.hypixel.hytale.server.core.entity.entities.player.windows.BlockWindow
com.hypixel.hytale.builtin.crafting.window.BenchWindow
- All Implemented Interfaces:
MaterialContainerWindow, ValidatedWindow
- Direct Known Subclasses:
CraftingWindow, ProcessingBenchWindow
-
Nested Class Summary
Nested classes/interfaces inherited from class Window
Window.WindowCloseEvent -
Field Summary
Fields inherited from class Window
CLIENT_REQUESTABLE_WINDOW_TYPES -
Constructor Summary
ConstructorsConstructorDescriptionBenchWindow(WindowType windowType, int x, int y, int z, int rotationIndex, BlockType blockType, BenchBlock benchBlock) Constructor for aBenchWindowinstance with explicit position. -
Method Summary
Modifier and TypeMethodDescriptioncom.google.gson.JsonObjectgetData()Gets the extra resources section of this material container windowvoidbooleanisValid()voidonClose0(Ref<EntityStore> ref, ComponentAccessor<EntityStore> componentAccessor) voidsetBlockInteractionState(String state, World world) Called to set the block interaction state at the window's positionvoidupdateBenchTierLevel(int newValue) voidupdateBenchUpgradeJob(float percent) voidupdateCraftingJob(float percent) voidupdateQueueSize(int size) Methods inherited from class BlockWindow
getBlockType, getMaxDistance, getRotationIndex, getX, getY, getZ, setMaxDistance, validateMethods inherited from class Window
close, equals, getId, getPlayerRef, getType, handleAction, hashCode, init, registerCloseEvent, registerCloseEvent, registerCloseEvent, setId
-
Constructor Details
-
BenchWindow
public BenchWindow(@Nonnull WindowType windowType, int x, int y, int z, int rotationIndex, @Nonnull BlockType blockType, @Nonnull BenchBlock benchBlock) Constructor for aBenchWindowinstance with explicit position.- Parameters:
windowType- The window type affiliated with this windowx- The X position of the benchy- The Y position of the benchz- The Z position of the benchrotationIndex- The rotation index of the benchblockType- The block type of the benchbenchBlock- The associated BenchBlock component
-
-
Method Details
-
getData
-
onClose0
public void onClose0(@Nonnull Ref<EntityStore> ref, @Nonnull ComponentAccessor<EntityStore> componentAccessor) -
setBlockInteractionState
-
updateQueueSize
public void updateQueueSize(int size) -
updateCraftingJob
public void updateCraftingJob(float percent) -
updateBenchUpgradeJob
public void updateBenchUpgradeJob(float percent) -
updateBenchTierLevel
public void updateBenchTierLevel(int newValue) -
getExtraResourcesSection
Description copied from interface:MaterialContainerWindowGets the extra resources section of this material container window- Specified by:
getExtraResourcesSectionin interfaceMaterialContainerWindow- Returns:
- The extra resources section
-
invalidateExtraResources
public void invalidateExtraResources()- Specified by:
invalidateExtraResourcesin interfaceMaterialContainerWindow
-
isValid
public boolean isValid()- Specified by:
isValidin interfaceMaterialContainerWindow
-