[stash commit]

This commit is contained in:
Chanbin Kim
2025-12-02 10:37:54 +09:00
parent 4d7736a6cd
commit 756c5795a1
11 changed files with 155 additions and 4 deletions
@@ -164,6 +164,8 @@ call Update_Resources.bat
<ClInclude Include="..\Public\Magic_Icon.h" />
<ClInclude Include="..\Public\Magic_Item.h" />
<ClInclude Include="..\Public\Magic_Meter.h" />
<ClInclude Include="..\public\MapElement.h" />
<ClInclude Include="..\public\MapElement_Light.h" />
<ClInclude Include="..\Public\Potion.h" />
<ClInclude Include="..\Public\Protego.h" />
<ClInclude Include="..\Public\Bombard.h" />
@@ -255,6 +257,8 @@ call Update_Resources.bat
<ClCompile Include="..\Private\Magic_Icon.cpp" />
<ClCompile Include="..\Private\Magic_Item.cpp" />
<ClCompile Include="..\Private\Magic_Meter.cpp" />
<ClCompile Include="..\private\MapElement.cpp" />
<ClCompile Include="..\private\MapElement_Light.cpp" />
<ClCompile Include="..\Private\Potion.cpp" />
<ClCompile Include="..\Private\Protego.cpp" />
<ClCompile Include="..\Private\Bombard.cpp" />
@@ -262,6 +262,12 @@
<ClInclude Include="..\Public\Revelio.h">
<Filter>02.GameObjects\Effect\Revelio</Filter>
</ClInclude>
<ClInclude Include="..\public\MapElement.h">
<Filter>02.GameObjects\Environment\03.MapElement</Filter>
</ClInclude>
<ClInclude Include="..\public\MapElement_Light.h">
<Filter>02.GameObjects\Environment\03.MapElement\Light</Filter>
</ClInclude>
<ClInclude Include="..\Public\Troll.h">
<Filter>02.GameObjects\Monster\Troll</Filter>
</ClInclude>
@@ -578,6 +584,12 @@
<Filter Include="04.Mechanic\Skill\Skill_Data">
<UniqueIdentifier>{2bc5b43e-0e24-49d4-95b0-549ad4428201}</UniqueIdentifier>
</Filter>
<Filter Include="02.GameObjects\Environment\03.MapElement">
<UniqueIdentifier>{f3f219aa-034f-4aa2-9f2e-d75d15bd1f4a}</UniqueIdentifier>
</Filter>
<Filter Include="02.GameObjects\Environment\03.MapElement\Light">
<UniqueIdentifier>{71f6a568-488d-4ec1-be79-8fcce6677e27}</UniqueIdentifier>
</Filter>
<Filter Include="02.GameObjects\Monster\Troll">
<UniqueIdentifier>{a1b1f17d-ed4f-4b20-aa8e-c52e693683d4}</UniqueIdentifier>
</Filter>
@@ -838,6 +850,12 @@
<ClCompile Include="..\private\Skill_Data.cpp">
<Filter>04.Mechanic\Skill\Skill_Data</Filter>
</ClCompile>
<ClCompile Include="..\private\MapElement.cpp">
<Filter>02.GameObjects\Environment\03.MapElement</Filter>
</ClCompile>
<ClCompile Include="..\private\MapElement_Light.cpp">
<Filter>02.GameObjects\Environment\03.MapElement\Light</Filter>
</ClCompile>
<ClCompile Include="..\Private\Troll.cpp">
<Filter>02.GameObjects\Monster\Troll</Filter>
</ClCompile>
@@ -25,7 +25,7 @@ void CBuildingContainer::Update(_float fTimeDelta)
{
__super::Update(fTimeDelta);
m_fCamDepth = XMVectorGetX(XMVector3Length(XMLoadFloat4(m_pGameInstance->Get_CamPosition()) - XMLoadFloat3(&m_vExtentWorldPosition)));
m_fCamDepth = XMVectorGetX(XMVector3LengthSq(XMLoadFloat4(m_pGameInstance->Get_CamPosition()) - XMLoadFloat3(&m_vExtentWorldPosition)));
for (auto& pCollisiton : m_ColiisonPartObjects){
pCollisiton->Update(fTimeDelta);
@@ -81,6 +81,10 @@ HRESULT CInfoInstance::Load_MapObjects(const _char* pFilePath)
{
return m_pMapInfo->Load_MapObjects(pFilePath);
}
HRESULT CInfoInstance::Load_LightElements(const _char* pFilePath)
{
return m_pMapInfo->Load_LightElements(pFilePath);
}
#pragma endregion
LEVEL CInfoInstance::Get_RestartLevel()
{
@@ -120,10 +120,13 @@ HRESULT CLevel_GamePlay::Ready_Background()
/* Map Containters */
/* 테스트용 맵 */
// CInfoInstance::GetInstance()->Load_MapObjects("ClientTest");
//CInfoInstance::GetInstance()->Load_MapObjects("ClientTest");
/* 전체 맵 */
CInfoInstance::GetInstance()->Load_MapObjects("Map1129");
/* 조명 오브젝트 */
CInfoInstance::GetInstance()->Load_LightElements("LightElement");
CInstancedProp::INSTANCE_PROP_DESC Desc = {};
+29
View File
@@ -88,6 +88,7 @@
#include "MapObject_Render.h"
#include "MapObject_Collision.h"
#include "InstancedProp.h"
#include "MapElement_Light.h"
#pragma endregion
@@ -636,6 +637,27 @@ HRESULT CLoader::Loading_For_GamePlay()
CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::SINGLE, TEXT("../Bin/Resources/Textures/Terrain/Hogsmeade_AlphaMap.dds"), 0)))) {
return E_FAIL;
}
/* For.Prototype_Component_LightPost_Emissive */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("LightPost_Emissive"),
CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::SINGLE,
TEXT("C:/MeshTable/Game/Environment/Hogsmeade/Common/Textures/LightPosts/T_HM_LampPost_Glass_E.png"), 0)))) {
return E_FAIL;
}
/* For.Prototype_Component_LightPost_Mask */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("LightPost_Mask"),
CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::SINGLE,
TEXT("C:/MeshTable/Game/Environment/Hogsmeade/Common/Textures/LightPosts/T_HM_LampPost_Glass_D.png"), 0)))) {
return E_FAIL;
}
/* For.Prototype_Component_LightPost_Base */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("LightPost_Base"),
CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::SINGLE,
TEXT("C:/MeshTable/Game/Environment/Hogsmeade/Common/Textures/LightPosts/T_HM_LampPost_Glass_Dark_D.png"), 0)))) {
return E_FAIL;
}
#pragma endregion
@@ -1028,6 +1050,8 @@ HRESULT CLoader::Loading_For_GamePlay()
}
}
/* For.Prototype_Component_VIBuffer_Model_Instancel_SM_OakTree_MedA */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_VIBuffer_Model_Instancel_SM_OakTree_MedA"),
CVIBuffer_Model_Instance::Create(m_pDevice, m_pContext,
@@ -1075,6 +1099,11 @@ HRESULT CLoader::Loading_For_GamePlay()
/* For.Prototype_GameObject_CInstancedProp */
if (FAILED(m_pGameInstance->Add_Prototype<CInstancedProp>(g_iStaticLevel, CInstancedProp::Create(m_pDevice, m_pContext))))
return E_FAIL;
/* For.Prototype_GameObject_MapElement_Light */
if (FAILED(m_pGameInstance->Add_Prototype<CMapElement_Light>(g_iStaticLevel, CMapElement_Light::Create(m_pDevice, m_pContext))))
return E_FAIL;
#pragma endregion // MAP PROTOTYPE
#pragma region ACTOR PROTOTYPE
@@ -7,6 +7,7 @@
#include "MAPPartObject.h"
#include "MapObject_Render.h"
#include "MapObject_Collision.h"
#include "MapElement_Light.h"
CMapInfo::CMapInfo()
{
@@ -269,6 +270,96 @@ HRESULT CMapInfo::Load_MapCollisionObjects(tinyxml2::XMLElement* Container, CMap
return S_OK;
}
HRESULT CMapInfo::Load_LightElements(const _char* pFileName)
{
tinyxml2::XMLDocument xmlDoc;
string strPath = "../Bin/Resources/Data/Map/" + string(pFileName) + ".xml";
if ((tinyxml2::XML_SUCCESS != xmlDoc.LoadFile(strPath.c_str())))
return E_FAIL;
tinyxml2::XMLElement* root = xmlDoc.FirstChildElement("MapLightObjects");
if (nullptr == root)
{
MSG_BOX("Failed to Find root");
return S_OK;
}
for (auto* Object = root->FirstChildElement("Object"); Object; Object = Object->NextSiblingElement("Object"))
{
CMapElement_Light::MAPELEMENT_LIGHT_DESC Desc = {};
/* Model Prototypes */
Object->QueryUnsignedAttribute("Lod_Level", &Desc.iMaxLodLevel);
string strTag = {};
for (auto* PrototypeTag = Object->FirstChildElement("PrototypeTag"); PrototypeTag; PrototypeTag = PrototypeTag->NextSiblingElement("PrototypeTag"))
{
strTag = PrototypeTag->GetText();
Desc.ModelPrototypeTags.push_back(CMyTools::ToWstring(strTag));
}
/* Transform */
auto* Position = Object->FirstChildElement("Position");
Position->QueryFloatAttribute("x", &Desc.vPosition.x);
Position->QueryFloatAttribute("y", &Desc.vPosition.y);
Position->QueryFloatAttribute("z", &Desc.vPosition.z);
auto* Scale = Object->FirstChildElement("Scale");
Scale->QueryFloatAttribute("x", &Desc.vScale.x);
Scale->QueryFloatAttribute("y", &Desc.vScale.y);
Scale->QueryFloatAttribute("z", &Desc.vScale.z);
auto* Rotation = Object->FirstChildElement("Rotation");
Rotation->QueryFloatAttribute("x", &Desc.vRotation.x);
Rotation->QueryFloatAttribute("y", &Desc.vRotation.y);
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
/* Light Desc */
auto* Diffuse = Object->FirstChildElement("Diffuse");
Diffuse->QueryFloatAttribute("x", &Desc.vDiffuse.x);
Diffuse->QueryFloatAttribute("y", &Desc.vDiffuse.y);
Diffuse->QueryFloatAttribute("z", &Desc.vDiffuse.z);
auto* Ambient = Object->FirstChildElement("Ambient");
Ambient->QueryFloatAttribute("x", &Desc.vAmbient.x);
Ambient->QueryFloatAttribute("y", &Desc.vAmbient.y);
Ambient->QueryFloatAttribute("z", &Desc.vAmbient.z);
auto* Specular = Object->FirstChildElement("Specular");
Specular->QueryFloatAttribute("x", &Desc.vSpecular.x);
Specular->QueryFloatAttribute("y", &Desc.vSpecular.y);
Specular->QueryFloatAttribute("z", &Desc.vSpecular.z);
auto* PosOffset = Object->FirstChildElement("PosOffset");
PosOffset->QueryFloatAttribute("x", &Desc.vPosOffset.x);
PosOffset->QueryFloatAttribute("y", &Desc.vPosOffset.y);
PosOffset->QueryFloatAttribute("z", &Desc.vPosOffset.z);
auto* Info = Object->FirstChildElement("Info");
Info->QueryUnsignedAttribute("GlassIndex", &Desc.iGlassMeshIndex);
Info->QueryFloatAttribute("BloomStrength", &Desc.fBloomStregth);
Info->QueryFloatAttribute("Range", &Desc.fRange);
_uint iPow = {};
Info->QueryUnsignedAttribute("Pow", &iPow);
Desc.isPow = 0 == iPow ? false : true;
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Light>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Light"), &Desc)))
return E_FAIL;
}
MSG_BOX("Successed to Load File");
return S_OK;
return S_OK;
}
HRESULT CMapInfo::Initialize(ID3D11Device* pDevice, ID3D11DeviceContext* pContex)
{
m_pGameInstance = CGameInstance::GetInstance();
+1 -1
View File
@@ -8,7 +8,7 @@ namespace Client
enum class SHADER_PASS_ANIM { DEFAULT, SHADOW, CAPTURE, BLUR, HAIR, EYELASH, OUTLINE_WRITE, OUTLINE_READ, END };
enum class SHADER_PASS_CUBE { DEFAULT, SHADOW, BLUR, END };
enum class SHADER_PASS_MESH { DEFAULT, SHADOW, SKYBOX, ALPHABLEND, EFFECT_ALPHABLEND, EFFECT_BLEND, EFFECT_ALPHABLEND_CULL, EFFECT_BLEND_CULL, CAPTURE, BLUR, EFFECT_ALPHABLEND_UVMOVE, MAPTOOL, GLASS, OUTLINE_WRITE, OUTLINE_READ, END };
enum class SHADER_PASS_MESH { DEFAULT, SHADOW, SKYBOX, ALPHABLEND, EFFECT_ALPHABLEND, EFFECT_BLEND, EFFECT_ALPHABLEND_CULL, EFFECT_BLEND_CULL, CAPTURE, BLUR, EFFECT_ALPHABLEND_UVMOVE, MAPTOOL, GLASS, OUTLINE_WRITE, OUTLINE_READ, BLOOM, END };
enum class SHADER_PASS_NORTEX { DEFAULT, TERRAIN, ENV_TERRAIN_ANISO, END };
enum class SHADER_PASS_PARTICLE { EXPLOSION, END };
enum class SHADER_PASS_POSTEX { DEFAULT, SCISSOR, UI, UVMOVE, TRAIL, TRAIL_BLUR, TRAIL_BLOOM, END };
@@ -40,6 +40,7 @@ class CInfoInstance final : public CBase
#pragma endregion
#pragma region MAP_INFO
HRESULT Load_MapObjects(const _char* pFilePath);
HRESULT Load_LightElements(const _char* pFilePath);
#pragma endregion
+1
View File
@@ -22,6 +22,7 @@ class CMapInfo final : public CBase
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);
private:
CGameInstance* m_pGameInstance = { nullptr };
@@ -30,7 +30,7 @@ class CMapObject_Render final : public CMapPartObject // Render PartObject
private:
MAPOBJECT_RENDER_TYPE m_Type = {};
CShader* m_pShaderCom = { nullptr };
CShader* m_pShaderCom = { nullptr };
vector<CModel*> m_pModelComs;
_uint m_iLodIndex = {};