-
-
Notifications
You must be signed in to change notification settings - Fork 594
Decentralized
Edit: We went for Nakama for the first stage to get things going.
https://3box.io/hub https://3box.io/products/profiles https://github.com/3box/3box-dapp https://github.com/heroiclabs/nakama/issues/436 https://3box.io/0x21f53db4d2eacde70a2e4f0407d073c971ec1a33
https://itnext.io/making-a-multiplayer-blockchain-game-using-phaser-nodejs-and-ethereum-pt-1-d967aa714efe https://docs.ethhub.io/built-on-ethereum/games/what-is-blockchain-gaming
This document explains how the decentralized online multiplayer system should work; Warning: first draft, very rough state atm.
nodejs server(s) dealing with lobbies and matchmaking basically a server that will deal with other servers
master server handling accounts and logging in which are actually both optional gameplay parts
each client also contains a server that can verify moves and is capable to creating rooms that will get listed in lobbies to one or more official lobby servers which are currently on rooms are joinable from lobbies or by accessing special links //todo: need to figure out a way to be able to bypass lobbies so that pre-match games can still be accessible by any players the game should also be playable offline, on the same machine
there can be official peers that will spectate certain games in order to validate the moves done by the players real time this will happen for official tournament rounds, games where bitcoin bets are taking place between all the players and any matches in which a player with an active subscription is newly registered accounts (assumed new players) could also be babysit in order to make sure they're not being trolled or that they're not cheating themselves, causing frustration
one or more headless servers will be deployed via Node.js in order to constantly validate game logs of finished matches and penalizing any cheating players that are using accounts
virtually unlimited of players can spectate matches by having to propagate (and confirm) the player moves to other peers
unit cards and perhaps power-ups are allowed to be farmed by players that own good hardware and bandwidth by actually having them validate player actions from any random games that are currently undergoing, without needing to spectate this is similar to how p2p cryptocurrency networks operate
when the validation of player actions from multiple peers doesn't match, an official peer will join in to resolve the dispute in the background, making sure the match will resume properly and that the faulty peers are sanctioned
This would allow for a decentralized account system
Library that deals with p2p connections and more
- https://libp2p.io/
- https://github.com/libp2p/libp2p
- https://github.com/libp2p/js-libp2p
- https://github.com/trufflesuite/ganache
Implementation references
Good read concerning p2p technology
- https://github.com/noffle/p2p-faq
- https://en.wikipedia.org/wiki/Torrent_poisoning
- http://arxiv.org/pdf/1504.01358.pdf
A list of p2p stuff https://github.com/ziasistani/awesome-peer-to-peer