From 0cffdadd33de1fa5d9f249c836e1b233e95a95f7 Mon Sep 17 00:00:00 2001 From: PlatinumSkink Date: Fri, 2 Oct 2015 14:20:53 +0200 Subject: [PATCH] Removed some couts. --- src/game/Core/Renderer.cpp | 2 +- src/game/Game/BallSystem.cpp | 2 ++ src/game/Game/HitLagSystem.cpp | 1 - src/game/Game/LevelSystem.cpp | 4 ++-- src/game/Physics/PhysicsSystem.cpp | 3 ++- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/game/Core/Renderer.cpp b/src/game/Core/Renderer.cpp index d1ccbfc..6abf221 100755 --- a/src/game/Core/Renderer.cpp +++ b/src/game/Core/Renderer.cpp @@ -59,7 +59,7 @@ void dd::Renderer::Initialize() } // Create default camera - m_DefaultCamera = std::unique_ptr(new dd::Camera((float)m_Resolution.Width / m_Resolution.Height, -10.f, 0.01f, 5000.f)); + m_DefaultCamera = std::unique_ptr(new dd::Camera((float)m_Resolution.Width / m_Resolution.Height, 45.f, 0.01f, 5000.f)); m_DefaultCamera->SetPosition(glm::vec3(0, 0, 0)); if (m_Camera == nullptr) { m_Camera = m_DefaultCamera.get(); diff --git a/src/game/Game/BallSystem.cpp b/src/game/Game/BallSystem.cpp index 36435ba..36780de 100644 --- a/src/game/Game/BallSystem.cpp +++ b/src/game/Game/BallSystem.cpp @@ -344,6 +344,8 @@ bool dd::Systems::BallSystem::OnMultiBall(const dd::Events::MultiBall &event) transform1->Velocity = glm::normalize(glm::vec3(5, 5 ,0.f)) * ball1->Speed; transform2->Velocity = glm::normalize(glm::vec3(-5, 5 ,0.f)) * ball2->Speed; + //std::cout << "1: " <Velocity.x << " " << transform1->Velocity.y << std::endl; + //std::cout << "2: " <Velocity.x << " " << transform2->Velocity.y << std::endl; SetMultiBalls(MultiBalls() + 2); diff --git a/src/game/Game/HitLagSystem.cpp b/src/game/Game/HitLagSystem.cpp index da2b25f..7276d05 100644 --- a/src/game/Game/HitLagSystem.cpp +++ b/src/game/Game/HitLagSystem.cpp @@ -16,7 +16,6 @@ void dd::Systems::HitLagSystem::Update(double dt) if (IsPaused()) { if (HitLag()) { SetHitLagTimer(HitLagTimer() += dt); - std::cout << HitLagTimer() << std::endl; if (HitLagDuration() < HitLagTimer()) { SetHitLagTimer(0); SetHitLag(false); diff --git a/src/game/Game/LevelSystem.cpp b/src/game/Game/LevelSystem.cpp index 4e8741d..1e54325 100755 --- a/src/game/Game/LevelSystem.cpp +++ b/src/game/Game/LevelSystem.cpp @@ -265,14 +265,14 @@ bool dd::Systems::LevelSystem::OnScoreEvent(const dd::Events::ScoreEvent &event) bool dd::Systems::LevelSystem::OnMultiBall(const dd::Events::MultiBall &event) { SetMultiBalls(MultiBalls()+2); - std::cout << MultiBalls() << std::endl; + //std::cout << MultiBalls() << std::endl; return true; } bool dd::Systems::LevelSystem::OnMultiBallLost(const dd::Events::MultiBallLost &event) { SetMultiBalls(MultiBalls()-1); - std::cout << MultiBalls() << std::endl; + //std::cout << MultiBalls() << std::endl; return true; } diff --git a/src/game/Physics/PhysicsSystem.cpp b/src/game/Physics/PhysicsSystem.cpp index 805859d..99cc81b 100644 --- a/src/game/Physics/PhysicsSystem.cpp +++ b/src/game/Physics/PhysicsSystem.cpp @@ -121,7 +121,7 @@ void dd::Systems::PhysicsSystem::SyncBodiesWithEntities() auto physicsComponent = m_World->GetComponent(entity); if (physicsComponent->Calculate) { //TODO: REPLACE THIS WITH PARTICLE COLLISION FILTERS - transformComponent->Position.x = transformComponent->Position.x + (transformComponent->Velocity.x * m_TimeStep); + //transformComponent->Position.x = transformComponent->Position.x + (transformComponent->Velocity.x * m_TimeStep); transformComponent->Position.y = transformComponent->Position.y + (transformComponent->Velocity.y * m_TimeStep); } else { b2Vec2 position = body->GetPosition(); @@ -149,6 +149,7 @@ void dd::Systems::PhysicsSystem::Update(double dt) while(m_Accumulator >= m_TimeStep) { + UpdateParticleEmitters(dt); SyncEntitiesWithBodies();