diff --git a/Code/Game/GameClient/GameClientState/GameState.cpp b/Code/Game/GameClient/GameClientState/GameState.cpp index 4192779f..7d04edda 100644 --- a/Code/Game/GameClient/GameClientState/GameState.cpp +++ b/Code/Game/GameClient/GameClientState/GameState.cpp @@ -190,45 +190,45 @@ bool GameState::Render() }*/ // RB DEBUG render wire frame - if(this->privData->renderWhireframe) - { - Oyster::Graphics::API::StartRenderWireFrame(); - - Oyster::Math3D::Float4x4 translation = Oyster::Math3D::TranslationMatrix(Float3( 0,132, 20)); - Oyster::Math3D::Float4x4 scale = Oyster::Math3D::ScalingMatrix(Float3( 0.5f, 0.5f, 0.5f)); - Oyster::Math3D::Float4x4 world = translation * scale; - Oyster::Graphics::API::RenderDebugCube( world ); - Oyster::Graphics::API::RenderDebugCube(this->privData->player.getRBWorld()); - - staticObject = this->privData->staticObjects->begin(); - for( ; staticObject != this->privData->staticObjects->end(); ++staticObject ) - { - if( staticObject->second->getBRtype() == RB_Type_Cube) - { - Oyster::Graphics::API::RenderDebugCube( staticObject->second->getRBWorld()); - } - if( staticObject->second->getBRtype() == RB_Type_Sphere) - { - Oyster::Graphics::API::RenderDebugSphere( staticObject->second->getRBWorld()); - } - } - - dynamicObject = this->privData->dynamicObjects->begin(); - for( ; dynamicObject != this->privData->dynamicObjects->end(); ++dynamicObject ) - { - if( dynamicObject->second ) - { - if( dynamicObject->second->getBRtype() == RB_Type_Cube) - { - Oyster::Graphics::API::RenderDebugCube( dynamicObject->second->getRBWorld()); - } - if( dynamicObject->second->getBRtype() == RB_Type_Sphere) - { - Oyster::Graphics::API::RenderDebugSphere( dynamicObject->second->getRBWorld()); - } - } - } - } + //if(this->privData->renderWhireframe) + //{ + // Oyster::Graphics::API::StartRenderWireFrame(); + // + // Oyster::Math3D::Float4x4 translation = Oyster::Math3D::TranslationMatrix(Float3( 0,132, 20)); + // Oyster::Math3D::Float4x4 scale = Oyster::Math3D::ScalingMatrix(Float3( 0.5f, 0.5f, 0.5f)); + // Oyster::Math3D::Float4x4 world = translation * scale; + // Oyster::Graphics::API::RenderDebugCube( world ); + // Oyster::Graphics::API::RenderDebugCube(this->privData->player.getRBWorld()); + // + // staticObject = this->privData->staticObjects->begin(); + // for( ; staticObject != this->privData->staticObjects->end(); ++staticObject ) + // { + // if( staticObject->second->getBRtype() == RB_Type_Cube) + // { + // Oyster::Graphics::API::RenderDebugCube( staticObject->second->getRBWorld()); + // } + // if( staticObject->second->getBRtype() == RB_Type_Sphere) + // { + // Oyster::Graphics::API::RenderDebugSphere( staticObject->second->getRBWorld()); + // } + // } + // + // dynamicObject = this->privData->dynamicObjects->begin(); + // for( ; dynamicObject != this->privData->dynamicObjects->end(); ++dynamicObject ) + // { + // if( dynamicObject->second ) + // { + // if( dynamicObject->second->getBRtype() == RB_Type_Cube) + // { + // Oyster::Graphics::API::RenderDebugCube( dynamicObject->second->getRBWorld()); + // } + // if( dynamicObject->second->getBRtype() == RB_Type_Sphere) + // { + // Oyster::Graphics::API::RenderDebugSphere( dynamicObject->second->getRBWorld()); + // } + // } + // } + //} // !RB DEBUG Oyster::Graphics::API::EndFrame(); diff --git a/Code/Game/GameLogic/CollisionManager.cpp b/Code/Game/GameLogic/CollisionManager.cpp index 6fed6ec2..4c21fc8a 100644 --- a/Code/Game/GameLogic/CollisionManager.cpp +++ b/Code/Game/GameLogic/CollisionManager.cpp @@ -23,7 +23,7 @@ using namespace GameLogic; void Player::PlayerCollision(Oyster::Physics::ICustomBody *rigidBodyPlayer, Oyster::Physics::ICustomBody *obj, Oyster::Math::Float kineticEnergyLoss) { - Player *player = ((Game::PlayerData*)(rigidBodyPlayer->GetCustomTag()))->player; + Player *player = ((Player*)(rigidBodyPlayer->GetCustomTag())); Object *realObj = (Object*)obj->GetCustomTag(); //needs to be changed? switch (realObj->GetObjectType())