Network Replication Possibly the ugliest thing to learn this semester Many different states Simulated Functions Is it an Event or function? Roles.

Slides:



Advertisements
Similar presentations
Internet for multimedia content Yogendra Pal Chief Engineer, All India Radio.
Advertisements

TCP/IP MODEL Maninder Kaur
COMP 655: Distributed/Operating Systems Summer 2011 Dr. Chunbo Chu Week 7: Consistency 4/13/20151Distributed Systems - COMP 655.
CECS 474 Computer Network Interoperability Notes for Douglas E. Comer, Computer Networks and Internets (5 th Edition) Tracy Bradley Maples, Ph.D. Computer.
Network synchronization of Online Games Li, Zetan.
Slide 1 Client / Server Paradigm. Slide 2 Outline: Client / Server Paradigm Client / Server Model of Interaction Server Design Issues C/ S Points of Interaction.
Group Communications Group communication: one source process sending a message to a group of processes: Destination is a group rather than a single process.
CS490T Advanced Tablet Platform Applications Network Programming Evolution.
© 2006 Cisco Systems, Inc. All rights reserved. 2.3: Encapsulating Voice Packets for Transport.
Networking Theory (Part 1). Introduction Overview of the basic concepts of networking Also discusses essential topics of networking theory.
Latency Compensating Methods in Client/Server In-game Protocol Design and Optimization I’m Curtis.
CS335 Principles of Multimedia Systems Multimedia Over IP Networks -- I Hao Jiang Computer Science Department Boston College Nov. 6, 2007.
Octopus system1 Moshe Tocker Avihai Mejer. Octopus system2 The Octopus system Goal The system’s primary goal is to Measure performance parameters in real.
© Lethbridge/Laganière 2001 Chap. 3: Basing Development on Reusable Technology 1 Let’s get started. Let’s start by selecting an architecture from among.
CPSC 372 John D. McGregor Module 0 Session 1 Introduction.
Applying Real-time Simulation to Real-time Collaboration Bart Miller.
RTSP Real Time Streaming Protocol
Computer Networks  Network - A system of computers interconnected in order to share information.  Data transmission - consists of sending and receiving.
1. When things go wrong: how to find SQL error Sveta Smirnova Principle Technical Support Engineer, Oracle.
Hands-On Microsoft Windows Server 2003 Networking Chapter Three TCP/IP Architecture.
Presentation on Osi & TCP/IP MODEL
Checking Network/Port Connectivity using Kaseya Agent Procedures Developed By: Emmanuel Giboyeaux Advisor : Dr. S. Masoud Sadjadi School of Computing and.
CPSC 871 John D. McGregor Module 0 Session 1 Introduction.
Ophelia User-friendly Network Multi-player Game Engine Albert Öhrling.
Lecture 16 Page 1 CS 236 Online SQL Injection Attacks Many web servers have backing databases –Much of their information stored in a database Web pages.
Sega 500 More replication Jeff “Ezeikeil” Giles
1 CSC111H Client-Server: An Introduction Dennis Burford
10/9/20151 Unreal Basics CIS 488/588 Bruce R. Maxim UM-Dearborn.
Design and Programming Chapter 7 Applied Software Project Management, Stellman & Greene See also:
Outline Overview Video Format Conversion Connection with An authentication Streaming media Transferring media.
Warcraft III, by Blizzard CSE 381 – Advanced Game Programming Networked Gaming Issues.
Important UDK Classes How they fit together Copyright © 2015 – Curt Hill.
Interactive TV Team. Parts of software  Admin control panel (UI) Any control panel designed for a specific use, our target basketball game.  Restful.
Section 4.2 AQA Computing A2 © Nelson Thornes 2009 Types of Operating System Unit 3 Section 4.1.
Advanced Computer Networks Topic 2: Characterization of Distributed Systems.
Data Communications and Computer Networks Chapter 2 CS 3830 Lecture 8 Omar Meqdadi Department of Computer Science and Software Engineering University of.
Sega 500 An Introduction to Replication Jeff “Ezeikeil” Giles
Light Cycles Galore Building a Multi-Server Multiplayer Game Architecture By Per Lohmann.
I Power Higher Computing Software Development High Level Language Constructs.
Networked Graphics Building Networked Virtual Environments and Networked Games Issues in Networking Graphics.
Game Programming Patterns Game Loop From the book by Robert Nystrom
Warlords Patrick Levoshko SE 558 – Multiplayer Game Design.
Lecture 4 Mechanisms & Kernel for NOSs. Mechanisms for Network Operating Systems  Network operating systems provide three basic mechanisms that support.
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.
Computer Science Lecture 3, page 1 CS677: Distributed OS Last Class: Communication in Distributed Systems Structured or unstructured? Addressing? Blocking/non-blocking?
Network Replication Possibly the ugliest thing to learn this semester Many different states Simulated Functions Is it an Event or function? Roles.
Computerized Beer Game
For Programming Challenge N. H. N. D. de Silva. Introduction General Game Architecture Server Architecture Joining the game Game initiation Moving and.
McGraw-Hill Chapter 23 Process-to-Process Delivery: UDP, TCP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Running Commodity Operating Systems on Scalable Multiprocessors Edouard Bugnion, Scott Devine and Mendel Rosenblum Presentation by Mark Smith.
Monitoring Dynamic IOC Installations Using the alive Record Dohn Arms Beamline Controls & Data Acquisition Group Advanced Photon Source.
Socket Programming original by Joonbok Lee KAIST heavily adapted by /Jens.
Vocabulary Prototype: A preliminary sketch of an idea or model for something new. It’s the original drawing from which something real might be built or.
Master’s Project Presentation
Development of a Simulator for the HANARO Research Reactor (Communication Protocol) H.S. Jung.
WWW and HTTP King Fahd University of Petroleum & Minerals
Remote Method Invocation
SQL Injection Attacks Many web servers have backing databases
LCGAA nightlies infrastructure
CHAPTER 3 Architectures for Distributed Systems
File Transfer and access
Multimedia networking: outline
Process-to-Process Delivery:
CPEG514 Advanced Computer Networkst
Performance Evaluation of Computer Networks
Multimedia networking: outline
Performance Evaluation of Computer Networks
Computer Networks Protocols
Last Class: Communication in Distributed Systems
Exceptions and networking
Presentation transcript:

