SpiritVale systems map

Inside the DPS simulator.

A browsable map from character build to combat timeline to meter-comparable output. Follow one packet, inspect the scheduler, or isolate clone and status channels.

RNG / EVExpected fast default; Rolled is seeded opt-in
t → eventJumps between meaningful timestamps
1 sheetShared SVSimCore stat derivation
3 gatesDisassembly, oracle, live control
InputStateCalculationOutput
01

From build to answer

The build simulator owns character construction. The DPS page consumes its snapshot, resolves fight state, runs fast deterministic Expected execution by default or explicit seeded Rolled trials, then presents meter-comparable channels.

End-to-end architecture
flowchart LR
  subgraph BUILD[Build simulator]
    B1[Class and attributes] --> B4[SVSimCore derive]
    B2[Gear cards artifacts gems] --> B4
    B3[Skills and stages] --> B4
    B4 --> SNAP[sv-dps-snapshot]
  end
  subgraph DATA[Shared data]
    D1[Skills and statuses]
    D2[Monsters and mechanics]
    D3[Weapons and stat rules]
  end
  subgraph LOAD[DPS page]
    L1[Load and sanitize] --> L2[Resolve skills and autocasts]
    L1 --> L3[Resolve buffs and targets]
    L2 --> L4[Effective actor sheets]
    L3 --> L4
  end
  subgraph ENGINE[Shared combat engine]
    E1[Event scheduler] --> E2[Packet calculator]
    E2 --> E3[State windows]
    E3 --> E1
    E1 --> E4[Channel aggregation]
  end
  subgraph OUT[Results]
    O1[DPS and totals]
    O2[Skill and AA breakdown]
    O3[Uptime mana and log]
    O4[Compare and optimizer]
  end
  SNAP --> L1
  D1 --> L1
  D2 --> L1
  D3 --> L1
  L4 --> E1
  E4 --> O1
  E4 --> O2
  E4 --> O3
  E4 --> O4
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class B1,B2,B3,SNAP,D1,D2,D3 input
  class L1,L2,L3,L4,E1,E3 state
  class B4,E2,E4 calc
  class O1,O2,O3,O4 output
Single stat authority

SVSimCore derives both the build sheet and the DPS sheet.

Two result modes

Expected is the fast stable default for comparisons. Rolled fights are opt-in seeded trials that sample keyed outcomes and report a distribution.

State remains temporal

Buffs, debuffs, weapon gates and summon snapshots still change across time.

02

The fight clock

The simulation advances to the earliest meaningful event. It never needs to emulate rendered frames or combat animations.

Discrete event loop
flowchart TD
  START[Initialize t = 0] --> SETUP[Rotation mana charges buffs summons]
  SETUP --> NEXT[Find earliest next event]
  A[Skill ready] --> NEXT
  B[Free-running AA timer] --> NEXT
  C[Buff or debuff expiry] --> NEXT
  D[DoT or HoT tick] --> NEXT
  E[Zone wave] --> NEXT
  F[Summon action] --> NEXT
  G[Charge refill or stance arm] --> NEXT
  NEXT --> DONE{Event after fight end?}
  DONE -- Yes --> FINAL[Close windows and aggregate]
  DONE -- No --> ADV[Advance time]
  ADV --> EXPIRE[Expire windows and rebuild changed sheets]
  EXPIRE --> TYPE{Event kind}
  TYPE -- Cast --> CAST[Check mana charge weapon and skill gates]
  CAST --> QUALIFY{Qualifying SpawnSkill?}
  QUALIFY -- Damaging healing or TargetType 0 --> BREAK[Remove RemoveOnAttack statuses]
  QUALIFY -- No --> CLOCK{Cast effect on AA channel}
  BREAK --> CLOCK
  TYPE -- AA --> AABREAK[Remove RemoveOnAttack statuses]
  AABREAK --> AUTO[Resolve due basic attack and proc channels]
  TYPE -- Tick --> TICK[Resolve live stacks]
  TYPE -- Wave --> WAVE[Resolve half packet]
  TYPE -- Summon --> PET[Resolve summon kit]
  TYPE -- State --> STATE[Update timeline state]
  CLOCK -- Magic --> MAGIC[Keep AA timer; block only for cast bar]
  CLOCK -- Attack skill --> PAUSE[Reset AA timer to max 0.3s or weapon delay]
  MAGIC --> APPLY
  PAUSE --> APPLY
  AUTO --> APPLY
  TICK --> APPLY
  WAVE --> APPLY
  PET --> APPLY
  STATE --> LOG[Record transition]
  APPLY --> PROC[Statuses autocasts events summons]
  PROC --> LOG
  LOG --> NEXT
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class A,B,C,D,E,F,G input
  class SETUP,ADV,EXPIRE,STATE,LOG,MAGIC,PAUSE,BREAK,AABREAK state
  class NEXT,TYPE,CAST,QUALIFY,CLOCK,AUTO,TICK,WAVE,PET,APPLY,PROC calc
  class FINAL output
