Class CombatTracker

java.lang.Object
net.minecraft.world.damagesource.CombatTracker

public class CombatTracker extends Object
  • Field Details

    • RESET_DAMAGE_STATUS_TIME

      public static final int RESET_DAMAGE_STATUS_TIME
      See Also:
    • RESET_COMBAT_STATUS_TIME

      public static final int RESET_COMBAT_STATUS_TIME
      See Also:
    • INTENTIONAL_GAME_DESIGN_STYLE

      public static final Style INTENTIONAL_GAME_DESIGN_STYLE
    • entries

      private final List<CombatEntry> entries
    • mob

      private final LivingEntity mob
    • lastDamageTime

      private int lastDamageTime
    • combatStartTime

      private int combatStartTime
    • combatEndTime

      private int combatEndTime
    • inCombat

      private boolean inCombat
    • takingDamage

      private boolean takingDamage
  • Constructor Details

  • Method Details

    • recordDamage

      public void recordDamage(DamageSource source, float damage)
    • shouldEnterCombat

      private static boolean shouldEnterCombat(DamageSource source)
    • getMessageForAssistedFall

      private Component getMessageForAssistedFall(Entity attackerEntity, Component attackerName, String messageWithItem, String messageWithoutItem)
    • getFallMessage

      public Component getFallMessage(CombatEntry knockOffEntry, @Nullable Entity killingEntity)
    • getDisplayName

      private static @Nullable Component getDisplayName(@Nullable Entity entity)
    • getDeathMessage

      public Component getDeathMessage()
    • getMostSignificantFall

      public @Nullable CombatEntry getMostSignificantFall()
    • getCombatDuration

      public int getCombatDuration()
    • recheckStatus

      public void recheckStatus()