Skip to content

Multiplayer examples need to be expanded #277

Open

Description

@valkyrienyanko

The current examples are barebones and only showcase syncing positions. The examples should be expanded into an actual game to showcase that the netcode is actually nice to work with. The game could be a barebones MMORPG example showcasing inventory syncing across multiple clients among other things like combat. This is a very involved issue. I don't think I will ever get to this point on my own.

As a small reminder in the following example:

// The client
public partial class GameClient : GodotClient
{
    public GameClient()
    {
        OnPacket<SPlayerPositions>(packet =>
        {
            Log($"Received {packet.Positions.Count} player positions");
        });
    }

    protected override void OnConnected()
    {
        Send(new CPlayerJoined("Valk"));
    }
}

OnPacket<SPlayerPositions> should be changed to OnPacketReceived<SPlayerPositions>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions