Royal Pool King
8-ball pool with its own physics engine, three computer opponents, 22 career levels and a practice table, playable in your browser.
BoardLast reviewed
Carrom Royale is carrom for the browser, with three rule sets, three computer levels and a practice board. The physics uses the Matter.js engine tuned for carrom, and this page explains the rules, how the computer plays and the numbers behind the board.

Browser-native HTML5 game. No downloads or installations required.
Drag to place the striker, then press and pull back on it to aim and set power. With a keyboard: ←/→ move the striker, A/D aim, W/S power, Space shoots and Esc pauses.
Drag along the board to slide the striker, then press on it and pull back to aim and set power. Let go to shoot.
| Setting | What changes | Values from the code |
|---|---|---|
| Easy | Gentle shots, occasional aiming errors, relaxed pace. Picks at random from its 4 best shots. | Aim error up to ±4.5° · power ±0.10 · thinks 0.5 s |
| Medium | Balanced targeting and good power. Picks at random from its 2 best shots. | Aim error up to ±1.8° · power ±0.04 · thinks 0.7 s |
| Hard | Always takes its best shot, tries twice as many striker positions and values the queen more highly. | Aim error up to ±0.4° · power ±0.04 · thinks 0.9 s |
Aim error is a random angle added to the shot the computer chose; power is on a scale of 0 to 1. The thinking time is a pause before the shot so you can see what it is doing.
These tips follow from how the game's rules and numbers work.
Carrom Royale uses the Matter.js 2D physics engine, stepped 240 times a second. Its tuning:
stepHz: 240,
coinMass: 5.5,
strikerMass: 16.5, // three times a coin
restitution: 0.88, // bounciness of coin and striker collisions
contactFriction: 0.035,
frictionAir: 0.004,
slideDecel: 300, // how quickly pieces slow on the board
stopSpeed: 5.5The striker weighing three coins is the important number. It is why a full hit drives a coin hard while the striker slows sharply, and why a striker that clips a coin thinly keeps most of its speed and is likely to follow it into a pocket.
You pull back from the striker and the shot goes the opposite way. A pull that ends very close to the striker is ignored, so a mis-tap does not waste your turn, and shots have a minimum power. The dotted guide shows the first disc the striker will hit; the settings let you extend it to show the path after one rail rebound.
On its turn the computer tries striker positions along its baseline (every 24 units on Easy and Medium, every 12 on Hard). For each, it looks at every coin it is allowed to pocket and every pocket, works out where the striker must touch the coin to send it at that pocket, and drops cuts that are too thin. Each remaining shot gets a score: higher for straighter cuts, lower the further the coin is from the pocket and the striker from the coin, plus 30 for one of its own coins and a bonus for the queen (20, or 45 on Hard). It does not check whether other coins are in the way. Then:
// choose
easy: random pick from the top 4 shots
medium: random pick from the top 2 shots
hard: always the top shot
// then miss on purpose
aimError = random(-1, 1) * (easy ? 4.5 : medium ? 1.8 : 0.4) degreesThat is a simplified version of the game's code. The random error is why Easy misses long cuts: an error of 4.5 degrees moves the aim by about 8 cm for every metre the striker travels.
Play with Friend uses PeerJS to connect the two browsers directly over WebRTC. One player creates a room and shares the code or link, the other joins, and from then on the shots go straight between the two browsers. Only names, avatars and shots are exchanged.


Classic: you own one colour, must cover the queen, and score the opponent coins left on the board plus 3 for the queen. Disc Pool: pocket all your discs, then the queen; pocketing the queen early loses the frame. Freestyle: anyone may pocket anything; white is 20, black 10, a covered queen 50.
Pocketing the striker, and pocketing your last coin before the queen is covered. After a striker foul, coins you pocketed on that shot come back and you return one coin.
One player creates a room and shares the code or invite link. The game connects the two browsers directly using the public PeerJS service. You need an internet connection, and the other player's browser can see your IP address; see the Privacy Policy.
Yes: ←/→ move the striker, A/D aim, W/S change power, Space shoots and Esc pauses.
8-ball pool with its own physics engine, three computer opponents, 22 career levels and a practice table, playable in your browser.