Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/util/mission_goal.cc @ 9869

Last change on this file since 9869 was 9869, checked in by bensch, 18 years ago

orxonox/trunk: merged the new_class_id branche back to the trunk.
merged with command:
svn merge https://svn.orxonox.net/orxonox/branches/new_class_id trunk -r9683:HEAD
no conflicts… puh..

File size: 1.5 KB
Line 
1/*
2   orxonox - the future of 3D-vertical-scrollers
3
4   Copyright (C) 2004 orx
5
6   This program is free software; you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation; either version 2, or (at your option)
9   any later version.
10
11   ### File Specific:
12   main-programmer: Patrick Boenzli
13   co-programmer: ...
14*/
15
16#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_GAME_RULES
17
18#include "mission_goal.h"
19#include "game_rules.h"
20
21#include "state.h"
22#include "util/loading/load_param.h"
23
24
25
26ObjectListDefinition(MissionGoal);
27/**
28 * standard constructor
29 * @todo this constructor is not jet implemented - do it
30*/
31MissionGoal::MissionGoal (const TiXmlElement* root)
32{
33  this->registerObject(this, MissionGoal::_objectList);
34
35   this->missionState = MS_PASSIVE;
36   // add the mission to the current game rule
37   GameRules* gr = State::getGameRules();
38   if( gr)
39     gr->addMissionGoal(this);
40
41   if( root != NULL)
42     this->loadParams(root);
43}
44
45
46/**
47 * standard deconstructor
48*/
49MissionGoal::~MissionGoal ()
50{
51
52}
53
54/**
55 * loading parameter function: more help on the wiki pages
56 */
57void MissionGoal::loadParams(const TiXmlElement* root)
58{
59  BaseObject::loadParams(root);
60
61  LoadParam(root, "title", this, MissionGoal, setMissionName)
62      .describe("sets the title of the mission");
63  LoadParam(root, "description", this, MissionGoal, setMissionDescription)
64      .describe("sets the mission description");
65}
66
Note: See TracBrowser for help on using the repository browser.