Ogdc 2013 network stragegy for mmo game

Post on 09-May-2015

205 views 0 download

Transcript of Ogdc 2013 network stragegy for mmo game

Network Strategy for MMO Game

Trần Như Toàn , Lead Software

Engineer,

Game Studio North , VNG Corporation

Who Am I ?Technical Leader

myPlay Game Portal

myPlay Mobile

Problems

This topic suite for

Turn-based, Real-time MMO Games

Network Game Developers

MMO Mobile Games

Agenda

11

22

33Common Problems

Disconnection

Lag

1. Lag

35% Game Client

(un-trusted , multitasking)

35% Game Servers (Overloaded ,Costly)

30% Network

(latency , bandwidth)

Effective Protocol

Packet Optimization

Data Protocol

Combination

Compress

Data Transfer Protocol

Combination & Compress

myPlay Results

OLD

Traffic of 3200 CCU:

In: 1,53 KB/s

Out: 325,08 KB/s

NỘI DUNG

11

22

33Common Problems

Disconnection

Lag

Slow Connection Disconnection

2. Disconnection

Maintain connection until time-out

Slow Connection

• Use session for each

connection

• Hold connection state in

session

• Activate connection when

having any signal

myPlay before

Slow Connection

Disconnection

Why ???

• Interrupted, even temporarily

• ISP might have intermittent

issues , router fail

• Drop in the strength of the

signal

Solutions

Disconnect protection Re-connection

Re-connection

Automatically reconnectwhen connection is lost

Remain user’s state

Game flow is not interrupted

Auto - Reconnection System

Session

Game Client

State

Data

New Connection

Priority Message Queue

Auto - Reconnection System

Game flow is not interrupted

Client games auto-reconnect when connection lost

Remain state of User

The complexity of the reconnection is hidden from the developers.

Auto - Reconnection System

Result

NỘI DUNG

11

22

33Common Problems

Disconnection

Lag

Ghost User

3. Common Problems

Firewall

Firewall

Block Game Port

Http Tunnel by-pass Firewall

Http Tunnel

Ghost Users

Incomplete TCP disconnection occurs (e.g. disable 3g, wifi ….)

Why?How to deal with ghosts?

Ghost User Hunter

Reduce the impact of pending connections

• Create scheduled task (called Ghost Hunter)

• Check the integrity of each connection

• Remove those that are stale

Summary

Choose right protocol

Optimize packet

Lag

Reduce Slow Connection

Use Auto-reconnecting

system

Happy Gaming