Balatro-Multiplayer / Balatro-Multiplayer/BalatroMultiplayer
[Beta v3 PvP] Cocktail Deck applies zero mixed-in decks
- Dominant language
- Lua
- Stars
- 335
- Forks
- 106
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 1
Description
**Status: root cause confirmed**
**Affects:** MultiplayerPvP Closed Beta v3 (mqtt branch)
## Symptom
Tester report: "cocktail just doesnt work." Picking the Cocktail Deck behaves like a plain deck — no mixed-in deck effects are applied.
## Root cause
The legacy create-lobby path seeded `MP.LOBBY.config.cocktail` from the player's saved config right before lobby creation (`ui/main_menu/play_button/play_button_callbacks.lua:135` pre-conversion). That file was deleted in the MQTT conversion (86434fd) and the new path (`pvp_api/flow.lua`) never re-added the seed. The config string therefore stays `""` (the `reset_lobby_config` default, `core.lua:200`).
`MP.cocktail_cfg_get()` (`objects/decks/ZZ_cocktail.lua:586-592`) treats `""` as a set value (empty string is truthy in Lua) and never falls back to `MP.config.cocktail`, so the deck-pool cull (`ZZ_cocktail.lua:156-166`) matches zero positions and the apply loop mixes in zero decks.
Two related defects in the same feature:
- `mod_whitelist` (`ZZ_cocktail.lua:6-11`) still gates on mod id `"Multiplayer"`, but the mod id changed to `"MultiplayerPvP"` — the mod's own cocktail-eligible decks are silently excluded from the pool.
- `MP.pvp_lobby_metadata` (`pvp_api/flow.lua:15-26`) never ships `cocktail` (or `sleeve`/`challenge`) to the guest, so even a correctly-seeded host config cannot reach the guest client.
Contributor guide
Research direction
Start by reading pvp_api/flow.lua, objects/decks/ZZ_cocktail.lua, and the reset default in core.lua:200, then compare the deleted legacy callback at ui/main_menu/play_button/play_button_callbacks.lua:135. Trace lobby creation and guest metadata handling; done means cocktail configuration reaches both clients and the eligible deck pool produces mixed-in effects, including the mod's own decks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- game-dev, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 58/100