Planeshift
Classes | Public Member Functions | Public Attributes

NpcDialogMenu Class Reference

Holds the trigger menu, if it exists, for a given location in a dialog. More...

#include <dictionary.h>

List of all members.

Classes

struct  DialogTrigger

Public Member Functions

void Add (NpcDialogMenu *add)
 Adds a the triggers of the NpcDialogMenu to the array of triggers.
void AddTrigger (const csString &menuText, const csString &trigger, psQuest *quest, psQuestPrereqOp *script=NULL)
 Adds a trigger to the menu.
void DeleteAllMenusOfQuest (psQuest *quest)
 Remove the specified quest's menus.
 NpcDialogMenu ()
 Default construtor.
void SetPrerequisiteScript (psQuestPrereqOp *script)
 sets the prerequisite script for all DialogTriggers.
void ShowMenu (Client *client, csTicks delay, gemNPC *npc)
 display the menu on the client.

Public Attributes

csArray< DialogTrigger > triggers
 list of menu items

Detailed Description

Holds the trigger menu, if it exists, for a given location in a dialog.

Definition at line 325 of file dictionary.h.


Constructor & Destructor Documentation

NpcDialogMenu::NpcDialogMenu ( )

Default construtor.


Member Function Documentation

void NpcDialogMenu::Add ( NpcDialogMenu *  add)

Adds a the triggers of the NpcDialogMenu to the array of triggers.

Parameters:
addcontains the triggers to add.
void NpcDialogMenu::AddTrigger ( const csString &  menuText,
const csString &  trigger,
psQuest *  quest,
psQuestPrereqOp *  script = NULL 
)

Adds a trigger to the menu.

Parameters:
menuTextis the text to display in the menu
triggeris the text that the player needs to enter to trigger the menu entry
questthat the trigger refers to
scriptare the quest prerequisites for ???
void NpcDialogMenu::DeleteAllMenusOfQuest ( psQuest *  quest)

Remove the specified quest's menus.

Parameters:
questpointer to the quest to remove
void NpcDialogMenu::SetPrerequisiteScript ( psQuestPrereqOp *  script)

sets the prerequisite script for all DialogTriggers.

The complete triggers array is iterated through and all structs have the prerequisite set to the script.

Parameters:
scriptthe prerequisites that are to be set.
void NpcDialogMenu::ShowMenu ( Client *  client,
csTicks  delay,
gemNPC *  npc 
)

display the menu on the client.

Parameters:
clientto display the menu on
npcis the npc the dialog is conducted with

Member Data Documentation

list of menu items

Definition at line 346 of file dictionary.h.


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