From: Remi B. <els...@us...> - 2004-06-30 12:08:20
|
Update of /cvsroot/once/oncecode/src/client In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7587/client Modified Files: ocdisplay.cpp ocplrinput.cpp Log Message: Various bug fixes. Index: ocdisplay.cpp =================================================================== RCS file: /cvsroot/once/oncecode/src/client/ocdisplay.cpp,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** ocdisplay.cpp 16 Jun 2004 16:08:10 -0000 1.42 --- ocdisplay.cpp 30 Jun 2004 12:08:07 -0000 1.43 *************** *** 54,57 **** --- 54,58 ---- #include "ocsubscripmgr.h" + #undef CAMERA_POSITION_DEBUG /// *** TERRAIN TEST *** *************** *** 130,136 **** ocID<ocEntity> entity = player->GetAvatar(); iCamera* camera = view->GetCamera(); ! csOrthoTransform transform(camera->GetTransform().GetO2T(), ! entity->GetPosition()); camera->SetTransform(transform); } --- 131,142 ---- ocID<ocEntity> entity = player->GetAvatar(); iCamera* camera = view->GetCamera(); ! csVector3 position = entity->GetPosition(); ! csOrthoTransform transform(camera->GetTransform().GetO2T(), position); camera->SetTransform(transform); + + #ifdef CAMERA_POSITION_DEBUG + printf("Moving camera to: (%f, %f, %f)\n", + position.x, position.y, position.z); + #endif } *************** *** 262,271 **** ocEntity* entity = (ocEntity*) obj; - if (entity == display->player->GetAvatar()) { - display->SetCameraPos(); - } if (entity->GetMesh()) entity->GetMesh()->SetPosition(entity->GetPosition()); } --- 268,277 ---- ocEntity* entity = (ocEntity*) obj; if (entity->GetMesh()) entity->GetMesh()->SetPosition(entity->GetPosition()); + + if (entity == display->player->GetAvatar()) + display->SetCameraPos(); } Index: ocplrinput.cpp =================================================================== RCS file: /cvsroot/once/oncecode/src/client/ocplrinput.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** ocplrinput.cpp 16 Jun 2004 16:08:10 -0000 1.6 --- ocplrinput.cpp 30 Jun 2004 12:08:07 -0000 1.7 *************** *** 31,34 **** --- 31,35 ---- kbd = CS_QUERY_REGISTRY(clientsys->object_reg, iKeyboardDriver); move_time = 0; + rotation_changed = false; rotation_time = 0; y_rotation = 0; |