Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9915 in orxonox.OLD for branches


Ignore:
Timestamp:
Nov 3, 2006, 10:27:59 AM (18 years ago)
Author:
rennerc
Message:

moved copy constructor from LimitedWidthText to BaseObject

Location:
branches/network/src
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/lib/graphics/importer/md2/md2Model.cc

    r9912 r9915  
    268268/**
    269269 * @brief draws the model: interface for all other classes out in the world
    270  * @todo make it const and virtual
    271  * FIXME
    272270 */
    273271void MD2Model::draw() const
  • branches/network/src/lib/graphics/text_engine/limited_width_text.cc

    r9913 r9915  
    3434}
    3535
    36 
    37 
    38 /**
    39  * copy constructor
    40  * @param lwt create copy of this instance
    41  */
    42 LimitedWidthText::LimitedWidthText( const LimitedWidthText & lwt )
    43 {
    44   this->registerObject(this, LimitedWidthText::_objectList);
    45  
    46   this->_dotedText = lwt._dotedText;
    47   this->_lineWidth = lwt._lineWidth;
    48   this->_lineEnds = lwt._lineEnds;
    49 }
    5036
    5137/**
  • branches/network/src/lib/graphics/text_engine/limited_width_text.h

    r9913 r9915  
    2323
    2424  public:
    25     LimitedWidthText( const LimitedWidthText& lwt );
    2625    LimitedWidthText(const std::string& fontFile = "", unsigned int fontSize = TEXT_DEFAULT_SIZE, float lineWidth = 100.0, DotsPosition dotsPosition = Begin);
    2726
  • branches/network/src/lib/lang/base_object.cc

    r9912 r9915  
    3434  this->registerObject(this, BaseObject::_objectList);
    3535}
     36
     37/**
     38 * copyconstructor
     39 * @param bo instance to copy
     40 */
     41BaseObject::BaseObject( const BaseObject& bo )
     42{
     43  this->className = "BaseObject";
     44  this->objectName = "";
     45  this->xmlElem = NULL;
     46  this->registerObject( this, BaseObject::_objectList);
     47}
     48
    3649
    3750/**
  • branches/network/src/lib/lang/base_object.h

    r9908 r9915  
    3030public:
    3131  BaseObject (const std::string& objectName = "");
     32  BaseObject( const BaseObject& bo );
    3233
    3334  virtual ~BaseObject ();
  • branches/network/src/world_entities/spectator.cc

    r9869 r9915  
    2121
    2222#include "shared_network_data.h"
     23
     24#include "src/world_entities/creatures/fps_player.h"
    2325
    2426#include "class_id_DEPRECATED.h"
     
    7981  registerEvent(KeyMapper::PEV_RIGHT);
    8082  registerEvent(KeyMapper::PEV_FIRE1);
     83  registerEvent(KeyMapper::PEV_JUMP);
    8184  registerEvent(EV_MOUSE_MOTION);
    8285
     
    229232    this->yMouse += event.yRel;
    230233  }
    231 }
    232 
    233 
    234 
    235 
     234  else if( event.type == KeyMapper::PEV_JUMP)
     235  {
     236    //FPSPlayer * fps = new FPSPlayer();
     237    WorldEntity * fps = new WorldEntity();
     238   
     239    fps->setAbsCoor( this->getAbsCoorX(), this->getAbsCoorY(), this->getAbsCoorZ() );
     240    fps->setAbsDir( this->getAbsDir() );
     241    //fps->loadMD2Texture( "doom_guy.png" );
     242    //fps->loadModel( "models/creatures/doom_guy.md2", 10.0f );
     243    fps->loadModel( "models/ships/terran_cruizer.obj" );
     244
     245    //((Playable*)fps)->setPlayDirection(  0, 0, 1, 0 );
     246  }
     247}
     248
     249
     250
     251
Note: See TracChangeset for help on using the changeset viewer.