Network Replication Possibly the ugliest thing to learn this semester Many different states Simulated Functions Is it an Event or function? Roles

More Architecture Unreal is made of Objects. The Game Level is an Object Actor is an Object capable of moving and interacting within the Level Object The Level is filled with Actors

The Server This is the source of all the gameplay, and the server is responsible for ticking the game. –A tick is the games clock –The tick is not fixed and scalable, to allow the game to run at a variable Frame Rate In a single player game the server is the machine you play on

Clients Maintain as closely as possible a proper representation of what is happening on the server

The Game Loop The Server sends the current state of play to all clients Clients send their requested movements and actions to the server, and receive the new game state information from the server The server then performs a tick operation updating the game state

During the Tick operation –Variables and Actors can be modified –Actors can be created or destroyed In games of old, like Doom each client ran a copy of the game world, and sent their actions to every other client. (A P2P network) The complexities of Unreal Negate this approach –Thankyou Physics!

The problem The bandwidth needed to update the entire game state on client machines would be incredible. (Approx 300kb/s for standard deathmatch levels of the original Unreal Tournament)

The Solution Doesn’t exist….. The Network code in Unreal is intended to give the clients a reasonable approximation of the game state.

Relevant Actors Unreal minimises the Actors which it updates for clients, to only those deemed relevant Pretty much any actor the player can see, or has seen recently, as well as any actors with static=true or bNoDelete=true See the references if you want the full details on relevance.

Further Prioritising Every Actor has a variable called NetPriority –Relative Ratios Default of Actor is 1.0 Inventory / Pickups 1.4 Players / Vehicles 3.0 Replication can be divided into 3 parts –Actors –Variables –Function Calls

Your Responsibility The game engine does not keep track of what actors are relevant to who This is your job. –Any Objects / Variables you create How? –The Replication Statement

Do you need one for every class? No Only when your Class defines new variables or functions which need to be replicated In UT only about 10 of the 500 classes needed replication statements In ut2004 there are roughly 140 replication statements

Stolen from RocketLauncher.uc replication { reliable if (Role == ROLE_Authority && bNetOwner) bLockedOn; reliable if (Role < ROLE_Authority) ServerSetTightSpread, ServerClearTightSpread; }

replication { // Variables the server should send to the client. reliable if( Role==ROLE_Authority ) Weapon; reliable if( Role==ROLE_Authority && bNetOwner ) PlayerName, Team, TeamName, bIsPlayer, CarriedDecoration, SelectedItem, GroundSpeed, WaterSpeed, AirSpeed, AccelRate, JumpZ, MaxStepHeight, bBehindView; unreliable if( Role==ROLE_Authority && bNetOwner && bIsPlayer && bNetInitial ) ViewRotation; unreliable if( Role==ROLE_Authority && bNetOwner ) Health, MoveTarget, Score; // Functions the server calls on the client side. reliable if( Role==ROLE_Authority && RemoteRole==ROLE_AutonomousProxy ) ClientDying, ClientReStart, ClientGameEnded, ClientSetRotation; unreliable if( Role==ROLE_Authority ) ClientHearSound, ClientMessage; reliable if( Role<ROLE_Authority ) NextItem, SwitchToBestWeapon, bExtra0, bExtra1, bExtra2, bExtra3; // Input sent from the client to the server. unreliable if( Role<ROLE_AutonomousProxy ) bZoom, bRun, bLook, bDuck, bSnapLevel, bStrafe; unreliable always if( Role<=ROLE_AutonomousProxy ) bFire, bAltFire; }

Reliable and Unreliable Unreliable Packets may –Disappear –Arrive out of order Reliable Packets will eventually be received The amount of packets lost varies, and an estimate is between 1% and 10% of all unreliable packets could be lost

Replication Conditions Firstly the roles each Class may have –ROLE_None –ROLE_DumbProxy –ROLE_SimulatedProxy –ROLE_AutonomousProxy –ROLE_Authority Checks can also be done using boolean checks –EG: if (Role < Role_Authority)

Simulated Functions For proxy Actors only functions marked simulated will execute on the client machines Actors like Weapon.uc and Vehicle.uc rely heavily on simulated functions

AutonomousProxy Aka The player This code is written in UnrealScript (As of up to UT2004) Uses an error / correction approach

Network management GameInfo – Runs the game from the server –InitGame This function recieves the startup command line –PreLogin Called on the server before a player is allowed to log in to the game –Login This is where the player will be spawned within the game Called after players download content, so rejecting players now is rude!

Optimisation The game already runs on the server fine The Network optimisation goal is to make the clients view of the game world as realistic as possible to the player Vectors get rounded!!! –Converted to 16bit ints for data stream –Bypass this by passing 3x Floats IF you need the accuracy

Network capabilities of UT You have both TCP and UDP class access built in to UT Get Excited, it will allow you to interface with the real world! (Well any software you like)

References