Oliver-Akins / Phantom-Ink-Online

The online prototype for Resonym's game titled Phantom Ink.
http://phantominkgame.com/
6 stars 2 forks source link

Hand Updating Across The Team #18

Closed Oliver-Akins closed 3 years ago

Oliver-Akins commented 3 years ago

Overview

Each team must keep the cards between each of the mediums synchronized, there are few different ways that this can be done listed below:

Solution:

Client:

Event Listeners:

Event Emissions:

Server:

Event Listeners:

Event Emissions:

Oliver-Akins commented 3 years ago

The solution is being modified a bit to instead of having the NewCard event, we will just have all clients solely using the the UpdateHand event listening for updating all forms of the hand, what this means is that the spirit will also have the event listening and we will be storing the Spirit's hand in the team object as well as the medium's hand, this also helps prevent disconnections from losing any gamestate.