0 Members and 2 Guests are viewing this topic.
Another method of doing link play is to only send your own keypresses. So each calculator will be receiving input both from their own user, and key input from the other user from the linkport. As long as both games treat the input in exactly the same way, both games will be carried out in the same fashion.
Unless you use a deterministic RNG and seed it at the start
Like I always say, linking is easy, but syncing is hard. Puyo Puyo runs fast because it only needs to send data when a particular "event" occurs (combos). Event driven programming style is a little different than what you're used to but basically you put the Get() in your main loop so its always ready to receive an event. Don't forget, Get() doesn't delay or wait unless the other calc is sending something.You send data by first sending an enumerated event type (1 bytes) followed by the event data (which may be different length depending on the event). For instance you might need to send a character's position. This can be done by sending a "X change" event followed by the x coordinate whenever that coordinate changes and a "Y change" event followed by a y coordinate. The actual transfer speed is about 500 bytes per second maybe. If your main loop is running at 30fps and don't mind reducing to 20fps that's about 8 bytes per frame of data you can send which is probably enough for a decent subsets of multiplayer games.