Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/network/src/story_entities/multi_player_world.cc @ 6404

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

network: working on the last steps, completion is in reach. sadly the world isn't loaded anymore at the moment. continue work later. work flush

File size: 1.6 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*/
14
15#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD
16
17#include "multi_player_world.h"
18#include "multi_player_world_data.h"
19
20#include "factory.h"
21#include "load_param.h"
22
23
24using namespace std;
25
26
27//! This creates a Factory to fabricate a MultiPlayerWorld
28CREATE_FACTORY(MultiPlayerWorld, CL_MULTI_PLAYER_WORLD);
29
30
31MultiPlayerWorld::MultiPlayerWorld(const TiXmlElement* root)
32  : GameWorld(root)
33{
34  this->setClassID(CL_MULTI_PLAYER_WORLD, "MultiPlayerWorld");
35
36  this->multiPlayerWorldData = new MultiPlayerWorldData();
37  this->loadParams(root);
38}
39
40
41/**
42 *  remove the MultiPlayerWorld from memory
43 *
44 *  delete everything explicitly, that isn't contained in the parenting tree!
45 *  things contained in the tree are deleted automaticaly
46 */
47MultiPlayerWorld::~MultiPlayerWorld ()
48{
49  PRINTF(3)("MultiPlayerWorld::~MultiPlayerWorld() - deleting current world\n");
50  if( this->multiPlayerWorldData)
51    delete this->multiPlayerWorldData;
52}
53
54
55/**
56 * loads the parameters of a MultiPlayerWorld from an XML-element
57 * @param root the XML-element to load from
58 */
59void MultiPlayerWorld::loadParams(const TiXmlElement* root)
60{
61  static_cast<GameWorld*>(this)->loadParams(root);
62
63  PRINTF(4)("Creating a MultiPlayerWorld\n");
64}
65
66
67
68
69
70
Note: See TracBrowser for help on using the repository browser.