java.lang.Object
com.hypixel.hytale.server.core.modules.entity.damage.DeathComponent
All Implemented Interfaces:
Component<EntityStore>, Cloneable

public class DeathComponent extends Object implements Component<EntityStore>
  • Field Details

    • CODEC

      public static final BuilderCodec<DeathComponent> CODEC
    • deathCause

      private String deathCause
    • deathMessage

      @Nullable private Message deathMessage
    • showDeathMenu

      private boolean showDeathMenu
    • itemsLostOnDeath

      private ItemStack[] itemsLostOnDeath
    • itemsAmountLossPercentage

      private double itemsAmountLossPercentage
    • itemsDurabilityLossPercentage

      private double itemsDurabilityLossPercentage
    • displayDataOnDeathScreen

      private boolean displayDataOnDeathScreen
    • deathInfo

      @Nullable private Damage deathInfo
    • itemsLossMode

      private DeathConfig.ItemsLossMode itemsLossMode
    • interactionChain

      @Nullable private InteractionChain interactionChain
  • Constructor Details

    • DeathComponent

      protected DeathComponent(@Nonnull Damage deathInfo)
    • DeathComponent

      protected DeathComponent()
  • Method Details

    • getComponentType

      public static ComponentType<EntityStore,DeathComponent> getComponentType()
    • getDeathCause

      @Nullable public DamageCause getDeathCause()
    • getDeathMessage

      @Nullable public Message getDeathMessage()
    • setDeathMessage

      public void setDeathMessage(@Nullable Message deathMessage)
    • isShowDeathMenu

      public boolean isShowDeathMenu()
    • setShowDeathMenu

      public void setShowDeathMenu(boolean showDeathMenu)
    • getItemsLostOnDeath

      public ItemStack[] getItemsLostOnDeath()
    • setItemsLostOnDeath

      public void setItemsLostOnDeath(List<ItemStack> itemsLostOnDeath)
    • getItemsAmountLossPercentage

      public double getItemsAmountLossPercentage()
    • setItemsAmountLossPercentage

      public void setItemsAmountLossPercentage(double itemsAmountLossPercentage)
    • getItemsDurabilityLossPercentage

      public double getItemsDurabilityLossPercentage()
    • setItemsDurabilityLossPercentage

      public void setItemsDurabilityLossPercentage(double itemsDurabilityLossPercentage)
    • displayDataOnDeathScreen

      public boolean displayDataOnDeathScreen()
    • setDisplayDataOnDeathScreen

      public void setDisplayDataOnDeathScreen(boolean displayDataOnDeathScreen)
    • getDeathInfo

      @Nullable public Damage getDeathInfo()
    • getItemsLossMode

      public DeathConfig.ItemsLossMode getItemsLossMode()
    • setItemsLossMode

      public void setItemsLossMode(DeathConfig.ItemsLossMode itemsLossMode)
    • getDeathItemLoss

      public DeathItemLoss getDeathItemLoss()
    • getInteractionChain

      @Nullable public InteractionChain getInteractionChain()
    • setInteractionChain

      public void setInteractionChain(@Nullable InteractionChain interactionChain)
    • clone

      @Nonnull public Component<EntityStore> clone()
      Specified by:
      clone in interface Component<EntityStore>
      Overrides:
      clone in class Object
    • tryAddComponent

      public static void tryAddComponent(@Nonnull CommandBuffer<EntityStore> commandBuffer, @Nonnull Ref<EntityStore> ref, @Nonnull Damage damage)
    • tryAddComponent

      public static void tryAddComponent(@Nonnull Store<EntityStore> store, @Nonnull Ref<EntityStore> ref, @Nonnull Damage damage)