mc_join_server
Join a Minecraft multiplayer server by address. Automatically disconnects from the current world, accepts resource packs, and waits until the player is in-world before returning.
Instructions
Join a multiplayer server by address ("host" or "host:port"). Disconnects from the current world/server first if needed, so this changes the user's play session — don't point it at a new server without being asked. The server's resource pack is pre-accepted by default so the join doesn't stall on the confirmation prompt.
The bridge ack means the connect attempt has started — current bridges defer it until the client has settled (no startup/reload overlay), so a join issued right after client launch is safe and may take some extra seconds to ack. By default this also polls until the player is actually in-world: success when a game snapshot shows a player, failure when a DisconnectedScreen appears (its title is returned as the reason). When called from inside a world, the poll first waits for the old session to drop so a stale snapshot of it can't masquerade as the new join. Set wait=false to just fire the join and return.
For repeated automated test runs, prefer a local throwaway server over a live community server — live servers have nondeterministic worlds, other players, and rules about automation.
Requires session_control_enabled=true in the DebugBridge config.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | Poll until in-world / disconnected before returning. Default true. | |
| address | Yes | Server address, "host" or "host:port" (e.g. "localhost:25565") | |
| timeoutSeconds | No | How long to wait for the join to complete. Default 60. | |
| acceptResourcePacks | No | Pre-accept the server resource pack. Default true. |