Reliving the history of multiplayer games

  • 2,189 views
Uploaded on

At Wooga we are creating the next generation of social games. To be truly social, a game needs to offer real interaction between players in various forms. What started with simple, asynchronous gift …

At Wooga we are creating the next generation of social games. To be truly social, a game needs to offer real interaction between players in various forms. What started with simple, asynchronous gift requests is evolving into real time interactions between players. We are experiencing a renaissance of multiplayer games, giving us the opportunity to look into problems that have been solved over a decade ago, such as network architectures, communication protocols, latency and connection loss. And we now leverage that knowledge to bring multiplayer games to the mobile world.

In our talk we’ll cover this evolution of user interaction in our games, what technical problems they posed and how we solved them.

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
2,189
On Slideshare
0
From Embeds
0
Number of Embeds
5

Actions

Shares
Downloads
23
Comments
0
Likes
4

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Reliving the history of multi player games @phuesler @rirei
  • 2. At Wooga Evolution is driven by teams
  • 3. Technologies
  • 4. Architecture
  • 5. Platforms
  • 6. User interaction
  • 7. Level 1: Read-only interaction
  • 8. High score Pacman
  • 9. read-only access Client Score DB Client
  • 10. Level 2: Inbox interaction
  • 11. Turn based Empire Civilization
  • 12. inbox Client Inbox Client DB
  • 13. Inbox interaction Client Inbox App Client
  • 14. woo.ga/backend
  • 15. Level 3: Real interaction
  • 16. Real interaction MUD World of Warcraft
  • 17. Real interaction Client Usr Usr Loc App Client
  • 18. Handling conflicts Client Usr Usr Loc App Log Log Client
  • 19. woo.ga/backend
  • 20. Level 4: Real time interaction
  • 21. Real time interaction Super Mario Kart Starcraft
  • 22. Player 1 Player 2 Server
  • 23. Player 1 Player 2 Server
  • 24. Player 1 Player 2 Server
  • 25. Sources of inspiration
  • 26. • good throughput • low latency • low packet loss • no jitter We depend on
  • 27. Level 4: Real time interaction on mobile
  • 28. 3G Internet
  • 29. Bandwidth 0.73 Mbps 1.2 Mbps3G https://de.wikipedia.org/wiki/High_Speed_Uplink_Packet_Access https://de.wikipedia.org/wiki/High_Speed_Downlink_Packet_Access
  • 30. Added Latency (RTT) * 3G 70 - 180 ms http://202.194.20.8/proc/VTC09Spring/DATA/09-18-19.PDF * HSDPA/HSUPA
  • 31. Packet loss
  • 32. Latency Jitter 0 75 150 225 300 RTT ms
  • 33. Let’s do Bomberman
  • 34. Client Prediction Extrapolation Interpolation Lag Compensation Latency Object Replication Quality of Service Physics Collision Detection TCP UDP Real Time Match Making Packet Loss Synchronization Peer-To-Peer Lockstep Protocol
  • 35. 1
  • 36. Architecture C1 C2Server move :up c1 moved :up place bombc2 placed bomb bomb exploded bomb exploded game over game over
  • 37. TCP JSON EASY!!!
  • 38. Works on Wifi:)
  • 39. game doesn’t work on 3G :(
  • 40. Jitter
  • 41. Dropped packets
  • 42. TCP Packet Ordering and Resend
  • 43. TCP Flow and Congestion Control
  • 44. Warping noupdate noupdate noupdate 4 updates at once
  • 45. or WORSE :(
  • 46. 2
  • 47. Architecture move :up C1 C2Server c1 moved :up place bombc2 placed bomb bomb exploded bomb exploded game over game over
  • 48. UDP 3G Will it work?
  • 49. Poor man’s TCP User Id Local Seq No Remote Seq No Ack bitfield JSON PayloadJSON PayloadJSON PayloadJSON Payload • http://gafferongames.com/networking-for-game-programmers/reliability-and-flow-control/
  • 50. Poor man’s TCP Ordering Acknowledge Packets Resending Packets Flow Control Congestion Control ✔ ✔ X X X
  • 51. UDP 3G ✔Tested with a few providers in Germany, Switzerland and Netherlands
  • 52. game barely works on Wifi :|
  • 53. game doesn’t work at all on 3G!!! :(
  • 54. Packet Loss
  • 55. No synchronization
  • 56. 3
  • 57. UDP JSON State updates
  • 58. Send full state Full State Full State Full State Full State
  • 59. MTU Ethernet 1500 bytes PPPoE 1492 bytes Edge 1440 bytes https://en.wikipedia.org/wiki/Maximum_transmission_unit http://ipixcel.org/EDGE_Capabilities,_Technology,_and_Applications_PDF.pdf
  • 60. Architecture C1 C2Server move :up state update state update state update state update game over game over move :down
  • 61. 10 msg/second
  • 62. 100 ms walking speed
  • 63. Game works on 3G:)
  • 64. Highscores and Matchmaking are BROKEN!:(
  • 65. 4
  • 66. Architecture C1 C2Server move :up state update state update state update state update game over game over move :down
  • 67. Different Concerns Game Play Matchmaking Highscores Login/Logout User Data Reliable Unreliable
  • 68. Different Concerns Game Play Matchmaking Highscores Login/Logout User Data HTTP UDP
  • 69. Server architecture Lobby Server HTTP Service User Registry Matchmaking Logic Game Server UDP Service User Registry Game Logic RPC Database
  • 70. UDP Binary
  • 71. Binary protocol 64 bit 32bit 32bit 8bit 8bit Rest User Id SeqNr Ack Bitfield Command Payload 144 bits 944 bits 118 bytes18 bytes
  • 72. 2 Player State update ~ 136 bytes
  • 73. 56K Modem 7 KBps 10 msg/second 1.420 KBps ✔
  • 74. Improved Gameplay :)
  • 75. 5
  • 76. FIFO with timers
  • 77. Casual Matchmaking Skill Time 4 Players Match
  • 78. Hierarchical Clustering
  • 79. Better Matchmaking 1 2 3 4 5 6 7 Queueing =10 10 10 10 Start Game 1 2 3 4 5 6 7 Find Matches =1 Reschedule 2 3 4 6 10 10 10 =1
  • 80. Better Matchmaking:)
  • 81. Geo Matching
  • 82. Play Locally:)
  • 83. Debugging
  • 84. Terminal Client
  • 85. Bots
  • 86. Network Link Conditioner
  • 87. Erlang tools erlscript WX Widgets Remote Shell Hot Code Reload
  • 88. Level 4: Finished mobile multi player
  • 89. User interaction
  • 90. Questions? @phuesler @jrirei http://wooga.com/jobs