| |
CBTextWindowData::CBTextWindowData() |
|
|
| Comments: |
| Constructor. |
| Sets the initial amount of Chat Messages this instance
should hold. Defaults to CB_DEFAULT_MAXIMUM_STORED_TEXT_MESSAGES. |
|
|
|
|
|
|
| |
|
| |
CBTextWindowData::CBTextWindowData( |
int nTextWindowID) |
|
| Comments: |
| Constructor which sets the initial related GUI
WindowID for this instance. |
| Sets the initial amount of Chat Messages this instance
should hold. Defaults to CB_DEFAULT_MAXIMUM_STORED_TEXT_MESSAGES. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::StoreUITextWindowID( |
int nTextWindowID) |
|
| Comments: |
| Sets the stored ID of the related UI Text Window or
Chat Tab. |
| Each CBTextWindowData instance should have one related
GUI Text Window/Tab that it assists. |
|
|
| Parameters: |
| nTextWindowID |
| The WindowID of the
Text Window that this instance should store Chat
Messages and Monitored Channels for. |
|
|
|
|
|
| |
|
| int |
CBTextWindowData::ClearMessages( |
int bNotifyGUI = CB_TRUE) |
|
|
|
| Parameters: |
| bNotifyGUI |
| Defaults to CB_TRUE which
indicates the related GUI Text Window should be
informed its
contents have been cleared. Set to
CB_FALSE if the related GUI Text Window should
not be notified. |
|
|
|
|
|
| |
|
| int |
CBTextWindowData::SetMaximumSize( |
int nMaxSize) |
|
| Comments: |
| Function which sets the maximum amount of Chat Messages to store. |
| Once this limit is hit the oldest Messages shall be popped off. |
| This function does not pre-allocate space in the deque. |
|
|
| Parameters: |
| nMaxSize |
| The Maximum amount of
Chat Messages this instance should
retain. |
|
|
|
|
|
| |
|
|
|
| Comments: |
| Function which adds in a Chat Message for storage. |
| If more than m_nMaximumSize is added,
this function shall pop off the oldest Message in the
deque (FIFO). |
| Chat Messages are stored in dqMessageArray. |
| When a Chat Message is added to ChatBlade, ChatBlade
shall look through all the CBTextWindowData instances
and find those which are Monitoring the Chat Channel of
the Message. |
| ChatBlade then calls this function to add the Chat
Message to the correct CBTextWindowData
instances. |
| Called by CBChatHandler::AddMessageToTextWindowDatas(). |
|
|
| Parameters: |
| cbChatMessage |
| A Chat Message on a
Chat Channel this instance is Monitoring.
The Chat Message is then added to the
deque. |
|
|
|
| Returns: |
| CB_ERROR_CHANNEL_SIZE_ZERO if the Maximum size is set
to 0, this instance cannot store any Chat
Messages. |
| CB_ERROR_INCORRECT_CHANNEL if the Chat Message is not
on a ChannelID that this instance is
Monitoring. |
| CB_SUCCESS if the Chat Message was stored. |
|
| |
|
| int |
CBTextWindowData::GetCurrentSize() |
|
|
| Comments: |
| Returns the amount of Chat Messages currently in the CBTextWindowData
instance. |
| Does not return the Memory Size, just the amount of
stored Chat Messages. |
|
|
|
|
| Returns: |
| Returns the size of dqMessageArray which is the amount
of Chat Messages it is currently storing. |
|
| |
|
| int |
CBTextWindowData::ClearChannelIDs() |
|
|
| Comments: |
| Removes all ChannelIDs from the list of Chat Channels
that this instance is Monitoring. |
| If an instance is not Monitoring any Chat Channels
then that instance should no longer receive Chat
Messages. |
| Developers may want to call this function when a
Player changes the Chat Channels a Text Window should
Monitor. First call this function to clear out all
ChannelIDs, then call one of the AddChannelXXX()
functions to add in some Chat Channels to Monitor as
specified by the Player. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::RemoveChannelID( |
int nChannelType) |
|
| Comments: |
| Removes the ChannelID from the list of Chat Channels
this instance is Monitoring. |
| This instance should no longer receive Chat Messages
on the specified Chat Channel. |
|
|
| Parameters: |
| nChannelType |
| A ChannelID of Chat
Messages that this instance no longer cares
about. |
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddChannelID( |
int nChannelType) |
|
| Comments: |
| Adds a ChannelID of a Chat Channel that this instance
should be Monitoring. |
| Any Chat Messages coming in on that Chat Channel are
added to this instance by ChatBlade. |
| Call this function repeatedly with different
ChannelIDs to Monitor multiple Chat
Channels. |
| Typically a Player would have a GUI element to enable
them to determine which Chat Channels each GUI Text
Window/Tab should Monitor. |
| Game Developers may want to call ClearChannelIDs()
first then invoke this function once for each Chat
Channel a Player has enabled for a Text
Window. |
|
|
| Parameters: |
| nChannelType |
| The ChannelID of a
Chat Channel that this class should Monitor such
as CB_CHANNEL_SAY, or CB_CHANNEL_GROUP. |
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddAllChannelIDs() |
|
|
| Comments: |
| This helper function causes the CBTextWindowData
instance to Monitor Chat Messages on all Chat Channels
expect for CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL. |
| CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL is designed for
use in Customer Service Clients only. Normal
Players should not be able to Monitor this Chat
Channel. |
| After Calling this function, the related Text
Window/Tab should receive most all Chat Messages which
ChatBlade processes. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddMandatoryChannelIDs() |
|
|
| Comments: |
| Helper function which adds in most Mandatory type Chat
ChannelIDs to be Monitored. |
| Mandatory Chat Channels are those which should always
be able to be displayed and should not be disabled by
the Player. |
| Chat Messages on these Chat Channels typically would
be things like Server Coming Down type messages and
Tells from Customer Service Representatives and
GMs. |
| It is envisioned that at least one GUI Text Window
should be Monitoring the Mandatory Chat Channels at all
times. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddCustomerServiceInternalChannelID() |
|
|
| Comments: |
| Adds the CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL Chat
Channel to those which should be Monitored. |
| It is envisioned that CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL
shall be used by CSR's to talk amongst themselves.
In general, Players should not be able to Monitor this
Chat Channel. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddBaseChannelIDs() |
|
|
| Comments: |
| Helper function which adds in a wide assortment of
Chat Channels this instance should Monitor. |
| Includes Says, Tells, Group, Guilds, Auctions, Yells,
Errors, OOC, LFG, and many other Chat
Channels. |
| See the Source Code for a complete list of Chat
Channels which are added. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddAllCombatChannelIDs() |
|
|
| Comments: |
| Helper Function which enables Monitoring on all Combat
related Chat Channels. |
| Enables Monitoring on Damage, Healing, Hits, Misses,
Spells/Psionics, Procs, and Pet combat Chat
Channels. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddCombatBaseChannelIDs() |
|
|
| Comments: |
| Helper function which Adds in the generic Combat
related Chat Channels to those this instance should
Monitor. |
| Includes generic Damage, Warnings, Procs, Damage
Shields, Critical Hits, Special moves, and other Chat
Channel IDs. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddCombatHitAndMissChannelIDs() |
|
|
| Comments: |
| Helper function which Adds in Monitoring of the Chat Channels
related to Hits and Misses by the Player, Group, Others,
Pets, and Enemies. |
| Includes both Ranged combat and Hand to
Hand. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddCombatPowerChannelIDs() |
|
|
| Comments: |
| Helper function which adds in the Chat Channel IDs of
the Channels relating to the use of Powers in the
Game. |
| Powers might include Spell Casting, Psionics,
Super-Powers, Nano-Tech, or whatever abilities are
defined by the Game genre. ChatBlade uses the
generic word Power to represent these. |
| This function adds the ChannelIDs relating to Power
Activation, Failure, and Status for the Player, Group,
Enemies, Pets, and Others. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::AddCombatHealingChannelIDs() |
|
|
| Comments: |
| Helper function which adds in all Healing related Chat
ChannelIDs to those which should be
Monitored. |
| Includes Healing from the Player, Group, Enemies,
Pets, and Others. |
|
|
|
|
|
|
| |
|
| int |
CBTextWindowData::IsMonitoredChannel( |
int nChannelID) |
|
| Comments: |
| Function which checks if the specified Chat Channel is
one this instance is Monitoring. |
| Returns CB_TRUE if the ChannelID is in the list of
Chat Channels to Monitor for this instance. |
| Called by CBChatHandler::AddMessageToTextWindowDatas()
to determine which CBTextWindowData instances should
receive a Chat Message. |
|
|
| Parameters: |
| nChannelID |
| The ChannelID which is
compared against m_ChannelIDSet
to determine if it is currently being
Monitored. |
|
|
|
| Returns: |
| CB_FALSE if the Chat Channel is not being
Monitored. |
| CB_TRUE if the specified ChannelID is one being
Monitored by this instance. |
|
| |
|
| int |
CBTextWindowData::NotifyGUITextWindow() |
|
|
| Comments: |
| This function gets called each time a Chat Message is
added to the instance. It is also invoked if ClearMessages()
is called. |
| This function in-turn calls CBData::pChatHandler->m_ClientImplementation.OnMessageAddedToTextWindow()
in order that the GUI Text Window/Tab may be informed
that its contents have changed. |
| Game Developers should implement CBClientImplementation::OnMessageAddedToTextWindow()
and have it Notify the related GUI Text Window/Tab of
content change. |
| This function is designed so that the GUI Text Window
can know when to redraw in response to Addition or
Removal of Chat Messages. |
|
|
|
|
|
|
| |
|
| static
int |
CBTextWindowData::GetAllChatTextWithHyperlinkTags( |
int nTextWindowID /*IN*/, |
| |
|
CBSTRING &
sChatText /*OUT*/) |
|
| Comments: |
| This static function retrieves the text of all Chat
Messages stored for the specified Text
Window. |
| Each Chat Message text is separated by a
Newline. |
| Any Hyperlink Tags are included in the text.
Developers should remove the tags and change them to
Hyperlinks before display. |
| This function is designed so that the GUI Text Window
can retrieve all of its Chat Text with one function
call. |
| If a Text Window just needs the text from the
latest message added, Developers may call CBTextWindowData::GetLastChatMessage()
instead and get the text from the CBChatMessage
returned. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to obtain all
of its Chat text. |
|
| sChatText |
| A reference to a CBSTRING
which shall contain all the Chat Text for a Text
Window, upon function return. |
|
|
|
| Returns: |
| Upon return sChatText shall contain the combined text
of each CBChatMessage
instance stored in the CBTextWindowData matching the
specified nTextWindowID. |
| CB_SUCCESS |
|
| |
|
| static int |
CBTextWindowData::GetAllChatText( |
int nTextWindowID /*IN*/, |
| |
|
CBSTRING &
sChatText /*OUT*/) |
|
| Comments: |
| This static function retrieves the text of all Chat
Messages stored for the specified Text
Window. |
| Each Chat Message text is separated by a
Newline. |
| Any Hyperlink Tags are excluded from the text,
although the Hyperlink string portions are
included. |
| This function is designed so that the GUI Text Window
can retrieve all of its Chat Text with one function
call. |
| If a Text Window just needs the text from the
latest message added, Developers may call CBTextWindowData::GetLastChatMessage()
instead and get the text from the CBChatMessage
returned. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to obtain all
of its Chat text. |
|
| sChatText |
| A reference to a CBSTRING
which shall contain all the Chat Text for a Text
Window, upon function return. |
|
|
|
| Returns: |
| Upon return sChatText shall contain the combined text
of each CBChatMessage
instance stored in the CBTextWindowData matching the
specified nTextWindowID. |
| CB_SUCCESS |
|
| |
|
| static int |
CBTextWindowData::GetLastChatMessage( |
int nTextWindowID /*IN*/, |
| |
|
CBChatMessage & cbChatMessage
/*OUT*/) |
|
| Comments: |
| This static function retrieves the last Chat Message
added to the CBTextWindowData instance that is helping
the specified Text Window. |
| It is designed to be used in response to a GUI Text
Window being notified that a Chat Message has been added
(via CBClientImplementation::OnMessageAddedToTextWindow()). |
| The GUI Text Window may call this function and
retrieve the new Chat Message, and then display the text
of that Chat Message. |
| If there are no Chat Messages stored for the specified
Text Window this function returns CB_ERROR_DOES_NOT_EXIST
and cbChatMessage is cleared. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to retrieve
the latest Chat Message added. |
|
| cbChatMessage |
| A reference to a
CBChatMessage which shall contain the data of
the newest Chat Message added. |
|
|
|
| Returns: |
| Upon return, cbChatMessage should contain the data
of the newest Chat Message added to the CBTextWindowData
instance affiliated with the specified
nWindowID. |
| CB_ERROR_DOES_NOT_EXIST if there are no Chat Messages
stored for the Window. |
| CB_SUCCESS |
|
| |
|
| static int |
CBTextWindowData::ClearChannelIDs( |
int nTextWindowID) |
|
| Comments: |
| Removes all ChannelIDs from the list of Chat Channels
that the specified instance is Monitoring. |
| If an instance is not Monitoring any Chat Channels
then that instance should no longer receive Chat
Messages. |
| Developers may want to call this function when a
Player changes the Chat Channels a Text Window should
Monitor. First call this function to clear out all
ChannelIDs, then call one of the AddChannelXXX()
functions to add in some Chat Channels to Monitor as
specified by the Player. |
| This function is the Static version which takes the
Text Window ID as its first parameter. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to remove all
Channels being Monitored. |
|
|
|
|
|
| |
|
| static int |
CBTextWindowData::RemoveChannelID( |
int nTextWindowID, |
| |
|
int nChannelType) |
|
| Comments: |
| Removes the ChannelID from the list of Chat Channels
this Text Window is Monitoring. |
| The CBTextWindowData instance helping the specified
Text Window should no longer receive Chat Messages
on the specified Chat Channel. |
| This function is the Static version which takes the
Text Window ID as its first parameter. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to remove a
Monitored Channel. |
|
| nChannelType |
| A ChannelID of Chat
Messages that the Text Window no longer cares
about. |
|
|
|
|
|
| |
|
| static int |
CBTextWindowData::AddChannelID( |
int nTextWindowID, |
| |
|
int nChannelType) |
|
| Comments: |
| Adds a ChannelID of a Chat Channel that a Text
Window/Tab should be Monitoring. |
| Any Chat Messages coming in on that Chat Channel are
added to the CBTextWindowData instance helping the
specified Text Window by ChatBlade. |
| Call this function repeatedly with different
ChannelIDs to Monitor multiple Chat
Channels. |
| Typically a Player would have a GUI element to enable
them to determine which Chat Channels each GUI Text
Window/Tab should Monitor. |
| Game Developers may want to call CBTextWindowData::ClearChannelIDs(nTextWindowID)
first then invoke this function once for each Chat
Channel a Player has enabled for a Text
Window. |
| This function is the Static version which takes the
Text Window ID as its first parameter. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to add another
Channel to Monitor. |
|
| nChannelType |
| The ChannelID of a
Chat Channel that the Text Window should Monitor such
as CB_CHANNEL_SAY, or CB_CHANNEL_GROUP. |
|
|
|
|
|
| |
|
| static int |
CBTextWindowData::AddAllChannelIDs( |
int nTextWindowID) |
|
| Comments: |
| This helper function causes the specified CBTextWindowData
instance to Monitor Chat Messages on all Chat Channels
expect for CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL. |
| CB_CHANNEL_CUSTOMER_SERVICE_INTERNAL is designed for
use in Customer Service Clients only. Normal
Players should not be able to Monitor this Chat
Channel. |
| After Calling this function, the related Text
Window/Tab should receive most all Chat Messages which
ChatBlade processes. |
| This function is the Static version which takes the
Text Window ID as its first parameter. |
|
|
| Parameters: |
| nTextWindowID |
| The Text Window ID of a GUI
Text Window/Tab for which we wish to Monitor all
Chat Channels. |
|
|
|
|
|
| |
|
| |