Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 2115 in orxonox.OLD for orxonox/branches/chris/src/track.cc


Ignore:
Timestamp:
Jul 13, 2004, 10:49:20 AM (20 years ago)
Author:
chris
Message:

orxonox/branches/chris: Managed to apply all that rotating and translating so that you now actually see the debug player following the track. You can even steer the spaceship via the keys now… unfortunately the coordinate transformations are still a mess. Even though mapping from Locations to Placements seems to work in general, applying the finetuned position and rotation still messes up the whole damn thing…

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/chris/src/track.cc

    r2112 r2115  
    5050       
    5151        camplc->r = trace.r + (trace.a * ((lookat->dist-10.0) / l)) + Vector(0,0,5.0);
    52         camplc->w = Quaternion((trace.r + (trace.a * ((lookat->dist) / l)) - camplc->r), Vector(0,0,1));
     52        camplc->w = Quaternion(Vector(0,0,0) - ((trace.r + (trace.a * ((lookat->dist) / l)) - camplc->r)), Vector(0,0,1));
    5353       
    5454}
     
    6969        Quaternion dir(trace.a, Vector(0,0,1));
    7070       
    71         plc->r = trace.r + (trace.a * ((loc->dist) / l)) + dir.apply(loc->pos);
     71        plc->r = trace.r + (trace.a * ((loc->dist) / l)) + /*dir.apply*/(loc->pos);
    7272        plc->w = dir * loc->rot;
    7373       
Note: See TracChangeset for help on using the changeset viewer.