Casino game script
Search code, repositories, users, issues, pull requests
Welcome to the casino roulette documentation. This is the plain HTML, CSS and JS (TypeScript) casino roulette implementation that is originally written using JSX but compiles to plain JS by Babel.
Live example - thisisnl.nl
If you need the same for your React project, take a look at - thisisnl.nl
Where * means required
Optn | Type | Default value | Description |
---|---|---|---|
id* | - | The wheel render element id | |
type* | - | The wheel type: American or European |
Method | Arguments | Description |
---|---|---|
changeType | New wheel type. American or European | |
doSpin | Start spinning wheel function. It takes a number of a winning bet on the wheel and a function which will be called when the wheel stop spinning (optional argument) |
Where * means required
Opt | Type | Default value | Description |
---|---|---|---|
id* | - | The table render element id | |
type* | - | The table type: American or European | |
bets* | - | The table bets. Type: { [key: string]: { icon?: string; } } | |
onBet* | - | Function which handles user bets |
Method | Arguments | Description |
---|---|---|
changeType | New table type. American or European | |
render | Renders the table with updated data. Call this method every time your bets object changes |
- - tests
- - dev
- - production. See for the folder
Make sure you link the roulette css & js file.