[6355] | 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 | |
---|
[6386] | 11 | ### File Specific: |
---|
[6355] | 12 | main-programmer: Patrick Boenzli |
---|
| 13 | */ |
---|
| 14 | |
---|
| 15 | #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD |
---|
| 16 | |
---|
[6386] | 17 | #include "dedicated_server_world.h" |
---|
[6355] | 18 | |
---|
| 19 | #include "state.h" |
---|
[6386] | 20 | #include "class_list.h" |
---|
[6355] | 21 | |
---|
[7193] | 22 | #include "util/loading/load_param.h" |
---|
[6355] | 23 | #include "fast_factory.h" |
---|
[7193] | 24 | #include "util/loading/factory.h" |
---|
[6355] | 25 | |
---|
[6386] | 26 | #include "world_entity.h" |
---|
[6355] | 27 | #include "npcs/npc_test1.h" |
---|
| 28 | |
---|
| 29 | |
---|
[6386] | 30 | using namespace std; |
---|
[6355] | 31 | |
---|
[6386] | 32 | //! This creates a Factory to fabricate a DedicatedServerWorld |
---|
| 33 | CREATE_FACTORY(DedicatedServerWorld, CL_DEDICATED_SERVER_WORLD); |
---|
[6355] | 34 | |
---|
| 35 | |
---|
| 36 | |
---|
[6386] | 37 | DedicatedServerWorld::DedicatedServerWorld(const TiXmlElement* root) |
---|
| 38 | : GameWorld(root) |
---|
[6355] | 39 | { |
---|
[6386] | 40 | this->setClassID(CL_DEDICATED_SERVER_WORLD, "DedicatedServerWorld"); |
---|
| 41 | this->setName("DedicatedServerWorld uninitialized"); |
---|
[6355] | 42 | |
---|
| 43 | this->loadParams(root); |
---|
| 44 | } |
---|
| 45 | |
---|
[6386] | 46 | |
---|
[6355] | 47 | /** |
---|
[6386] | 48 | * remove the DedicatedServerWorld from memory |
---|
[6355] | 49 | * |
---|
| 50 | * delete everything explicitly, that isn't contained in the parenting tree! |
---|
| 51 | * things contained in the tree are deleted automaticaly |
---|
| 52 | */ |
---|
[6386] | 53 | DedicatedServerWorld::~DedicatedServerWorld () |
---|
[6355] | 54 | { |
---|
[6386] | 55 | PRINTF(3)("DedicatedServerWorld::~DedicatedServerWorld() - deleting current world\n"); |
---|
[6355] | 56 | } |
---|
| 57 | |
---|
| 58 | |
---|
| 59 | /** |
---|
[6386] | 60 | * loads the parameters of a DedicatedServerWorld from an XML-element |
---|
[6355] | 61 | * @param root the XML-element to load from |
---|
| 62 | */ |
---|
[6386] | 63 | void DedicatedServerWorld::loadParams(const TiXmlElement* root) |
---|
[6355] | 64 | { |
---|
[6512] | 65 | GameWorld::loadParams(root); |
---|
[6355] | 66 | |
---|
[6386] | 67 | PRINTF(4)("Loaded DedicatedServerWorld specific stuff\n"); |
---|
[6355] | 68 | } |
---|
| 69 | |
---|