C# Class Gruppe22.Backend.NetLogic

All Game Logic events are handled server side -> send / receive events via network instead of handling them locally
Inheritance: Logic, IHandleEvent
Afficher le fichier Open project: propra13-orga/gruppe22

Protected Properties

Свойство Type Description
_network Gruppe22.Client.NetPlayer

Méthodes publiques

Méthode Description
HandleEvent ( bool DownStream, Events eventID ) : void

React to incoming events

NetLogic ( IHandleEvent parent, NetPlayer network ) : System

Constructor

RequestMap ( ) : void

Update local version of map

SendChat ( string text ) : void

Exchange text messages

Update ( GameTime gameTime ) : void

Exchange events with server

Method Details

HandleEvent() public méthode

React to incoming events
public HandleEvent ( bool DownStream, Events eventID ) : void
DownStream bool
eventID Events
Résultat void

NetLogic() public méthode

Constructor
public NetLogic ( IHandleEvent parent, NetPlayer network ) : System
parent IHandleEvent A local event handler to send messages to
network Gruppe22.Client.NetPlayer The network connection to use for handling events
Résultat System

RequestMap() public méthode

Update local version of map
public RequestMap ( ) : void
Résultat void

SendChat() public méthode

Exchange text messages
public SendChat ( string text ) : void
text string Text to send to other users
Résultat void

Update() public méthode

Exchange events with server
public Update ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime Current elapsed time
Résultat void

Property Details

_network protected_oe property

An object representing the network connection
protected NetPlayer,Gruppe22.Client _network
Résultat Gruppe22.Client.NetPlayer