Class CustomUIPage

java.lang.Object
com.hypixel.hytale.server.core.entity.entities.player.pages.CustomUIPage
Direct Known Subclasses:
AugmentMessagePage, BasicCustomUIPage, BlockLorePage, InteractiveCustomUIPage

public abstract class CustomUIPage extends Object
Represents a UI page that the player has opened
  • Constructor Details

    • CustomUIPage

      public CustomUIPage(@Nonnull PlayerRef playerRef, @Nonnull CustomPageLifetime lifetime)
      Default Constructor for a CustomUIPage instance
      Parameters:
      playerRef - The PlayerRef instance of the associated player
      lifetime - The lifetime behaviour of the page
  • Method Details

    • setLifetime

      public void setLifetime(@Nonnull CustomPageLifetime lifetime)
      Called to set the lifetime of this page
      Parameters:
      lifetime - The lifetime to set
    • getLifetime

      @Nonnull public CustomPageLifetime getLifetime()
      Returns:
      the lifetime of this page
    • handleDataEvent

      public void handleDataEvent(@Nonnull Ref<EntityStore> ref, @Nonnull Store<EntityStore> store, String rawData)
      Called to handle a data event using the given raw data
      Parameters:
      ref - The entity reference of the affiliated entity
      store - The entity store for component access
      rawData - The raw data to be processed
    • build

      public abstract void build(@Nonnull Ref<EntityStore> ref, @Nonnull UICommandBuilder commandBuilder, @Nonnull UIEventBuilder eventBuilder, @Nonnull Store<EntityStore> store)
      Called to build this page
      Parameters:
      ref - The entity ref of the affiliated player
      commandBuilder - The command builder used while building this UI
      eventBuilder - The event builder used while building this UI
      store - The entity store for component access
    • onDismiss

      public void onDismiss(@Nonnull Ref<EntityStore> ref, @Nonnull Store<EntityStore> store)
      Called when this page is dismissed