Skip to content

CtxWallet

Defined in: core/wallet.ts:29

What game code sees as ctx.wallet (ADR 0007). Keys are unique within the table.

balance(seat): Promise<number>

Defined in: core/wallet.ts:33

The seat's player's available funds. Runs now.

number

Promise<number>


commit(key): void

Defined in: core/wallet.ts:35

Turns a reservation into a debit, after this entry commits.

string

void


credit(seat, amount, key): void

Defined in: core/wallet.ts:39

Pays the seat's player, after this entry commits.

number

number

string

void


release(key): void

Defined in: core/wallet.ts:37

Cancels a reservation, after this entry commits.

string

void


reserve(seat, amount, key): Promise<boolean>

Defined in: core/wallet.ts:31

Holds amount from the seat's player. Runs now; resolves false if refused.

number

number

string

Promise<boolean>