Last change
on this file since 6828 was
6512,
checked in by bensch, 19 years ago
|
orxonox/trunk: loadParams is now virtual.
ALL THE CLASSES HAVE TO CALL
SuperClass::loadParams(root);
isntead of:
static_cast<SuperClass*>(this)→loadParams(root);
which was quite stupid anyways
|
File size:
1.3 KB
|
Rev | Line | |
---|
[2636] | 1 | |
---|
| 2 | |
---|
[4592] | 3 | /* |
---|
[2636] | 4 | orxonox - the future of 3D-vertical-scrollers |
---|
| 5 | |
---|
| 6 | Copyright (C) 2004 orx |
---|
| 7 | |
---|
| 8 | This program is free software; you can redistribute it and/or modify |
---|
| 9 | it under the terms of the GNU General Public License as published by |
---|
| 10 | the Free Software Foundation; either version 2, or (at your option) |
---|
| 11 | any later version. |
---|
| 12 | |
---|
| 13 | ### File Specific: |
---|
| 14 | main-programmer: Patrick Boenzli |
---|
[4592] | 15 | co-programmer: |
---|
[2636] | 16 | */ |
---|
| 17 | |
---|
| 18 | |
---|
[6424] | 19 | #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD |
---|
| 20 | |
---|
| 21 | |
---|
[2636] | 22 | #include "story_entity.h" |
---|
| 23 | |
---|
[6424] | 24 | #include "load_param.h" |
---|
[2636] | 25 | |
---|
[6424] | 26 | |
---|
[2636] | 27 | using namespace std; |
---|
| 28 | |
---|
| 29 | |
---|
[6424] | 30 | /** |
---|
| 31 | * default constructor initializes all needed data |
---|
| 32 | */ |
---|
[4592] | 33 | StoryEntity::StoryEntity () |
---|
| 34 | { |
---|
[4597] | 35 | this->setClassID(CL_STORY_ENTITY, "StoryEntity"); |
---|
[6424] | 36 | |
---|
[6153] | 37 | this->isInit = false; |
---|
| 38 | this->isPaused = false; |
---|
[6424] | 39 | this->isRunning = false; |
---|
| 40 | |
---|
| 41 | this->storyID = -1; |
---|
| 42 | this->nextStoryID = WORLD_ID_GAMEEND; |
---|
[4592] | 43 | } |
---|
[6153] | 44 | |
---|
[2636] | 45 | |
---|
[4592] | 46 | /** |
---|
[6424] | 47 | * deconstructor |
---|
| 48 | */ |
---|
| 49 | StoryEntity::~StoryEntity () |
---|
| 50 | {} |
---|
[3221] | 51 | |
---|
[2636] | 52 | |
---|
[4592] | 53 | /** |
---|
[6424] | 54 | * loads the Parameters of a Campaign |
---|
| 55 | * @param root: The XML-element to load from |
---|
| 56 | */ |
---|
| 57 | void StoryEntity::loadParams(const TiXmlElement* root) |
---|
[2636] | 58 | { |
---|
[6512] | 59 | BaseObject::loadParams(root); |
---|
[2636] | 60 | |
---|
[6424] | 61 | LoadParam(root, "identifier", this, StoryEntity, setStoryID) |
---|
| 62 | .describe("A Unique Identifier for this StoryEntity"); |
---|
[2636] | 63 | |
---|
[6424] | 64 | LoadParam(root, "nextid", this, StoryEntity, setNextStoryID) |
---|
| 65 | .describe("Sets the ID of the next StoryEntity"); |
---|
[4592] | 66 | |
---|
[6424] | 67 | PRINTF(4)("Loaded StoryEntity specific stuff\n"); |
---|
[2636] | 68 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.