Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/network/src/story_entities/story_entity.cc @ 6386

Last change on this file since 6386 was 6386, checked in by patrick, 18 years ago

network: many changes in the StoryEntity and Campaign framework: introduced CampaignData as a container for the data of the Campaign and made some changes in the GameWorlds, which are not yet finished

File size: 1.3 KB
Line 
1
2
3/*
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
15   co-programmer:
16*/
17
18
19#include "story_entity.h"
20
21#include "load_param.h"
22
23using namespace std;
24
25
26/**
27 *  default constructor initializes all needed data
28 */
29StoryEntity::StoryEntity ()
30{
31  this->setClassID(CL_STORY_ENTITY, "StoryEntity");
32
33  this->isInit = false;
34  this->isPaused = false;
35  this->isRunning = false;
36
37  this->storyID = -1;
38  this->nextStoryID = WORLD_ID_GAMEEND;
39}
40
41
42/**
43 *  deconstructor
44 */
45StoryEntity::~StoryEntity ()
46{}
47
48
49/**
50 *  loads the Parameters of a Campaign
51 * @param root: The XML-element to load from
52 */
53void StoryEntity::loadParams(const TiXmlElement* root)
54{
55  static_cast<BaseObject*>(this)->loadParams(root);
56
57  LoadParam(root, "identifier", this, StoryEntity, setStoryID)
58      .describe("A Unique Identifier for this StoryEntity");
59
60  LoadParam(root, "nextid", this, StoryEntity, setNextStoryID)
61      .describe("Sets the ID of the next StoryEntity");
62
63  PRINTF(4)("Loaded StoryEntity specific stuff\n");
64}
Note: See TracBrowser for help on using the repository browser.