Limbo
Use Limbo when you want to build a wager around a target multiplier.
What the builder does
createBetTransaction('limbo', options) converts your multiplier into the fixed-point values expected by the contract, then builds the Limbo play transaction.
Required options
ownercoinTypestaketargetMultiplier
Optional game-specific options
scale
Shared optional options
cashStakebetCountmetadatagasBudgetallowGasCoinShortcut
Example
const tx = client.suigar.tx.createBetTransaction('limbo', {
owner: '0x123',
coinType: '0x2::sui::SUI',
stake: 1_000_000_000n,
betCount: 3,
targetMultiplier: 2.5,
});
Typical usage
The usual Limbo flow is:
- read live stake and multiplier bounds
- collect a human multiplier such as
2.5 - build the transaction with the human value, not the scaled integer
- sign and execute it
- decode results if you want to display the resolved multiplier or payout details
Read current limits
Use live parameters when you need the current allowed stake or multiplier bounds before building the transaction:
import { fromMoveFloat } from '@suigar/sdk/utils';
const parameters = await client.suigar.getGameParameters('limbo', {
coinType: '0x2::sui::SUI',
});
const minMultiplier = fromMoveFloat(parameters.min_target_multiplier);
const maxMultiplier = fromMoveFloat(parameters.max_target_multiplier);
This is useful when your UI needs to:
- clamp a user-entered multiplier to the current allowed range
- show live min and max multiplier guidance beside the input
- compare a custom
targetMultiplieragainst the current onchain bounds before building the transaction
Notes
- The SDK uses
DEFAULT_LIMBO_MULTIPLIER_SCALEfrom@suigar/sdk/utilsas the default multiplier scale. Its current value is100. targetMultiplier: 2.5becomes250before being sent to Move.- Use a custom
scaleonly if your integration needs to stay aligned with a different fixed-point representation. - partner attribution is injected automatically when the extension is registered with
partner - reserved metadata keys such as
partnerandreferrerare ignored with a warning when passed manually - fields such as
min_target_multiplier,max_target_multiplier,min_rtp, andmax_rtpare returned as generated Move float structs, so decode them withfromMoveFloat()