Pvp
constPvp:object
Defined in: client/api.d.ts:4851
Player-vs-player presentation and diagnostics. Who may hurt whom is the server’s (its Pvp builtin); this client resolves the same relation per player and wears it on their proxy natively.
Type Declaration
Section titled “Type Declaration”reactState()
Section titled “reactState()”reactState():
object
reactStatus as data. An empty component means the pawn carries no ability component and the stagger cap is inert; reactionRunning is null when the readback itself failed; cancels counts remote impacts whose reaction request was dropped, impacts every remote impact seen on the pawn (dropped or not). Reads only.
Returns
Section titled “Returns”object
activeAbility
Section titled “activeAbility”activeAbility:
string
cancels
Section titled “cancels”cancels:
number
chain:
number
component
Section titled “component”component:
string
enabled
Section titled “enabled”enabled:
boolean
impacts
Section titled “impacts”impacts:
number
lastStagger
Section titled “lastStagger”lastStagger:
string
maxChain
Section titled “maxChain”maxChain:
number
probeQueued
Section titled “probeQueued”probeQueued:
number
reactionRunning
Section titled “reactionRunning”reactionRunning:
boolean|null
suppressed
Section titled “suppressed”suppressed:
boolean
suppressedFor
Section titled “suppressedFor”suppressedFor:
number
suppressFor
Section titled “suppressFor”suppressFor:
number
suppressions
Section titled “suppressions”suppressions:
number
window
Section titled “window”window:
number
reactStatus()
Section titled “reactStatus()”reactStatus():
string
Reads the react policy’s live state: the resolved reaction component, whether a reaction is running right now, the current chain count and any active suppression window. Reads only.
Returns
Section titled “Returns”string
relation()
Section titled “relation()”relation(
playerId): {aim:"lock"|"skillshot";defeat:"death"|"kneel";hostile:boolean;reason:string; } |null
How this client resolves that player against us, from the server’s rules and pairs and both players’ flag and team: the same answer the server gives Pvp.relation. Null while they are not streamed in. pvpRelationChanged fires when it changes.
Parameters
Section titled “Parameters”playerId
Section titled “playerId”number
Returns
Section titled “Returns”{ aim: "lock" | "skillshot"; defeat: "death" | "kneel"; hostile: boolean; reason: string; } | null
restoreReactions()
Section titled “restoreReactions()”restoreReactions():
string
WRITES. Ends any active stagger-immunity window now and turns the pawn’s reactions back on, leaving the policy itself alone. Call it wherever a duel or gamemode ends — reactions must never be left off.
Returns
Section titled “Returns”string
setReactPolicy()
Section titled “setReactPolicy()”setReactPolicy(
policy?):string
WRITES. The victim-side stagger economy: after maxChain staggers inside window seconds (or one unbroken stagger longer than window), impacts from other players stop requesting a hit reaction on the local pawn until suppressFor seconds after the current stagger ends, so a spammed basic attack can no longer chain full-body reactions into an unanswerable lock. Damage, PvE hits, death and crowd control (Glacius, Petrificus, Levioso, Arresto, Transformation) are never affected. Defaults: 2 staggers per 1.5s, then 1s of stagger immunity.
Parameters
Section titled “Parameters”policy?
Section titled “policy?”boolean | { enabled?: boolean; maxChain?: number; suppressFor?: number; window?: number; }
Omitted fields keep their current value; a bare boolean toggles enabled.
Returns
Section titled “Returns”string
showMeter()
Section titled “showMeter()”showMeter(
playerId?):string
WRITES. Points the retail boss/duel HUD meter at that player’s proxy and writes their character name (CCD first+last, nickname fallback) into it. The bar/level track their real vitals via the native relay.
Parameters
Section titled “Parameters”playerId?
Section titled “playerId?”number | "auto" | null
Whose proxy to track; 0 uses a dev-spawned student; ‘auto’ follows whoever your hits land on (team duels/FFA); null/omitted hides the meter.
Returns
Section titled “Returns”string