[add] CCT 보정
This commit is contained in:
@@ -25,7 +25,7 @@ int APIENTRY wWinMain(_In_ HINSTANCE hInstance,
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
_CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF);
|
||||
//_CrtSetBreakAlloc(1181);
|
||||
_CrtSetBreakAlloc(45489776);
|
||||
//_CrtSetBreakAlloc(1182);
|
||||
//_CrtSetBreakAlloc(1183);
|
||||
//_CrtSetBreakAlloc(1184);
|
||||
|
||||
@@ -127,7 +127,7 @@
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>cd /d "$(SolutionDir)"
|
||||
call Update_Shaders.bat
|
||||
call Update_Resources.bat
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -154,7 +154,7 @@ call Update_Shaders.bat
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>cd /d "$(SolutionDir)"
|
||||
call Update_Shaders.bat
|
||||
call Update_Resources.bat
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
@@ -232,8 +232,10 @@ void CNomalJap::OnCollision(CGameObject* pOther, void* pDesc)
|
||||
Get_PartObject<CTrailObject>()->Set_Visible(false);
|
||||
Get_PartObject<CTrailObject>()->Get_Component<CTransform>()->Set_State(STATE::POSITION, XMVectorSet(0.f, 0.f, 0.f, 1.f));
|
||||
|
||||
m_pPhysHitBox->Set_Dead();
|
||||
SAFE_RELEASE(m_pPhysHitBox);
|
||||
if (nullptr != m_pPhysHitBox) {
|
||||
m_pPhysHitBox->Set_Dead();
|
||||
SAFE_RELEASE(m_pPhysHitBox);
|
||||
}
|
||||
}
|
||||
|
||||
void CNomalJap::Free()
|
||||
|
||||
@@ -253,7 +253,7 @@ HRESULT CPlayer::Ready_Components()
|
||||
Desc.iSubKind = ENUM_CLASS(COLLIDABLEOBJECT::PLAYER);
|
||||
Desc.pTransform = m_pTransformCom;
|
||||
Desc.eBodyType = ACTOR::CAPSULE;
|
||||
Desc.fContactOffset = 0.1f;
|
||||
Desc.fContactOffset = 0.17f;
|
||||
Desc.fMaterial = { 0.5f, 0.5f, 0.6f };
|
||||
Desc.bAutoStepping = { false };
|
||||
Desc.fStepOffset = { 0.05f };
|
||||
|
||||
@@ -159,7 +159,7 @@ void CCharacter_Controller::Move(_float fTimeDelta)
|
||||
const PSX::PxObstacleContext* pPxObstacles = { nullptr }; // 캐릭터가 충돌해야할 추가적인 장애물 객체?, 닿은 장애물은 캐시된다?
|
||||
|
||||
if (true == m_bGravity) {
|
||||
m_pTransform->AccumulateMomentum(XMVectorSet(0.f, -3.5f * fTimeDelta, 0.f, 0.f));
|
||||
m_pTransform->AccumulateMomentum(XMVectorSet(0.f, -GRAVITY * m_fGravity * fTimeDelta, 0.f, 0.f));
|
||||
}
|
||||
XMStoreFloat3((_float3*)&pxVecMomentum, m_pTransform->Get_CurrentMomentum());
|
||||
|
||||
@@ -372,7 +372,8 @@ void CCharacter_Controller::Describe_Entity()
|
||||
GUIHelpMarker("A capsule is affected by its lower sphere and tends to generate an up vector on steps.\nIn eEASY, the up vector is combined with the step offset, allowing easier climbing; in eCONSTRAINED, the up vector is removed during step detection and only the step offset is used.");
|
||||
}
|
||||
}
|
||||
GUI::Text("%.1f", cosf(m_fSlopeLimit)); GUI::SameLine(); GUI::SliderFloat("m_fSlopeLimit", &m_fSlopeLimit, 0.0f, 1.f);
|
||||
GUI::Text("%.1f", XMConvertToDegrees(acosf(m_fSlopeLimit))); GUI::SameLine(); GUI::SliderFloat("m_fSlopeLimit", &m_fSlopeLimit, 0.0f, 1.f);
|
||||
GUI::SliderFloat("m_fGravity_Multiplier", &m_fGravity, 0.0f, 3.f);
|
||||
if (GUI::SliderFloat3("Volume", (_float*)&vVolume, 0.1f, 10.f, "%.2f")) {
|
||||
Modify_Volume(vVolume);
|
||||
}GUIHelpMarker("Box uses vSize; Capsule uses x->fRadius, y->fHeight.\nThe capsule's fHeight is likely the distance from the lower sphere center to the upper sphere center.");
|
||||
|
||||
@@ -534,16 +534,20 @@ HRESULT CPhysX_Manager::Initialize()
|
||||
m_pMaterials.push_back(m_pPhysics->createMaterial(0.5f, 0.5f, 0.6f));
|
||||
|
||||
// m_pScene->overlap();??????
|
||||
#ifdef EDITOR_PROJECT
|
||||
|
||||
PlaneData.eKind = PHYSX_KIND::BODY_STATIC;
|
||||
PlaneData.iSubKind = UINT_MAX;
|
||||
PlaneData.pOwner = nullptr;
|
||||
PlaneData.pBody = nullptr;
|
||||
if (true == m_bDebugCreatePlane) {
|
||||
PlaneData.eKind = PHYSX_KIND::BODY_STATIC;
|
||||
PlaneData.iSubKind = UINT_MAX;
|
||||
PlaneData.pOwner = nullptr;
|
||||
PlaneData.pBody = nullptr;
|
||||
|
||||
PSX::PxRigidStatic* pGroundPlane = PxCreatePlane(*m_pPhysics, physx::PxPlane(0, 1, 0, 0), *m_pMaterials[ENUM_CLASS(PXMATERIAL::DEFAULT)]);
|
||||
pGroundPlane->userData = &PlaneData;
|
||||
pGroundPlane->setName("PHYSX_MANAGER_PLANE");
|
||||
m_pScene->addActor(*pGroundPlane);;
|
||||
PSX::PxRigidStatic* pGroundPlane = PxCreatePlane(*m_pPhysics, physx::PxPlane(0, 1, 0, 0), *m_pMaterials[ENUM_CLASS(PXMATERIAL::DEFAULT)]);
|
||||
pGroundPlane->userData = &PlaneData;
|
||||
pGroundPlane->setName("PHYSX_MANAGER_PLANE");
|
||||
m_pScene->addActor(*pGroundPlane);
|
||||
}
|
||||
#endif
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
@@ -582,7 +586,7 @@ CPhysX_Manager* CPhysX_Manager::Create(ID3D11Device* pDevice, ID3D11DeviceContex
|
||||
void CPhysX_Manager::Free()
|
||||
{
|
||||
ClearScene();
|
||||
|
||||
|
||||
for (auto& pMeshes : m_TriangleMeshes) {
|
||||
pMeshes.second->release();
|
||||
} m_TriangleMeshes.clear();
|
||||
@@ -591,6 +595,14 @@ void CPhysX_Manager::Free()
|
||||
Safe_Delete(pGeometry.second);
|
||||
} m_TriangleMeshGeometry.clear();
|
||||
|
||||
for (auto& pGeometry : m_HeightFieldGeometry) {
|
||||
Safe_Delete(pGeometry.second);
|
||||
} m_HeightFieldGeometry.clear();
|
||||
|
||||
for (auto& pField : m_HeightFields) {
|
||||
pField.second->release();
|
||||
} m_HeightFields.clear();
|
||||
|
||||
if (nullptr != m_pCookingParam) {
|
||||
Safe_Delete(m_pCookingParam);
|
||||
}
|
||||
|
||||
@@ -69,9 +69,10 @@ class ENGINE_DLL CCharacter_Controller final :
|
||||
private:
|
||||
ACTOR m_eBodyType = { ACTOR::END };
|
||||
PSX::PxController* m_pController = { nullptr };
|
||||
CTransform* m_pTransform = { nullptr };
|
||||
CTransform* m_pTransform = { nullptr };
|
||||
_bool m_bAutoStepping = { false };
|
||||
_float m_fSlopeLimit = { 0.5f/*0~1*/}; // cosf각도, 오르막 경사각 제한. ( 추가설정 필요함 )
|
||||
_float m_fGravity = { 0.129f };
|
||||
_float m_fSlopeLimit = { 0.69f/*0~1*/}; // cosf각도, 오르막 경사각 제한. ( 추가설정 필요함 )
|
||||
PhsXUserData m_tagData = {};
|
||||
|
||||
PSX::PxControllerCollisionFlags m_eBeforeCollisionFlags = {};
|
||||
|
||||
@@ -89,7 +89,13 @@ class CPhysX_Manager final : public CBase
|
||||
map<_wstring, PSX::PxHeightField*> m_HeightFields = {};
|
||||
map<_wstring, PSX::PxHeightFieldGeometry*> m_HeightFieldGeometry = {};
|
||||
|
||||
|
||||
#ifdef EDITOR_PROJECT
|
||||
_bool m_bDebugCreatePlane = { true };
|
||||
PhsXUserData PlaneData = {};
|
||||
#else
|
||||
_bool m_bDebugCreatePlane = { false };
|
||||
#endif // EDITOR_PROJECT
|
||||
|
||||
vector<PSX::PxMaterial*> m_pMaterials = { };
|
||||
_uint m_iNumLevel = {};
|
||||
|
||||
Reference in New Issue
Block a user