Manager class that handles loading/searching/casting spells.
More...
#include <spellmanager.h>
|
void | Cast (gemActor *caster, const csString &spellName, float kFactor, Client *client) |
| Case a particular spell. More...
|
|
void | EndPurifying (psCharacter *character, uint32 glyphUID) |
| Purifying on a glyph has been complete. More...
|
|
void | HandleGlyphRequest (MsgEntry *notused, Client *client) |
| Handles a glyph request from a client. More...
|
|
void | SendGlyphs (MsgEntry *notused, Client *client) |
| Sends out the glyphs to a client. More...
|
|
| SpellManager (ClientConnectionSet *clients, iObjectRegistry *object_reg, CacheManager *cachemanager) |
|
virtual | ~SpellManager () |
|
void | HandleMessage (MsgEntry *msg, Client *client) |
| Transfers the message to the manager specific function. More...
|
|
void | Subscribe (FunctionPointer fpt, msgtype type, uint32_t flags=0x01) |
| Subscribes this manager to a specific message type with a custom callback. More...
|
|
bool | Unsubscribe (msgtype type) |
| Unsubscribes this manager from a specific message type. More...
|
|
bool | Unsubscribe (FunctionPointer handler, msgtype type) |
| Unsubscribes a specific handler from a specific message type. More...
|
|
bool | UnsubscribeAll () |
| Unsubscribes this manager from all message types. More...
|
|
virtual | ~MessageManager () |
| Unsubscribes all messages then destroys this object. More...
|
|
csArray< csString > | DecodeCommandArea (Client *client, csString target) |
| Decodes an area: expression. More...
|
|
gemObject * | FindObjectByString (const csString &str, gemActor *me) const |
| Find the object we are referring to in str. More...
|
|
Client * | FindPlayerClient (const char *name) |
| Finds Client* of character with given name. More...
|
|
virtual bool | Verify (MsgEntry *pMsg, unsigned int flags, Client *&client) |
|
Manager class that handles loading/searching/casting spells.
This class also manages a number of psSpell Events.
Definition at line 51 of file spellmanager.h.
virtual SpellManager::~SpellManager |
( |
| ) |
|
|
virtual |
Case a particular spell.
- Parameters
-
me | message entry for the client spell caster message. |
client | the clien that cast the spell. |
void SpellManager::Cast |
( |
gemActor * |
caster, |
|
|
const csString & |
spellName, |
|
|
float |
kFactor, |
|
|
Client * |
client |
|
) |
| |
Case a particular spell.
- Parameters
-
caster | The caster of the spell. |
spellName | The name of the spell to cast. |
kFactor | The power factor that the spell is cast with. |
client | The client that is casting the spell. |
void SpellManager::EndPurifying |
( |
psCharacter * |
character, |
|
|
uint32 |
glyphUID |
|
) |
| |
Purifying on a glyph has been complete.
This will send out a network message to the client and update it's inventory with the new purified glyph.
- Parameters
-
character | The character this is for. |
glyphUID | The unique ID for this item instance of the glyph. |
Find a spell in the assorted glyphs.
This checks ths list of glyphs and see if it matches any known spell. This is for when players are researching spells.
- Parameters
-
client | The client this data is for. |
assembler | A list of glyphs to check for spell match. |
- Returns
- A spell if a match found, NULL otherwise.
Handles a command when player tries to research.
- Parameters
-
client | The client this is for. |
me | The message from that client. |
void SpellManager::HandleCancelSpell |
( |
MsgEntry * |
notused, |
|
|
Client * |
client |
|
) |
| |
|
protected |
void SpellManager::HandleGlyphRequest |
( |
MsgEntry * |
notused, |
|
|
Client * |
client |
|
) |
| |
Handles a glyph request from a client.
- Parameters
-
notused | A not used message entry. |
client | The client that requested glyphs. |
void SpellManager::SaveSpell |
( |
Client * |
client, |
|
|
csString |
spellName |
|
) |
| |
|
protected |
Save a spell to the database for when a player has researched it.
- Parameters
-
client | The client that this is for. |
spellName | The name of the spell to save for that player. |
Sends out the glyphs to a client.
Builds and sends psRequestGlyphsMessage for the client.
- Parameters
-
notused | A not used message entry. |
client | The client that will be sent it's current glyphs. |
void SpellManager::SendSpellBook |
( |
MsgEntry * |
notused, |
|
|
Client * |
client |
|
) |
| |
|
protected |
Send the player's spell book.
- Parameters
-
notused | A not used message entry. |
client | The client that will be sent the spell book. |
Start to purify a glyph.
This will also send out notifications to the client about the start of operation.
- Parameters
-
me | The inncomming message. |
client | The client that this data is for. |
iObjectRegistry* SpellManager::object_reg |
|
protected |
The documentation for this class was generated from the following file: