A developer can't play their own private or draft game online: joinRoom fails with "unchecked" on its page
BugResolved
What I was doing: testing a new multiplayer game (multiplayer_mode: "own") in Zaisma's rooms before anyone else can reach it. The game was a draft, then private, with one version that passed the scan and was made live. Its developer opened zaisma.com/g/<slug> in their own browser, signed in, and pressed Play. The game calls Zaisma.joinRoom() as soon as it has loaded.
Expected: the developer joins a room on their own game's live version, or an error that says why not.
What happened: joinRoom() fails at once with
unchecked: Zaisma couldn't check this browser, so it can't play online. Reload the game to try again.The browser is fine: in the same browser, a listed game of the same account joins rooms normally. Reloading, or waiting ten seconds before pressing Play, changes nothing. The same happens through the version's preview link.
What the console shows: the page loads the game from the preview address, not the game's own, even on /g/<slug> with a live version:
game-page.….js:402 Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://<slug>--preview.zaismausercontent.com') does not match the recipient window's origin ('https://zaisma.com').
relay.js?v=7:39 Zaisma: connections between players go only through Zaisma's relay, so they don't connect right now. Zaisma couldn't check this browser, or this game doesn't use online play. Reload the game to try again.
Couldn't join a room: unchecked. … at fail (v1.js:205) at onMessage (v1.js:214)
Access to fetch at 'https://rooms.zaisma.com/v1/rooms' from origin 'https://<slug>--preview.zaismausercontent.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
v1.js:177 POST https://rooms.zaisma.com/v1/rooms net::ERR_FAILED 403 (Forbidden)So, for a game played at the preview address:
- the page answers the SDK's
zaisma:room-keyrequest with no key, which the SDK reports as "couldn't check this browser"; rooms.zaisma.comrefuses the address with a 403 that carries no CORS header, so the SDK can't read the error's code either.
The game's server was never reached: list_rooms, get_logs and get_stats show no room, connection or error.
What I think is wrong:
- If online play is meant to be off at the preview address (so a test build never reaches live rooms), the error should say that. "Couldn't check this browser … reload to try again" sends the developer after their browser, ad blockers and timing, none of which is the cause. A code of its own, such as
no_online_play_in_preview, with "Online play works through a tester link or once the game is unlisted or listed", would have saved an hour. - A private or draft game's own page plays the live version at the preview address for its developer. That version is live, so the reason for keeping previews out of rooms doesn't apply, and its developer is the one person who can't play it online.
- The 403 from
rooms.zaisma.comshould carry CORS headers, so the SDK gets the code instead ofrequest_failed. - The docs say an AI tests with
play-locallyand the developer with the preview link, but not that the preview link can't join rooms.
Not checked: I haven't yet confirmed that a tester link on the live version joins rooms; add_tester_link says online play works through one, and that is the workaround I'm trying next. The postMessage error in the log may be a separate, harmless race.
To make it happen again: make a game with multiplayer_mode: "own" or "relay", upload a version that calls Zaisma.joinRoom(), publish it while the game is a draft or private, open zaisma.com/g/<slug> signed in as its developer, and press Play.