Network synchronization of Online Games Li, Zetan.

Slides:



Advertisements
Similar presentations
Gameplay Networking Jacob Steinfort. Importance of Multiplayer Games If gamers had to choose either a single-player game or a multiplayer game, most people.
Advertisements

IS333, Ch. 26: TCP Victor Norman Calvin College 1.
Network Protocols Mark Stanovich Operating Systems COP 4610.
Slide 1 Client / Server Paradigm. Slide 2 Outline: Client / Server Paradigm Client / Server Model of Interaction Server Design Issues C/ S Points of Interaction.
A CHAT CLIENT-SERVER MODULE IN JAVA BY MAHTAB M HUSSAIN MAYANK MOHAN ISE 582 FALL 2003 PROJECT.
Transport Layer 3-1 Transport Layer r To learn about transport layer protocols in the Internet: m TCP: connection-oriented protocol m Reliability protocol.
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 17 Introduction to the Application.
Reliable Networking Systems The goals: Implement a reliable network application of a file sharing network. Implement a reliable network application of.
Networking Support In Java Nelson Padua-Perez Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
Online Chess Project 3 Due date: April 17 th. Introduction Third in series of three projects This project focuses on adding online support –2 players.
Department of Electronic Engineering City University of Hong Kong EE3900 Computer Networks Transport Protocols Slide 1 Transport Protocols.
Department of Information Engineering 1 Objectives A basic understanding of the following –What is Internet? –What is client-server computing? –What is.
WXES2106 Network Technology Semester /2005 Chapter 8 Intermediate TCP CCNA2: Module 10.
What Is TCP/IP? The large collection of networking protocols and services called TCP/IP denotes far more than the combination of the two key protocols.
FIREWALL TECHNOLOGIES Tahani al jehani. Firewall benefits  A firewall functions as a choke point – all traffic in and out must pass through this single.
Magda El Zarki Professor of CS Univ. of CA, Irvine
TCP Sockets Reliable Communication. TCP As mentioned before, TCP sits on top of other layers (IP, hardware) and implements Reliability In-order delivery.
Process-to-Process Delivery:
Game Networking CS381 Sushil J. Louis Dept. of Computer Science and Engineering University of Nevada, Reno From and much thanks to
Networked File System CS Introduction to Operating Systems.
Presentation on Osi & TCP/IP MODEL
UNIT-V Computer Network Transport Layer 1 Prepared by - ROHIT KOSHTA.
1 Chapter Client-Server Interaction. 2 Functionality  Transport layer and layers below  Basic communication  Reliability  Application layer.
Introduction to Networked Graphics Part 3 of 5: Latency.
Networks – Network Architecture Network architecture is specification of design principles (including data formats and procedures) for creating a network.
I. Basic Network Concepts. I.1 Networks Network Node Address Packet Protocol.
© 2007 Cisco Systems, Inc. All rights reserved.Cisco Public 1 Version 4.0 OSI Transport Layer Network Fundamentals – Chapter 4.
TCP Lecture 13 November 13, TCP Background Transmission Control Protocol (TCP) TCP provides much of the functionality that IP lacks: reliable service.

Networked & Distributed Systems TCP/IP Transport Layer Protocols UDP and TCP University of Glamorgan.
The Transmission Control Protocol (TCP) Application Services (Telnet, FTP, , WWW) Reliable Stream Transport (TCP) Connectionless Packet Delivery.
7/26/ Design and Implementation of a Simple Totally-Ordered Reliable Multicast Protocol in Java.
Chapter 15 – Part 2 Networks The Internal Operating System The Architecture of Computer Hardware and Systems Software: An Information Technology Approach.
COP 5611 Operating Systems Spring 2010 Dan C. Marinescu Office: HEC 439 B Office hours: M-Wd 2:00-3:00 PM.
TCP Sockets Reliable Communication. TCP As mentioned before, TCP sits on top of other layers (IP, hardware) and implements Reliability In-order delivery.
Multimedia streaming Application Anandi Giridharan Electrical Communication Engineering, Indian Institute of Science, Bangalore – , India Querying.
E Multimedia Communications Anandi Giridharan Electrical Communication Engineering, Indian Institute of Science, Bangalore – , India Multimedia.
Networking Basics CCNA 1 Chapter 11.
An Introduction to Networking
1 Client-Server Interaction. 2 Functionality Transport layer and layers below –Basic communication –Reliability Application layer –Abstractions Files.
GLOBAL EDGE SOFTWERE LTD1 R EMOTE F ILE S HARING - Ardhanareesh Aradhyamath.
UNIT 2 LESSON 5 CS PRINCIPLES. OBJECTIVES Students will be able to: Explain why protocols are necessary to overcome the underlying unreliability of the.
The Client Server Model And Software Design
5. The Transport Layer 5.1 Role of Transport Layer It bridge the gab between applications and the network layer. Provides reliable cost-effective data.
Chapter 13 Introduction to the Transport Layer
CS/EE 145A Reliable Transmission over Unreliable Channel II Netlab.caltech.edu/course.
Chapter 16 - TCP: Software For Reliable Communication Introduction A Packet Switching System Can Be Overrun (merging highways) TCP Helps IP Guarantee Delivery.
4343 X2 – The Transport Layer Tanenbaum Ch.6.
INTRO TO NETWORKING. OVERVIEW Transmitting data Across a physical media Ethernet Wi-fi Bluetooth Etc. Cross-platform (usually) Challenges Varying network.
Netprog: Chat1 Chat Issues and Ideas for Service Design Refs: RFC 1459 (IRC)
McGraw-Hill Chapter 23 Process-to-Process Delivery: UDP, TCP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
DATA LINK CONTROL. DATA LINK LAYER RESPONSIBILTIES  FRAMING  ERROR CONTROL  FLOW CONTROL.
UDP: User Datagram Protocol. What Can IP Do? Deliver datagrams to hosts – The IP address in a datagram header identify a host – treats a computer as an.
BASICS Gabriella Paolini (GARR) 27/05/11 - ICCU Roma 1 How INTERNET works !
Game Networking CS381 Spring Internet ● An information superhighway ● A collection of pipes ● Arpanet – Robust communication in the face of infrastructure.
Networking Project. Game Networking Game Networking Topology Star (client/server) Topology – All devices are connected to a central hub (server) – Nodes.
The Transport Layer Implementation Services Functions Protocols
Unity Networking.
Code.org Lessons 11 & 12 Lesson 11- Packets and Making a Reliable Internet Lesson 12- The Need for DNS.
Sarah Diesburg Operating Systems COP 4610
Chat Refs: RFC 1459 (IRC).
Process-to-Process Delivery:
Andy Wang Operating Systems COP 4610 / CGS 5765
Code.org Lessons 11 & 12 Lesson 11- Packets and Making a Reliable Internet Lesson 12- The Need for DNS.
Internet Applications & Programming
Code.org Lessons 11 & 12 Lesson 11- Packets and Making a Reliable Internet Lesson 12- The Need for DNS.
Process-to-Process Delivery: UDP, TCP
Computer Networks Protocols
The TCP/IP Model.
Presentation transcript:

