java.lang.Object
com.hypixel.hytale.builtin.adventure.objectives.Objective
All Implemented Interfaces:
NetworkSerializable<Objective>

public class Objective extends Object implements NetworkSerializable<Objective>
  • Field Details

    • CODEC

      public static final BuilderCodec<Objective> CODEC
    • objectiveUUID

      protected UUID objectiveUUID
    • objectiveId

      protected String objectiveId
    • objectiveLineHistoryData

      @Nullable protected ObjectiveLineHistoryData objectiveLineHistoryData
    • objectiveHistoryData

      protected ObjectiveHistoryData objectiveHistoryData
    • playerUUIDs

      protected Set<UUID> playerUUIDs
    • activePlayerUUIDs

      @Nonnull protected Set<UUID> activePlayerUUIDs
    • currentTasks

      @Nullable protected ObjectiveTask[] currentTasks
    • currentTaskSetIndex

      protected int currentTaskSetIndex
    • completed

      protected boolean completed
    • worldUUID

      protected UUID worldUUID
    • markerUUID

      @Nullable protected UUID markerUUID
    • dirty

      protected boolean dirty
    • objectiveItemStarter

      protected ItemStack objectiveItemStarter
  • Constructor Details

    • Objective

      public Objective(@Nonnull ObjectiveAsset asset, @Nullable UUID objectiveUUID, @Nonnull Set<UUID> playerUUIDs, @Nonnull UUID worldUUID, @Nullable UUID markerUUID)
    • Objective

      protected Objective()
  • Method Details

    • getObjectiveUUID

      @Nonnull public UUID getObjectiveUUID()
    • getObjectiveId

      @Nonnull public String getObjectiveId()
    • getObjectiveAsset

      @Nullable public ObjectiveAsset getObjectiveAsset()
    • getObjectiveLineHistoryData

      @Nullable public ObjectiveLineHistoryData getObjectiveLineHistoryData()
    • setObjectiveLineHistoryData

      public void setObjectiveLineHistoryData(@Nullable ObjectiveLineHistoryData objectiveLineHistoryData)
    • getObjectiveHistoryData

      @Nonnull public ObjectiveHistoryData getObjectiveHistoryData()
    • getObjectiveLineAsset

      @Nullable public ObjectiveLineAsset getObjectiveLineAsset()
    • getPlayerUUIDs

      public Set<UUID> getPlayerUUIDs()
    • getActivePlayerUUIDs

      @Nonnull public Set<UUID> getActivePlayerUUIDs()
    • getCurrentTasks

      @Nullable public ObjectiveTask[] getCurrentTasks()
    • getCurrentTaskSetIndex

      public int getCurrentTaskSetIndex()
    • getCurrentDescription

      public String getCurrentDescription()
    • isCompleted

      public boolean isCompleted()
    • getWorldUUID

      public UUID getWorldUUID()
    • getMarkerUUID

      @Nullable public UUID getMarkerUUID()
    • isDirty

      public boolean isDirty()
    • getObjectiveItemStarter

      public ItemStack getObjectiveItemStarter()
    • setObjectiveItemStarter

      public void setObjectiveItemStarter(@Nonnull ItemStack objectiveItemStarter)
    • setup

      public boolean setup(@Nonnull Store<EntityStore> componentAccessor)
    • setupCurrentTasks

      public boolean setupCurrentTasks(@Nonnull Store<EntityStore> store)
    • checkTaskSetCompletion

      public boolean checkTaskSetCompletion(@Nonnull Store<EntityStore> store)
    • taskSetComplete

      protected void taskSetComplete(@Nonnull Store<EntityStore> store)
    • complete

      public void complete(@Nonnull Store<EntityStore> store)
    • cancel

      public void cancel()
    • unload

      public void unload()
    • getTaskInfoMessage

      @Nonnull public Message getTaskInfoMessage()
    • reloadObjectiveAsset

      public void reloadObjectiveAsset(@Nonnull Map<String,ObjectiveAsset> reloadedAssets)
    • checkPossibleAssetReload

      @Nullable private ObjectiveTaskAsset[] checkPossibleAssetReload(@Nonnull Map<String,ObjectiveAsset> reloadedAssets)
    • setupAndUpdateTasks

      @Nullable private ObjectiveTask[] setupAndUpdateTasks(@Nonnull ObjectiveTaskAsset[] taskAssets, @Nonnull Store<EntityStore> store)
    • findMatchingObjectiveTask

      @Nullable private ObjectiveTask findMatchingObjectiveTask(@Nonnull ObjectiveTaskAsset taskAsset)
    • cancelReload

      private void cancelReload(@Nonnull ObjectiveTask[] newTasks)
    • revertRemovedTasks

      private void revertRemovedTasks(@Nonnull ObjectiveTask[] newTasks)
    • forEachParticipant

      public void forEachParticipant(@Nonnull Consumer<Ref<EntityStore>> consumer)
    • forEachParticipant

      public <T> void forEachParticipant(@Nonnull BiConsumer<Ref<EntityStore>,T> consumer, T meta)
    • forEachParticipant

      public <T, U> void forEachParticipant(@Nonnull TriConsumer<Ref<EntityStore>,T,U> consumer, @Nonnull T t, @Nonnull U u)
    • getPosition

      @Nullable public Vector3d getPosition(@Nonnull ComponentAccessor<EntityStore> componentAccessor)
    • addActivePlayerUUID

      public void addActivePlayerUUID(UUID playerUUID)
    • removeActivePlayerUUID

      public void removeActivePlayerUUID(UUID playerUUID)
    • markDirty

      public void markDirty()
    • consumeDirty

      public boolean consumeDirty()
    • toPacket

      @Nonnull public Objective toPacket()
      Specified by:
      toPacket in interface NetworkSerializable<Objective>
    • toString

      @Nonnull public String toString()
      Overrides:
      toString in class Object