パッケージ simulation.event

クラス PeriodicDamageEvent

java.lang.Object
simulation.event.PeriodicDamageEvent
すべての実装されたインタフェース:
TimerEvent

public class PeriodicDamageEvent extends Object implements TimerEvent
A TimerEvent that fires a repeating AttackAction at a fixed interval for a defined duration, optionally running an additional callback on each tick.

Typical use-cases: field DoT effects such as Beidou's Stormbreaker lightning, Fischl's Oz shots, Xiangling's Pyronado hits, or any ability that deals repeated damage ticks while another character is on-field.

The event completes when currentTime >= startTime + duration.

  • コンストラクタの詳細

    • PeriodicDamageEvent

      public PeriodicDamageEvent(String sourceName, AttackAction tickAction, double startTime, double interval, double duration)
      Constructs a periodic damage event without an additional callback.
      パラメータ:
      sourceName - the name of the character owning this event (used for damage attribution)
      tickAction - the AttackAction to execute on each tick; may be null to skip damage but still run the callback
      startTime - the simulation time of the first tick
      interval - the time in seconds between consecutive ticks
      duration - the total duration in seconds; the event finishes when currentTime >= startTime + duration
    • PeriodicDamageEvent

      public PeriodicDamageEvent(String sourceName, AttackAction tickAction, double startTime, double interval, double duration, Consumer<CombatSimulator> onTick)
      Constructs a periodic damage event with an additional per-tick callback.
      パラメータ:
      sourceName - the name of the character owning this event
      tickAction - the AttackAction to execute on each tick; may be null
      startTime - the simulation time of the first tick
      interval - the time in seconds between consecutive ticks
      duration - the total duration in seconds
      onTick - optional callback invoked after damage on each tick (e.g. applying a DEF shred); may be null
  • メソッドの詳細