Skip to content

Missing players.clear() inside the remove_multiplayer_peer of the example lobby implementation #10367

@Gr0minet

Description

@Gr0minet

Your Godot version: v4.3.stable.official.77dcf97d8

Issue description: In the example lobby implementation, a call to players.clear() is missing inside the remove_multiplayer_peer function. Otherwise the players dictionary is not reinitialized when a player disconnects and reconnects. The dictionary will contain among others his own previous multiplayer id which should have been erased because he disconnected, or multiplayer ids of players who disconnected when the player was disconnected himself.

URL to the documentation page: https://docs.godotengine.org/en/stable/tutorials/networking/high_level_multiplayer.html#example-lobby-implementation

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:manualIssues and PRs related to the Manual/Tutorials section of the documentationbugcontent:example codeIssues and PRs involving code examplestopic:multiplayer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions