| |
CBClientImplementation::CBClientImplementation() |
|
|
| Comments: |
| Empty Constructor |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadSlashCommands() |
|
|
| Comments: |
| This function should load up all of the initial Slash
Commands for the game. |
| Each OnCommandXXX() function found in CBSlashCommands
should have a corresponding CBCommandMap
Instance. This CBCommandMap
instance should be filled with the Slash Commands that
invoke the OnCommandXXX() function. |
| An Array of these Command Maps is stored in CBData::vCommandMapArray
and each CBCommandMap
instance should be added onto this array. |
| So for each OnCommandXXX() Function first create a CBCommandMap
instance. Then Fill it with the pointer to the
OnCommandXXX() function. Next add in all the Slash
Commands that invoke that Function. Finally invoke
CBData::AddCommandMap()
passing it the CBCommandMap
instance to add the Command Map to
ChatBlade. |
| See CBSampleImplementation::LoadSlashCommands()
for an example. |
| See How To Load
the Slash Commands Interface for details on
implementing this function. |
| While the Games Slash Commands can be loaded from a
Database or Hardcoded into the Code, ChatBlade allows
for a better implementation by allowing the Slash
Commands to be configurable by the User. CBSampleImplementation::LoadSlashCommands()
is sample code that loads all the Slash Commands via an
XML file the Player can edit. Alternatively the
Game Developer may want to create a GUI component to
allow the Players to alter each Slash Command as they
desire. |
| ChatBlades ability to allow the Players to alter the
Slash Commands is one of its most innovative
features. |
| This function is invoked from CBChatHandler::InitializeChat()
via CBChatHandler::InitializeSlashCommands(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadChatFilter() |
|
|
| Comments: |
| This function should Load up the Chat Filter with Bad
Words. |
| ChatBlade uses the CBChatFilter
instance that is a member of CBChatHandler. |
| Each bad word should be loaded via CBData::pChatHandler->m_ChatFilter.AddString().
See CBSampleImplementation::LoadChatFilter()
for a sample implementation. |
| CBSampleImplementation::LoadChatFilter()
reads in an XML file of offensive words and fills the
Chat Filter with them. Game Developers may want to
move this XML data to the Backend and load the bad words
via the Network. |
| The ChatBlade Chat Filter filters out entire words and
not partial words. The Complete word that should
be filtered needs to be loaded. Case is not
important. The Chat Filter should ignore
punctuation in any of the bad words Users may type
in. |
| No portion of the word Cockatrice shall get filtered
using ChatBlades filtering method. Since ChatBlade
filters entire words this means that each variation of a
bad word needs to be added to the Chat Filter. So
if one wanted to filter out the word Boob, then one
would need to add in Boob, Boobs, Boobies, Booby,
Boobhead and any other permutation. |
| Only single words should be loaded into the Chat
Filter, there should be no space in an added
string. |
| Note: ChatBlade allows Players to dynamically
add to, or remove words from the Chat Filter during game
play by using the /filterword and /unfilterword Slash
Commands (by default). |
| This function is invoked by CBChatHandler::InitializeChat()
via CBChatHandler::InitializeChatFilter(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadLanguageTables() |
|
|
| Comments: |
| This function should load up the CBLanguageTables
with the Data of in-game Fantasy Languages. |
| ChatBlade stores a Map of all the Language Tables in CBChatHandler
and each is indexed by their LanguageID. |
| This function should create a CBLanguageTable
instance for each in-game Language such as Elvish or
Klingon. It should then fill up that Language
Table by calling cbLanguageTableInstance.AddWord() for
each word of the Language. Finally it should add
that Language Table to ChatBlades list by calling CBLanguageTable::AddLanguageTable().
|
| See CBSampleImplementation::LoadLanguageTables()
for an example of loading an Elvish Language
Table. |
| ChatBlade uses the words in the Language Table to
replace typed words when a Character is not fully fluent
in the Language the Chat Message was spoken
in. |
| A Hash is used internally to ensure that each real
word always matches up to the same in-game Fantasy
Language word. |
| Each Language Table should hold a variety of words
under 3 letters length, words over 6 letters long, and
words in between. ChatBlade attempts to maintain
the approximate length of words when they are being
replaced by their Fantasy Language
equivalents. |
| This function is invoked by CBChatHandler::InitializeChat()
via CBChatHandler::InitializeLanguageTables(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadAliasList() |
|
|
| Comments: |
| This function should load up a Players list of Alias
commands they had created in previous
sessions. |
| ChatBlade stores the Alias List in CBData::pChatHandler->m_AliasList. |
| Alias commands should be added one at a time via a
CBData::pChatHandler->m_AliasList.AddAlias()
call. |
| Aliases are Player created Slash Commands which expand
into existing game defined Slash Commands when
used. Players create Alias commands using the
/alias Slash Command. |
| Note: An Alias that is identical to an existing
Slash Command may prevent that command from being
invoked until the conflicting Alias is
removed. |
| This function is invoked by CBChatHandler::InitializeChat()
via CBChatHandler::InitializeAliasList(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadNicknameList() |
|
|
| Comments: |
| This function should load up a list of local Nicknames
for other Players Characters that the User had
previously created. |
| ChatBlade stores the Nickname List in CBData::pChatHandler->m_NicknameList. |
| Nicknames should be added one at a time via a
CBData::pChatHandler->m_NicknameList.AddNickname()
call. |
| Nicknames are used to facilitate
/tells. |
| Players create Nicknames for other Characters,
typically supplying a short easy to type Nickname that
shall expand to a Characters full name when used in a
/tell. |
| Players create local Nicknames for other Players
Characters, not for their own. Each Player shall
have a separate list of Nicknames that they use.
Nicknames are not shared Globally and are specific to
each User. |
| Note: A Nickname that is identical to an existing
Characters name may prevent the Player from sending
/tells to the real Character name until the conflicting
Nickname is removed. |
| This function is invoked by CBChatHandler::InitializeChat()
via CBChatHandler::InitializeNicknameList(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadIgnoreList() |
|
|
| Comments: |
| This function should load up a Players Ignore
List. |
| ChatBlade stores the Ignore List in CBData::pChatHandler->m_IgnoreList. |
| Ignored Characters should be added one at a time via a
CBData::pChatHandler->m_IgnoreList.AddCharacter()
call. |
| Messages with a Source of a Character Name on the
Ignore List are discarded. |
| Care should be taken that GMs, CSRs, and other
official Characters cannot be added to the Ignore
List. In addition the string "CBNONE"
should not appear in the Ignore List. |
| This function is invoked by CBChatHandler::InitializeChat()
via CBChatHandler::InitializeIgnoreList(). |
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::LoadSpamFilter() |
|
|
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::SaveAliasList() |
|
|
| Comments: |
| This function should save a Players Alias List for
persistence. |
| ChatBlade stores the Alias List in CBData::pChatHandler->m_AliasList. |
| Aliases found in this list should be saved to the Game
Database or a local file so they may be loaded again the
next time the Player logs in. |
| ChatBlade does not invoke, nor implement this
function. It is merely a stub that Developers may
make use of according to Game Design. |
| Alternatively, instead of using this function, the
persisted Alias list may be altered each time a Player
adds or removes an Alias. |
|
|
|
|
| Returns: |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::SaveNicknameList() |
|
|
| Comments: |
| This function should save a Players Nickname List for
persistence. |
| ChatBlade stores the Nickname List in CBData::pChatHandler->m_NicknameList. |
| Nicknames found in this list should be saved to the
Game Database or a local file so they may be loaded
again the next time the Player logs in. |
| ChatBlade does not invoke, nor implement this
function. It is merely a stub that Developers may
make use of according to Game Design. |
| Alternatively, instead of using this function, the
persisted Nickname list may be altered each time a
Player adds or removes a Nickname. |
|
|
|
|
| Returns: |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::SaveIgnoreList() |
|
|
| Comments: |
| This function should save a Players Ignore List for
persistence. |
| ChatBlade stores the Ignore List in CBData::pChatHandler->m_IgnoreList. |
| Ignored Character names found in this list should be
saved to the Game Database or a local file so they may
be loaded again the next time the Player logs
in. |
| ChatBlade does not invoke, nor implement this
function. It is merely a stub that Developers may
make use of according to Game Design. |
| Alternatively, instead of using this function, the
persisted Ignore list may be altered each time a Player
adds or removes a Character name to Ignore. |
|
|
|
|
| Returns: |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::ExpandMacros( |
CBSTRING & sLine /*IN
OUT*/) |
|
| Comments: |
| Stub function to enable any % macros to be expanded
before the Chat Message is processed. |
| Game developers should parse the line and replace any
% macros with their text equivalents. |
| For example %T might expand to be the Players current
Target name. %L might expand to be the Characters
current location. |
Star Wars Galaxies used the following
%Macros:
- %TU - your full name (first and last)
- %TT - your current look at target target's full
name
- %NU - your first name
- %NT - your target's short version name (first
only)
- %SU - personal subjective pronoun: he/she/it for
the speaker
- %ST - he/she/it for the target
- %OU - personal objective pronoun: him/her/it for
the speaker
- %OT - him/her/it for your target
- %PU - possessive: his/her/its for the speaker
- %PT - his/her/its for your target
- %RU - your species
- %RT - your target's species
- %KU - your profession title
- %KT - your target's profession title
|
| EverQuest used the following
%Macros:
%M – Returns
the character’s pet's name (when they have a pet)
%T - Returns the
current target
%S - Returns the
subjective gender-specific pronoun for the target (He,
She, It)
%O - Returns the
objective gender-specific pronoun for the target (Him,
Her, It)
%P - Returns the
possessive gender-specific pronoun for the target (His,
Her, Its)
%R - Returns the
race of the target (only works on Player characters)
%G - Returns the
gender of the target
|
| Currently % Macros are non-standardized.
ChatBlade does not endeavor to provide Standardization
in this regard so Game Developers should implement
whatever % Macros make the most sense for their
Game. |
| Expansion of the % Macros should be done
in-place. |
| For Example: |
| Player
types:
/yell Help at %L, I am being chased by a %T. |
| should be expanded to: /yell Help at
152X, 240Y, I am being chased by a Levin
Cat. |
| This function is called by CBChatHandler::OnLineEntered(). |
|
|
| Parameters: |
| sLine |
| A reference to a line
of text the Player has typed in. Upon exit
any % Macros found in the line should be
replaced with their Text
Equivalents. |
|
|
|
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::OnMessageAddedToTextWindow( |
int nGUITextWindowID) |
|
| Comments: |
| This function gets called whenever a Chat Message is
added to or removed from a CBTextWindowData
instance. |
| So, in effect, anytime a message gets added to a Chat
Window this function shall be invoked in order to enable
the Game to refresh its GUI windows. |
| The ID or the Window that has a new message is passed
to this function. Game Developers should then have
the matching GUI Text Window redraw its data in order to
display the new Chat Message. |
| Each GUI Text Window should have a matching CBTextWindowData
instance that keeps track of its Chat Messages and which
Chat Channels to monitor in that Text
Window. |
| When ChatBlade receives a Chat Message on a Chat
Channel a Text Window is monitoring, it shall add that
Chat Message to the Text Windows CBTextWindowData
instance. When a Chat Message is added CBTextWindowData
.NotifyGUITextWindow() gets invoked which in turn calls
this function. |
| Game Developers should inform their GUI Text Windows
that their underlying data has changed whenever this
function is invoked. |
| This function is called by CBTextWindowData
.NotifyGUITextWindow() and CBTextWindowData
.ClearMessages(). |
|
|
|
| Parameters: |
| nGUITextWindowID |
| The ID of the GUI Text
Window that has had its contents
changed. |
|
|
|
|
|
|
|
|
|
| |
|
| CBSTRING |
CBClientImplementation::GetCharacterName() |
|
|
|
|
|
|
| Returns: |
| A string representing the current Characters
Name. |
|
| |
|
| int |
CBClientImplementation::GetCharacterFaction() |
|
|
| Comments: |
| This function should return the FactionID of the
current Characters Faction. |
| For use in Games which make use of
Factions. |
| Factions are primarily used in PvP games and are
utilized by ChatBlade in order to prevent Players from
opposing Factions from seeing each others Chat
Messages. |
| For Example if a Game has 2 sides, Orcs and Elves,
then it is often desirable to have each side unable to
communicate with the other. Each Character on a
side would have a FactionID that is different from that
of the opposing side. |
| ChatBlade calls CBChatHandler::IsDisplayableChatMessage()
in order to determine if a Chat Message should be
displayed. |
| By default, ChatBlade adds a Characters FactionID onto
each Chat Message. If a Game does not make use of
Factions, the FactionID portion of CBChatMessage
can be removed. Doing so entails going through the
ChatBlade code and removing any references to a
FactionID. |
| Called by CBUtils::MakePlayerSentChatMessage(). |
|
|
|
|
| Returns: |
| The FactionID of the current Characters Faction.
May be CB_FACTION_NONE. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetFactionName( |
int nFactionID) |
|
| Comments: |
| This function should return the Name of the Faction
referenced by nFactionID. |
| ChatBlade needs this information in order to support
the Faction Chat Channel (CB_CHANNEL_FACTION). |
| Game Developers should implement this
function. |
| For Example: This function might return the
strings "Elves" or
"Orcs". |
| Called by CBChatMessage::GetChannelSourceStringBeginning(). |
|
|
| Parameters: |
| nFactionID |
| The ID of the Faction we
want to retrieve the Name of. |
|
|
|
|
|
|
|
| Returns: |
| A string representing the Name of the specified
Faction. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetCharacterClassName() |
|
|
| Comments: |
| This function should return the Name of the Current
Characters primary Class or Profession. |
| ChatBlade needs this information in order to support
the Class Chat Channel (CB_CHANNEL_CLASS). |
| Game Developers should implement this
function. |
| Examples of Class Names might be Bard, Ranger, or
Psionicist. |
| Called by CBSlashCommands::OnCommandClassChat(). |
|
|
|
|
| Returns: |
| A string representing the current Characters primary
Class. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetCharacterRaceName() |
|
|
| Comments: |
| This function should return the Name of the Current
Characters Race. |
| ChatBlade needs this information in order to support
the Race Chat Channel (CB_CHANNEL_RACE) |
| Game Developers should implement this
function. |
| Examples of Races may be Elf, Human, or Tarsion. |
| Called by CBSlashCommands::OnCommandRaceChat(). |
|
|
|
|
| Returns: |
| A string representing the current Characters
Race. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetCharacterLevelAsString() |
|
|
| Comments: |
| This function should return the Current Characters
Level as a string. |
| ChatBlade needs this information in order to support
the Level Chat Channel (CB_CHANNEL_LEVEL) which is
designed to send Chat Messages to other Characters of
similar Level. |
| Game Developers should implement this
function. |
| Examples might be "10" or
"22". |
| Called by CBSlashCommands::OnCommandLevelChat(). |
|
|
|
|
| Returns: |
| A string representing the current Characters
Level. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetTargetName() |
|
|
| Comments: |
| This function should return the Name of the Characters
current Target. |
| ChatBlade needs this information in order to support
the /targettell Slash Command which sends a Tell to the
Players current Target. |
| Game Developers should implement this
function. |
| Examples might be "Vanadia Delfin", or
"Blast Shield D". Tells to targeted
items should fail gracefully. |
| Should return CB_NONE if the Player has no
Target. |
| Called by CBSlashCommands::OnCommandTargetTell(). |
|
|
|
|
| Returns: |
| A string representing the Characters current Target or
"CBNONE" if there is no Target. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetGroupIDCode() |
|
|
| Comments: |
| This function should return the GroupID of the
Characters current Group. |
| ChatBlade needs this information in order to support
Group Chat and Group Priority Chat. |
| It is envisioned that each Group shall have a separate
ID. ChatBlade shall use this GroupID as the
destination string in Group Chat Messages. A Chat
Server can then look up the other members of the group
via the GroupID and forward messages along to
them. |
| Game Developers should implement this
function. |
| Examples of GroupIDs might be "Vanadia Group
A" or "Palladia Group". They should
be whatever the GroupID is known as in the main Game
Database returned as a String. |
| Should return CB_NONE if the Player has no
Group. |
| Called by CBSlashCommands::OnCommandGroupChat()
and CBSlashCommands::OnCommandGroupPriorityChat(). |
|
|
|
|
| Returns: |
| A string representing the Characters current GroupID
or "CBNONE" if the Character is not in a
Group. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetGuildIDCode() |
|
|
| Comments: |
| This function should return the GuildID of the
Characters current Guild. |
| ChatBlade needs this information in order to support
Guild Chat, Priority Guild Chat, and Officer
Chat. |
| It is envisioned that each Guild shall have a separate
ID. ChatBlade shall use this GuildID as the
destination string in Guild Chat Messages. A Chat
Server can then look up the other online members of the
Guild via the GuildID and forward messages along to
them. |
| Game Developers should implement this
function. |
| Examples of GuildIDs might be "Dolphin Pod"
or "Blades of Justice". They should be
whatever the GuildID is known as in the main Game
Database returned as a String. |
| Should return CB_NONE if the Player has no Guild. |
| Called by CBSlashCommands::OnCommandGuildChat(),
CBSlashCommands::OnCommandOfficerChat(),
and CBSlashCommands::OnCommandGuildPriorityChat(). |
|
|
|
|
| Returns: |
| A string representing the Characters current GuildID
or "CBNONE" if the Character is not in a Guild. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetRaidIDCode() |
|
|
| Comments: |
| This function should return the RaidID of the
Characters current Raid. |
| ChatBlade needs this information in order to support
Raid Chat and Priority Raid Chat. |
| A Raid is a Group of Groups. |
| It is envisioned that each Raid shall have a separate
ID. ChatBlade shall use this RaidID as the
destination string in Raid Chat Messages. A Chat
Server can then look up the other members of the Raid
via the RaidID and forward messages along to them. |
| Game Developers should implement this
function. |
| Examples of RaidIDs might be "Vanadia Raid
A" or "Palladia Raid". They should
be whatever the RaidID is known as in the main Game
Database returned as a String. |
| Should return CB_NONE if the Player is not in a Raid. |
| Called by CBSlashCommands::OnCommandRaidChat()
and CBSlashCommands::OnCommandRaidPriorityChat(). |
|
|
|
|
| Returns: |
| A string representing the Characters current RaidID or
"CBNONE" if the Character is not in a Raid. |
|
| |
|
| CBSTRING |
CBClientImplementation::GetAllianceIDCode() |
|
|
| Comments: |
| This function should return the AllianceID of the
Characters current Alliance. |
| ChatBlade needs this information in order to support
Alliance Chat and Alliance Priority Chat. |
| An Alliance is a Group of Guilds. |
| It is envisioned that each Alliance shall have a
separate ID. ChatBlade shall use this AllianceID
as the destination string in Alliance Chat
Messages. A Chat Server can then look up the other
online members of the Alliance via the AllianceID and
forward messages along to them. |
| Game Developers should implement this
function. |
| Examples of AllianceIDs might be "Alliance
BA2" or "Freedom Fighter Alliance
A". They should be whatever the AllianceID is
known as in the main Game Database returned as a
String. |
| Should return CB_NONE if the Player is not in an
Alliance. |
| Called by CBSlashCommands::OnCommandAllianceChat(()
and CBSlashCommands::OnCommandAlliancePriorityChat(). |
|
|
|
|
| Returns: |
| A string representing the Characters current
AllianceID or "CBNONE" if the Character is not in an
Alliance. |
|
| |
|
| int |
CBClientImplementation::GetCurrentIntoxicationLevel() |
|
|
| Comments: |
| This function should return a value representing how
Intoxicated the current Character is. |
| For use in Games which support Drinking. |
| Used by ChatBlade to determine how much to Intoxicate
speech. |
| ChatBlade supports 4 possible Intoxication
Levels:
CB_INTOXICATION_NONE
CB_INTOXICATION_LIGHT
CB_INTOXICATION_MEDIUM
CB_INTOXICATION_HEAVY
|
| ChatBlade shall slur the speech more the greater the
level of Intoxication. |
| Developers should return the current level of
drunkenness of the Character. If Drinking is not
supported this function should return CB_INTOXICATION_NONE.
Drunken speech may not work for all character sets such
as Mandarin or Korean. |
| Called by most Chat type commands in CBSlashCommands. |
|
|
|
|
| Returns: |
| CB_INTOXICATION_NONE if the Character is not
Drunk. |
| CB_INTOXICATION_LIGHT if the Character is slightly
Drunk. |
| CB_INTOXICATION_MEDIUM if the Character is
Drunk. |
| CB_INTOXICATION_HEAVY if the Character is very
Drunk. |
|
| |
|
| int |
CBClientImplementation::GetLanguageKnowledgeLevel( |
int nLanguageID) |
|
| Comments: |
| This function should return a value indicating how
Fluent the current Character is in the target
Language. |
| This function should return a value in the range of 0
- 100 where 0 means the Character does not know any of
the Language and 100 means the Character is fully Fluent
in the specified Language. |
| ChatBlade shall use this information in order to
determine how much to Language Convert Chat Messages
spoken in a Language the Character is not fully Fluent
in.
ChatBlade shall also use this information to
determine which Languages a Character can choose as
their default with the /language Slash
Command. |
| If this function returns 50, (meaning that the
Character halfway knows the Language) then ChatBlade
shall convert approximately Half the words of a Chat
Message into fantasy words of that Language.
A return value of 20 would mean that 80% of the words
would be converted from English (or whatever real
Language they were typed in) to Elvish or whatever
fantasy Language the message was sent in. |
| This function is for use with in-game Fantasy
Languages such as Elvish or Vulcan, and not for use with
real world Languages such as Korean or
Chinese. |
| For use in Games which support in-game
Languages. Developers should implement this
function.
For Games which do not have in-game Languages this
function should return 100. |
| Called by CBSlashCommands::OnCommandLanguage()
and CBLanguageTable::LanguageConvertString(). |
|
|
| Parameters: |
| nLanguageID |
| The ID of the Language
we want to determine how Fluent the current
Character is in. |
|
|
|
|
|
|
|
| Returns: |
| An Int between 0 - 100 (inclusive) representing how
Fluent the current Character is in the specified
Language. |
|
| |
|
| int |
CBClientImplementation::GetLanguageString( |
int nLanguageID /*IN*/, |
| |
|
CBSTRING & sLanguageString
/*OUT*/) |
|
| Comments: |
| Stub function which should supply a string value for a Language when given its ID. |
| ChatBlade uses the Language string supplied to display
which Language a Chat Message was sent in. |
| Game Developers should alter this function to fit
the Languages actually in their Game. |
|
|
| Parameters: |
| nLanguageID |
| The LanguageID of a
Language for which we want to find the text
String of. |
|
| sLanguageString |
| A reference to a
string which shall contain the text
representation of the Language, upon function
return. |
|
|
|
| Returns: |
| Upon return sLanguageString should contain the text
name of the Language, such as
"Elvish". |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::AnimateChat( |
CBSTRING sChatString) |
|
| Comments: |
| Stub which allows the Game to perform
silent Animations based upon that which a Character
says. |
| This stub is included for Games which want
to include Chat Animation. Chat Animation is a
mechanism where certain silent Emotes are invoked
automatically by things a Character may say. |
| Players do not have to type in /emote
first in order to invoke Chat Animation. |
| sChatString should be parsed for strings
which might invoke a Chat Animation. |
| For Example: |
| If a Player says.
"No Way." Chat Animation may be invoked
to have the Character shake his head. |
| If a Player types,
"Sure, lead the way." Chat Animation may
be invoked to have the Character give a Thumbs Up
emote. |
| This function provides a Stub where such
Chat Animation can be implemented. |
| Called by CBSlashCommands::ProcessSayTypeCommand(),
CBSlashCommands::ProcessAdvancedChannelCommand(),
CBSlashCommands::OnCommandSay(),
CBSlashCommands::OnCommandGroupChat(),
and CBSlashCommands::OnCommandRaidChat(). |
|
|
| Parameters: |
| sChatString |
| Represents a line of
Text a Player has typed in on certain spoken
type Chat Channels (including Group and
Raid). |
|
|
|
|
|
|
|
| Returns: |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::IsDisplayableFaction( |
int nFactionID) |
|
| Comments: |
| This function should return whether or not a Chat
Message should be displayed based upon the Faction of
the Character and the FactionID in the Chat
Message. |
| For use in Games which support Factions and want to
limit communication between opposing
Factions. |
| Game Developers should implement this function based
upon their Game Design. |
| Primarily for use with PvP type games where Players on
opposing Factions cannot communicate with each
other. |
| The FactionID should be compared
against the Characters FactionID and if they are
opposing then this function should return
CB_FALSE. In such cases ChatBlade shall not
display the Chat Message. |
| This function should return CB_TRUE if messages from
the Faction should be Displayed. |
| In Games with no Faction Filtering this function
should return CB_TRUE. |
| Called by CBChatHandler::IsDisplayableChatMessage(). |
|
|
| Parameters: |
| nFactionID |
| A FactionID of an in
game Faction for which we wish to
determine the displayability of Chat
Messages. |
|
|
|
|
|
|
|
| Returns: |
| CB_FALSE if Chat Messages from the Faction should not be
Displayed. |
| CB_TRUE if Chat Messages from the Faction should be
Displayed. |
|
| |
|
| int |
CBClientImplementation::SendChatMessage( |
CBChatMessage cbChatMessage) |
|
| Comments: |
| Stub function which should pass the Chat Message onto
the Chat Server via the Network. |
| This function should be designed to take cbChatMessage
and pass it to the Network Code for
transmittal to the Chat Server. |
| It is envisioned that each Game Developer might use
their own Networking Back End. As such, the
Networking component of Chat is not included with
ChatBlade. ChatBlade does ship with Sample Network
Code but this is only a Sample and not intended for
Production use. |
| This function should invoke whatever Networking Back
End a Game is actually using. |
| This function is called by CBChatHandler::SendChatMessage()
whenever a Player sends a Chat Message to
others. |
|
|
| Parameters: |
| cbChatMessage |
| A Chat Message that
should be forwarded to the Chat Server via the
Network. |
|
|
|
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::IsIgnorableCharacterName( |
CBSTRING sCharacterName) |
|
| Comments: |
| This function should return whether or not a Character
Name can be Ignored. |
| The Names of CSRs and GMs should be immune from being
Ignored. |
| Game Developers should implement this function to
compare the supplied Name vs. those of known Customer
Service Representatives and GMs. If the Name
matches a CSR or GM this function should return
CB_FALSE. |
| This function should return CB_TRUE for most Player
Character Names. |
| Called by CBIgnoreList::AddCharacter() |
|
|
| Parameters: |
| sCharacterName |
| A name of a Character
that this Player wants to
Ignore. |
|
|
|
|
|
|
|
| Returns: |
| CB_FALSE if the Name supplied is that of a CSR or GM
employee. |
| CB_TRUE if the Name supplied is a normal Player
Character Name. |
|
| |
|
| int |
CBClientImplementation::ChatBubble( |
CBChatMessage cbChatMessage) |
|
| Comments: |
| Stub which allows the Game to display a Chat Bubble over a
Characters head. |
| This stub is included for Games which want
to include Chat Bubbles for Characters in view of the
Player. |
| Not all Chat Channel Messages should have
Chat Bubbles displayed, but the logic is left to the
Game Developer. |
| ChatBlade supports Chat Bubbles by
providing CBChatMessage::GetChatBubbleString()
and by invoking this Stub when an incoming message is
received. |
| Most of the implementation for Chat
Bubbles is left to the Game Developer. |
| This function provides a Stub where Chat
Bubbles may be implemented. |
| Called by CBChatHandler::AddMessageToTextWindowDatas(). |
|
|
| Parameters: |
| cbChatMessage |
| A Chat Message that
has been received by ChatBlade. May or may
not be suitable for display in a Chat
Bubble. |
|
|
|
|
|
|
|
| Returns: |
| CB_ERROR_NOT_IMPLEMENTED |
|
| |
|
| int |
CBClientImplementation::ChatBeep( |
CBChatMessage cbChatMessage) |
|
| Comments: |
| Stub which allows the Game to perform an audio indicator on Incoming Chat. |
| This stub is included for Games which want
to beep when a Player receives a Tell or Group
Chat. |
| Developers should determine which Chat
Channels they want to make sounds for. |
| Preferably different Chat Channels would
have differing sounds. This way a Player could
receive an audio alert for Server messages that sounds
distinct from that of normal Group
Chat. |
| This function provides a Stub where Chat
Beeps can be implemented for incoming
messages. |
| Called by CBChatHandler::OnIncomingChatMessage(). |
|
|
| Parameters: |
| cbChatMessage |
| A Chat Message
received over the wire. |
|
|
|
|
|
|
|
|
|
| |
|
| int |
CBClientImplementation::DebugDisplayChatMessage( |
CBChatMessage cbChatMessage) |
|
| Comments: |
| Stub which allows developers to display the contents of a Chat Message. |
| This stub is included to allow Game
Developers a place in which to call a Debug function
which displays the contents of the latest Chat
Message. |
| Developers may want to wrap this function
in #ifdef DEBUG
directives. |
| Called by CBChatHandler::AddMessageToTextWindowDatas(). |
|
|
| Parameters: |
| cbChatMessage |
| A Chat Message whose
contents we want to display for Debug purposes. |
|
|
|
|
|
|
|
|
|
| |
|
| |