Planeshift
psStatsMessage Class Reference

This message is sent to the client to let it know the basic stats of the player. More...

#include <messages.h>

Public Member Functions

 PSF_DECLARE_MSG_FACTORY ()
 
 psStatsMessage (uint32_t client, float maxHP, float maxMana, float maxWeight, float maxCapacity)
 Sends a message to the client. More...
 
 psStatsMessage (MsgEntry *me)
 Crack open the message from the server. More...
 
 psStatsMessage ()
 Send a request to the server for the stats. More...
 
virtual csString ToString (NetBase::AccessPointers *accessPointers)
 Converts the message into human readable string. More...
 
- Public Member Functions inherited from psMessageCracker
void FireEvent ()
 Publishes the message to the local program. More...
 
virtual csString GetMessageTypeName () const =0
 Gets the name of the message type. More...
 
void Multicast (csArray< PublishDestination > &multi, uint32_t except, float range)
 Multicasts the message to all current connections. More...
 
 psMessageCracker ()
 
void SendMessage ()
 Sends the message to the client/server. More...
 
virtual ~psMessageCracker ()
 

Public Attributes

float capacity
 
float hp
 
float mana
 
bool request
 
float weight
 
- Public Attributes inherited from psMessageCracker
int filterNumber
 
csRef< MsgEntrymsg
 
bool valid
 

Additional Inherited Members

- Static Public Attributes inherited from psMessageCracker
static MsgHandlermsghandler
 

Detailed Description

This message is sent to the client to let it know the basic stats of the player.

Definition at line 2811 of file messages.h.

Constructor & Destructor Documentation

psStatsMessage::psStatsMessage ( uint32_t  client,
float  maxHP,
float  maxMana,
float  maxWeight,
float  maxCapacity 
)

Sends a message to the client.

Parameters
clientThe active client number to send to.
maxHPThe newly calculated maximum HP for this client's character.
maxManaThe newly calculated maximum mana for this client's character.
maxWeightThe maximum weight that this character can carry.
maxCapacityThe maximum capacity of items that this character can carry.
psStatsMessage::psStatsMessage ( MsgEntry me)

Crack open the message from the server.

psStatsMessage::psStatsMessage ( )

Send a request to the server for the stats.

Member Function Documentation

psStatsMessage::PSF_DECLARE_MSG_FACTORY ( )
virtual csString psStatsMessage::ToString ( NetBase::AccessPointers accessPointers)
virtual

Converts the message into human readable string.

Parameters
accessPointersA struct to a number of access pointers.
Returns
Return a human readable string for the message.

Implements psMessageCracker.

Member Data Documentation

float psStatsMessage::capacity

Definition at line 2843 of file messages.h.

float psStatsMessage::hp

Definition at line 2840 of file messages.h.

float psStatsMessage::mana

Definition at line 2841 of file messages.h.

bool psStatsMessage::request

Definition at line 2839 of file messages.h.

float psStatsMessage::weight

Definition at line 2842 of file messages.h.


The documentation for this class was generated from the following file: