|
Zap::GameConnection class Reference
Zap::GameConnection Class Reference#include <gameConnection.h>
Inheritance diagram for Zap::GameConnection:
|
Public Types |
enum | MessageColors {
ColorWhite,
ColorRed,
ColorGreen,
ColorBlue,
ColorAqua,
ColorYellow,
ColorNuclearGreen,
ColorCount
} |
Public Member Functions |
| GameConnection () |
| ~GameConnection () |
void | setClientName (const char *string) |
void | setClientRef (ClientRef *theRef) |
ClientRef * | getClientRef () |
StringTableEntryRef | getClientName () |
bool | isAdmin () |
void | setIsAdmin (bool admin) |
| TNL_DECLARE_RPC (c2sAdminPassword,(StringPtr pass)) |
| TNL_DECLARE_RPC (s2cSetIsAdmin,()) |
| TNL_DECLARE_RPC (c2sAdminPlayerAction,(StringTableEntry playerName, U32 actionIndex)) |
bool | isInCommanderMap () |
| TNL_DECLARE_RPC (c2sRequestCommanderMap,()) |
| TNL_DECLARE_RPC (c2sReleaseCommanderMap,()) |
| TNL_DECLARE_RPC (c2sRequestLoadout,(Vector< U32 > loadout)) |
| TNL_DECLARE_RPC (s2cDisplayMessageESI,(RangedU32< 0, ColorCount > color, RangedU32< 0, NumSFXBuffers > sfx, StringTableEntry formatString, Vector< StringTableEntry > e, Vector< StringPtr > s, Vector< S32 > i)) |
| TNL_DECLARE_RPC (s2cDisplayMessageE,(RangedU32< 0, ColorCount > color, RangedU32< 0, NumSFXBuffers > sfx, StringTableEntry formatString, Vector< StringTableEntry > e)) |
| TNL_DECLARE_RPC (s2cDisplayMessage,(RangedU32< 0, ColorCount > color, RangedU32< 0, NumSFXBuffers > sfx, StringTableEntry formatString)) |
| TNL_DECLARE_RPC (s2cAddLevel,(StringTableEntry name, StringTableEntry type)) |
| TNL_DECLARE_RPC (c2sRequestLevelChange,(S32 newLevelIndex)) |
GameConnection * | getNextClient () |
const Vector< U32 > & | getLoadout () |
void | writeConnectRequest (BitStream *stream) |
| Writes the NetEvent class count into the stream, so that the remote host can negotiate a class count for the connection.
|
bool | readConnectRequest (BitStream *stream, const char **errorString) |
| Reads the NetEvent class count max that the remote host is requesting.
|
void | onConnectionEstablished () |
| Called when the connection is successfully established with the remote host.
|
void | onConnectTerminated (TerminationReason r, const char *) |
| Called when a pending connection is terminated.
|
void | onConnectionTerminated (TerminationReason r, const char *string) |
| Called when this established connection is terminated for any reason.
|
| TNL_DECLARE_NETCONNECTION (GameConnection) |
Static Public Member Functions |
GameConnection * | getClientList () |
Data Fields |
Vector< StringTableEntry > | mLevelNames |
Vector< StringTableEntry > | mLevelTypes |
Private Types |
typedef ControlObjectConnection | Parent |
Private Member Functions |
void | linkToClientList () |
Private Attributes |
GameConnection * | mNext |
GameConnection * | mPrev |
bool | mInCommanderMap |
bool | mIsAdmin |
StringTableEntry | mClientName |
Vector< U32 > | mLoadout |
SafePtr< ClientRef > | mClientRef |
Static Private Attributes |
GameConnection | gClientList |
Member Typedef Documentation
Member Enumeration Documentation
|
- Enumeration values:
-
ColorWhite |
|
ColorRed |
|
ColorGreen |
|
ColorBlue |
|
ColorAqua |
|
ColorYellow |
|
ColorNuclearGreen |
|
ColorCount |
|
|
Constructor & Destructor Documentation
Zap::GameConnection::GameConnection |
( |
|
) |
|
|
Member Function Documentation
void Zap::GameConnection::linkToClientList |
( |
|
) |
[private] |
|
void Zap::GameConnection::setClientName |
( |
const char * |
string |
) |
[inline] |
|
void Zap::GameConnection::setClientRef |
( |
ClientRef * |
theRef |
) |
|
|
ClientRef* Zap::GameConnection::getClientRef |
( |
|
) |
|
|
bool Zap::GameConnection::isAdmin |
( |
|
) |
[inline] |
|
void Zap::GameConnection::setIsAdmin |
( |
bool |
admin |
) |
[inline] |
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sAdminPassword |
, |
|
|
(StringPtr pass) |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
s2cSetIsAdmin |
, |
|
|
() |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sAdminPlayerAction |
, |
|
|
(StringTableEntry playerName, U32 actionIndex) |
|
|
) |
|
|
bool Zap::GameConnection::isInCommanderMap |
( |
|
) |
[inline] |
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sRequestCommanderMap |
, |
|
|
() |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sReleaseCommanderMap |
, |
|
|
() |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sRequestLoadout |
, |
|
|
(Vector< U32 > loadout) |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
s2cDisplayMessageE |
, |
|
|
(RangedU32< 0, ColorCount > color, RangedU32< 0, NumSFXBuffers > sfx, StringTableEntry formatString, Vector< StringTableEntry > e) |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
s2cDisplayMessage |
, |
|
|
(RangedU32< 0, ColorCount > color, RangedU32< 0, NumSFXBuffers > sfx, StringTableEntry formatString) |
|
|
) |
|
|
Zap::GameConnection::TNL_DECLARE_RPC |
( |
c2sRequestLevelChange |
, |
|
|
(S32 newLevelIndex) |
|
|
) |
|
|
const Vector<U32>& Zap::GameConnection::getLoadout |
( |
|
) |
[inline] |
|
void Zap::GameConnection::writeConnectRequest |
( |
BitStream * |
stream |
) |
[virtual] |
|
|
Writes the NetEvent class count into the stream, so that the remote host can negotiate a class count for the connection.
Reimplemented from TNL::EventConnection. |
bool Zap::GameConnection::readConnectRequest |
( |
BitStream * |
stream, |
|
|
const char ** |
errorString |
|
) |
[virtual] |
|
|
Reads the NetEvent class count max that the remote host is requesting.
If this host has MORE NetEvent classes declared, the mEventClassCount is set to the requested count, and is verified to lie on a boundary between versions.
Reimplemented from TNL::EventConnection. |
void Zap::GameConnection::onConnectionEstablished |
( |
|
) |
[virtual] |
|
|
Called when the connection is successfully established with the remote host.
Reimplemented from TNL::NetConnection. |
void Zap::GameConnection::onConnectTerminated |
( |
TerminationReason |
r, |
|
|
const char * |
|
|
) |
[virtual] |
|
void Zap::GameConnection::onConnectionTerminated |
( |
TerminationReason |
r, |
|
|
const char * |
string |
|
) |
[virtual] |
|
|
Called when this established connection is terminated for any reason.
Reimplemented from TNL::NetConnection. |
Field Documentation
|