- Timestamp:
- Jan 27, 2007, 12:10:56 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/spectator.cc
r10114 r10401 102 102 registerVar( new SynchronizeableBool( &bBackward, &bBackward, "bBackward", PERMISSION_OWNER ) ); 103 103 registerVar( new SynchronizeableQuaternion( &mouseDir, &mouseDir, "mouseDir", PERMISSION_OWNER ) ); 104 105 this->setPlayDirection(Quaternion(0,Vector(0,1,0)), 0.); 104 106 } 105 107 … … 167 169 void Spectator::tick (float time) 168 170 { 169 Playable::tick( time );171 // Playable::tick( time ); 170 172 171 173 if( ( xMouse != 0 || yMouse != 0 ) && ( !State::isOnline() || this->getOwner() == SharedNetworkData::getInstance()->getHostID() ) ) … … 177 179 angleY -= yMouse; 178 180 179 if ( angleY > 2.05 ) 180 angleY = 2.05; 181 182 if ( angleY < -1.15 ) 183 angleY = -1.15; 181 // if ( angleY > 1.90 ) 182 // angleY = 1.95; 183 // 184 // if ( angleY < -1.07 ) 185 // angleY = -1.07; 186 187 xMouse = yMouse = 0; 184 188 185 189 this->mouseDir = Quaternion( angleX, Vector( 0, 1, 0 ) ) * Quaternion( angleY, Vector( 0, 0, 1 ) ); 186 190 187 xMouse = yMouse = 0; 191 192 188 193 } 189 194 … … 240 245 { 241 246 // FPSPlayer * fps = new FPSPlayer(); 242 //GenericNPC* fps = new GenericNPC();243 WorldEntity* fps = new WorldEntity();244 //WorldEntity * fps = new WorldEntity();245 246 fps->setAbsCoor( this->getAbsCoorX(), this->getAbsCoorY(), this->getAbsCoorZ() );247 fps->setAbsDir( this->getAbsDir() );248 fps->loadMD2Texture( "doom_guy.png" );249 fps->loadModel( "models/creatures/doom_guy.md2", 10.0f );250 fps->toList( OM_GROUP_00);251 //fps->loadModel( "models/ships/terran_cruizer.obj" );252 253 //((Playable*)fps)->setPlayDirection( 0, 0, 1, 0 );254 } 255 } 256 257 258 259 247 // //GenericNPC* fps = new GenericNPC(); 248 // WorldEntity* fps = new WorldEntity(); 249 // //WorldEntity * fps = new WorldEntity(); 250 // 251 // fps->setAbsCoor( this->getAbsCoorX(), this->getAbsCoorY(), this->getAbsCoorZ() ); 252 // fps->setAbsDir( this->getAbsDir() ); 253 // fps->loadMD2Texture( "doom_guy.png" ); 254 // fps->loadModel( "models/creatures/doom_guy.md2", 10.0f ); 255 // fps->toList( OM_GROUP_00); 256 // //fps->loadModel( "models/ships/terran_cruizer.obj" ); 257 258 // ((Playable*)fps)->setPlayDirection( 0, 0, 1, 0 ); 259 } 260 } 261 262 263 264
Note: See TracChangeset
for help on using the changeset viewer.