Closed raj5036 closed 2 years ago
If I am not mistaken every subscriber for every game should wait on a different channel. So I guess the channel should be named after the game id, eg. channel name f'GAME_{str(game_id)}
for each game.
Now I think the save_results should publish the results of the game. And the player1 in websocket_host
in the end should subscribe and wait for a message to the channel, that will be fired by websocket_join
in the end instead of inform_host
or simply change all the inform_host
to only do save_results
I have added some changes and In order to save the results I am planning to Modify the save_results method in the GameManager Class but I am having an issue about one thing....that is
In order to add the result of the game to the pubsub message I need to subscribe to a channel. So which channel would it be? Can you tell me the Channel's name?