Network synchronization of Online Games Li, Zetan

What is cyber game? Players share the same scenery and interact with each other. Compare to traditional single games. Usually require access to internet.(Or at least local area network)

How does cyber game work Sharing one virtual world? It's an illusion. :P What is actually going on underneath is quite different from what you see. What you perceive as a shared reality is only an approximation unique to your own point of view and place in time. Message exchange Two different games running on two different machines, and try to maintain same scenery through massage exchange.

Synchronization Peer-to-peer lockstep Client/server

Synchronization Peer-to-peer lockstep In the beginning games were networked peer-to-peer, with each other computer exchanging information with each other in a fully connected mesh topology.

Synchronization —— peer-to-peer lock step Abstract the game into a series of turns and a set of command messages when processed at the beginning of each turn direct the evolution of the game state. Advantage – Simple to implement Drawback & Limitation -- Cannot guarantee 100% deterministic of a game. One tiny difference will results in complete desynchronization over time -- Have to wait until all the players’ messages are collected --- Impossible to join in the middle of game. Still using in RTS game today

Synchronization Client/Server model Most lagged player makes game slow? Using client/server model! First appear in Quake,1996 Using widely in games today, especially action games.

Synchronization —— Client/Server Each player was now a “client” and they all communicated with just one computer called the “server”. Game only exist on the server, client act like a terminal Each player send their input to server. Server response with their new states. Possible for players to come and go in the middle of the game

msg Client Server

Problems for Client/Server model Latency makes game sucks Solution Client-Side Prediction Latency Compensation

Client-Side Prediction Client immediately in response to player’s input Using server’s response to correct player’s state ——Why not let client manipulate the state of itself: prevent cheating ——Circular buffer of past character state *Brief introduction on Latency Compensation

Networked Physics What is physics engine Game with physics simulation

How to synchronize physics performance Send state of all objects? You are challenging bandwidth Simple illustration: FPS 1.Character physics are completely driven from input data 2.Physics state is known and can be fully encapsulated in a state structure 3.The physics simulation is reasonably deterministic given the same initial state and inputs

Example: FPS Arrange input and state information: Physics is run on the server according to a stream of input from clients Clients approximate server physics locally Deal with latency 1.Client prediction 2.Packet loss struct Input { bool left; bool right; bool forward; bool back; bool jump; }; struct State { Vector position; Vector velocity; };

Protocol TCP v.s UDP TCP Connection based Guaranteed reliable and ordered Automatically breaks up your data into packets for you Makes sure it doesn’t send data too fast for the internet connection to handle (flow control) Easy to use, you just read and write data like its a file UDP No concept of connection, you have to code this yourself No guarantee of reliability or ordering of packets, they may arrive out of order, be duplicated, or not arrive at all! You have to manually break your data up into packets and send them You have to make sure you don’t send data too fast for your internet connection to handle If a packet is lost, you need to devise some way to detect this, and resend that data if necessary

Why Not TCP? Games have a real time requirement on packet delivery. Packet loss will make game stop and wait for packet resent.

References every-programmer-needs-to-know-about-game-networking/ every-programmer-needs-to-know-about-game-networking/ and-receiving-packets/ and-receiving-packets/ tcp/ tcp/ 8_network_.php

Thank You! Questions??