Summary
Arcade casino for RP servers: Blackjack, horse racing, Mines, Chicken Road, Keno and Plinko. Live spectator screen, blinking lights. Plugs into your server's money system.
Description
CASINO (RP)
Six gambling games on arcade machines - built for roleplay servers and dedicated servers.
GAMES
• Blackjack - 6 decks, dealer stands on 17, blackjack pays 3:2, double down, split pairs
• Horse racing - 6 horses with fixed odds, the race runs live on the screen
• Mines - 5x5 grid, choose the number of mines, cash out any time
• Chicken Road - get the chicken across the road, three difficulty levels
• Keno - pick 1 to 10 numbers out of 40, 10 are drawn
• Plinko - 8, 12 or 16 rows, three risk levels
THE MACHINE
• One player per machine - others see "occupied" and can watch
• Live screen: everyone nearby sees the running game on the machine (without the player's balance)
• 52 lights with changing patterns, the machine flashes gold/white on a win
• Placeable by Game Masters, collision and interaction ready to use
FAIR ODDS
Every menu has an ODDS button with win probabilities and multipliers. All pay tables are calculated from scratch (fair, then multiplied by the house edge), not copied from other casinos.
Return to player with default settings:
• Blackjack approx. 99.5 % (with good strategy, simulated)
• Mines 97 % • Plinko approx. 96.5 % • Chicken Road 96 % • Keno approx. 96 % • Horse racing approx. 90 %
The house edge can be set per game in the prefab.
NETWORKING AND SECURITY
The server decides everything. The client only displays and sends requests ("hit", "reveal tile").
• Requests go through the player's own PlayerController (reliable RPC), so the server knows who is asking - whatever the client claims about itself does not count.
• The server checks every request: distance to the machine (3 m), whether the machine is free, bet limits, balance, game rules. At most 10 requests per second per player, extra data limited to 256 characters.
• Randomness only on the server: cards, mines, race winner, draws, ball path. The dealer's hole card, the shoe and the mines never leave the server before the round is over. Every player has their own shoe.
• The response containing the balance goes to that player only. The spectator screen gets the same state without the balance (broadcast RPC to clients that have the machine streamed in).
• Machine occupancy is a single replicated number. It is released when the player closes the menu, walks away or leaves the server.
• Network traffic only on an action, one short text per response - nothing is sent per frame.
• The race and the Plinko ball are pre-decided results that the menu just plays back.
• Singleplayer, Workbench, listen server and dedicated server all use the same path.
PERFORMANCE
• The dedicated server renders nothing: no screen, no lights, no menus.
• The screen only runs on clients closer than 25 m (30 fps); further away everything is torn down.
• The lights are not light sources but part of the screen image - practically free.
• View distance, frame rate and lights are configurable per machine.
FOR SERVER OWNERS
Out of the box the casino uses play money: every player has $1,000, kept in memory only (back to $1,000 after a restart). With play money there is also a "+$1,000" button for testing.
For real money, connect your server's money system with a small class (three functions: balance, withdraw, deposit) - see the GMB_Wallet class in the mod.
Configurable per machine (prefab attributes): min/max bet, house edge, max payout, decks and dealer rule, horses with names and weights, mine options, lanes and survival chances, spectator screen, one player per machine, lights.
Prefabs: Prefabs/Casino/Arcade/GMB_Arcade_<Game>.et
NOTE
In-game money only. This mod has nothing to do with real money.
LICENSE
Arma Public License Share Alike (APL-SA): share and modify with attribution, non-commercial, Arma games only, under the same license.
Credits: LuKy.License
Arma Public License Share Alike (APL-SA)