#include <src/orxonox/objects/quest/CompleteQuest.h>
Public Member Functions | |
CompleteQuest (BaseObject *creator) | |
Constructor. Registers the object. | |
virtual bool | invoke (PlayerInfo *player) |
Invokes the QuestEffect. | |
virtual void | XMLPort (Element &xmlelement, XMLPort::Mode mode) |
Method for creating a CompleteQuest object through XML. | |
virtual | ~CompleteQuest () |
Destructor. |
Creating a CompleteQuest through XML goes as follows:
<CompleteQuest questid="id"> //Where id is a GUID, see http://en.wikipedia.org/wiki/Globally_Unique_Identifier#Basic_structure for more information, and identifies the Quest that should be completed.
orxonox::CompleteQuest::CompleteQuest | ( | BaseObject * | creator | ) |
orxonox::CompleteQuest::~CompleteQuest | ( | ) | [virtual] |
Destructor.
bool orxonox::CompleteQuest::invoke | ( | PlayerInfo * | player | ) | [virtual] |
Invokes the QuestEffect.
player | The player the QuestEffect is invoked on. |
< You know, what we think of NULL-pointers...
Implements orxonox::ChangeQuestStatus.
References orxonox::Quest::complete(), COUT, orxonox::QuestManager::findQuest(), orxonox::Exception::getFullDescription(), orxonox::QuestItem::getId(), orxonox::QuestManager::getInstance(), and orxonox::ChangeQuestStatus::getQuestId().
void orxonox::CompleteQuest::XMLPort | ( | Element & | xmlelement, | |
XMLPort::Mode | mode | |||
) | [virtual] |
Method for creating a CompleteQuest object through XML.
Reimplemented from orxonox::ChangeQuestStatus.
References COUT, orxonox::ChangeQuestStatus::getQuestId(), and SUPER.