Independent action clocks

The cast bar blocks attacks; the longer aftercast gate blocks skills. Magic casts leave the free-running AA timer intact, while damaging Melee/Ranged casts reset it.

Event-first status expiry

RemoveOnAttack statuses close before a qualifying SpawnSkill or basic-attack packet resolves.

Piecewise sheets

The effective sheet is rebuilt only when a state input changes.

Deterministic optimizer

The optimizer always evaluates candidates through Expected mode; sampled fights never choose a rotation.

03

One damage packet

Every direct skill follows the same central path: calibrate the skill, construct Power, resolve attack and defense, then scale the result across hits and instances.

Skill packet pipeline
flowchart LR
  IN[Skill level caster target] --> VALID{Valid weapon and target?}
  VALID -- No --> ZERO[No packet]
  VALID -- Yes --> LV[Resolve trained granted copied and gear levels]
  LV --> POWER[Build Power]
  POWER --> KIND{Damage type}
  KIND -- Melee or Ranged --> ATK[ATK physical pool]
  KIND -- Hybrid --> HYB[ATK plus MATK]
  KIND -- Magic --> MATK[MATK magic pool]
  KIND -- True --> TRUE[True damage]
  KIND -- Reflect --> REF[ATK plus combined DEF once]
  KIND -- Sacrifice --> SAC[Max HP as Power]
  ATK --> SCALE[Weapon and stat scaling]
  HYB --> SCALE
  MATK --> SCALE
  TRUE --> SCALE
  REF --> SCALE
  SAC --> SCALE
  SCALE --> MOD[Skill element and target modifiers]
  MOD --> DEF[DEF or MDEF and pierce]
  DEF --> HIT[Perfect Hit → Dodge → Block → Crit → Accuracy]
  HIT --> HITS[Calibrated hit ratio]
  HITS --> INST[Chains splash targets and instances]
  INST --> ZONE{Zone or spin?}
  ZONE -- No --> COMBO[Caster-local combo multiplier]
  ZONE -- Yes --> WAVES[Half packet each 0.5 second wave]
  WAVES --> CAP[Duration and oldest-instance eviction]
  CAP --> COMBO
  COMBO --> OUT[Expected blend or discrete rolled packet]
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class IN input
  class LV,KIND,ZONE state
  class POWER,ATK,HYB,MATK,TRUE,REF,SAC,SCALE,MOD,DEF,HIT,HITS,INST,WAVES,CAP,COMBO calc
  class ZERO,OUT output
Physical crit rule

Melee and ranged skills crit regardless of the raw CanCrit flag.

Crit Defence

clamp(Crit + SkillCrit − CritDef, 0, 100)%; it subtracts directly rather than multiplying chance.

Reflect boundary

The shared sheet already combines hard and flat DEF; reflect consumes that value once.

Boss HP boundary

Percent-HP DoTs use raw HP, while direct DamageMax uses the full boss bar.

04

Auto attacks and meter events

The AA timer is its own combat channel. Attempts, weapon-hand rolls, landed events and damage are related but distinct quantities, and the breakdown preserves those boundaries.

