Class AttackHistory

java.lang.Object
privbot.mechanics.AttackHistory

public final class AttackHistory extends Object
Single-owner record of accepted attack sends and independently confirmed fires, eats and clearing exits. It does not read the client, dispatch actions, or infer a fire from a click. Feed observations before recording actions decided from the same sample, and feed fires before confirmed eats in that sample. A different fight clears the target-specific send but retains our own clock. This low-level record does not detect animations or inventory changes for the caller.
  • Constructor Details

    • AttackHistory

      public AttackHistory()
  • Method Details

    • sent

      public void sent(int tick, AttackHistory.Family family)
      Record only a dispatch known to have been accepted; acceptance is not a fire.
    • fire

      public void fire(int tick, AttackHistory.Family family, CombatStyle style, String weapon)
      Record a confirmed fire. A fire in the same sample as a send precedes that send.
    • eatLanded

      public void eatLanded(int tick, String foodIdentity)
      Record a food consumption proved by a fresh inventory read; repeated reports for an item and tick count once.
    • cleared

      public void cleared(int tick)
      Record a confirmed clearing exit that happened after the send, not a merely dispatched action.
    • newFight

      public void newFight()
      A new opponent invalidates the old send; our last confirmed fire and eats still describe our timer.
    • unsettled

      public boolean unsettled()
    • sentTick

      public Integer sentTick()
    • firedTick

      public Integer firedTick()
    • firedStyle

      public CombatStyle firedStyle()
      Style of the last confirmed fire, or null when it could not be classified.
    • eatsSinceFire

      public int eatsSinceFire()
    • estimatedReady

      public Integer estimatedReady(Map<String,Integer> overrides)
      Estimated next attack fire, or null when the required observations are missing.
    • pending

      public Boolean pending(int tick, Map<String,Integer> overrides)
      True, false or unknown: a missing fire estimate cannot establish a pending deadline.