Changeset 3013 in orxonox.OLD for orxonox/branches/bezierTrack/src/world.cc
- Timestamp:
- Nov 27, 2004, 12:45:12 PM (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/bezierTrack/src/world.cc
r3010 r3013 100 100 // create some path nodes 101 101 this->pathnodes = new Vector[6]; 102 this->pathnodes[0] = Vector(0, 0, 0); 103 this->pathnodes[1] = Vector(10, 5, 0); 104 this->pathnodes[2] = Vector(20, 0, 0); 105 this->pathnodes[3] = Vector(10, 3, 0); 106 this->pathnodes[4] = Vector(50, 0, 0); 107 this->pathnodes[5] = Vector(100, 0, 0); 108 109 // create the tracks 110 this->tracklen = 5; 102 103 this->tracklen = 6; 111 104 this->track = new Track(); 112 for( int i = 0; i < this->tracklen; i++) 113 { 114 // this->track[i] = Track( i, (i+1)%this->tracklen, &this->pathnodes[i], &this->pathnodes[(i+1)%this->tracklen]); 115 track->addPoint(this->pathnodes[i]); 116 } 105 106 track->addPoint (Vector(0, 0, 0)); 107 track->addPoint (Vector(10, 5, 0)); 108 track->addPoint (Vector(20, 0, 0)); 109 track->addPoint (Vector(10, 3, 0)); 110 track->addPoint (Vector(50, 0, 0)); 111 track->addPoint (Vector(0, 0, 0)); 112 117 113 118 114 // create a player … … 130 126 131 127 Placement* plc = new Placement; 132 plc-> r= Vector(100, 10, 10);133 plc-> w= Quaternion();128 plc->pos = Vector(100, 10, 10); 129 plc->rot = Quaternion(); 134 130 WorldEntity* env = new Environment(); 135 131 this->spawn(env, plc); … … 647 643 if( plc == NULL) 648 644 { 649 zeroPlc. r= Vector();650 zeroPlc. w= Quaternion();645 zeroPlc.pos = Vector(); 646 zeroPlc.rot = Quaternion(); 651 647 plc = &zeroPlc; 652 648 }
Note: See TracChangeset
for help on using the changeset viewer.