Game Coding Complete Community

This community site is a companion to Game Coding Complete, written by Mike "MrMike" McShaffry and David "Rez" Graham. Programmers of all levels are invited to participate.

Unread Threads

Topic Replies Last Reply

User Avatar

Prediction in an online multiplayer game with an event manager

IgnatusZuk - - Book Forum (4th Ed.)
5
User Avatar

IgnatusZuk

Recent Activities

  • User Avatar

    IgnatusZuk -

    Replied to the thread Prediction in an online multiplayer game with an event manager.

    Post
    @mrmike Thanks for the excellent reply. This actually seems like a pretty big thing I've overlooked. So it looks like there are two type of events: Input and Output which all go through the server logic. Yep this solution makes me quite happy, and even…
  • User Avatar

    mrmike -

    Replied to the thread Prediction in an online multiplayer game with an event manager.

    Post
    Looking at the graph, I see one important difference between the system I propose in the book versus what yours. In mine I never have the client send a position update to the server - instead I send something like "Move this direction at some speed". The…
  • User Avatar

    IgnatusZuk -

    Replied to the thread Prediction in an online multiplayer game with an event manager.

    Post
    Thanks for the feedback. @Rez Yep, I'm dealing with a client->server architecture, and I was hoping to implement prediction&correction with out creating a bunch of new events for every action that needs prediction. I guess I'm hoping for an elegant…
  • User Avatar

    rezination -

    Replied to the thread Prediction in an online multiplayer game with an event manager.

    Post
    You need an authority. These days, that authority rests with a dedicated server that every connects to. If you load up Battlefield or Left 4 Dead multiplayer, you're connecting to that server just like every other player. In the olden days of Quake or…
  • User Avatar

    Dendra -

    Replied to the thread Prediction in an online multiplayer game with an event manager.

    Post
    A few days ago, I thought about how I would personally go about doing events for a multiplayer game. I think that it should be sufficient to just send the input of each player to every other player. If your event handling is deterministic, all players…
  • User Avatar

    IgnatusZuk -

    Posted a new thread: Prediction in an online multiplayer game with an event manager

    Thread
    Hi, how would you handle prediction in an online multiplayer game with an event manager, such as in GCC? It seems to me that it would not be as simple as forwarding the same events from client to server and vice versa. So client logic and…
  • User Avatar

    amosco -

    Replied to the thread Networking part BinaryPacket behavior.

    Post
    Yeah ok, got it. I cleaned all the tests and now it is working. Thanks for showing me the light ;) :thumbsup:
  • User Avatar

    mholley519 -

    Replied to the thread Networking part BinaryPacket behavior.

    Post
    No problem, let us know if you need any more help. Quote: “I still don't understand why the watcher show me a null terminated string in m_Data after the htonl affectation. It is like it interprets m_Data as a string.” This is because m_Data is…
  • User Avatar

    amosco -

    Replied to the thread Networking part BinaryPacket behavior.

    Post
    Well of course that works with a simple code sample in a simple online editor. X( Now I really guess this comes from the visual studio interpretation of m_Data and the fact I don't know very well that editor. Thank you again for your answers. I guess…
  • User Avatar

    amosco -

    Replied to the thread Networking part BinaryPacket behavior.

    Post
    I agree with you again that what I expected. I assumed the sentence by what I see in the watcher. So far so good, I will make code snippets to demonstrate what I have. I still don't understand why the watcher show me a null terminated string in m_Data…