RoundStatus
Defined in: packages/engine/src/components/Round.tsx:55
Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
countdownLeft |
number |
Seconds of its countdown left. |
elapsed |
number |
Simulated seconds it has played. |
fail |
(reason) => void |
Loses a round that has not ended, for reason. |
finish |
() => void |
Wins a round in play. |
lap |
number |
Laps finished, and the laps that win it; 0 for none. |
laps |
number |
- |
reason |
string |
Why it was lost: "time", or the reason passed to fail. |
restart |
() => void |
Starts its scene again, so the coins, the player and the round spawn anew. |
score |
number |
The coins in the player’s wallet. |
secondsLeft |
number |
Simulated seconds the round has left, never below zero; Infinity with no limit. |
start |
() => void |
Starts a round that is ready. |
state |
RoundState |
- |
target |
number |
The score that wins the round; 0 for none. |