AA channel
flowchart TD
  TIMER[Free-running attack delay timer] --> DUE{Timer due}
  DUE --> CASTING{Cast bar active?}
  CASTING -- Yes --> WAIT[Wait only until cast bar ends]
  CASTING -- No --> ATTEMPT[One attack attempt]
  WAIT --> ATTEMPT
  PAUSE[Damaging Melee or Ranged cast] --> RESET[Set timer to max 0.3s or weapon delay]
  RESET --> TIMER
  ATTEMPT --> HANDS{Offhand weapon?}
  HANDS -- No --> ONE[One hand roll]
  HANDS -- Yes --> TWO[Mainhand and offhand rolls]
  ONE --> LAND[Resolve Perfect Hit crit and accuracy]
  TWO --> LAND
  LAND --> COUNT[Combat-meter Basic Attack events]
  LAND --> DMG[Expected or sampled AA damage]
  LAND --> HITAC[AutocastHit]
  LAND --> ATTACKAC[AutocastAttack]
  LAND --> RIDER[Active-status hit riders]
  LAND --> MULTI[AA Multistrike writes Damage.Hits]
  MULTI --> STACKS[Coating stack multiplicity]
  HITAC --> SPAWN[Spawn real skill]
  ATTACKAC --> SPAWN
  SPAWN --> ROW[Autocast breakdown row]
  DMG --> TOTAL[Basic Attack total]
  COUNT --> METER[Meter-comparable count]
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class TIMER,PAUSE input
  class DUE,CASTING,ATTEMPT,HANDS,ONE,TWO,WAIT,RESET state
  class LAND,DMG,HITAC,ATTACKAC,RIDER,MULTI,SPAWN calc
  class COUNT,STACKS,ROW,TOTAL,METER output
Expected meter countattack attempts × weapon hands × landed probability
Rolled meter countinteger landed hand callbacks in that trial
Magic-cast boundaryAA blocked until cast-bar end; aftercast skill gate does not delay the next attack
05

Autocasts and combo windows

An autocast is a real spawned skill. It has a calibrated level, a caster-owned sheet, and access to that caster’s combo timer.

Autocast path
flowchart TD
  EVENT[Eligible attack or hit] --> ROLL[Proc chance with AutocastChance]
  ROLL --> LV[Autocast level]
  LV --> FALLBACK[round 0.3 × MaxLv fallback]
  LV --> LEARNED[Learned or granted level]
  LV --> MOD[SkillLevel modifier]
  FALLBACK --> CAL[Calibrated SkillState]
  LEARNED --> CAL
  MOD --> CAL
  CAL --> SPAWN[AutoCast → SpawnSkill]
  SPAWN --> OWNER{SkillsComponent owner}
  OWNER -- Player --> PS[Player sheet and timer]
  OWNER -- Clone --> CS[Clone sheet and clone-local timer]
  OWNER -- Inherited pet handler --> IS[Owner-bound inherited SkillState]
  PS --> PACKET[Calculate skill packet]
  CS --> PACKET
  IS --> PACKET
  PACKET --> READY{ComboReady?}
  READY -- Yes --> OPEN[Open caster-local window]
  READY -- No --> FIN
  OPEN --> FIN{ComboFinisher?}
  FIN -- Yes --> BOOST[Apply finisher × window probability]
  FIN -- No --> BOOK[Book damage and statuses]
  BOOST --> BOOK
  BOOK --> ROW[Combine same-skill owner and clone streams]
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class EVENT input
  class OWNER,PS,CS,IS,OPEN state
  class ROLL,LV,FALLBACK,LEARNED,MOD,CAL,SPAWN,PACKET,READY,FIN,BOOST,BOOK calc
  class ROW output
Probabilistic combo uptimeP(window live) = 1 − product((1 − proc chance) ^ eligible rolls inside the window)
06

Shadow Clone split

Independent clone combat and explicit CloneCast echoes are different engine channels. They must not share one blanket multiplier.

Clone ownership and channels
flowchart TD
  OWNER[Owner state at summon time] --> SNAP[Snapshot gear and active effects]
  SNAP --> MODS[Apply SummonClone modifiers]
  MODS --> ATK[TotalAtk minus 75]
  MODS --> MATK[TotalMatk minus 75]
  MODS --> NSA[NoStatusApply plus 1]
  ATK --> SHEET[Clone sheet]
  MATK --> SHEET
  NSA --> SHEET
  SHEET --> SPLIT{Channel}
  SPLIT -- Independent --> AA[Own AA timer]
  AA --> HANDS[Own weapon-hand rolls]
  HANDS --> AC[Copied gear autocasts]
  AC --> LOCAL[Own SkillsComponent and combo timer]
  LOCAL --> IPACKET[Clone-sheet packet]
  SPLIT -- Explicit CloneCast --> MIRROR[Mirror owner skill]
  MIRROR --> EPACKET[Explicit 25 percent echo packet]
  NSA --> GATE{Status source}
  GATE -- Copied active rider --> BLOCK[Block coating-style application]
  GATE -- Authored skill effect --> ALLOW[Use skill effect path]
  IPACKET --> AGG[Clone rows]
  EPACKET --> AGG
  BLOCK --> AGG
  ALLOW --> AGG
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class OWNER input
  class SNAP,MODS,SHEET,SPLIT,LOCAL,GATE state
  class ATK,MATK,NSA,AA,HANDS,AC,IPACKET,MIRROR,EPACKET,BLOCK,ALLOW calc
  class AGG output
