Havok includes and libs working, ready for implementation.
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
#include "PrecompiledHeader.h"
|
||||
#include <Common/Base/keycode.cxx>
|
||||
|
||||
// We’re not using anything product specific yet. We undef these so we don’t get the usual
|
||||
// product initialization for the products.
|
||||
#undef HK_FEATURE_PRODUCT_AI
|
||||
//#undef HK_FEATURE_PRODUCT_ANIMATION
|
||||
#undef HK_FEATURE_PRODUCT_ANIMATION
|
||||
#undef HK_FEATURE_PRODUCT_CLOTH
|
||||
#undef HK_FEATURE_PRODUCT_DESTRUCTION_2012
|
||||
#undef HK_FEATURE_PRODUCT_DESTRUCTION
|
||||
@@ -15,8 +15,12 @@
|
||||
#define HK_EXCLUDE_FEATURE_RegisterVersionPatches
|
||||
#define HK_EXCLUDE_FEATURE_RegisterReflectedClasses
|
||||
#define HK_EXCLUDE_FEATURE_MemoryTracker
|
||||
#define HK_CLASSES_FILE "Common/Serialize/classlist/hkClasses.h"
|
||||
#include "Common/Serialize/Util/hkBuiltinTypeRegistry.cxx"
|
||||
#define HK_COMPAT_FILE "Common/Compat/hkCompatVersions.h"
|
||||
// This include generates an initialization function based on the products
|
||||
// and the excluded features.
|
||||
#include <Common/Base/keycode.cxx>
|
||||
#include <Common/Base/Config/hkProductFeatures.cxx>
|
||||
#include "PhysicsSystem.h"
|
||||
#include "World.h"
|
||||
@@ -30,7 +34,7 @@ Systems::PhysicsSystem::PhysicsSystem(World* world) : System(world)
|
||||
hkMemoryRouter* memoryRouter = hkMemoryInitUtil::initDefault(hkMallocAllocator::m_defaultMallocAllocator, finfo);
|
||||
hkBaseSystem::init(memoryRouter, HavokErrorReport);
|
||||
|
||||
{
|
||||
|
||||
hkpWorldCinfo worldInfo;
|
||||
worldInfo.setupSolverInfo(hkpWorldCinfo::SOLVER_TYPE_4ITERS_MEDIUM);
|
||||
worldInfo.m_gravity = hkVector4(0.0f, -9.8f, 0.0f);
|
||||
@@ -39,7 +43,7 @@ Systems::PhysicsSystem::PhysicsSystem(World* world) : System(world)
|
||||
// You must specify the size of the broad phase - objects should not be simulated outside this region
|
||||
worldInfo.setBroadPhaseWorldSize(1000.0f);
|
||||
m_PhysicsWorld = new hkpWorld(worldInfo);
|
||||
}
|
||||
|
||||
// Register all collision agents, even though only box - box will be used in this particular example.
|
||||
// It's important to register collision agents before adding any entities to the world.
|
||||
hkpAgentRegisterUtil::registerAllAgents(m_PhysicsWorld->getCollisionDispatcher());
|
||||
@@ -59,7 +63,7 @@ Systems::PhysicsSystem::PhysicsSystem(World* world) : System(world)
|
||||
|
||||
void Systems::PhysicsSystem::Update(double dt)
|
||||
{
|
||||
m_PhysicsWorld->stepDeltaTime(dt);
|
||||
m_PhysicsWorld->stepDeltaTime(0.0166f);
|
||||
|
||||
// Step the visual debugger
|
||||
StepVisualDebugger();
|
||||
@@ -118,7 +122,7 @@ void Systems::PhysicsSystem::StepVisualDebugger()
|
||||
|
||||
void HK_CALL Systems::PhysicsSystem::HavokErrorReport(const char* msg, void*)
|
||||
{
|
||||
LOG_ERROR("%s", msg);
|
||||
LOG_DEBUG("%s", msg);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
#include "System.h"
|
||||
#include "Components/Transform.h"
|
||||
|
||||
|
||||
|
||||
// Math and base include
|
||||
|
||||
#include <Common/Base/hkBase.h>
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<IncludePath>$(HAVOK_ROOT)\Source;$(BOOST_ROOT);$(SolutionDir)\..\src;$(SolutionDir)\..\libs;$(SolutionDir)\..\libs\glew-1.10.0\include;$(SolutionDir)\..\libs\glfw-3.0.4\include;$(SolutionDir)\..\libs\glm-0.9.5.3;$(SolutionDir)\..\libs\openal-soft-1.15.1\include;$(SolutionDir)\..\libs\bullet-2.82-r2704\src;$(SolutionDir)\..\libs\SOIL\src;$(IncludePath)</IncludePath>
|
||||
<LibraryPath>$(HAVOK_ROOT)\Lib\win32_vs2012_win7\debug;$(BOOST_ROOT)\lib32-msvc-11.0;$(SolutionDir)\..\libs\glew-1.10.0\lib\Debug\Win32;$(SolutionDir)\..\libs\glfw-3.0.4\lib\Debug;$(SolutionDir)\..\libs\openal-soft-1.15.1\lib\Win32\Debug;$(SolutionDir)\..\libs\bullet-2.82-r2704\lib\Debug;$(SolutionDir)\..\libs\SOIL\lib\Debug;$(LibraryPath)</LibraryPath>
|
||||
<LibraryPath>$(HAVOK_ROOT)\Lib\win32_vs2012_win7\debug_dll;$(BOOST_ROOT)\lib32-msvc-11.0;$(SolutionDir)\..\libs\glew-1.10.0\lib\Debug\Win32;$(SolutionDir)\..\libs\glfw-3.0.4\lib\Debug;$(SolutionDir)\..\libs\openal-soft-1.15.1\lib\Win32\Debug;$(SolutionDir)\..\libs\bullet-2.82-r2704\lib\Debug;$(SolutionDir)\..\libs\SOIL\lib\Debug;$(LibraryPath)</LibraryPath>
|
||||
<OutDir>$(SolutionDir)\..\bin\$(Configuration)\</OutDir>
|
||||
<IntDir>$(SolutionDir)\..\obj\$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
@@ -59,11 +59,13 @@
|
||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||
<PrecompiledHeaderFile>PrecompiledHeader.h</PrecompiledHeaderFile>
|
||||
<BrowseInformation>true</BrowseInformation>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
<CompileAsManaged>false</CompileAsManaged>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalDependencies>OpenAL32.lib;opengl32.lib;glu32.lib;SOIL.lib;glew32d.lib;glfw3.lib;hkBase.lib;hkVisualize.lib;hkInternal.lib;hkSerialize.lib;hkGeometryUtilities.lib;hkcdInternal.lib;hkcdCollide.lib;hkpCollide.lib;hkpConstraint.lib;hkpConstraintSolver.lib;hkpDynamics.lib;hkpInternal.lib;hkpUtilities.lib;hkpVehicle.lib;hkSceneData.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>OpenAL32.lib;opengl32.lib;glu32.lib;SOIL.lib;glew32d.lib;glfw3.lib;hkBase.lib;hkVisualize.lib;hkInternal.lib;hkSerialize.lib;hkGeometryUtilities.lib;hkcdInternal.lib;hkcdCollide.lib;hkpCollide.lib;hkpConstraint.lib;hkpConstraintSolver.lib;hkpDynamics.lib;hkpInternal.lib;hkpUtilities.lib;hkSceneData.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalOptions> /ignore:4221</AdditionalOptions>
|
||||
</Link>
|
||||
<CustomBuildStep />
|
||||
@@ -81,12 +83,13 @@
|
||||
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeader>Create</PrecompiledHeader>
|
||||
<PrecompiledHeaderFile>PrecompiledHeader.h</PrecompiledHeaderFile>
|
||||
<EnableEnhancedInstructionSet>StreamingSIMDExtensions2</EnableEnhancedInstructionSet>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalDependencies>OpenAL32.lib;opengl32.lib;glu32.lib;SOIL.lib;glew32.lib;glfw3.lib;hkBase.lib;hkVisualize.lib;hkInternal.lib;hkSerialize.lib;hkGeometryUtilities.lib;hkcdInternal.lib;hkcdCollide.lib;hkpCollide.lib;hkpConstraint.lib;hkpConstraintSolver.lib;hkpDynamics.lib;hkpInternal.lib;hkpUtilities.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>OpenAL32.lib;opengl32.lib;glu32.lib;SOIL.lib;glew32.lib;glfw3.lib;hkaAnimation.lib;hkaInternal.lib;hkaPhysics2012Bridge.lib;hkBase.lib;hkcdCollide.lib;hkcdInternal.lib;hkCompat.lib;hkgBridge.lib;hkgCommon.lib;hkgDx11.lib;hkgDx9s.lib;hkGeometryUtilities.lib;hkgOglES.lib;hkgOglES2.lib;hkgOgls.lib;hkgSoundCommon.lib;hkgSoundXAudio2.lib;hkInternal.lib;hkpCollide.lib;hkpConstraint.lib;hkpConstraintSolver.lib;hkpDynamics.lib;hkpInternal.lib;hkpUtilities.lib;hkpVehicle.lib;hkSceneData.lib;hkSerialize.lib;hkVisualize.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<CustomBuildStep />
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
Reference in New Issue
Block a user