[add] Unified 적용
[add] Glass Render 적용 [fix] MapElement_Static 수정
This commit is contained in:
@@ -86,6 +86,7 @@ void CCamera_Debug::Priority_Update(_float fTimeDelta)
|
||||
|
||||
void CCamera_Debug::Update(_float fTimeDelta)
|
||||
{
|
||||
Describe_Entity();
|
||||
}
|
||||
|
||||
void CCamera_Debug::Late_Update(_float fTimeDelta)
|
||||
@@ -177,6 +178,16 @@ void CCamera_Debug::Free()
|
||||
|
||||
void CCamera_Debug::Describe_Entity()
|
||||
{
|
||||
_float3 vPosition = {};
|
||||
GUI::Begin("PickingPos");
|
||||
if (m_pGameInstance->Key_Pressing(DIK_Y))
|
||||
{
|
||||
if (m_pGameInstance->isPicking(&vPosition))
|
||||
{
|
||||
GUI::InputFloat3("Pos", (float*)&vPosition);
|
||||
}
|
||||
}
|
||||
GUI::End();
|
||||
}
|
||||
|
||||
#endif // _DEBUG
|
||||
|
||||
@@ -108,29 +108,29 @@ CMonster* CInfoInstance::Get_TargetMonster()
|
||||
#pragma endregion
|
||||
|
||||
#pragma region MAP_INFO
|
||||
HRESULT CInfoInstance::Load_MapObjects(const _char* pFilePath)
|
||||
HRESULT CInfoInstance::Load_MapObjects(const _char* pFilePath, const _wchar* pLayerTag)
|
||||
{
|
||||
return m_pMapInfo->Load_MapObjects(pFilePath);
|
||||
return m_pMapInfo->Load_MapObjects(pFilePath, pLayerTag);
|
||||
}
|
||||
HRESULT CInfoInstance::Load_LightElements(const _char* pFilePath)
|
||||
HRESULT CInfoInstance::Load_LightElements(const _char* pFilePath, const _wchar* pLayerTag)
|
||||
{
|
||||
return m_pMapInfo->Load_LightElements(pFilePath);
|
||||
return m_pMapInfo->Load_LightElements(pFilePath, pLayerTag);
|
||||
}
|
||||
HRESULT CInfoInstance::Load_InteractableElements(const _char* pFileName)
|
||||
HRESULT CInfoInstance::Load_InteractableElements(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
return m_pMapInfo->Load_InteractableElements(pFileName);
|
||||
return m_pMapInfo->Load_InteractableElements(pFileName, pLayerTag);
|
||||
}
|
||||
HRESULT CInfoInstance::Load_WaterElemet(const _char* pFileName)
|
||||
{
|
||||
return m_pMapInfo->Load_WaterElemet(pFileName);
|
||||
}
|
||||
HRESULT CInfoInstance::Load_DoorElemet(const _char* pFileName)
|
||||
HRESULT CInfoInstance::Load_DoorElemet(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
return m_pMapInfo->Load_DoorElemet(pFileName);
|
||||
return m_pMapInfo->Load_DoorElemet(pFileName, pLayerTag);
|
||||
}
|
||||
HRESULT CInfoInstance::Load_ChestElemet(const _char* pFileName)
|
||||
HRESULT CInfoInstance::Load_ChestElemet(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
return m_pMapInfo->Load_ChestElemet(pFileName);
|
||||
return m_pMapInfo->Load_ChestElemet(pFileName, pLayerTag);
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ HRESULT CLand::Initialize(void* pArg)
|
||||
if (FAILED(Ready_Components(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
m_fRaduis = m_pModelCom->Get_Radius();
|
||||
m_fRaduis = 350.f;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -116,9 +116,19 @@ HRESULT CLevel_Field::Render()
|
||||
|
||||
HRESULT CLevel_Field::Ready_Lights()
|
||||
{
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CLight_Main>(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT))) {
|
||||
CLight_Main* pLight = { nullptr };
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CLight_Main>(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT,nullptr, nullptr, &pLight))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
_float4 vDiffuse = _float4(0.3f, 0.3f, 0.3f, 0.f);
|
||||
_float4 vAmbient = _float4(0.12f, 0.12f, 0.12f, 0.f);
|
||||
_float4 vSpecular = _float4(0.05f, 0.05f, 0.05f, 0.f);
|
||||
|
||||
pLight->Get_Component<CLight>()->Set_Color(vDiffuse, vAmbient, vSpecular);
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -169,7 +179,7 @@ HRESULT CLevel_Field::Ready_Background()
|
||||
m_pGameInstance->Set_FogColor(vColor);
|
||||
m_pGameInstance->Set_Fog(10.f, 5.f);
|
||||
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Dungeon_Map_Data");
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Dungeon_Map_Data", LAYER_BACKGROUND);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -237,9 +237,6 @@ HRESULT CLevel_GamePlay::Ready_Background()
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CLand>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Land_Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CUnified>(g_iStaticLevel, NEXT_LEVEL, LAYER_UNIFIED)))
|
||||
return E_FAIL;
|
||||
|
||||
|
||||
// ---------------------------------
|
||||
@@ -269,37 +266,27 @@ HRESULT CLevel_GamePlay::Ready_Background()
|
||||
if(false == isReady_Background)
|
||||
{
|
||||
/* 테스트용 맵 */
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Map1215");
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Map1215", LAYER_HOGSMEADE);
|
||||
}
|
||||
else
|
||||
{
|
||||
#if 진우
|
||||
|
||||
#else
|
||||
/* 전체 맵 */
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Hogsmeade_MapContainer_Data");
|
||||
if (FAILED(Ready_Layer_Hogsmeade()))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Layer_Hogwart()))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Layer_Unified()))
|
||||
return E_FAIL;
|
||||
|
||||
/* 물 오브젝트 */
|
||||
if (FAILED(CInfoInstance::GetInstance()->Load_WaterElemet("Element_Water_Info"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
/* 조명 오브젝트 */
|
||||
CInfoInstance::GetInstance()->Load_LightElements("LightElement");
|
||||
#endif
|
||||
|
||||
/* 상호작용 오브젝트 */
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_Barrel");
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_PostPackage_B");
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_PostPackage_F");
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_TeaShopTable");
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_TeaShopChair");
|
||||
|
||||
/* Doors */
|
||||
CInfoInstance::GetInstance()->Load_DoorElemet("Element_Door_Info");
|
||||
|
||||
/* Chests */
|
||||
CInfoInstance::GetInstance()->Load_ChestElemet("Element_Chest_Info");
|
||||
|
||||
if (FAILED(Ready_IntstanceProp()))
|
||||
return E_FAIL;
|
||||
@@ -308,6 +295,75 @@ HRESULT CLevel_GamePlay::Ready_Background()
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CLevel_GamePlay::Ready_Layer_Hogsmeade()
|
||||
{
|
||||
/* 전체 맵 */
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Hogsmeade_MapContainer_Data", LAYER_HOGSMEADE);
|
||||
|
||||
/* 조명 오브젝트 */
|
||||
CInfoInstance::GetInstance()->Load_LightElements("LightElement", LAYER_HOGSMEADE);
|
||||
|
||||
/* 상호작용 오브젝트 */
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_Barrel", LAYER_HOGSMEADE);
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_PostPackage_B", LAYER_HOGSMEADE);
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_PostPackage_F", LAYER_HOGSMEADE);
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_TeaShopTable", LAYER_HOGSMEADE);
|
||||
CInfoInstance::GetInstance()->Load_InteractableElements("E_INTER_TeaShopChair", LAYER_HOGSMEADE);
|
||||
|
||||
/* Doors */
|
||||
CInfoInstance::GetInstance()->Load_DoorElemet("Element_Door_Info", LAYER_HOGSMEADE);
|
||||
|
||||
/* Chests */
|
||||
CInfoInstance::GetInstance()->Load_ChestElemet("Element_Chest_Info", LAYER_HOGSMEADE);
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CLevel_GamePlay::Ready_Layer_Hogwart()
|
||||
{
|
||||
|
||||
CInfoInstance::GetInstance()->Load_MapObjects("Hogwart_MapContainer_Data", LAYER_HOGWART);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CLevel_GamePlay::Ready_Layer_Unified()
|
||||
{
|
||||
CUnified::UNIFIED_DESC Desc = {};
|
||||
|
||||
/* Hogwart Unified*/
|
||||
Desc.fLodSwitchDistnace = 400.f;
|
||||
Desc.vUnifiedCenterPos = _float4(-250.2f, 17.2f, -500.7f, 1.f);
|
||||
Desc.vPosition = _float3(-291.2f, 17.2f, -474.7f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.srtLayerTag = LAYER_HOGWART;
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HW_HogwartsShell_B"));
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CUnified>(g_iStaticLevel, NEXT_LEVEL, LAYER_UNIFIED, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
Desc.srtModelPrototypeTags.clear();
|
||||
/* Hogwart Unified*/
|
||||
Desc.fLodSwitchDistnace = 500.f;
|
||||
Desc.vUnifiedCenterPos = _float4(62.f, 10.f, 93.f, 1.f);
|
||||
Desc.vPosition = _float3(62.f, 10.f, 93.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.srtLayerTag = LAYER_HOGSMEADE;
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HM_Unified_LOD1_Baked_0"));
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HM_Unified_LOD1_Baked_1"));
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HM_Unified_LOD1_Baked_2"));
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HM_Unified_LOD1_Baked_3"));
|
||||
Desc.srtModelPrototypeTags.push_back(TEXT("Prototype_GameObject_SM_HM_Unified_Streets_LOD1_Merged_0"));
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CUnified>(g_iStaticLevel, NEXT_LEVEL, LAYER_UNIFIED, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CLevel_GamePlay::Ready_IntstanceProp()
|
||||
{
|
||||
CInstancedProp::INSTANCE_PROP_DESC Desc = {};
|
||||
@@ -336,70 +392,70 @@ HRESULT CLevel_GamePlay::Ready_IntstanceProp()
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_HM_OwlPost_Window_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/OwlPost_Window.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
///* WA_Rectangle_Double_A */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_WA_Rectangle_Double_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/Rectangle_Double_A.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
///* WC_Retangle_Double_A */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_WC_Retangle_Double_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/WC_Retangle_Double_A.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
///* WA_Square_Double_C */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_WA_Square_Double_C";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/WA_Square_Double_C.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* Quid_Window_A */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_Quid_Window_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/Quid_Window_A.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* Ollivanders_Box_Window */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_Ollivanders_Box_Window";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/Ollivanders_Box.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* WC_L_DoubleS_A */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_WC_L_DoubleS_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/WC_L_DoubleS_A.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* WC_Round_Double_A */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_WC_Round_Double_A";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/WC_Round_Double_A.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* SM_HM_Door1a */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_HM_Door1a";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/Door1a.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* SM_HM_Door2b */
|
||||
Desc.isShake = false;
|
||||
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_HM_Door2b";
|
||||
Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/Door2b.bin";
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CInstancedProp>(g_iStaticLevel, NEXT_LEVEL, LAYER_HOGSMEADE, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
/* OakTree_TallA */
|
||||
|
||||
@@ -374,7 +374,13 @@ HRESULT CLoader::Loading_For_GamePlay()
|
||||
}
|
||||
{ /* Hogwart LOD */
|
||||
jobMapModels.emplace_back(Deferred_FolderLoad(
|
||||
"../Bin/Resources/Models/MapMesh/Game/Environment/Hogwarts/HogwartsLOD/",
|
||||
"../Bin/Resources/Models/MapMesh/Game/Environment/Hogwarts/HogwartsLOD",
|
||||
".bin", false
|
||||
));
|
||||
}
|
||||
{ /* Hogsmeade LOD */
|
||||
jobMapModels.emplace_back(Deferred_FolderLoad(
|
||||
"../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/HogsmeadeLOD/ProxyAssets",
|
||||
".bin", false
|
||||
));
|
||||
}
|
||||
@@ -635,6 +641,18 @@ HRESULT CLoader::Loading_For_GamePlay()
|
||||
".bin", false
|
||||
));
|
||||
}
|
||||
/* ------------------------------------ HOGWART ------------------------------- */
|
||||
{ /* QuidditchPitch */
|
||||
/* */
|
||||
jobMapModels.emplace_back(Deferred_FolderLoad(
|
||||
"../Bin/Resources/Models/MapMesh/Game/Environment/Hogwarts/SUB_QuidditchPitch/Static_Mesh/KIT_Ext",
|
||||
".bin", false
|
||||
));
|
||||
jobMapModels.emplace_back(Deferred_FolderLoad(
|
||||
"../Bin/Resources/Models/MapMesh/Game/Environment/Hogwarts/SUB_QuidditchPitch/Static_Mesh/Collisions",
|
||||
".bin", false
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ HRESULT CMapElement_Static::Initialize(void* pArg)
|
||||
_float fMaxScale = max(pDesc->vScale.x, pDesc->vScale.y);
|
||||
fMaxScale = max(fMaxScale, pDesc->vScale.z);
|
||||
|
||||
m_fRadius = m_pModelComs[0]->Get_Radius() * fMaxScale;
|
||||
m_fRadius = m_pModelComs[0]->Get_Radius() * fMaxScale * 1.2f;
|
||||
|
||||
ReadyForPhysX();
|
||||
ConvertToPhysX();
|
||||
@@ -62,15 +62,15 @@ void CMapElement_Static::Update(_float fTimeDelta)
|
||||
}
|
||||
|
||||
void CMapElement_Static::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
{/*
|
||||
if (m_pGameInstance->IsIn_WorldFrustum(Get_WorldPostion(), m_fRadius)) {
|
||||
|
||||
m_fCamDepth = XMVectorGetX(XMVector3LengthSq(XMLoadFloat4(m_pGameInstance->Get_CamPosition()) - m_pTransformCom->Get_State(STATE::POSITION)));
|
||||
|
||||
m_iLodIndex = min(m_iMaxLodLevel, (_uint)(m_fCamDepth / (m_fRadius * m_fRadius + 3600.f)));
|
||||
m_iLodIndex = min(m_iMaxLodLevel, (_uint)(m_fCamDepth / (m_fRadius * m_fRadius + 40000.f)));*/
|
||||
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
|
||||
}
|
||||
//}
|
||||
}
|
||||
|
||||
HRESULT CMapElement_Static::Render()
|
||||
|
||||
@@ -25,7 +25,7 @@ void CMapInfo::Update(_float fTimeDelta)
|
||||
Describe_Entity();
|
||||
#endif // _DEBUG
|
||||
|
||||
static _bool s_bConverted = { false };
|
||||
/*static _bool s_bConverted = { false };
|
||||
static _bool s_bReadyToCreate = { false };
|
||||
|
||||
if (true != s_bConverted || true != s_bReadyToCreate) {
|
||||
@@ -55,14 +55,14 @@ void CMapInfo::Update(_float fTimeDelta)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
void CMapInfo::Change_Level()
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_MapObjects(const _char* pFileName)
|
||||
HRESULT CMapInfo::Load_MapObjects(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
tinyxml2::XMLDocument xmlDoc;
|
||||
|
||||
@@ -92,21 +92,21 @@ HRESULT CMapInfo::Load_MapObjects(const _char* pFileName)
|
||||
|
||||
if (0 == iMapContainerType)
|
||||
{
|
||||
Load_BuildingContainer(Container, &pContainerObject);
|
||||
Load_BuildingContainer(Container, &pContainerObject, pLayerTag);
|
||||
}
|
||||
else if (1 == iMapContainerType)
|
||||
{
|
||||
Load_StreetContainer(Container, &pContainerObject);
|
||||
Load_StreetContainer(Container, &pContainerObject, pLayerTag);
|
||||
}
|
||||
else {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(Load_MapRenderObjects(Container, pContainerObject))){
|
||||
if (FAILED(Load_MapRenderObjects(Container, pContainerObject, pLayerTag))){
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(Load_MapCollisionObjects(Container, pContainerObject))){
|
||||
if (FAILED(Load_MapCollisionObjects(Container, pContainerObject, pLayerTag))){
|
||||
return E_FAIL;
|
||||
}
|
||||
}
|
||||
@@ -145,7 +145,7 @@ HRESULT CMapInfo::Load_MapObjects(const _char* pFileName)
|
||||
}
|
||||
|
||||
if (MAPOBJECT_TYPE::ELEMENT_STATIC == eType)
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Static>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Static"), &Desc);
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Static>(g_iStaticLevel, NEXT_LEVEL, pLayerTag, &Desc);
|
||||
/*else if (MAPOBJECT_TYPE::ELEMENT_INTERACT == eType)
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Interactable>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Interact"), &Desc);*/
|
||||
}
|
||||
@@ -153,7 +153,7 @@ HRESULT CMapInfo::Load_MapObjects(const _char* pFileName)
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_BuildingContainer(tinyxml2::XMLElement* Container, CMapContainer** ppContainerObject)
|
||||
HRESULT CMapInfo::Load_BuildingContainer(tinyxml2::XMLElement* Container, CMapContainer** ppContainerObject, const _wchar* pLayerTag)
|
||||
{
|
||||
CBuildingContainer::MAP_CONTAINER_DESC ContainerDesc = {};
|
||||
|
||||
@@ -183,12 +183,12 @@ HRESULT CMapInfo::Load_BuildingContainer(tinyxml2::XMLElement* Container, CMapCo
|
||||
BoundingBox_Max->QueryFloatAttribute("z", &ContainerDesc.vContainerMax.z);
|
||||
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CBuildingContainer>(
|
||||
g_iStaticLevel, ENUM_CLASS(LEVEL::GAMEPLAY), LAYER_BACKGROUND, &ContainerDesc, nullptr, reinterpret_cast<CBuildingContainer**>(ppContainerObject));
|
||||
g_iStaticLevel, ENUM_CLASS(LEVEL::GAMEPLAY), pLayerTag, &ContainerDesc, nullptr, reinterpret_cast<CBuildingContainer**>(ppContainerObject));
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_StreetContainer(tinyxml2::XMLElement* Container, CMapContainer** ppContainerObject)
|
||||
HRESULT CMapInfo::Load_StreetContainer(tinyxml2::XMLElement* Container, CMapContainer** ppContainerObject, const _wchar* pLayerTag)
|
||||
{
|
||||
CMapContainer::MAP_CONTAINER_DESC ContainerDesc = {};
|
||||
|
||||
@@ -208,12 +208,12 @@ HRESULT CMapInfo::Load_StreetContainer(tinyxml2::XMLElement* Container, CMapCont
|
||||
ContainerRotation->QueryFloatAttribute("z", &ContainerDesc.vRotation.z);
|
||||
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CStreetContainer>(
|
||||
g_iStaticLevel, ENUM_CLASS(LEVEL::GAMEPLAY), LAYER_BACKGROUND, &ContainerDesc, nullptr, reinterpret_cast<CStreetContainer**>(ppContainerObject));
|
||||
g_iStaticLevel, ENUM_CLASS(LEVEL::GAMEPLAY), pLayerTag, &ContainerDesc, nullptr, reinterpret_cast<CStreetContainer**>(ppContainerObject));
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_MapRenderObjects(tinyxml2::XMLElement* Container, CMapContainer* pContainerObject)
|
||||
HRESULT CMapInfo::Load_MapRenderObjects(tinyxml2::XMLElement* Container, CMapContainer* pContainerObject, const _wchar* pLayerTag)
|
||||
{
|
||||
#pragma region ADD_PARTOBJECT
|
||||
for (auto* PartObject = Container->FirstChildElement("PartObject"); PartObject; PartObject = PartObject->NextSiblingElement("PartObject"))
|
||||
@@ -265,7 +265,7 @@ HRESULT CMapInfo::Load_MapRenderObjects(tinyxml2::XMLElement* Container, CMapCon
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_MapCollisionObjects(tinyxml2::XMLElement* Container, CMapContainer* pContainerObject)
|
||||
HRESULT CMapInfo::Load_MapCollisionObjects(tinyxml2::XMLElement* Container, CMapContainer* pContainerObject, const _wchar* pLayerTag)
|
||||
{
|
||||
#pragma region ADD_COLLISION
|
||||
for (auto* Collision = Container->FirstChildElement("Collision"); Collision; Collision = Collision->NextSiblingElement("Collision"))
|
||||
@@ -312,7 +312,7 @@ HRESULT CMapInfo::Load_MapCollisionObjects(tinyxml2::XMLElement* Container, CMap
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_LightElements(const _char* pFileName)
|
||||
HRESULT CMapInfo::Load_LightElements(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
tinyxml2::XMLDocument xmlDoc;
|
||||
|
||||
@@ -390,7 +390,7 @@ HRESULT CMapInfo::Load_LightElements(const _char* pFileName)
|
||||
|
||||
Desc.isPow = 0 == iPow ? false : true;
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Light>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Light"), &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Light>(g_iStaticLevel, NEXT_LEVEL, pLayerTag, &Desc)))
|
||||
return E_FAIL;
|
||||
}
|
||||
#ifndef 기무리
|
||||
@@ -400,7 +400,7 @@ HRESULT CMapInfo::Load_LightElements(const _char* pFileName)
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_InteractableElements(const _char* pFileName)
|
||||
HRESULT CMapInfo::Load_InteractableElements(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
tinyxml2::XMLDocument xmlDoc;
|
||||
|
||||
@@ -459,7 +459,7 @@ HRESULT CMapInfo::Load_InteractableElements(const _char* pFileName)
|
||||
LocalTranslation->QueryFloatAttribute("y", &Desc.vBoxLocalPosition.y);
|
||||
LocalTranslation->QueryFloatAttribute("z", &Desc.vBoxLocalPosition.z);
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Interactable>(g_iStaticLevel, NEXT_LEVEL, LAYER_INTERACTABLE, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Interactable>(g_iStaticLevel, NEXT_LEVEL, pLayerTag, &Desc)))
|
||||
return E_FAIL;
|
||||
}
|
||||
//MSG_BOX("Successed to Create Interactalbe Element");
|
||||
@@ -576,7 +576,7 @@ HRESULT CMapInfo::Load_WaterElemet(const _char* pFileName)
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_DoorElemet(const _char* pFileName)
|
||||
HRESULT CMapInfo::Load_DoorElemet(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
tinyxml2::XMLDocument xmlDoc;
|
||||
|
||||
@@ -634,14 +634,14 @@ HRESULT CMapInfo::Load_DoorElemet(const _char* pFileName)
|
||||
//LocalTranslation->QueryFloatAttribute("y", &Desc.vBoxLocalPosition.y);
|
||||
//LocalTranslation->QueryFloatAttribute("z", &Desc.vBoxLocalPosition.z);
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Door>(g_iStaticLevel, NEXT_LEVEL, LAYER_DOOR, &Desc)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Door>(g_iStaticLevel, NEXT_LEVEL, pLayerTag, &Desc)))
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CMapInfo::Load_ChestElemet(const _char* pFileName)
|
||||
HRESULT CMapInfo::Load_ChestElemet(const _char* pFileName, const _wchar* pLayerTag)
|
||||
{
|
||||
tinyxml2::XMLDocument xmlDoc;
|
||||
|
||||
|
||||
@@ -67,6 +67,9 @@ HRESULT CMapObject_Collision::Initialize(void* pArg)
|
||||
|
||||
XMStoreFloat4x4(&m_CombinedWorldMatrix, m_pTransformCom->Get_XMWorldMatrix() * m_pParentTransformCom->Get_XMWorldMatrix());
|
||||
|
||||
ReadyForPhysX();
|
||||
ConvertToPhysX();
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -37,11 +37,10 @@ HRESULT CMapObject_Render::Initialize(void* pArg)
|
||||
//m_ModelPathIndices.push_back((*pDesc->pModelPathIndices)[i]);
|
||||
}
|
||||
|
||||
/*if (_wstring::npos != m_ModelPrototypeTags.front().find(L"Glass"))
|
||||
m_iShaderPass = 12;
|
||||
else*/
|
||||
|
||||
m_iShaderPass = ENUM_CLASS(SHADER_PASS_MESH::DEFAULT);
|
||||
if (_wstring::npos != m_ModelPrototypeTags.front().find(L"Glass"))
|
||||
m_iShaderPass = ENUM_CLASS(SHADER_PASS_MESH::GLASS_CUBE);
|
||||
else
|
||||
m_iShaderPass = ENUM_CLASS(SHADER_PASS_MESH::DEFAULT);
|
||||
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
@@ -83,21 +82,8 @@ void CMapObject_Render::Late_Update(_float fTimeDelta)
|
||||
|
||||
m_iNumMeshe = m_pModelComs[m_iLodIndex]->Get_NumMeshes();
|
||||
|
||||
switch (m_Type)
|
||||
{
|
||||
case MAPOBJECT_RENDER_TYPE::NORMAL:
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
|
||||
Set_Shadow(m_pGameInstance->IsIn_ShadowViewFrustum(XMLoadFloat4((_float4*)&m_CombinedWorldMatrix.m[3][0]), m_fRadius));
|
||||
break;
|
||||
case MAPOBJECT_RENDER_TYPE::GLASS:
|
||||
break;
|
||||
case MAPOBJECT_RENDER_TYPE::DECAL:
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::DECAL, this);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
|
||||
Set_Shadow(m_pGameInstance->IsIn_ShadowViewFrustum(XMLoadFloat4((_float4*)&m_CombinedWorldMatrix.m[3][0]), m_fRadius));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -113,6 +99,17 @@ HRESULT CMapObject_Render::Render()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (20 == m_iShaderPass)
|
||||
{
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_vCamPosition", m_pGameInstance->Get_CamPosition(), sizeof(_float4)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_SRV("g_CubeTexture", m_pDefaultGlassTextureCom->Get_SRV(0))))
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Begin(m_iShaderPass))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
@@ -243,6 +240,11 @@ HRESULT CMapObject_Render::Ready_Components()
|
||||
reinterpret_cast<CComponent**>(&m_pShaderCom))))
|
||||
return E_FAIL;
|
||||
|
||||
/* Com_Texture */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Lake_Cube_D"),
|
||||
reinterpret_cast<CComponent**>(&m_pDefaultGlassTextureCom))))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -297,6 +299,7 @@ void CMapObject_Render::Free()
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pShaderCom);
|
||||
SAFE_RELEASE(m_pDefaultGlassTextureCom);
|
||||
|
||||
for (_uint i = 0; i < m_RigidBodies.size(); ++i) {
|
||||
for (_uint j = 0; j < m_RigidBodies[i].size(); ++j) {
|
||||
|
||||
@@ -77,6 +77,8 @@ HRESULT CStreetContainer::Initialize(void* pArg)
|
||||
m_pTransformCom->Set_Scale(pDesc->vScale);
|
||||
m_pTransformCom->Rotation(XMConvertToRadians(pDesc->vRotation.x), XMConvertToRadians(pDesc->vRotation.y), XMConvertToRadians(pDesc->vRotation.z));
|
||||
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#include "Unified.h"
|
||||
|
||||
#include "GameInstance.h"
|
||||
#include "Layer.h"
|
||||
|
||||
CUnified::CUnified(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CGameObject{ pDevice, pContext }
|
||||
@@ -19,12 +20,23 @@ void CUnified::Priority_Update(_float fTimeDelta)
|
||||
|
||||
void CUnified::Update(_float fTimeDelta)
|
||||
{
|
||||
//Describe_Entity();
|
||||
_float fCamDistance = XMVector3Length(XMLoadFloat4(&m_vUnifiedCenterPos) - XMLoadFloat4(m_pGameInstance->Get_CamPosition())).m128_f32[0];
|
||||
|
||||
if (true == m_isLayerEnable && m_fLodSwitchDistnace <= fCamDistance)
|
||||
{ // LOD 전환
|
||||
m_isLayerEnable = false;
|
||||
m_pGameInstance->Get_Layer(CURRENT_LEVEL, m_srtLayerTag)->Set_LayerEnabled(false);
|
||||
}
|
||||
else if (false == m_isLayerEnable && m_fLodSwitchDistnace > fCamDistance)
|
||||
{ // LOD 해제
|
||||
m_isLayerEnable = true;
|
||||
m_pGameInstance->Get_Layer(CURRENT_LEVEL, m_srtLayerTag)->Set_LayerEnabled(true);
|
||||
}
|
||||
}
|
||||
|
||||
void CUnified::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
if (m_isVisible)
|
||||
if (false == m_isLayerEnable)
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
|
||||
}
|
||||
|
||||
@@ -34,25 +46,29 @@ HRESULT CUnified::Render()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
for (_uint i = 0; i < m_iNumMesh; ++i)
|
||||
for (auto& pModel : m_pModelComs)
|
||||
{
|
||||
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
_uint iNumMeshes = pModel->Get_NumMeshes();
|
||||
for (_uint i = 0; i < iNumMeshes; i++)
|
||||
{
|
||||
if (FAILED(pModel->Bind_Material(i, m_pShaderCom))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_fUsingSurfaceParams", &m_fUsingSurfaceParams, sizeof(_float)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_fUsingSurfaceParams", &m_fUsingSurfaceParams, sizeof(_float)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_vSurfaceColor", &m_vSurfaceColor, sizeof(_float4))))
|
||||
return E_FAIL;
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_vSurfaceColor", &m_vSurfaceColor, sizeof(_float4))))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_MESH::NONMRO)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_MESH::NONMRO)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pModelCom->Render(i))) {
|
||||
return E_FAIL;
|
||||
if (FAILED(pModel->Render(i))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -72,11 +88,17 @@ HRESULT CUnified::Initialize(void* pArg)
|
||||
if (FAILED(Ready_Components(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
m_iNumMesh = m_pModelCom->Get_NumMeshes();
|
||||
UNIFIED_DESC* pDesc = static_cast<UNIFIED_DESC*>(pArg);
|
||||
|
||||
m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(-291.2f, 17.2f, -474.7f, 1.f));
|
||||
m_srtLayerTag = pDesc->srtLayerTag;
|
||||
m_fLodSwitchDistnace = pDesc->fLodSwitchDistnace;
|
||||
m_vUnifiedCenterPos = pDesc->vUnifiedCenterPos;
|
||||
|
||||
m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&pDesc->vPosition), 1.f));
|
||||
m_pTransformCom->Set_Scale(pDesc->vScale);
|
||||
m_pTransformCom->Rotation(XMConvertToRadians(pDesc->vRotation.x), XMConvertToRadians(pDesc->vRotation.y), XMConvertToRadians(pDesc->vRotation.z));
|
||||
m_fUsingSurfaceParams = 2.f / 27.f;
|
||||
m_vSurfaceColor = _float4(1.f, 1.f, 1.f, 1.f);
|
||||
m_vSurfaceColor = _float4(0.f, 0.5f, 1.f, 1.f);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
@@ -86,11 +108,23 @@ HRESULT CUnified::Ready_Components(void* pArg)
|
||||
if (FAILED(__super::Ready_Components(pArg))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
UNIFIED_DESC* pDesc = static_cast<UNIFIED_DESC*>(pArg);
|
||||
|
||||
/* Com_Model */
|
||||
if (FAILED(__super::Add_Asset_Component(NEXT_LEVEL, TEXT("Prototype_GameObject_SM_HW_HogwartsShell_B"),
|
||||
reinterpret_cast<CComponent**>(&m_pModelCom))))
|
||||
return E_FAIL;
|
||||
CModel* pModel = { nullptr };
|
||||
|
||||
_uint iNumModel = (_uint)pDesc->srtModelPrototypeTags.size();
|
||||
m_pModelComs.reserve(iNumModel);
|
||||
|
||||
for (_uint i = 0; i < iNumModel; ++i)
|
||||
{
|
||||
if (FAILED(__super::Add_Asset_Component(NEXT_LEVEL, pDesc->srtModelPrototypeTags[i],
|
||||
reinterpret_cast<CComponent**>(&pModel))))
|
||||
return E_FAIL;
|
||||
|
||||
m_pModelComs.push_back(pModel);
|
||||
}
|
||||
|
||||
/* Com_Shader */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_MESH,
|
||||
@@ -146,13 +180,18 @@ CGameObject* CUnified::Clone(void* pArg, CGameObject* pOwner)
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
void CUnified::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pShaderCom);
|
||||
SAFE_RELEASE(m_pModelCom);
|
||||
|
||||
for (auto& pModelCom : m_pModelComs)
|
||||
SAFE_RELEASE(pModelCom);
|
||||
m_pModelComs.clear();
|
||||
}
|
||||
|
||||
#ifdef _DEBUG
|
||||
void CUnified::Describe_Entity()
|
||||
{
|
||||
|
||||
@@ -45,6 +45,8 @@ namespace Client {
|
||||
#define LAYER_SKYBOX TEXT("Layer_SkyBox")
|
||||
#define LAYER_EDITOR_CAMERA TEXT("Layer_Editor_Camera")
|
||||
#define LAYER_BACKGROUND TEXT("Layer_BackGround")
|
||||
#define LAYER_HOGSMEADE TEXT("Layer_Hogsmeade")
|
||||
#define LAYER_HOGWART TEXT("Layer_Hogwart")
|
||||
#define LAYER_MARKER TEXT("Layer_Marker")
|
||||
#define LAYER_PLAYER TEXT("Layer_Player")
|
||||
#define LAYER_CAMERA TEXT("Layer_Camera")
|
||||
@@ -64,6 +66,7 @@ namespace Client {
|
||||
#define LAYER_DOOR TEXT("Layer_Door")
|
||||
#define LAYER_HIDDEN TEXT("Layer_HIDDEN")
|
||||
|
||||
|
||||
#define LAYER_MAPOBJECTMANAGER TEXT("Layer_MapObjectManager")
|
||||
|
||||
#pragma endregion
|
||||
|
||||
@@ -45,12 +45,12 @@ DECLARE_SINGLETON(CInfoInstance)
|
||||
class CMonster* Get_TargetMonster();
|
||||
#pragma endregion
|
||||
#pragma region MAP_INFO
|
||||
HRESULT Load_MapObjects(const _char* pFilePath);
|
||||
HRESULT Load_LightElements(const _char* pFilePath);
|
||||
HRESULT Load_InteractableElements(const _char* pFileName);
|
||||
HRESULT Load_MapObjects(const _char* pFilePath, const _wchar* pLayerTag);
|
||||
HRESULT Load_LightElements(const _char* pFilePath, const _wchar* pLayerTag);
|
||||
HRESULT Load_InteractableElements(const _char* pFileName, const _wchar* pLayerTag);
|
||||
HRESULT Load_WaterElemet(const _char* pFileName);
|
||||
HRESULT Load_DoorElemet(const _char* pFileName);
|
||||
HRESULT Load_ChestElemet(const _char* pFileName);
|
||||
HRESULT Load_DoorElemet(const _char* pFileName, const _wchar* pLayerTag);
|
||||
HRESULT Load_ChestElemet(const _char* pFileName, const _wchar* pLayerTag);
|
||||
#pragma endregion
|
||||
#pragma region Spell_INFO
|
||||
HRESULT Load_SpellInfo(const _char* pFilePath);
|
||||
@@ -94,7 +94,7 @@ DECLARE_SINGLETON(CInfoInstance)
|
||||
_int m_eSpell = ENUM_CLASS(SKILL_TYPE::END);
|
||||
|
||||
_float m_fDamage{};
|
||||
UI_STATE m_eUI_State;
|
||||
UI_STATE m_eUI_State = { UI_STATE::END };
|
||||
|
||||
// 임시로 이벤트 1개 만들어 둠
|
||||
multimap<_wstring, function<void(void*)>> UI_Event;
|
||||
|
||||
@@ -24,6 +24,9 @@ class CLevel_GamePlay final : public CLevel
|
||||
HRESULT Initialize(void* pArg);
|
||||
HRESULT Ready_Lights();
|
||||
HRESULT Ready_Background();
|
||||
HRESULT Ready_Layer_Hogsmeade();
|
||||
HRESULT Ready_Layer_Hogwart();
|
||||
HRESULT Ready_Layer_Unified();
|
||||
HRESULT Ready_IntstanceProp();
|
||||
HRESULT Ready_Markers();
|
||||
HRESULT Ready_Layer_UI(const _wstring& strLayerTag);
|
||||
|
||||
@@ -17,16 +17,16 @@ class CMapInfo final : public CBase
|
||||
public:
|
||||
void Update(_float fTimeDelta);
|
||||
void Change_Level();
|
||||
HRESULT Load_MapObjects(const _char* pFilePath);
|
||||
HRESULT Load_BuildingContainer(tinyxml2::XMLElement* Container, class CMapContainer** ppContainerObject);
|
||||
HRESULT Load_StreetContainer(tinyxml2::XMLElement* Container, class CMapContainer** ppContainerObject);
|
||||
HRESULT Load_MapRenderObjects(tinyxml2::XMLElement* Container, class CMapContainer* pContainerObject);
|
||||
HRESULT Load_MapCollisionObjects(tinyxml2::XMLElement* Container, class CMapContainer* pContainerObject);
|
||||
HRESULT Load_LightElements(const _char* pFileName);
|
||||
HRESULT Load_InteractableElements(const _char* pFileName);
|
||||
HRESULT Load_MapObjects(const _char* pFilePath, const _wchar* pLayerTag);
|
||||
HRESULT Load_BuildingContainer(tinyxml2::XMLElement* Container, class CMapContainer** ppContainerObject, const _wchar* pLayerTag);
|
||||
HRESULT Load_StreetContainer(tinyxml2::XMLElement* Container, class CMapContainer** ppContainerObject, const _wchar* pLayerTag);
|
||||
HRESULT Load_MapRenderObjects(tinyxml2::XMLElement* Container, class CMapContainer* pContainerObject, const _wchar* pLayerTag);
|
||||
HRESULT Load_MapCollisionObjects(tinyxml2::XMLElement* Container, class CMapContainer* pContainerObject, const _wchar* pLayerTag);
|
||||
HRESULT Load_LightElements(const _char* pFileName, const _wchar* pLayerTag);
|
||||
HRESULT Load_InteractableElements(const _char* pFileName, const _wchar* pLayerTag);
|
||||
HRESULT Load_WaterElemet(const _char* pFileName);
|
||||
HRESULT Load_DoorElemet(const _char* pFileName);
|
||||
HRESULT Load_ChestElemet(const _char* pFileName);
|
||||
HRESULT Load_DoorElemet(const _char* pFileName, const _wchar* pLayerTag);
|
||||
HRESULT Load_ChestElemet(const _char* pFileName, const _wchar* pLayerTag);
|
||||
|
||||
private:
|
||||
CGameInstance* m_pGameInstance = { nullptr };
|
||||
|
||||
@@ -17,41 +17,45 @@ class CMapObject_Render final : public CMapPartObject // Render PartObject
|
||||
virtual ~CMapObject_Render() = default;
|
||||
|
||||
public:
|
||||
virtual HRESULT Initialize_Prototype() override;
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
virtual void Priority_Update(_float fTimeDelta) override;
|
||||
virtual void Update(_float fTimeDelta) override;
|
||||
virtual void Late_Update(_float fTimeDelta) override;
|
||||
virtual HRESULT Render() override;
|
||||
virtual HRESULT Render_Shadow(SHADOW eType) override;
|
||||
void ReadyForPhysX();
|
||||
void ConvertToPhysX();
|
||||
virtual HRESULT Initialize_Prototype() override;
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
virtual void Priority_Update(_float fTimeDelta) override;
|
||||
virtual void Update(_float fTimeDelta) override;
|
||||
virtual void Late_Update(_float fTimeDelta) override;
|
||||
virtual HRESULT Render() override;
|
||||
virtual HRESULT Render_Shadow(SHADOW eType) override;
|
||||
void ReadyForPhysX();
|
||||
void ConvertToPhysX();
|
||||
|
||||
public:
|
||||
virtual _wstring Get_PrototypeTag(_uint iLodIndex = 0);
|
||||
HRESULT Add_LodModel(const _tchar* pModelPrototypeTag);
|
||||
|
||||
private:
|
||||
MAPOBJECT_RENDER_TYPE m_Type = {};
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
vector<CModel*> m_pModelComs;
|
||||
vector<vector<CRigidBody_Static*>> m_RigidBodies;
|
||||
_bool m_bReadyToCreatePhysX = { false };
|
||||
_bool m_bConverted = { false };
|
||||
|
||||
_uint m_iLodIndex = {};
|
||||
_uint m_iShaderPass = {};
|
||||
_uint m_iNumMeshe = {};
|
||||
MAPOBJECT_RENDER_TYPE m_Type = {};
|
||||
RENDER m_eRenderGroup = { RENDER::END };
|
||||
|
||||
|
||||
_float m_fRadius = { 0.f };
|
||||
_bool m_bReadyToCreatePhysX = { false };
|
||||
_bool m_bConverted = { false };
|
||||
_uint m_iLodIndex = {};
|
||||
_uint m_iShaderPass = {};
|
||||
_uint m_iNumMeshe = {};
|
||||
|
||||
_float m_fRadius = { 0.f };
|
||||
|
||||
vector<_wstring> m_ModelPrototypeTags;
|
||||
vector<_uint> m_ModelPathIndices = { };
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
CTexture* m_pDefaultGlassTextureCom = { nullptr };
|
||||
vector<CModel*> m_pModelComs;
|
||||
vector<vector<CRigidBody_Static*>> m_RigidBodies;
|
||||
|
||||
vector<_wstring> m_ModelPrototypeTags;
|
||||
vector<_uint> m_ModelPathIndices = {};
|
||||
|
||||
private:
|
||||
HRESULT Ready_Components();
|
||||
HRESULT Bind_ShaderResources();
|
||||
HRESULT Ready_Components();
|
||||
HRESULT Bind_ShaderResources();
|
||||
|
||||
public:
|
||||
static CMapObject_Render* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
|
||||
@@ -12,6 +12,17 @@ NS_BEGIN(Client)
|
||||
|
||||
class CUnified final : public CGameObject
|
||||
{
|
||||
public:
|
||||
typedef struct tagUnified_Desc
|
||||
{
|
||||
_float fLodSwitchDistnace;
|
||||
_float4 vUnifiedCenterPos;
|
||||
_float3 vPosition;
|
||||
_float3 vRotation;
|
||||
_float3 vScale;
|
||||
_wstring srtLayerTag;
|
||||
vector<_wstring> srtModelPrototypeTags;
|
||||
}UNIFIED_DESC;
|
||||
private:
|
||||
CUnified(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CUnified(const CUnified& rhs);
|
||||
@@ -24,13 +35,22 @@ class CUnified final : public CGameObject
|
||||
virtual HRESULT Render() override;
|
||||
|
||||
private:
|
||||
_bool m_isVisible = { true };
|
||||
_uint m_iNumMesh = {};
|
||||
_bool m_isVisible = { false };
|
||||
_bool m_isLayerEnable = { true };
|
||||
|
||||
_uint m_iMaxLodLevel = {};
|
||||
_uint m_iLodIndex = {};
|
||||
_float m_fUsingSurfaceParams = {};
|
||||
_float m_fLodSwitchDistnace = {};
|
||||
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
CModel* m_pModelCom = { nullptr };
|
||||
|
||||
_float4 m_vUnifiedCenterPos = {};
|
||||
_float4 m_vSurfaceColor = {};
|
||||
|
||||
_wstring m_srtLayerTag;
|
||||
vector<CModel*> m_pModelComs;
|
||||
|
||||
private:
|
||||
virtual HRESULT Initialize_Prototype() override;
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user