Independent damage

Autos and gear autocasts use the clone’s additive −75 TotalAtk/TotalMatk sheet.

Explicit echo

A skill’s CloneCast mirror remains a separate 25% packet.

Local combo

Clone Venom Strike opens that clone’s timer; clone Black Blade consumes it.

07

Status and DoT lifecycle

The simulator retains application source, multiplicity, stack model, duration upper bounds and live caster sheet so ticks can be resolved honestly.

Application to expiry
flowchart TD
  QUALIFY[Qualifying SpawnSkill or basic attack] --> BREAK[Remove RemoveOnAttack statuses]
  BREAK --> PACKET[Resolve breaking attack or skill packet without expired bonus]
  PACKET --> HIT[Landed damage or status event]
  HIT --> SOURCE{Application source}
  SOURCE -- Authored skill link --> AUTH[Repeat SkillState.Hits times]
  SOURCE -- Coating rider --> COAT[Copy Damage.Hits into stacks]
  SOURCE -- Dynamic modifier --> DYN[Apply once per packet]
  SOURCE -- Direct buff or debuff --> DIRECT[Configured stacks and duration]
  AUTH --> APPLY[Apply effect]
  COAT --> APPLY
  DYN --> APPLY
  DIRECT --> APPLY
  APPLY --> MODEL{Stack model}
  MODEL -- Per stack --> TIMERS[Independent timers]
  MODEL -- StacksRefresh --> SHARED[Shared refreshed window]
  MODEL -- Observed per source --> PER[Refreshable source contribution]
  MODEL -- Plain --> PLAIN[Single refreshed window]
  TIMERS --> TICK[Tick wave]
  SHARED --> TICK
  PER --> TICK
  PLAIN --> TICK
  TICK --> LIVE[Resolve live stacks and live caster sheet]
  LIVE --> HP{Percent max HP?}
  HP -- Yes --> RAW[Use MaxHealthRaw]
  HP -- No --> FLAT[Use flat formula]
  RAW --> TOTAL[Tick packet × live stacks]
  FLAT --> TOTAL
  TOTAL --> END{Expired?}
  END -- No --> TICK
  END -- Yes --> CLOSE[Close uptime window]
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class QUALIFY input
  class BREAK,SOURCE,MODEL,TIMERS,SHARED,PER,PLAIN,LIVE state
  class PACKET,AUTH,COAT,DYN,DIRECT,APPLY,TICK,HP,RAW,FLAT,TOTAL calc
  class CLOSE output
Venom Strike at 206% Multistrike2 authored hits + 2.06 expected extra hits = 4.06 damage hits and 4.06 authored Poison applications
RemoveOnAttack closes first

Cloaking’s 25s window at level 5 is an upper bound. A qualifying SpawnSkill—damaging, healing, or TargetType 0—and every basic attack remove it before its packet resolves, so the breaking packet gets none of Cloaking’s +10 Crit/level.

08

Zones, instances and spawned skills

Long-lived skill instances own future waves. Instance modifiers change spawn count; caps remove the oldest instance and all of its remaining damage.

