CEL

Public API Reference

iQuestFactory Struct Reference

A quest factory. More...

#include <tools/questmanager.h>

Inheritance diagram for iQuestFactory:

List of all members.

Public Member Functions

virtual void ClearDefaultParameters ()=0
 Clear all default parameters on this factory.
virtual csPtr< iQuestCreateQuest (iCelParameterBlock *params)=0
 Instantiate a quest from this factory.
virtual iCelSequenceFactoryCreateSequence (const char *name)=0
 Create a new sequence factory in this factory.
virtual iQuestStateFactoryCreateState (const char *name)=0
 Create a new state in this factory.
virtual iCelParameterBlockGetDefaultParameters () const =0
 Get all default parameters.
virtual const char * GetName () const =0
 Get the name of this factory.
virtual iCelSequenceFactoryGetSequence (const char *name)=0
 Get a sequence factory in this factory.
virtual csRef
< iCelSequenceFactoryIterator
GetSequences () const =0
 Get an iterator over all the sequences.
virtual iQuestStateFactoryGetState (const char *name)=0
 Get a state from this factory.
virtual csRef
< iQuestStateFactoryIterator
GetStates () const =0
 Get an iterator over all the states.
virtual bool Load (iDocumentNode *node)=0
 Load this factory from a document node.
virtual bool RemoveSequence (const char *name)=0
 Remove a sequence from this factory.
virtual bool RemoveState (const char *name)=0
 Remove a state from this factory.
virtual bool Save (iDocumentNode *node)=0
 Save this factory to a document node.
virtual void SetDefaultParameter (const char *name, const char *value)=0
 Set a default parameter on this factory.

Detailed Description

A quest factory.

A quest factory is a template to create a quest from. All interfaces ending with 'Factory' are relevant in the concept of a quest factory.

Definition at line 246 of file questmanager.h.


Member Function Documentation

virtual void iQuestFactory::ClearDefaultParameters (  )  [pure virtual]

Clear all default parameters on this factory.

virtual csPtr<iQuest> iQuestFactory::CreateQuest ( iCelParameterBlock params  )  [pure virtual]

Instantiate a quest from this factory.

This instance will have the same structure as this factory but it will be made out of non-factory objects (iQuestTrigger, iQuestReward, ...).

Parameters:
params are the parameters with which this quest is instantiated.
virtual iCelSequenceFactory* iQuestFactory::CreateSequence ( const char *  name  )  [pure virtual]

Create a new sequence factory in this factory.

Return 0 on failure (name already exists).

virtual iQuestStateFactory* iQuestFactory::CreateState ( const char *  name  )  [pure virtual]

Create a new state in this factory.

Return 0 on failure (name already exists).

virtual iCelParameterBlock* iQuestFactory::GetDefaultParameters (  )  const [pure virtual]

Get all default parameters.

virtual const char* iQuestFactory::GetName (  )  const [pure virtual]

Get the name of this factory.

virtual iCelSequenceFactory* iQuestFactory::GetSequence ( const char *  name  )  [pure virtual]

Get a sequence factory in this factory.

Return 0 if the factory doesn't exist.

virtual csRef<iCelSequenceFactoryIterator> iQuestFactory::GetSequences (  )  const [pure virtual]

Get an iterator over all the sequences.

virtual iQuestStateFactory* iQuestFactory::GetState ( const char *  name  )  [pure virtual]

Get a state from this factory.

Return 0 if the state doesn't exist.

virtual csRef<iQuestStateFactoryIterator> iQuestFactory::GetStates (  )  const [pure virtual]

Get an iterator over all the states.

virtual bool iQuestFactory::Load ( iDocumentNode node  )  [pure virtual]

Load this factory from a document node.

Parameters:
node is the <quest> node.
Returns:
false on error (reporter is used to report).
virtual bool iQuestFactory::RemoveSequence ( const char *  name  )  [pure virtual]

Remove a sequence from this factory.

Returns false if the sequence didn't exist.

virtual bool iQuestFactory::RemoveState ( const char *  name  )  [pure virtual]

Remove a state from this factory.

Returns false if the state didn't exist.

virtual bool iQuestFactory::Save ( iDocumentNode node  )  [pure virtual]

Save this factory to a document node.

Parameters:
node is the node of the factory to be filled.
Returns:
false on error (reporter is used to report).
virtual void iQuestFactory::SetDefaultParameter ( const char *  name,
const char *  value 
) [pure virtual]

Set a default parameter on this factory.

If the parameter exists it will be overwritten.


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

Generated for CEL: Crystal Entity Layer 2.1 by doxygen 1.6.1