diff --git a/Code/Game/DanBiasGame/GameClientState/GameState.cpp b/Code/Game/DanBiasGame/GameClientState/GameState.cpp index c5fb9d66..7a3f69ef 100644 --- a/Code/Game/DanBiasGame/GameClientState/GameState.cpp +++ b/Code/Game/DanBiasGame/GameClientState/GameState.cpp @@ -95,7 +95,7 @@ bool GameState::LoadModels(std::wstring mapFile) // add box model modelData.world = Oyster::Math3D::Float4x4::identity; - translate = Oyster::Math3D::TranslationMatrix(Oyster::Math::Float3(-5,15,0)); + translate = Oyster::Math3D::TranslationMatrix(Oyster::Math::Float3(4,320,0)); modelData.world = modelData.world * translate; modelData.modelPath = L"box.dan"; modelData.id = 1; diff --git a/Code/Game/GameLogic/CollisionManager.cpp b/Code/Game/GameLogic/CollisionManager.cpp index 76ca668a..af7437da 100644 --- a/Code/Game/GameLogic/CollisionManager.cpp +++ b/Code/Game/GameLogic/CollisionManager.cpp @@ -84,6 +84,13 @@ using namespace GameLogic; Oyster::Math::Float3 pushForce = Oyster::Math::Float4(1,0,0) * (500); Oyster::Physics::ICustomBody::State state; Object *realObj = (Object*)obj->GetCustomTag(); + if(realObj->GetType() == OBJECT_TYPE_BOX) + { + state = obj->GetState(); + state.SetOrientation(Oyster::Math::Float3(1,0.5,1),Oyster::Math::Float3(1,0.5,1)); + obj->SetState(state); + } + if(realObj->GetType() == OBJECT_TYPE_PLAYER || realObj->GetType() == OBJECT_TYPE_WORLD) return; state = obj->GetState(); diff --git a/Code/Game/GameLogic/Game.cpp b/Code/Game/GameLogic/Game.cpp index 6bb4cdc9..063d173f 100644 --- a/Code/Game/GameLogic/Game.cpp +++ b/Code/Game/GameLogic/Game.cpp @@ -138,7 +138,7 @@ bool Game::NewFrame() if(this->players[i]->player) this->players[i]->player->EndFrame(); } - //gameInstance.onMoveFnc(this->level); + gameInstance.onMoveFnc(this->level); return true; } diff --git a/Code/Game/GameLogic/Game_PlayerData.cpp b/Code/Game/GameLogic/Game_PlayerData.cpp index 8dc29957..1b25b4f2 100644 --- a/Code/Game/GameLogic/Game_PlayerData.cpp +++ b/Code/Game/GameLogic/Game_PlayerData.cpp @@ -7,7 +7,7 @@ Game::PlayerData::PlayerData() { //set some stats that are appropriate to a player Oyster::Physics::API::SimpleBodyDescription sbDesc; - sbDesc.centerPosition = Oyster::Math::Float3(0,350,0); + sbDesc.centerPosition = Oyster::Math::Float3(0,320,0); sbDesc.size = Oyster::Math::Float3(4,7,4); sbDesc.mass = 10; //create rigid body diff --git a/Code/Game/GameLogic/Level.cpp b/Code/Game/GameLogic/Level.cpp index 8b2f3bf8..af96536c 100644 --- a/Code/Game/GameLogic/Level.cpp +++ b/Code/Game/GameLogic/Level.cpp @@ -41,7 +41,7 @@ void Level::InitiateLevel(float radius) // add box API::SimpleBodyDescription sbDesc_TestBox; - sbDesc_TestBox.centerPosition = Oyster::Math::Float4(-5,15,0,0); + sbDesc_TestBox.centerPosition = Oyster::Math::Float4(4,320,0,0); sbDesc_TestBox.ignoreGravity = false; sbDesc_TestBox.mass = 10; sbDesc_TestBox.size = Oyster::Math::Float4(0.5f,0.5f,0.5f,0); @@ -52,7 +52,7 @@ void Level::InitiateLevel(float radius) testBox = new DynamicObject(rigidBody_TestBox, OBJECT_TYPE::OBJECT_TYPE_BOX); rigidBody_TestBox->SetCustomTag(testBox); rigidBody_TestBox->GetState(state); - state.ApplyLinearImpulse(Oyster::Math::Float3(0,0,4)); + state.ApplyLinearImpulse(Oyster::Math::Float3(0,0,4000)); rigidBody_TestBox->SetState(state);