From b5f1b679b7433caf0eaa40bdbec409244ad94b0b Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Sun, 8 Jul 2012 21:19:16 +0000 Subject: [PATCH] test: minor tweaks to the physics demo. --- test/BtPhysTest.cpp | 2 +- test/PhysicObject.h | 26 +++++++++++++------------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/test/BtPhysTest.cpp b/test/BtPhysTest.cpp index 194cf6da..70149761 100644 --- a/test/BtPhysTest.cpp +++ b/test/BtPhysTest.cpp @@ -243,7 +243,7 @@ void BtPhysTest::TickGame(float seconds) m_simulation->TickContext(seconds); m_camera->SetTarget(vec3(.0f)); - m_camera->SetPosition(vec3(-30.0f, 10.0f, .0f)); + m_camera->SetPosition(vec3(-30.0f, 20.0f, .0f)); #if 0 ///step the simulation diff --git a/test/PhysicObject.h b/test/PhysicObject.h index 22776126..3cce304b 100644 --- a/test/PhysicObject.h +++ b/test/PhysicObject.h @@ -46,12 +46,12 @@ public: int SphereLimit = MeshRand.Count(); - MeshRand << "[sc#add asph16 2 2 2]"; - MeshRand << "[sc#dad asph16 2 2 2]"; - MeshRand << "[sc#dda asph16 2 2 2]"; - MeshRand << "[sc#daa asph16 2 2 2]"; - MeshRand << "[sc#ada asph16 2 2 2]"; - MeshRand << "[sc#aad asph16 2 2 2]"; + MeshRand << "[sc#add asph6 2 2 2]"; + MeshRand << "[sc#dad asph6 2 2 2]"; + MeshRand << "[sc#dda asph6 2 2 2]"; + MeshRand << "[sc#daa asph6 2 2 2]"; + MeshRand << "[sc#ada asph6 2 2 2]"; + MeshRand << "[sc#aad asph6 2 2 2]"; int ConeLimit = MeshRand.Count(); @@ -73,12 +73,12 @@ public: int CapsLimit = MeshRand.Count(); - MeshRand << "[sc#add scb#add asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; - MeshRand << "[sc#dad scb#dad asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; - MeshRand << "[sc#dda scb#dda asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; - MeshRand << "[sc#daa scb#daa asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; - MeshRand << "[sc#ada scb#ada asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; - MeshRand << "[sc#aad scb#aad asph16 2 2 2 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#add scb#add asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#dad scb#dad asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#dda scb#dda asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#daa scb#daa asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#ada scb#ada asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; + MeshRand << "[sc#aad scb#aad asph6 1 1 1 ty-1 my ac16 2 1 1 0 0]"; int RandValue = (int)(lol::RandF() * (MeshRand.Count() - 1)); @@ -87,7 +87,7 @@ public: if (RandValue < SphereLimit) m_physics.SetShapeToBox(BoxSize); else if (RandValue < ConeLimit) - m_physics.SetShapeToSphere(BoxSize.x); + m_physics.SetShapeToSphere(BoxSize.x * 2.f); else if (RandValue < CylLimit) m_physics.SetShapeToCone(BoxSize.x, BoxSize.y); else if (RandValue < CapsLimit)