- Timestamp:
- Dec 4, 2005, 11:04:50 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/spaceshipcontrol/src/world_entities/space_ships/space_ship.cc
r5908 r5909 281 281 /* FIXME: calculating the direction and orthDirection every timeSlice is redundant! save it somewhere */ 282 282 /* calculate the direction in which the craft is heading */ 283 Vector forwardDirection (1.0, 0.0, 0.0); //x283 Vector forwardDirection (1.0, 0.0, 0.0) ; //x 284 284 //direction = this->absDirection.apply (direction); 285 Vector rightDirection (0.0, 0.0, 0.1); // y285 Vector rightDirection (0.0, 0.0, 0.1); //z 286 286 //orthDirection = orthDirection.cross (direction); 287 Vector upDirection (0.0, 1.0, 0.0); //z287 Vector upDirection = (this->getAbsDirV()).getNormalized(); //y 288 288 289 289 … … 292 292 if( this->bUp ) 293 293 { 294 accel += (this->getAbsDirV()).getNormalized();294 accel += forwardDirection; 295 295 //if(travelSpeed <= 5000) travelSpeed += 10; 296 296 } … … 298 298 if( this->bDown ) 299 299 { 300 accel -= (this->getAbsDirV()).getNormalized();300 accel -= forwardDirection; 301 301 //if(travelSpeed >= 10) travelSpeed -= 10; 302 302 }
Note: See TracChangeset
for help on using the changeset viewer.