Persistent and spawned damage
flowchart TD
  CAST[Parent skill cast] --> TYPE{Skill behavior}
  TYPE -- Zone spin projectile --> INST[Create modified Instances count]
  INST --> CAP{Over MaxInstances?}
  CAP -- Yes --> EVICT[Evict oldest instance and future waves]
  CAP -- No --> WAVES[Keep instance]
  EVICT --> WAVES
  WAVES --> HALF[Half packet every 0.5 seconds]
  HALF --> DUR{Duration complete?}
  DUR -- No --> WAVES
  DUR -- Yes --> REMOVE[Remove instance]
  TYPE -- SkillConfig Event --> EVENT{Trigger}
  EVENT -- OnCast --> CHILD[Spawn child skill]
  EVENT -- OnApplyHit --> CHILD
  EVENT -- OnCastComplete --> CHILD
  CHILD --> PACKET[Run normal packet pipeline]
  PACKET --> ROW[Book child in separate row]
  CAST --> CHARGES{Charge skill?}
  CHARGES -- Yes --> SPEND[Spend one charge]
  SPEND --> EMPTY{Pool empty?}
  EMPTY -- Yes --> REFILL[Refill whole pool after shared window]
  EMPTY -- No --> READY[More immediate casts available]
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class CAST input
  class TYPE,INST,WAVES,DUR,EVENT,CHARGES,EMPTY state
  class CAP,EVICT,HALF,CHILD,PACKET,SPEND,REFILL calc
  class REMOVE,ROW,READY output
09

Aggregation and proof

Channels are grouped by what the combat meter exposes, while regression gates defend the engine boundaries underneath those combined rows.

Output and evidence chain
flowchart LR
  subgraph CH[Channels]
    C1[Rotation skills]
    C2[Basic attacks]
    C3[Owner autocasts]
    C4[Clone autos and autocasts]
    C5[Summons and echoes]
    C6[Spawned skills]
    C7[DoTs and healing]
  end
  C1 --> AGG[Aggregate by combat-meter source identity]
  C2 --> AGG
  C3 --> AGG
  C4 --> AGG
  C5 --> AGG
  C6 --> AGG
  C7 --> AGG
  AGG --> ROWS[Counts averages totals and contribution]
  AGG --> MODE{Result mode}
  MODE --> DPS[Expected default DPS or Rolled seeded-trial mean median P10 to P90]
  AGG --> SIDE[Uptime mana and fight 1 log]
  subgraph PROOF[Accuracy chain]
    P1[GameAssembly consumer trace] --> P2[Documented rule]
    P2 --> P3[Independent closed-form oracle]
    P2 --> P4[Simulator implementation]
    P3 --> P5[dps-regress against real page]
    P4 --> P5
    P5 --> P6[Live discriminating control]
    P6 --> P7[verify gate and staged browser smoke]
  end
  classDef input fill:#21172f,stroke:#b68cff,color:#f3eaff
  classDef state fill:#10271d,stroke:#5fd39a,color:#e7fff1
  classDef calc fill:#2b220d,stroke:#d9b24a,color:#fff3c7
  classDef output fill:#2d1717,stroke:#e0705f,color:#ffe8e3
  class C1,C2,C3,C4,C5,C6,C7,P1 input
  class P2,P6 state
  class AGG,MODE,P3,P4,P5,P7 calc
  class ROWS,DPS,SIDE output
Meter-comparable rows

Direct casts, autocasts and clone streams carrying the same skill source id combine only at presentation. Counts use landed meter callbacks, not authored Damage.Hits.

Result modes

Expected is the fast stable default. Explicit Rolled runs 4–128 seeded trials; the headline is their mean and spread, while breakdown, timeline and log show fight 1.

Compare mode

Each side swaps into shared state, simulates synchronously with the same seed and trial indexes, then restores the focused side.

Raw flags are not rules

A config field becomes a mechanic only after tracing the engine consumer.

10

Reading the atlas

The engine uses a small set of terms consistently.

Expected value
The fast stable default: the long-run average result of a random mechanic, calculated directly instead of sampled. It is the optimizer’s scoring mode.
Rolled fight
An explicit seeded option running 4–128 trials with discrete crit, hit, variance, proc, status and Multistrike outcomes. Matching setup, seed and trial index reproduce exactly.
Packet
Damage or healing attributed to one cast, proc, attack, wave or tick, represented as expected branches or one sampled outcome.
Event
A timestamp where an action or state transition can change the simulation.
RemoveOnAttack
A status flag that closes the active status before a qualifying SpawnSkill or basic-attack packet resolves; its nominal duration is only an upper bound.
Window
A time-bounded buff, debuff, combo, status or source contribution.
Sheet
The effective character stats for one actor under one state and weapon set.
Channel
A separately calculated source such as owner AA, clone autocast, summon kit or DoT.
Instance
A persistent skill object that owns future zone/projectile waves.
Meter identity
The skill or Basic Attack label under which the in-game combat meter groups events.
No matching sectionTry “clone”, “autocast”, “status”, “packet”, or “scheduler”.