Phoenix
A crash-style game with a fiery phoenix theme — watch the phoenix soar as the multiplier climbs and cash out before it flies away.
Import
import { PhoenixGameSDK } from '@maktubbet/sdk/phoenix'
import '@maktubbet/sdk/phoenix/styles.css'Usage
'use client'
import { useState } from 'react'
import { PhoenixGameSDK } from '@maktubbet/sdk/phoenix'
import '@maktubbet/sdk/phoenix/styles.css'
export default function PhoenixPage() {
return (
<PhoenixGameSDK
accessToken="user-jwt-token"
user={{ betCount: 0, isAuthenticated: true }}
updateBalance={(newBalance) => console.log(newBalance)}
onAuthRequired={() => console.log('Auth required')}
currency={{ code: 'USD', prefix: '$', rate: 1 }}
language="en"
logo={<span>MY LOGO</span>}
onToast={(t) => console.log('Toast:', t.title)}
theme={{
backgroundDark: '#0D1117',
backgroundDarkLight: '#161B22',
inputBackground: '#0D1117',
actionButtonColor: '#1C2333',
buttonColor: '#FFFFFF',
}}
/>
)
}Demo Mode
Demo mode is automatically enabled when a user places a bet with a $0 amount. To run the game entirely client-side without a backend session, pass isDemo — see Demo Mode.
Features
- Animated phoenix chart — a fiery phoenix soars along the multiplier curve with dynamic scaling
- Cash out anytime — lock in your multiplier before the phoenix flies away
- Auto cash out — set a target multiplier to automatically collect
- Epic crash effects — screen shake, fiery supernova explosion, and golden ash rain
- Bet history — track recent results and crash points
Props
See Shared Props — PhoenixGameSDK accepts the standard PhoenixGameSDKProps interface.
| Prop | Type | Required | Default |
|---|---|---|---|
accessToken | string | null | ✅ | — |
user | GameUser | ✅ | — |
updateBalance | (balance: number) => void | ✅ | — |
onAuthRequired | () => void | ✅ | — |
currency | GameCurrency | — | { code: 'USD', prefix: '$', rate: 1 } |
language | string | — | 'en' |
logo | ReactNode | — | — |
onToast | (toast: ToastData) => void | — | — |
theme | GameTheme | — | — |
Last updated on