Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/mount_points/src/world_entities/mount_point.cc @ 10059

Last change on this file since 10059 was 10059, checked in by patrick, 17 years ago

some renicements

File size: 2.0 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 patrick@orxonox.net
13   co-programmer:
14*/
15#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD_ENTITY
16
17
18#include "executor/executor.h"
19#include "util/loading/factory.h"
20#include "util/loading/load_param.h"
21
22
23#include "mount_point.h"
24#include "debug.h"
25#include "state.h"
26#include "class_id_DEPRECATED.h"
27
28
29ObjectListDefinition(MountPoint);
30CREATE_FACTORY(MountPoint);
31
32
33/**
34 * construct
35 */
36MountPoint::MountPoint ()
37{
38  this->init();
39}
40
41
42/**
43 * constructor
44 * @param root the xml root element
45 */
46MountPoint::MountPoint(const TiXmlElement* root)
47{
48  this->init();
49
50  if( root != NULL)
51    this->loadParams(root);
52}
53
54
55/**
56 * deconstructor
57 */
58MountPoint::~MountPoint ()
59{}
60
61
62/**
63 * initializing function
64 */
65void MountPoint::init()
66{
67  this->registerObject(this, MountPoint::_objectList);
68  this->toList(OM_GROUP_00);
69
70  this->_mount = NULL;
71}
72
73
74/**
75 * loads the Settings of a MD2Creature from an XML-element.
76 * @param root the XML-element to load the MD2Creature's properties from
77 */
78void MountPoint::loadParams(const TiXmlElement* root)
79{
80  WorldEntity::loadParams(root);
81}
82
83
84
85/**
86 * tick
87 * @param time  time passed since the last tick
88 */
89void MountPoint::tick (float time)
90{
91
92
93}
94
95
96/**
97 * draw this entity
98 */
99void MountPoint::draw() const
100{
101
102}
103
104
105
106/**
107 *  function called to draw the mount point itself for debug purposes only
108 */
109void MountPoint::debugDraw() const
110{
111
112}
113
114
115/**
116 * adds an entity to this mount point
117 * @param entity entity to be added
118 */
119void MountPoint::mount(WorldEntity* entity)
120{
121  this->_mount = entity;
122}
123
124
125/**
126 * removes an entity from this mount point
127 */
128void MountPoint::unmount()
129{
130  this->_mount = NULL;
131}
132
Note: See TracBrowser for help on using the repository browser.