24
P2P Multiplayer Gaming Dan Byers Manic Networks Inc. September 29th, 2009

P2P Multiplayer Gaming

Embed Size (px)

DESCRIPTION

This will be a session to introduce the Manic Gaming Network. We have designed a multiplayer gaming platform which gives developers an easy way to incorporate Peer 2 Peer gaming into their app. Will cover the following: * today’s problems with developing a multiplayer solution, and solutions available “out of the box” * walkthrough of Manic’s services available to the community of gamers and developers * quick introduction to an API we’re releasing for our service * game demo will be shown * review of some sample code to help developers get started

Citation preview

Page 1: P2P Multiplayer Gaming

P2P Multiplayer GamingDan Byers

Manic Networks Inc.

September 29th, 2009

Page 2: P2P Multiplayer Gaming

Introduction

• Manic?

• Startup

• Solutions for Game Developers

Page 3: P2P Multiplayer Gaming

Gaming Today

• Single player

• Multiplayer

• real-time

• non real-time

• Real-time and game play

Page 4: P2P Multiplayer Gaming

Mobile Multiplayer

• Picking up steam

• Wireless networks are improving

• Smartphones: faster, feature rich

• Social aspects, interactivity

Page 5: P2P Multiplayer Gaming

App Store games

• Play ‘n forget

• Need to improve ‘stickiness’

• Make the user feel that they can’t stop playing

Page 6: P2P Multiplayer Gaming

Social Factors

• More apt to join if you have friends also playing the game

• The out-of-game experience

• Communities can build upon themselves

Page 7: P2P Multiplayer Gaming

Architectures

• Client-server

• Peer-to-peer

A B

C D

Server

A B Cclients

clients

Page 8: P2P Multiplayer Gaming

Client-Server

• Persistent connections

• Game management in server

• Loads increase ... scaling issues

Server

A B Cclients

Page 9: P2P Multiplayer Gaming

Peer-to-Peer

• Direct communication between clients

• Server still required for player matching

• Reduces load off of a central server

• Be careful with game state

• “Local” peer to peer with Gamekit

A B

C D

clients

Page 10: P2P Multiplayer Gaming

Multiplayer Gaming - No Small Task

• For small teams, multiplayer can lead to months of added development & test effort

• Where do the difficulties lie?

Page 11: P2P Multiplayer Gaming

Hurdles

• Player synchronization, game state

• Network latency

• Server infrastructure - costly

• Connectivity - firewalls

Page 12: P2P Multiplayer Gaming

Firewalls Shmirewalls

• The main issue: NAT

Player A Player B

firewall firewall

Internet

Page 13: P2P Multiplayer Gaming

Firewalls & NAT

• Multiple devices share one public IP

• Devices are assigned private IP’s

• Firewall blocks inbound traffic by default

iPod/iPhone,or PC

Private IP and port: 192.168.1.10:2000

Public IP and port: 64.26.92.166:653

Firewallwith NAT Internet

Page 14: P2P Multiplayer Gaming

Firewall Hole Punching(NAT Traversal)

• External mediator assistance required

• Mediator helps each peer punch through to other peers

• Not always sucessful - need to be able to fallback to server-based traffic relays

Page 15: P2P Multiplayer Gaming

Working on a multiplayer game?

• Back-end servers for player matching, hole punching and traffic relay fallback

• Player database and player profiles

• Scores, ranks, achievements - submission and storing

• Game invites, challenges, game profiles

• Notifications, alerts, messaging, chat

Requirements

Page 16: P2P Multiplayer Gaming

The Solution

• Nothing that really fit the bill previously

• Until now...

Page 17: P2P Multiplayer Gaming

The Solution

• Nothing that really fit the bill previously

• Until now...

The Manic Gaming Network

Page 18: P2P Multiplayer Gaming

The Manic Gaming Network

• Currently in beta

• A community for both developers and gamers

• Services available for single player and multiplayer games

Page 19: P2P Multiplayer Gaming

Service Features

• Robust API for peer-to-peer player matching

• Multiple player matching options - random matches, friend matches, rank-based matches, game lobbies

• Firewall hole punching & traffic relaying

• Game profiles - global high score lists, player rankings, achievements

• In-game match invites / challenges

Page 20: P2P Multiplayer Gaming

Service Features (cont’d)

• Support for turn based games with storage of game states and turn notifications

• Notification sending (APNS, SMS, email, RSS)

• Private Developer Sandbox

• Marketing and promotion of your games

• API is Objective C

Page 21: P2P Multiplayer Gaming

Player Features

• Friend lists and Ignore lists

• Compare scores with friends

• Friend messaging

• Gaming notifications

• One profile to play any Manic-enabled game

• Personal profile for sharing

• View and share scores, ranks, achievement history

Page 22: P2P Multiplayer Gaming

Development Roadmap

• Manic Dashboard for service management

• Tournament support

• Chat rooms

• Internationalization

• Other client platforms

Page 23: P2P Multiplayer Gaming

Sample Code

• Demo game - Finger Wars!

• 2-4 player - random & friend matches

• results submission

• in-game account registration