Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Backend de jogos multiplayer
Search
Rodrigo Delduca
August 15, 2017
Programming
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Backend de jogos multiplayer
Rodrigo Delduca
August 15, 2017
More Decks by Rodrigo Delduca
See All by Rodrigo Delduca
Mágica com Qt’s meta-object system
skhaz
1
100
Como criar o seu próprio joystick
skhaz
0
2.3k
Other Decks in Programming
See All in Programming
運用ダッシュボードの設計を誰も教えてくれないのだけどみなさんどうしてるんですか? - チームに監視するという文化を根付かせるための第一歩を踏みたい -
satoshi256kbyte
1
130
「つくるAI」だけではバグは見つからない ~テストに必要な「見つけるAI」を分離させる戦略~
mfunaki
0
120
php-fpmのプロセスが枯渇した日-調査・対処・そして本当にやるべきだったこと-
shibuchaaaan
0
330
komatsuna「分散システムにおけるバグ分析手法」
komatsunaqa
0
270
リアルな遅延を測る仕様
kota_yata
1
120
React本体のコードリーディング
high_g_engineer
1
150
全PRの83%がAIレビューだけでマージできるようになった開発組織はその後どうなったか
athug
1
1.9k
言葉の格闘技のススメ~紙とペンと言葉から始める、キャリアの描き方~
progresscicada
2
160
MySQLとPostgreSQLって何が違うの?
akagami
0
120
自動化したのに回らないテスト運用の壁ーAI時代の品質責任と生産性
mfunaki
1
140
源内ハンズオン概要編
hideg
0
190
自動化したのに回らない テスト運用の壁―AI時代の品質責任と生産性
mfunaki
0
350
Featured
See All Featured
Product Roadmaps are Hard
iamctodd
55
12k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
10k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
720
Speed Design
sergeychernyshev
33
2k
Done Done
chrislema
186
16k
Faster Mobile Websites
deanohume
310
32k
GitHub's CSS Performance
jonrohan
1033
470k
Skip the Path - Find Your Career Trail
mkilby
1
190
Git: the NoSQL Database
bkeepers
PRO
432
67k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
900
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
230
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
370
Transcript
Backend de jogos multiplayer Rodrigo Delduca (@skhaz) https://skhaz.io https://nullonerror.org https://ultratech.software
PUC PR - 2017
Brace yourself. Sopa de letrinhas is coming!
Formas de comunicação • TCP • UDP • RawSocket •
WebSockets • SocketIO • WebRTC
Arquitetura
Otimizando o tamanho do payload
Otimizando o tamanho do payload payload = { "UpPressed": true,
"downPressed": false, "attackPressed": true } // 76 bytes
Otimizando o tamanho do payload payload = { "u": true,
"d": false, "a": true } // 46 bytes
Escovando os bits
Escovando os bits
Escovando os bits
Escovando os bits
Escovando os bits
Tecnologias • C/C++ • Python • Elixir • Java •
NodeJS • Swift • Erlang • … Ou qualquer outra linguagem que permita abrir uma conexão.
Qual tecnologia é melhor?
Qual tecnologia é melhor? A que você dominar melhor*
Qual tecnologia é melhor? A que você dominar melhor* só
não vale usar Visual Basic :)
E onde hospedar? • Google Cloud • Heroku • Digital
Ocean • Amazon Web Services (AWS) • Scaleway • Rackspace • Azure • IBM Bluemix
Banco de dados • PostgreSQL, MySQL, Oracle e SQLite (relacional)
• MongoDB, CouchBase e RethinkDB (orientado a documento) • Redis, memcached e Cassandra (chave-valor) • Neo4J e ArangoDB (banco de dados de grafos)
Outras alternativas … Que podem ser ideias para hackathon e
gamejams
Exemplo usando Socket.IO
Demo http://bit.ly/pucpr-mmo
• https://davidwalsh.name/websocket • http://blog.soom.la/2016/02/top-10-parse-alternatives-game-backend.html • https://realm.io/docs/realm-object-server/ • https://firebase.google.com/ • http://heroku.com/
• https://www.meteor.com/ • https://phaser.io • https://socket.io/ • https://cloud.google.com/ • http://choongsoo.info/docs/starcraft2.netgames12.pdf • https://blog.heroku.com/introducing_session_affinity
Perguntas?
Muito obrigado :) Scorpion wins Flawless victory Fatality!