@@ -16,6 +16,7 @@ Texture2D g_Texture;
|
||||
float g_fLightRange;
|
||||
float g_fSpotInnerAngle;
|
||||
float g_fSpotOuterAngle;
|
||||
|
||||
vector g_vLightDir;
|
||||
vector g_vLightPos;
|
||||
vector g_vCamPosition;
|
||||
@@ -29,6 +30,7 @@ Texture2D g_ShadowTexture;
|
||||
Texture2D g_PreShadowTexture;
|
||||
Texture2D g_BlurTexture;
|
||||
Texture2D g_BlurXTexture;
|
||||
Texture2D g_BlurWeightTexture;
|
||||
|
||||
|
||||
|
||||
@@ -36,6 +38,8 @@ vector g_vLightDiffuse;
|
||||
vector g_vLightAmbient;
|
||||
vector g_vLightSpecular;
|
||||
|
||||
|
||||
|
||||
struct VS_IN
|
||||
{
|
||||
float3 vPosition : POSITION;
|
||||
@@ -219,13 +223,15 @@ PS_OUT_LIGHT PS_MAIN_SPOT(PS_IN In)
|
||||
return Out;
|
||||
}
|
||||
|
||||
float g_fWeights[13] =
|
||||
float g_fWeights[32] =
|
||||
{
|
||||
0.0090, 0.0218, 0.0448, 0.0784, 0.1169,
|
||||
0.1486, 0.1610, 0.1486, 0.1169, 0.0784,
|
||||
0.0448, 0.0218, 0.0090
|
||||
0.000400, 0.000700, 0.001200, 0.002000, 0.003200, 0.005000, 0.007500, 0.011000,
|
||||
0.015700, 0.021700, 0.029000, 0.037300, 0.046200, 0.055200, 0.063600, 0.070800,
|
||||
0.075900, 0.078500, 0.078500, 0.075900, 0.070800, 0.063600, 0.055200, 0.046200,
|
||||
0.037300, 0.029000, 0.021700, 0.015700, 0.011000, 0.007500, 0.005000, 0.003200
|
||||
};
|
||||
|
||||
|
||||
PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
{
|
||||
PS_OUT_BACKBUFFER Out;
|
||||
@@ -295,15 +301,31 @@ PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
//{
|
||||
// Out.vBackBuffer *= 0.5f;
|
||||
//}
|
||||
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x;
|
||||
vTexcoord.y = In.vTexcoord.y + (float)i / g_vResolution.y;
|
||||
vTexcoord.y = In.vTexcoord.y + (float) i / g_vResolution.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBackBuffer += vColor;
|
||||
@@ -324,12 +346,32 @@ PS_OUT_BLUR_X PS_MAIN_BLUR_X(PS_IN In)
|
||||
float2 vTexcoord;
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//TODO 블러 조절 해보려햇는데 실패함..
|
||||
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x + (float) i / g_vResolution.x;
|
||||
vTexcoord.y = In.vTexcoord.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBlurX = vColor;
|
||||
|
||||
@@ -50,10 +50,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
|
||||
Out.vBackBuffer = float4(0.f, 0.f, 0.f, 0.f);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vDiffuseTexture = g_DiffuseTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(ClampSampler, In.vTexcoord);
|
||||
|
||||
if (0.f == vColorTexture.a)
|
||||
{
|
||||
@@ -66,7 +63,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
switch (iOption)
|
||||
{
|
||||
case 1:
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
break;
|
||||
case 2:
|
||||
Out.vBackBuffer.rgb += vColorTexture.rgb;
|
||||
@@ -78,7 +75,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
Out.vBackBuffer.rgb *= vColorTexture.rgb;
|
||||
break;
|
||||
case 5:
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
@@ -1,500 +1,24 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Land>
|
||||
<Container Name="3Broom_Ext">
|
||||
<Container Name="Key">
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_Awning_Trim</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_Awning_Trim_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_Awning_Trim_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_Awning_Trim_Lod3</PrototypeTag>
|
||||
<PartObject Lod_Level="2" Key_Index="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="5"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2" Key_Index="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels_sign</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels_sign_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrel_stands</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrel_stands_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrel_stands_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_chimneys_B</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_chimneys_B_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_chimneys_B_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_chimneys_B_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_decals</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_decals_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_decals_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_Decals_A</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_Decals_A_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_DoorFrameSide</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_DoorFrameSide_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_DoorFrameSide_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_Dormer_Wood_Slats</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_copper_tops</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_copper_tops_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_copper_tops_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_decals</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_roof_decals_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_side_garden_box</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_side_garden_box_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_side_garden_box_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_stone</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_stone_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_stone_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_trim_stone_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_walls</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_walls_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_walls_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_wood_Corbels</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_wood_Corbels_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_fireplace</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_fireplace_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_fireplace_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_fireplace_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_L</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_L_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_L_Lod2</PrototypeTag>
|
||||
<Position x="-1.05" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_R</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_R_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_R_Lod2</PrototypeTag>
|
||||
<Position x="1.05" y="0" z="0"/>
|
||||
<Scale x="0.99999952" y="1" z="0.99999952"/>
|
||||
<Rotation x="-0" y="180" z="-0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_DoorFrame</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_DoorFrame_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_DoorFrame_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Window_Glass</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Window_Glass_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_B</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_B_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_B_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_B_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
<Container Name="3Broom_Int">
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Bar</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Bar_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Bar_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_floors</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_floors_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_floors_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_A</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_A_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_B</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_B_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_B_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_D</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_stairs_D_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Stairs_Upper_Floors</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Stairs_Upper_Floors_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Stairs_Upper_Floors_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_windows</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_windows_Lod1</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_A</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_A_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_A_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_A_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_B</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_B_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_B_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_B_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="3">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_C</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_C_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_C_Lod2</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_C_Lod3</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_Stairs</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_Stairs_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_Stairs_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2">
|
||||
<PrototypeTag>Prototype_GameObject_SM_Broom_01</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_Broom_01_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_Broom_01_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
<Container Name="3Broom_Ext">
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrel_stands</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrel_stands</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_barrels</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_R</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
<Container Name="">
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Door_L</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_ext_Decals_A</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
<Container Name="HW_GreatHall">
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_FloorMain</PrototypeTag>
|
||||
<Position x="46.552219" y="0" z="38.898628"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_FloorEnd</PrototypeTag>
|
||||
<Position x="46.580196" y="-9.5367432e-07" z="66.865234"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Sconce_Gryffindor</PrototypeTag>
|
||||
<Position x="46.54007" y="0.49999908" z="68.490913"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallIntWindowB</PrototypeTag>
|
||||
<Position x="8.5603905" y="0" z="9.6546278"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallIntWindowB</PrototypeTag>
|
||||
<Position x="4.9284835" y="-9.5367432e-07" z="9.5142498"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallIntWindowC</PrototypeTag>
|
||||
<Position x="12.268991" y="0" z="9.9082165"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallPaneling</PrototypeTag>
|
||||
<Position x="10.824334" y="0" z="5.5098476"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallInt_FlatCeilingB</PrototypeTag>
|
||||
<Position x="4.8808293" y="5.9000006" z="1.8310394"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Sconce_Gryffindor</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Sconce_HufflePuff</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Sconce_Slytherin</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ShadowCaster</PrototypeTag>
|
||||
<Position x="46.50058" y="7.8999949" z="23.989874"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Table</PrototypeTag>
|
||||
<Position x="47.032993" y="0" z="50.447128"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Table</PrototypeTag>
|
||||
<Position x="39.611012" y="4.7683716e-07" z="50.22493"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Table</PrototypeTag>
|
||||
<Position x="55.278839" y="0" z="49.968864"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_TableRunnerGryff</PrototypeTag>
|
||||
<Position x="46.985992" y="9.6857548e-07" z="50.450001"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_TableRunnerHufflePuff</PrototypeTag>
|
||||
<Position x="39.449162" y="0" z="50.225445"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_TableRunnerRaven</PrototypeTag>
|
||||
<Position x="55.339188" y="0" z="49.954151"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallColumnAB</PrototypeTag>
|
||||
<Position x="58.90229" y="0" z="33.904556"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="0" y="89.999985" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallColumnAC</PrototypeTag>
|
||||
<Position x="59.996658" y="0" z="32.924282"/>
|
||||
<Scale x="0.99999988" y="1" z="0.99999988"/>
|
||||
<Rotation x="-0" y="-89.999985" z="-0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallColumnC</PrototypeTag>
|
||||
<Position x="29.750357" y="-4.7683716e-07" z="65.084366"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="-0" y="-70.000008" z="-0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallDoor</PrototypeTag>
|
||||
<Position x="52.069908" y="-4.7683716e-07" z="29.919998"/>
|
||||
<Scale x="0.99999952" y="1" z="0.99999952"/>
|
||||
<Rotation x="-0" y="-179.99998" z="-0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallDoorB</PrototypeTag>
|
||||
<Position x="44.34584" y="0" z="52.525215"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
</Land>
|
||||
|
||||
@@ -1,123 +1,56 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Land>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_Awning_Trim.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Container Name="Key">
|
||||
<Position x="33.378426" y="0" z="36.928886"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Ext_DoorFrameSide.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<PartObject Lod_Level="2" Key_Index="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="5"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
<PartObject Lod_Level="2" Key_Index="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod1</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ArchSmall_Lod2</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</PartObject>
|
||||
</Container>
|
||||
<Object Type="1" Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_FloorMain</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_FloorMain_Lod1</PrototypeTag>
|
||||
<Position x="48.988075" y="0" z="58.2355"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_MERGED_Entry_Base_Stones.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
</Object>
|
||||
<Object Type="1" Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallWindow</PrototypeTag>
|
||||
<Position x="48.56007" y="1.9073486e-06" z="51.822701"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_MERGED_Side_Stone_Steps.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
</Object>
|
||||
<Object Type="1" Lod_Level="1">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallTimbers</PrototypeTag>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_WallTimbers_Lod1</PrototypeTag>
|
||||
<Position x="45.475964" y="1.9073486e-06" z="47.131371"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_MERGED_Winter_Kit_Icicles.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
</Object>
|
||||
<Object Type="1" Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_Table</PrototypeTag>
|
||||
<Position x="39.54475" y="0" z="69.756302"/>
|
||||
<Scale x="0.99999976" y="1" z="0.99999976"/>
|
||||
<Rotation x="0" y="89.999962" z="0"/>
|
||||
</Object>
|
||||
<Object Type="1" Lod_Level="0">
|
||||
<PrototypeTag>Prototype_GameObject_SM_HW_GH_ShadowCaster</PrototypeTag>
|
||||
<Position x="48.098145" y="1.9073486e-06" z="37.810532"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_MERGED_Winter_Kit_Snow.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_A_Decal.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Debris_B_Decal.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Roof_Snow_Winter.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Window_Glass.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Wood_Steps_B.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_Wood_Steps_C.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_A.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_B.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_wood_Stairs.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_windows.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_walls.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
<Model>
|
||||
<PrototypeTag>Prototype_GameObject_SM_HM_3Broom_int_Stairs_Upper_Floors.mo</PrototypeTag>
|
||||
<Position x="0" y="0" z="0"/>
|
||||
<Scale x="1" y="1" z="1"/>
|
||||
<Rotation x="0" y="0" z="0"/>
|
||||
</Model>
|
||||
</Object>
|
||||
</Land>
|
||||
|
||||
|
After Width: | Height: | Size: 6.0 MiB |
|
After Width: | Height: | Size: 14 MiB |
|
After Width: | Height: | Size: 8.2 MiB |
|
After Width: | Height: | Size: 14 MiB |
|
After Width: | Height: | Size: 7.5 MiB |
|
After Width: | Height: | Size: 4.6 MiB |
|
After Width: | Height: | Size: 8.7 MiB |
|
After Width: | Height: | Size: 6.6 MiB |
|
After Width: | Height: | Size: 2.7 MiB |
|
After Width: | Height: | Size: 1.7 MiB |
|
After Width: | Height: | Size: 6.8 MiB |
@@ -16,6 +16,7 @@ Texture2D g_Texture;
|
||||
float g_fLightRange;
|
||||
float g_fSpotInnerAngle;
|
||||
float g_fSpotOuterAngle;
|
||||
|
||||
vector g_vLightDir;
|
||||
vector g_vLightPos;
|
||||
vector g_vCamPosition;
|
||||
@@ -29,6 +30,7 @@ Texture2D g_ShadowTexture;
|
||||
Texture2D g_PreShadowTexture;
|
||||
Texture2D g_BlurTexture;
|
||||
Texture2D g_BlurXTexture;
|
||||
Texture2D g_BlurWeightTexture;
|
||||
|
||||
|
||||
|
||||
@@ -36,6 +38,8 @@ vector g_vLightDiffuse;
|
||||
vector g_vLightAmbient;
|
||||
vector g_vLightSpecular;
|
||||
|
||||
|
||||
|
||||
struct VS_IN
|
||||
{
|
||||
float3 vPosition : POSITION;
|
||||
@@ -219,13 +223,15 @@ PS_OUT_LIGHT PS_MAIN_SPOT(PS_IN In)
|
||||
return Out;
|
||||
}
|
||||
|
||||
float g_fWeights[13] =
|
||||
float g_fWeights[32] =
|
||||
{
|
||||
0.0090, 0.0218, 0.0448, 0.0784, 0.1169,
|
||||
0.1486, 0.1610, 0.1486, 0.1169, 0.0784,
|
||||
0.0448, 0.0218, 0.0090
|
||||
0.000400, 0.000700, 0.001200, 0.002000, 0.003200, 0.005000, 0.007500, 0.011000,
|
||||
0.015700, 0.021700, 0.029000, 0.037300, 0.046200, 0.055200, 0.063600, 0.070800,
|
||||
0.075900, 0.078500, 0.078500, 0.075900, 0.070800, 0.063600, 0.055200, 0.046200,
|
||||
0.037300, 0.029000, 0.021700, 0.015700, 0.011000, 0.007500, 0.005000, 0.003200
|
||||
};
|
||||
|
||||
|
||||
PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
{
|
||||
PS_OUT_BACKBUFFER Out;
|
||||
@@ -295,15 +301,31 @@ PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
//{
|
||||
// Out.vBackBuffer *= 0.5f;
|
||||
//}
|
||||
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x;
|
||||
vTexcoord.y = In.vTexcoord.y + (float)i / g_vResolution.y;
|
||||
vTexcoord.y = In.vTexcoord.y + (float) i / g_vResolution.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBackBuffer += vColor;
|
||||
@@ -324,12 +346,32 @@ PS_OUT_BLUR_X PS_MAIN_BLUR_X(PS_IN In)
|
||||
float2 vTexcoord;
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//TODO 블러 조절 해보려햇는데 실패함..
|
||||
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x + (float) i / g_vResolution.x;
|
||||
vTexcoord.y = In.vTexcoord.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBlurX = vColor;
|
||||
|
||||
@@ -50,10 +50,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
|
||||
Out.vBackBuffer = float4(0.f, 0.f, 0.f, 0.f);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vDiffuseTexture = g_DiffuseTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(ClampSampler, In.vTexcoord);
|
||||
|
||||
if (0.f == vColorTexture.a)
|
||||
{
|
||||
@@ -66,7 +63,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
switch (iOption)
|
||||
{
|
||||
case 1:
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
break;
|
||||
case 2:
|
||||
Out.vBackBuffer.rgb += vColorTexture.rgb;
|
||||
@@ -78,7 +75,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
Out.vBackBuffer.rgb *= vColorTexture.rgb;
|
||||
break;
|
||||
case 5:
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
@@ -304,9 +304,6 @@ PS_OUT PS_MAIN_TEST(PS_IN In)
|
||||
return Out;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
technique11 DefaultTechnique
|
||||
{
|
||||
pass Default
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#include "Engine_Shader_Defines.hlsli"
|
||||
|
||||
float PI = 3.141592;
|
||||
|
||||
struct ParticleValue
|
||||
{
|
||||
@@ -41,10 +42,18 @@ float2 g_vMaskingUVGainAmount;
|
||||
float2 g_vDiffuseNoiseUVGainAmount;
|
||||
float2 g_vMaskNoiseUVGainAmount;
|
||||
|
||||
//
|
||||
int g_iMaskMoveLerpOption;
|
||||
int g_iDiffuseMoveLerpOption;
|
||||
int g_iMaskNoiseMoveLerpOption;
|
||||
int g_iDiffuseNoiseMoveLerpOption;
|
||||
//
|
||||
|
||||
float2 g_vUVCutting;
|
||||
float2 g_vUVMaskCutting;
|
||||
|
||||
|
||||
int g_iBlurWeight; // 블러 강도
|
||||
float g_fBlurIntensity; //블러 세기
|
||||
float g_fNoiseDistortionIntensity; // 노이즈 왜곡 세기
|
||||
|
||||
@@ -62,6 +71,47 @@ bool g_isMaskUVMove;
|
||||
|
||||
float g_fFar;
|
||||
|
||||
float2 SelectLerpUV(float2 fAmount, float _fRatio, int iSelectOption)
|
||||
{
|
||||
if (iSelectOption < 0)
|
||||
return float2(0 , 0);
|
||||
|
||||
float fRatio = _fRatio;
|
||||
switch (iSelectOption)
|
||||
{
|
||||
case 0:
|
||||
fRatio = fRatio; // Linear
|
||||
break;
|
||||
case 1:
|
||||
fRatio = fRatio * fRatio; // EaseInQuad 후반에 속도 증가
|
||||
break;
|
||||
case 2:
|
||||
fRatio = 1 - (1 - fRatio * fRatio); // EaseOutQuad 초반에 속도 증가
|
||||
break;
|
||||
case 3:
|
||||
fRatio = fRatio * fRatio * fRatio; // EaseInCubic 더 강하게 후반 속도 증가
|
||||
break;
|
||||
case 4:
|
||||
fRatio = 1 - (1 - fRatio * fRatio * fRatio); // EaseOutCubic 더 강하게 초반 속도 증가
|
||||
break;
|
||||
case 5:
|
||||
fRatio = 0.5f * (1 - cos(PI * fRatio)); // EaseInOutSin 사인 곡선
|
||||
break;
|
||||
case 6:
|
||||
fRatio = sin(13 * PI * fRatio) * (1 - fRatio) * (1 - fRatio); // EaseInBack 뒤로갔다가 앞으로
|
||||
break;
|
||||
case 7:
|
||||
fRatio = pow(2, 10 * (fRatio - 1)); // Expo 지수 함수
|
||||
break;
|
||||
case 8:
|
||||
fRatio = 1 - pow(1 - fRatio * fRatio, 0.5); // 원형 궤적
|
||||
break;
|
||||
}
|
||||
|
||||
return fAmount * fRatio;
|
||||
|
||||
}
|
||||
|
||||
|
||||
struct VS_IN
|
||||
{
|
||||
@@ -188,14 +238,15 @@ PS_OUT PS_NON_NORMALMAP(PS_IN In)
|
||||
UV = UV_Cutting(In.vTexcoord, g_vUVCutting, int(fAnimIndex.x));
|
||||
|
||||
if (g_isDiffuseUVMove)
|
||||
{
|
||||
UV += (g_vDiffuseUVGainAmount / g_vUVCutting) * (vDiffuseTime.x / vDiffuseTime.y);
|
||||
{
|
||||
UV += SelectLerpUV((g_vDiffuseUVGainAmount / g_vUVCutting), (vDiffuseTime.x / vDiffuseTime.y), g_iDiffuseMoveLerpOption);
|
||||
}
|
||||
|
||||
/* 노이즈 */
|
||||
if (g_isNoise == true)
|
||||
{
|
||||
float2 vNoiseUV = In.vTexcoord + (g_vDiffuseNoiseUVGainAmount) * (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y);
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + SelectLerpUV(g_vDiffuseNoiseUVGainAmount, (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y), g_iDiffuseNoiseMoveLerpOption);
|
||||
|
||||
vMtrlNoise = g_NoiseTexture.Sample(DefaultSampler, vNoiseUV);
|
||||
|
||||
@@ -235,8 +286,8 @@ PS_OUT PS_NON_NORMALMAP(PS_IN In)
|
||||
if (g_isNoise == true)
|
||||
{
|
||||
float2 UV; // 이미지의 UV값
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + (g_vMaskNoiseUVGainAmount) * (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y);
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + SelectLerpUV(g_vMaskNoiseUVGainAmount, (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y), g_iMaskNoiseMoveLerpOption);
|
||||
|
||||
vMtrlNoise = g_NoiseTexture.Sample(DefaultSampler, vNoiseUV);
|
||||
|
||||
@@ -247,7 +298,7 @@ PS_OUT PS_NON_NORMALMAP(PS_IN In)
|
||||
if (g_isMaskUVMove)
|
||||
{
|
||||
if (vMaskingTime.y > 0)
|
||||
vMaskTexcoord += g_vMaskingUVGainAmount * (vMaskingTime.x / vMaskingTime.y);
|
||||
vMaskTexcoord += SelectLerpUV(g_vMaskingUVGainAmount / g_vUVMaskCutting, (vMaskingTime.x / vMaskingTime.y), g_iMaskMoveLerpOption);
|
||||
}
|
||||
|
||||
vMtrlMask = g_MaskingTexture.Sample(PointSampler, vMaskTexcoord);
|
||||
@@ -324,6 +375,7 @@ struct PS_BLUR_IN
|
||||
struct PS_BLUR_OUT
|
||||
{
|
||||
float4 vDiffuse : SV_TARGET0;
|
||||
float4 vBlurWeight : SV_TARGET1;
|
||||
};
|
||||
|
||||
|
||||
@@ -332,6 +384,7 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
|
||||
PS_BLUR_OUT Out;
|
||||
|
||||
|
||||
vector vMtrlDiffuse;
|
||||
vector vMtrlMask;
|
||||
vector vMtrlNoise;
|
||||
@@ -344,31 +397,20 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
|
||||
if (g_isDiffuse == true)
|
||||
{
|
||||
float2 UV = In.vTexcoord; // 이미지의 UV값
|
||||
|
||||
int iTotalFrame = g_vUVCutting.x * g_vUVCutting.y; // 이미지의 최대 프레임 (몇 곱하기 몇인지)
|
||||
|
||||
int iCurrentFrame = int(fAnimIndex.x); // 현재 프레임이 어디 위치인지
|
||||
|
||||
int iFrameX = iCurrentFrame % (int) g_vUVCutting.x; // 현재 x축의 위치(현재 이미지의 몇번째 칸을 보여줄 지)
|
||||
int iFrameY = iCurrentFrame / (int) g_vUVCutting.x; // 현재 y축의 위치(현재 이미지의 몇번째 줄을 보여줄 지)
|
||||
|
||||
float fFreamWidth = 1.0 / g_vUVCutting.x; // 1.0 나누기 이미지 갯수를 해서 한칸에 얼마나 갈지 정해준다.
|
||||
float fFreamHeight = 1.0 / g_vUVCutting.y; // 1.0 나누기 이미지 갯수를 해서 한줄에 얼마나 갈지 정해준다.
|
||||
|
||||
UV.x = UV.x * fFreamWidth + iFrameX * fFreamWidth; // 먼저 uv를 0~1이 아닌 0~fFrameWidth로 만든 다음에 한칸씩 옆으로 밀어준다.
|
||||
UV.y = UV.y * fFreamHeight + iFrameY * fFreamHeight; // 먼저 uv를 0~1이 아닌 0~fFrameHeight로 만든 다음에 한줄씩 밑으로 내려준다.
|
||||
|
||||
float2 UV; // 이미지의 UV값
|
||||
|
||||
UV = UV_Cutting(In.vTexcoord, g_vUVCutting, int(fAnimIndex.x));
|
||||
|
||||
if (g_isDiffuseUVMove)
|
||||
{
|
||||
UV += (g_vDiffuseUVGainAmount / g_vUVCutting) * (vDiffuseTime.x / vDiffuseTime.y);
|
||||
UV += SelectLerpUV((g_vDiffuseUVGainAmount / g_vUVCutting), (vDiffuseTime.x / vDiffuseTime.y), g_iDiffuseMoveLerpOption);
|
||||
}
|
||||
|
||||
/* 노이즈 */
|
||||
if (g_isNoise == true)
|
||||
{
|
||||
float2 vNoiseUV = In.vTexcoord + (g_vDiffuseNoiseUVGainAmount) * (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y);
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + SelectLerpUV(g_vDiffuseNoiseUVGainAmount, (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y), g_iDiffuseNoiseMoveLerpOption);
|
||||
|
||||
vMtrlNoise = g_NoiseTexture.Sample(DefaultSampler, vNoiseUV);
|
||||
|
||||
@@ -387,7 +429,8 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
/* 최종 색깔 */
|
||||
vMtrlDiffuse = g_DiffuseTexture.Sample(DefaultSampler, UV);
|
||||
|
||||
vMtrlDiffuse += g_vColor;
|
||||
if (g_vColor.a > 0)
|
||||
vMtrlDiffuse += g_vColor;
|
||||
|
||||
if (vMtrlDiffuse.a < 0.3f)
|
||||
discard;
|
||||
@@ -402,10 +445,13 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
{
|
||||
float2 vMaskTexcoord = In.vTexcoord;
|
||||
|
||||
vMaskTexcoord = UV_Cutting(In.vTexcoord, g_vUVMaskCutting, int(fAnimIndex.x));
|
||||
|
||||
if (g_isNoise == true)
|
||||
{
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + (g_vMaskNoiseUVGainAmount) * (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y);
|
||||
float2 UV; // 이미지의 UV값
|
||||
|
||||
float2 vNoiseUV = In.vTexcoord + SelectLerpUV(g_vMaskNoiseUVGainAmount, (vNoiseUVMoveTime.x / vNoiseUVMoveTime.y), g_iMaskNoiseMoveLerpOption);
|
||||
|
||||
vMtrlNoise = g_NoiseTexture.Sample(DefaultSampler, vNoiseUV);
|
||||
|
||||
@@ -416,7 +462,7 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
if (g_isMaskUVMove)
|
||||
{
|
||||
if (vMaskingTime.y > 0)
|
||||
vMaskTexcoord += g_vMaskingUVGainAmount * (vMaskingTime.x / vMaskingTime.y);
|
||||
vMaskTexcoord += SelectLerpUV(g_vMaskingUVGainAmount / g_vUVMaskCutting, (vMaskingTime.x / vMaskingTime.y), g_iMaskMoveLerpOption);
|
||||
}
|
||||
|
||||
vMtrlMask = g_MaskingTexture.Sample(PointSampler, vMaskTexcoord);
|
||||
@@ -428,6 +474,17 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
|
||||
|
||||
|
||||
vMtrlDiffuse.a = saturate(vMtrlDiffuse.a * vMtrlMask.r);
|
||||
|
||||
if (g_isDissolve == true)
|
||||
{
|
||||
vMtrlDissolve = g_DissolveTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
if (vMtrlDissolve.r < (In.vLifeTime.x / In.vLifeTime.y))
|
||||
discard;
|
||||
}
|
||||
|
||||
|
||||
vMtrlDiffuse.a = saturate(vMtrlDiffuse.a * vMtrlMask.r);
|
||||
|
||||
if (g_isDissolve == true)
|
||||
@@ -439,6 +496,7 @@ PS_BLUR_OUT PS_BLUR(PS_BLUR_IN In)
|
||||
}
|
||||
|
||||
Out.vDiffuse = vMtrlDiffuse * g_fBlurIntensity;
|
||||
Out.vBlurWeight.r = g_iBlurWeight / 32.f;
|
||||
|
||||
return Out;
|
||||
}
|
||||
@@ -477,3 +535,7 @@ technique11 DefaultTechnique
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -189,8 +189,6 @@
|
||||
<ClInclude Include="..\Public\EffectObject.h" />
|
||||
<ClInclude Include="..\Public\DummyRect.h" />
|
||||
<ClInclude Include="..\Public\Dummy_Cube.h" />
|
||||
<ClInclude Include="..\Public\Dummy_Goblin.h" />
|
||||
<ClInclude Include="..\Public\Dummy_Goblin_Head.h" />
|
||||
<ClInclude Include="..\Public\Editor_Define.h" />
|
||||
<ClInclude Include="..\Public\Editor_Macro.h" />
|
||||
<ClInclude Include="..\Public\Editor_Struct.h" />
|
||||
@@ -256,7 +254,6 @@
|
||||
<ClCompile Include="..\Private\EffectObject.cpp" />
|
||||
<ClCompile Include="..\Private\DummyRect.cpp" />
|
||||
<ClCompile Include="..\Private\Dummy_Cube.cpp" />
|
||||
<ClCompile Include="..\Private\Dummy_Goblin.cpp" />
|
||||
<ClCompile Include="..\Private\Hair.cpp" />
|
||||
<ClCompile Include="..\Private\Loader.cpp" />
|
||||
<ClCompile Include="..\Private\Level_EffectViewer.cpp" />
|
||||
@@ -265,7 +262,6 @@
|
||||
<ClCompile Include="..\private\Loading_Panel.cpp" />
|
||||
<ClCompile Include="..\private\MiniMap_Panel.cpp" />
|
||||
<ClCompile Include="..\private\MiniMap_TrimBorder.cpp" />
|
||||
<ClCompile Include="..\Private\Dummy_Goblin_Head.cpp" />
|
||||
<ClCompile Include="..\Private\Head.cpp" />
|
||||
<ClCompile Include="..\private\Mission_Panel.cpp" />
|
||||
<ClCompile Include="..\Private\Level_Loading.cpp" />
|
||||
|
||||
@@ -67,12 +67,6 @@
|
||||
<Filter Include="50.UI\Mouse_Cursor">
|
||||
<UniqueIdentifier>{b5d188ff-5925-40bd-8da4-2ed00c89f730}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Dummy_Goblin">
|
||||
<UniqueIdentifier>{0ebb9c08-69b0-49b6-bac3-c827ca13319a}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Dummy_Goblin\Dummy_Goblin_Head">
|
||||
<UniqueIdentifier>{69af10ea-e8f1-4455-9435-93857b7eb198}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\ModelParts">
|
||||
<UniqueIdentifier>{a04e88c3-dabb-4a91-8b9f-ce7f5562def6}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -252,18 +246,12 @@
|
||||
<ClInclude Include="..\public\Mouse_Cursor.h">
|
||||
<Filter>50.UI\Mouse_Cursor</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Dummy_Goblin.h">
|
||||
<Filter>02.GameObjects\Dummy_Goblin</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Level_ObjectViewer.h">
|
||||
<Filter>01.Level\20.ObjectViewer</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Dummy_Cube.h">
|
||||
<Filter>02.GameObjects\Dummys\DummyCube</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Dummy_Goblin_Head.h">
|
||||
<Filter>02.GameObjects\Dummy_Goblin\Dummy_Goblin_Head</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Body.h">
|
||||
<Filter>02.GameObjects\ModelParts\Body</Filter>
|
||||
</ClInclude>
|
||||
@@ -448,18 +436,12 @@
|
||||
<ClCompile Include="..\private\Mouse_Cursor.cpp">
|
||||
<Filter>50.UI\Mouse_Cursor</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Dummy_Goblin.cpp">
|
||||
<Filter>02.GameObjects\Dummy_Goblin</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Level_ObjectViewer.cpp">
|
||||
<Filter>01.Level\20.ObjectViewer</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Dummy_Cube.cpp">
|
||||
<Filter>02.GameObjects\Dummys\DummyCube</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Dummy_Goblin_Head.cpp">
|
||||
<Filter>02.GameObjects\Dummy_Goblin\Dummy_Goblin_Head</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Body.cpp">
|
||||
<Filter>02.GameObjects\ModelParts\Body</Filter>
|
||||
</ClCompile>
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include "Terrain.h"
|
||||
#include "Layer.h"
|
||||
#include "VIBuffer_Terrain.h"
|
||||
#include "PartObject.h"
|
||||
|
||||
CBuildingContainer::CBuildingContainer(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
:CMapContainer(pDevice, pContext)
|
||||
@@ -139,7 +140,6 @@ void CBuildingContainer::Describe_Entity()
|
||||
{
|
||||
pTerrain->Get_Component<CVIBuffer_Terrain>()->Picking(pTerrain->Get_Component<CTransform>(), m_vPosition);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
GUI::Text("----- Rotation ----");
|
||||
|
||||
@@ -1,171 +0,0 @@
|
||||
#include "pch.h"
|
||||
#include "Dummy_Goblin.h"
|
||||
|
||||
#include "GameInstance.h"
|
||||
#include "DebugCamera.h"
|
||||
|
||||
CDummy_Goblin::CDummy_Goblin(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CGameObject( pDevice, pContext )
|
||||
{
|
||||
}
|
||||
|
||||
CDummy_Goblin::CDummy_Goblin(const CDummy_Goblin& Prototype)
|
||||
: CGameObject( Prototype )
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin::Initialize_Prototype()
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin::Initialize(void* pArg)
|
||||
{
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
|
||||
if (FAILED(Ready_Components()))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void CDummy_Goblin::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void CDummy_Goblin::Update(_float fTimeDelta)
|
||||
{
|
||||
//m_pModelCom->Play_Animation(fTimeDelta);
|
||||
}
|
||||
|
||||
void CDummy_Goblin::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
_float4 vPos;
|
||||
XMStoreFloat4(&vPos, Get_WorldPostion());
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::BLEND, this, vPos, 20.f);
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin::Render()
|
||||
{
|
||||
if (FAILED(Bind_ShaderResources())) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
_uint iNumMeshes = m_pModelCom->Get_NumMeshes();
|
||||
|
||||
//m_pShaderCom->Bind_SRV("g_NormalTexture", nullptr);
|
||||
for (_uint i = 0; i < iNumMeshes; i++)
|
||||
{
|
||||
if (FAILED(m_pModelCom->Bind_BoneMatrices(i, m_pShaderCom, "g_BoneMatrices"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom, "g_DiffuseTexture", aiTextureType_DIFFUSE, 0))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom, "g_NormalTexture", aiTextureType_NORMALS, 0))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::DEFAULT)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pModelCom->Render(i))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin::Ready_Components()
|
||||
{
|
||||
/* Com_Model */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_GoblinBody_Model"),
|
||||
reinterpret_cast<CComponent**>(&m_pModelCom))))
|
||||
return E_FAIL;
|
||||
|
||||
/* Com_Shader */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_ANIMMESH,
|
||||
reinterpret_cast<CComponent**>(&m_pShaderCom))))
|
||||
return E_FAIL;
|
||||
|
||||
m_pModelCom->Change_AnimationIndex(0, true, 0.4f, true);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin::Bind_ShaderResources()
|
||||
{
|
||||
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))){
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", m_pGameInstance->Get_Transform_Float4x4(D3DTS::VIEW)))){
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", m_pGameInstance->Get_Transform_Float4x4(D3DTS::PROJ)))){
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_vCamPosition", m_pGameInstance->Get_CamPosition(), sizeof(_float4)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_bRimLight", &m_bRimLight, sizeof(_bool)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_fRimStrength", &m_fRimLightStrength, sizeof(_float)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_fRimPower", &m_fRimLightPower, sizeof(_float)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_vRimColor", &m_vRimLightColor, sizeof(_float3)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
CDummy_Goblin* CDummy_Goblin::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
{
|
||||
CDummy_Goblin* pInstance = new CDummy_Goblin(pDevice, pContext);
|
||||
|
||||
if (FAILED(pInstance->Initialize_Prototype()))
|
||||
{
|
||||
MSG_BOX("Failed to Created : CDummy_Goblin");
|
||||
Safe_Release(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
CGameObject* CDummy_Goblin::Clone(void* pArg, CGameObject* pOwner)
|
||||
{
|
||||
CDummy_Goblin* pInstance = new CDummy_Goblin(*this);
|
||||
|
||||
if (FAILED(pInstance->Initialize(pArg)))
|
||||
{
|
||||
MSG_BOX("Failed to Cloned : CDummy_Goblin");
|
||||
Safe_Release(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
void CDummy_Goblin::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
Safe_Release(m_pShaderCom);
|
||||
Safe_Release(m_pModelCom);
|
||||
}
|
||||
|
||||
void CDummy_Goblin::Describe_Entity()
|
||||
{
|
||||
}
|
||||
@@ -1,170 +0,0 @@
|
||||
#include "pch.h"
|
||||
#include "Dummy_Goblin_Head.h"
|
||||
|
||||
#include "GameInstance.h"
|
||||
#include "DebugCamera.h"
|
||||
|
||||
CDummy_Goblin_Head::CDummy_Goblin_Head(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CGameObject(pDevice, pContext)
|
||||
{
|
||||
}
|
||||
|
||||
CDummy_Goblin_Head::CDummy_Goblin_Head(const CDummy_Goblin_Head& Prototype)
|
||||
: CGameObject(Prototype)
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin_Head::Initialize_Prototype()
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin_Head::Initialize(void* pArg)
|
||||
{
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Components()))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void CDummy_Goblin_Head::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void CDummy_Goblin_Head::Update(_float fTimeDelta)
|
||||
{
|
||||
m_pOwner->Get_Component<CModel>()->Play_Animation(fTimeDelta);
|
||||
m_pModelCom->Play_Animation(fTimeDelta);
|
||||
}
|
||||
|
||||
void CDummy_Goblin_Head::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
_float4 vPos;
|
||||
XMStoreFloat4(&vPos, Get_WorldPostion());
|
||||
m_pGameInstance->Add_RenderGroup(RENDER::BLEND, this, vPos, 20.f);
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin_Head::Render()
|
||||
{
|
||||
if (FAILED(Bind_ShaderResources())) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
_uint iNumMeshes = m_pModelCom->Get_NumMeshes();
|
||||
|
||||
for (_uint i = 0; i < iNumMeshes; i++)
|
||||
{
|
||||
if (FAILED(m_pModelCom->Bind_BoneMatrices(i, m_pShaderCom, "g_BoneMatrices"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom, "g_DiffuseTexture", aiTextureType_DIFFUSE, 0))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom, "g_NormalTexture", aiTextureType_NORMALS, 0))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::DEFAULT)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pModelCom->Render(i))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin_Head::Ready_Components()
|
||||
{
|
||||
/* Com_Model */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_GoblinHead_Model"),
|
||||
reinterpret_cast<CComponent**>(&m_pModelCom))))
|
||||
return E_FAIL;
|
||||
|
||||
/* Com_Shader */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_ANIMMESH,
|
||||
reinterpret_cast<CComponent**>(&m_pShaderCom))))
|
||||
return E_FAIL;
|
||||
|
||||
m_pModelCom->Change_AnimationIndex(0, true, 0.4f, true);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CDummy_Goblin_Head::Bind_ShaderResources()
|
||||
{
|
||||
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", m_pGameInstance->Get_Transform_Float4x4(D3DTS::VIEW)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", m_pGameInstance->Get_Transform_Float4x4(D3DTS::PROJ)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_vCamPosition", m_pGameInstance->Get_CamPosition(), sizeof(_float4)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_bRimLight", &m_bRimLight, sizeof(_bool)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_fRimStrength", &m_fRimLightStrength, sizeof(_float)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_fRimPower", &m_fRimLightPower, sizeof(_float)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pShaderCom->Bind_RawValue("g_vRimColor", &m_vRimLightColor, sizeof(_float3)))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
CDummy_Goblin_Head* CDummy_Goblin_Head::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
{
|
||||
CDummy_Goblin_Head* pInstance = new CDummy_Goblin_Head(pDevice, pContext);
|
||||
|
||||
if (FAILED(pInstance->Initialize_Prototype()))
|
||||
{
|
||||
MSG_BOX("Failed to Created : CDummy_Goblin_Head");
|
||||
Safe_Release(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
CGameObject* CDummy_Goblin_Head::Clone(void* pArg, CGameObject* pOwner)
|
||||
{
|
||||
CDummy_Goblin_Head* pInstance = new CDummy_Goblin_Head(*this);
|
||||
pInstance->m_pOwner = pOwner;
|
||||
if (FAILED(pInstance->Initialize(pArg)))
|
||||
{
|
||||
MSG_BOX("Failed to Cloned : CDummy_Goblin_Head");
|
||||
Safe_Release(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
void CDummy_Goblin_Head::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
Safe_Release(m_pShaderCom);
|
||||
Safe_Release(m_pModelCom);
|
||||
}
|
||||
|
||||
void CDummy_Goblin_Head::Describe_Entity()
|
||||
{
|
||||
}
|
||||
@@ -39,7 +39,7 @@ void CEditEffect::Priority_Update(_float fTimeDelta)
|
||||
void CEditEffect::Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
Reference_Mat_For_EditEffect();
|
||||
|
||||
|
||||
if (m_isBillboard)
|
||||
m_pGameInstance->BillBoard(m_pTransformCom);
|
||||
@@ -69,7 +69,7 @@ void CEditEffect::Late_Update(_float fTimeDelta)
|
||||
|
||||
void CEditEffect::Reference_Mat_For_EditEffect()
|
||||
{
|
||||
ImGui::Begin("Reference Material");
|
||||
|
||||
|
||||
const char* pCompute[] = { "DIFFUSE" , "MASK", "NOISE", "DISSOLVE" };
|
||||
|
||||
@@ -93,7 +93,7 @@ void CEditEffect::Reference_Mat_For_EditEffect()
|
||||
default:
|
||||
break;
|
||||
}
|
||||
ImGui::End();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -148,12 +148,7 @@ void CEditEffect::Describe_Entity()
|
||||
{
|
||||
//여기서 모델, 텍스쳐, 선택할 수 있도록 함
|
||||
|
||||
//트레일 만들기
|
||||
//사인 러프
|
||||
//머테리얼 바인딩
|
||||
//블러가 디졸브에 안사라짐
|
||||
//루프 빌보드
|
||||
|
||||
const char* pLerp[] = { "Linear" , "EaseInQuad", "EaseOutQuad", "EaseInCubic" , "EaseOutCubic" , "EaseInOutSin" , "EaseInBack" , "Expo" , "Circle" };
|
||||
const char* pRenderNames[] = { "PRIORITY" , "SHADOW", "NONBLEND", "BLUR" , "NONLIGHT" ,"EFFECT", "BLEND" , "UI" };
|
||||
|
||||
_int iCurrentItem = static_cast<_int>(m_eRenderOrder);
|
||||
@@ -169,7 +164,7 @@ void CEditEffect::Describe_Entity()
|
||||
GUI::Checkbox("Masking", &m_isMasking);
|
||||
GUI::Checkbox("Dissolve", &m_isDissolve);
|
||||
GUI::Checkbox("Noise", &m_isNoise);
|
||||
GUI::Checkbox("Blur", &m_isBlur);
|
||||
|
||||
|
||||
if (GUI::Checkbox("Billboard", &m_isBillboard))
|
||||
{
|
||||
@@ -184,8 +179,13 @@ void CEditEffect::Describe_Entity()
|
||||
|
||||
if (GUI::TreeNode("BLUR"))
|
||||
{
|
||||
GUI::Checkbox("Blur", &m_isBlur);
|
||||
|
||||
ImGui::PushItemWidth(80);
|
||||
GUI::DragFloat("BlurIntensity", &m_fBlurIntensity, 0.005f, 0.f, 1.f);
|
||||
GUI::DragInt("BlurWeight", &m_iBlurWeight, 1.f, 0, 32);
|
||||
|
||||
|
||||
ImGui::PopItemWidth();
|
||||
|
||||
GUI::TreePop();
|
||||
@@ -194,11 +194,11 @@ void CEditEffect::Describe_Entity()
|
||||
|
||||
if (GUI::TreeNode("EMISSIVE"))
|
||||
{
|
||||
const char* pCompute[] = { "EQUL" , "PLUS", "SUBSTRACT", "MULTY" , "DIV" };
|
||||
const char* pCompute[] = {"NONE", "DIV" , "PLUS", "SUBSTRACT", "MULTY" , "EQUL" };
|
||||
|
||||
_int iColorOption = (_int)m_fColorOption;
|
||||
|
||||
if (ImGui::Combo("OPTION", &iColorOption, pCompute, 5))
|
||||
if (ImGui::Combo("OPTION", &iColorOption, pCompute , 6))
|
||||
{
|
||||
m_fColorOption = (_float)iColorOption;
|
||||
}
|
||||
@@ -243,12 +243,28 @@ void CEditEffect::Describe_Entity()
|
||||
GUI::Checkbox("DiffuseUVMove", &m_isDiffuseUVMove);
|
||||
GUI::InputFloat2("DiffuseUVCutting", (_float*)&m_vUVCutting);
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
GUI::DragFloat2("DiffuseUVGainAmount", (_float*)&m_vDiffuseUVGainAmount, 0.01f);
|
||||
GUI::DragFloat2("DiffuseNoiseUVGainAmount", (_float*)&m_vDiffuseNoiseUVGainAmount, 0.01f);
|
||||
|
||||
|
||||
|
||||
_int iDiffuseMoveLerpOption = (_int)m_iDiffuseMoveLerpOption;
|
||||
|
||||
if (ImGui::Combo("Lerp DiffuseMove Option", &iDiffuseMoveLerpOption, pLerp, 9))
|
||||
{
|
||||
m_iDiffuseMoveLerpOption = iDiffuseMoveLerpOption;
|
||||
}
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
ImGui::PopItemWidth();
|
||||
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "DIFFUSE_TEXTURE", (CComponent**)&m_pDiffuse_TextureCom, nullptr, this);
|
||||
if (GUI::TreeNode("DIFFUSE_TEX"))
|
||||
{
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "DIFFUSE_TEXTURE", (CComponent**)&m_pDiffuse_TextureCom, nullptr, this);
|
||||
GUI::TreePop();
|
||||
}
|
||||
|
||||
GUI::Separator(); GUI::Spacing();
|
||||
|
||||
@@ -267,11 +283,27 @@ void CEditEffect::Describe_Entity()
|
||||
|
||||
ImGui::PushItemWidth(80);
|
||||
GUI::DragFloat2("MaskingUVGainAmount", (_float*)&m_vMaskingUVGainAmount, 0.01f);
|
||||
GUI::DragFloat2("MaskNoiseUVGainAmount", (_float*)&m_vMaskNoiseUVGainAmount, 0.01f);
|
||||
ImGui::PopItemWidth();
|
||||
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "MASKING_TEXTURE", (CComponent**)&m_pMasking_TextureCom, nullptr, this);
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
|
||||
_int iMaskMoveLerpOption = (_int)m_iMaskMoveLerpOption;
|
||||
|
||||
if (ImGui::Combo("Lerp MaskMove Option", &iMaskMoveLerpOption, pLerp, 9))
|
||||
{
|
||||
m_iMaskMoveLerpOption = iMaskMoveLerpOption;
|
||||
}
|
||||
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
if (GUI::TreeNode("MASKING_TEX"))
|
||||
{
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "MASKING_TEXTURE", (CComponent**)&m_pMasking_TextureCom, nullptr, this);
|
||||
GUI::TreePop();
|
||||
}
|
||||
GUI::Separator(); GUI::Spacing();
|
||||
|
||||
GUI::TreePop();
|
||||
@@ -282,8 +314,11 @@ void CEditEffect::Describe_Entity()
|
||||
{
|
||||
if (GUI::TreeNode("DISSOLVE"))
|
||||
{
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "DISSOLVE_TEXTURE", (CComponent**)&m_pDissolve_TextureCom, nullptr, this);
|
||||
|
||||
if (GUI::TreeNode("DISSOLV_TEX"))
|
||||
{
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "DISSOLVE_TEXTURE", (CComponent**)&m_pDissolve_TextureCom, nullptr, this);
|
||||
GUI::TreePop();
|
||||
}
|
||||
GUI::Separator(); GUI::Spacing();
|
||||
|
||||
GUI::TreePop();
|
||||
@@ -295,11 +330,40 @@ void CEditEffect::Describe_Entity()
|
||||
if (GUI::TreeNode("NOISE"))
|
||||
{
|
||||
ImGui::PushItemWidth(80);
|
||||
|
||||
GUI::DragFloat("NoiseDistortionIntensity", &m_fNoiseDistortionIntensity, 0.005f, 0.f, 1.f);
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
GUI::DragFloat2("DiffuseNoiseUVGainAmount", (_float*)&m_vDiffuseNoiseUVGainAmount, 0.01f);
|
||||
|
||||
_int iDiffuseNoiseMoveLerpOption = (_int)m_iDiffuseNoiseMoveLerpOption;
|
||||
|
||||
if (ImGui::Combo("Lerp DiffuseNoiseMove Option", &iDiffuseNoiseMoveLerpOption, pLerp, 9))
|
||||
{
|
||||
m_iDiffuseNoiseMoveLerpOption = iDiffuseNoiseMoveLerpOption;
|
||||
}
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
GUI::DragFloat2("MaskNoiseUVGainAmount", (_float*)&m_vMaskNoiseUVGainAmount, 0.01f);
|
||||
|
||||
_int iMaskNoiseMoveLerpOption = (_int)m_iMaskNoiseMoveLerpOption;
|
||||
|
||||
if (ImGui::Combo("Lerp MaskNoiseMove Option", &iMaskNoiseMoveLerpOption, pLerp, 9))
|
||||
{
|
||||
m_iMaskNoiseMoveLerpOption = iMaskNoiseMoveLerpOption;
|
||||
}
|
||||
|
||||
GUI::Spacing();
|
||||
|
||||
ImGui::PopItemWidth();
|
||||
|
||||
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "NOISE_TEXTURE", (CComponent**)&m_pNoise_TextureCom, nullptr, this);
|
||||
if (GUI::TreeNode("NOISE_TEX"))
|
||||
{
|
||||
m_pGameInstance->Asset_Description<CTexture>(ENUM_CLASS(LEVEL::EFFECT), "NOISE_TEXTURE", (CComponent**)&m_pNoise_TextureCom, nullptr, this);
|
||||
GUI::TreePop();
|
||||
}
|
||||
|
||||
GUI::Separator(); GUI::Spacing();
|
||||
|
||||
|
||||
@@ -3,12 +3,12 @@
|
||||
#include "GameInstance.h"
|
||||
|
||||
CEffectObject::CEffectObject(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
:CGameObject(pDevice, pContext)
|
||||
:CPartObject(pDevice, pContext)
|
||||
{
|
||||
}
|
||||
|
||||
CEffectObject::CEffectObject(const CEffectObject& rhs)
|
||||
:CGameObject(rhs)
|
||||
:CPartObject(rhs)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -66,6 +66,12 @@ HRESULT CEffectObject::Render_Blur()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iBlurWeight", &m_iBlurWeight, sizeof(_int)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
for (_uint i = 0; i < m_pInstance_ModelCom->Get_NumMeshes(); i++)
|
||||
{
|
||||
|
||||
@@ -174,6 +180,26 @@ HRESULT CEffectObject::Bind_ShaderResources()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iMaskMoveLerpOption", &m_iMaskMoveLerpOption, sizeof(_int)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iDiffuseMoveLerpOption", &m_iDiffuseMoveLerpOption, sizeof(_int)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iMaskNoiseMoveLerpOption", &m_iMaskNoiseMoveLerpOption, sizeof(_int)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iDiffuseNoiseMoveLerpOption", &m_iDiffuseNoiseMoveLerpOption, sizeof(_int)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if (m_pDiffuse_TextureCom != nullptr)
|
||||
{
|
||||
|
||||
@@ -8,12 +8,12 @@
|
||||
#include <sstream>
|
||||
|
||||
CEffect_Editor::CEffect_Editor(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CEffectObject{ pDevice, pContext }
|
||||
: CContainerObject{ pDevice, pContext }
|
||||
{
|
||||
}
|
||||
|
||||
CEffect_Editor::CEffect_Editor(const CEffect_Editor& rhs)
|
||||
: CEffectObject(rhs)
|
||||
: CContainerObject(rhs)
|
||||
, m_MatFiles(rhs.m_MatFiles)
|
||||
{
|
||||
|
||||
@@ -23,8 +23,8 @@ HRESULT CEffect_Editor::Initialize_Prototype()
|
||||
{
|
||||
|
||||
|
||||
ReadMaterials("../Bin/Resources/VFX/ParticleMaterials/Base_Mat");
|
||||
ReadMaterials("../Bin/Resources/VFX/ParticleMaterials/Mat_Instance");
|
||||
ReadMaterials("../Bin/Resources/VFX/Particles/Magic/Protego");
|
||||
|
||||
|
||||
for (auto iter : m_MatFiles)
|
||||
{
|
||||
@@ -38,6 +38,7 @@ HRESULT CEffect_Editor::Initialize_Prototype()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
||||
}
|
||||
@@ -60,17 +61,19 @@ HRESULT CEffect_Editor::Initialize(void* pArg)
|
||||
|
||||
void CEffect_Editor::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
__super::Priority_Update(fTimeDelta);
|
||||
}
|
||||
|
||||
void CEffect_Editor::Update(_float fTimeDelta)
|
||||
{
|
||||
Describe_Entity();
|
||||
__super::Update(fTimeDelta);
|
||||
|
||||
}
|
||||
|
||||
void CEffect_Editor::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
__super::Late_Update(fTimeDelta);
|
||||
}
|
||||
|
||||
HRESULT CEffect_Editor::Ready_Components(void* pArg)
|
||||
@@ -84,9 +87,20 @@ HRESULT CEffect_Editor::Ready_Components(void* pArg)
|
||||
|
||||
HRESULT CEffect_Editor::Ready_Child()
|
||||
{
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CEditEffect>(ENUM_CLASS(LEVEL::EFFECT), NEXT_LEVEL, LAYER_EFFECT, nullptr, this, reinterpret_cast<CEditEffect**>(&m_pEditEffect))))
|
||||
|
||||
|
||||
CPartObject::PARTOBJECT_DESC PartsDesc{};
|
||||
|
||||
PartsDesc.pParentTransform = m_pTransformCom;
|
||||
|
||||
if (FAILED(Add_PartObject<CEditEffect>("EffectObject" + to_string(m_iNumPart++), ENUM_CLASS(LEVEL::EFFECT), &m_pEditEffect, &PartsDesc)))
|
||||
return E_FAIL;
|
||||
|
||||
m_strCurrentEffectName = "EffectObject0";
|
||||
SAFE_RELEASE(m_pEditEffect);
|
||||
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -310,17 +324,136 @@ CGameObject* CEffect_Editor::Clone(void* pArg, CGameObject* pOwner)
|
||||
void CEffect_Editor::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pEditEffect);
|
||||
}
|
||||
|
||||
void CEffect_Editor::Describe_Entity()
|
||||
{
|
||||
ImGui::Begin("Effect Editor");
|
||||
|
||||
GUI::TextColored(ImVec4(1.f, 0.f, 1.f, 1.f), m_strCurrentEffectName.c_str());
|
||||
|
||||
if (m_pEditEffect != nullptr)
|
||||
m_pEditEffect->Describe_Entity();
|
||||
|
||||
ImGui::End();
|
||||
|
||||
ImGui::Begin("Reference Material");
|
||||
|
||||
if (m_pEditEffect != nullptr)
|
||||
m_pEditEffect->Reference_Mat_For_EditEffect();
|
||||
|
||||
ImGui::End();
|
||||
|
||||
ImGui::Begin("Effect Hierarchy");
|
||||
|
||||
#pragma region PopUp
|
||||
|
||||
if (ImGui::IsItemClicked(ImGuiMouseButton_Right))
|
||||
ImGui::OpenPopup("Effect Hierarchy");
|
||||
|
||||
|
||||
if (ImGui::BeginPopup("Effect Hierarchy"))
|
||||
{
|
||||
if (ImGui::MenuItem("Create Effect"))
|
||||
{
|
||||
|
||||
CPartObject::PARTOBJECT_DESC PartsDesc{};
|
||||
|
||||
PartsDesc.pParentTransform = m_pTransformCom;
|
||||
|
||||
if (FAILED(Add_PartObject<CEditEffect>("EffectObject" + to_string(m_iNumPart++), ENUM_CLASS(LEVEL::EFFECT), nullptr, &PartsDesc)))
|
||||
return;
|
||||
|
||||
|
||||
}
|
||||
|
||||
ImGui::EndPopup();
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
|
||||
_int iIndex = {};
|
||||
|
||||
for (auto& pPartObject : m_PartObjects)
|
||||
{
|
||||
_string strName = "EffectObject" + to_string(iIndex);
|
||||
|
||||
if (GUI::TreeNode(strName.c_str()))
|
||||
{
|
||||
|
||||
#pragma region PopUp
|
||||
|
||||
if (GUI::IsItemClicked(ImGuiMouseButton_Right))
|
||||
GUI::OpenPopup(strName.c_str());
|
||||
|
||||
|
||||
if (GUI::BeginPopup(strName.c_str()))
|
||||
{
|
||||
|
||||
if (ImGui::MenuItem("Delete Effect"))
|
||||
{
|
||||
auto iter = m_PartObjects.begin();
|
||||
advance(iter, iIndex); // 이터레이터를 증가시킨다
|
||||
|
||||
SAFE_RELEASE(pPartObject.second);
|
||||
m_PartObjects.erase(iter);
|
||||
|
||||
GUI::EndPopup();
|
||||
GUI::TreePop();
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
GUI::EndPopup();
|
||||
}
|
||||
|
||||
#pragma endregion
|
||||
|
||||
if (GUI::IsItemClicked()) // 선택창에 띄우기
|
||||
{
|
||||
CEditEffect* pSelectedEffectObject = dynamic_cast<CEditEffect*>(pPartObject.second);
|
||||
|
||||
if (pSelectedEffectObject == nullptr)
|
||||
{
|
||||
GUI::TreePop();
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
|
||||
if (m_pEditEffect == pSelectedEffectObject)
|
||||
{
|
||||
GUI::TreePop();
|
||||
continue;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Safe_Release(m_pEditEffect);
|
||||
|
||||
m_pEditEffect = pSelectedEffectObject;
|
||||
|
||||
Safe_AddRef(pSelectedEffectObject);
|
||||
|
||||
m_strCurrentEffectName = strName;
|
||||
|
||||
}
|
||||
|
||||
GUI::TreePop();
|
||||
}
|
||||
|
||||
iIndex++;
|
||||
}
|
||||
|
||||
|
||||
|
||||
ImGui::End();
|
||||
}
|
||||
|
||||
HRESULT CEffect_Editor::Bind_ShaderResources()
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include "Layer.h"
|
||||
#include "GameObject.h"
|
||||
#include "DummyObject.h"
|
||||
#include "DummySkyBox.h"
|
||||
|
||||
CLevel_ObjectViewer::CLevel_ObjectViewer(ID3D11Device* pDevice, ID3D11DeviceContext* pContext, LEVEL eLevelID)
|
||||
: CLevel{ pDevice, pContext, ENUM_CLASS(eLevelID) }
|
||||
@@ -46,7 +47,9 @@ void CLevel_ObjectViewer::Update(_float fTimeDelta)
|
||||
|
||||
Show_AnimList();
|
||||
|
||||
Object_Setting();
|
||||
Dummy_Object_Setting();
|
||||
|
||||
Parts_Object_Setting();
|
||||
}
|
||||
|
||||
HRESULT CLevel_ObjectViewer::Render()
|
||||
@@ -76,19 +79,20 @@ void CLevel_ObjectViewer::Add_Parts()
|
||||
{
|
||||
if (GUI::BeginTabBar("##MaleTabBar"))
|
||||
{
|
||||
if (GUI::BeginTabItem("Head"))
|
||||
if (GUI::BeginTabItem("Body"))
|
||||
{
|
||||
Category_PartsModelList("Human/Head/Male", "Head");
|
||||
Category_PartsModelList("Human/Body/Male", "Body");
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
|
||||
_bool bDisabled = {};
|
||||
if (m_HumanRoot)
|
||||
bDisabled = (m_HumanRoot->Get_MainModel());
|
||||
if (!bDisabled) GUI::BeginDisabled();
|
||||
if (GUI::BeginTabItem("Body"))
|
||||
if (GUI::BeginTabItem("Head"))
|
||||
{
|
||||
Category_PartsModelList("Human/Body/Male", "Body");
|
||||
Category_PartsModelList("Human/Head/Male", "Head");
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
@@ -97,6 +101,9 @@ void CLevel_ObjectViewer::Add_Parts()
|
||||
{
|
||||
Category_PartsModelList("Human/Hair/Male", "Hair");
|
||||
|
||||
if (m_HumanRoot)
|
||||
m_HumanRoot->Get_ModelParts(ENUM_CLASS(CRootModelPart::PARTSTYPE::HAIR))->Describe_Entity();
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
if (!bDisabled) GUI::EndDisabled();
|
||||
@@ -109,19 +116,20 @@ void CLevel_ObjectViewer::Add_Parts()
|
||||
{
|
||||
if (GUI::BeginTabBar("##FeMaleTabBar"))
|
||||
{
|
||||
if (GUI::BeginTabItem("Head"))
|
||||
if (GUI::BeginTabItem("Body"))
|
||||
{
|
||||
Category_PartsModelList("Human/Head/FeMale", "Head");
|
||||
Category_PartsModelList("Human/Body/FeMale", "Body");
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
|
||||
_bool bDisabled = {};
|
||||
if (m_HumanRoot)
|
||||
bDisabled = (m_HumanRoot->Get_MainModel());
|
||||
if (!bDisabled) GUI::BeginDisabled();
|
||||
if (GUI::BeginTabItem("Body"))
|
||||
if (GUI::BeginTabItem("Head"))
|
||||
{
|
||||
Category_PartsModelList("Human/Body/FeMale", "Body");
|
||||
Category_PartsModelList("Human/Head/FeMale", "Head");
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
@@ -130,6 +138,9 @@ void CLevel_ObjectViewer::Add_Parts()
|
||||
{
|
||||
Category_PartsModelList("Human/Hair/FeMale", "Hair");
|
||||
|
||||
if (m_HumanRoot)
|
||||
m_HumanRoot->Get_ModelParts(ENUM_CLASS(CRootModelPart::PARTSTYPE::HAIR))->Describe_Entity();
|
||||
|
||||
GUI::EndTabItem();
|
||||
}
|
||||
if (!bDisabled) GUI::EndDisabled();
|
||||
@@ -149,6 +160,8 @@ void CLevel_ObjectViewer::Show_ModelFilePath()
|
||||
Category_ModelList("Monster");
|
||||
|
||||
Category_ModelList("Human");
|
||||
|
||||
Category_ModelList("Object");
|
||||
}
|
||||
GUI::EndTabBar();
|
||||
GUI::End();
|
||||
@@ -214,8 +227,6 @@ void CLevel_ObjectViewer::Category_PartsModelList(const _char* Category, const _
|
||||
{
|
||||
if (GUI::Button(szCategory))
|
||||
{
|
||||
Save_LayerName(Layer);
|
||||
|
||||
CGameObject* pTempObject = { nullptr };
|
||||
|
||||
CDummyObject::PARTS_OBJECT_DESC Desc = {};
|
||||
@@ -225,10 +236,10 @@ void CLevel_ObjectViewer::Category_PartsModelList(const _char* Category, const _
|
||||
m_HumanRoot->Set_ModelName(szCategory);
|
||||
|
||||
_uint iIndex = 0;
|
||||
if (strstr(szCategory,"Head"))
|
||||
iIndex = ENUM_CLASS(CRootModelPart::PARTSTYPE::HEAD);
|
||||
else if (strstr(szCategory,"Body"))
|
||||
if (strstr(szCategory,"Body"))
|
||||
iIndex = ENUM_CLASS(CRootModelPart::PARTSTYPE::BODY);
|
||||
else if (strstr(szCategory,"Head"))
|
||||
iIndex = ENUM_CLASS(CRootModelPart::PARTSTYPE::HEAD);
|
||||
else if (strstr(szCategory,"Hair"))
|
||||
iIndex = ENUM_CLASS(CRootModelPart::PARTSTYPE::HAIR);
|
||||
|
||||
@@ -250,6 +261,7 @@ void CLevel_ObjectViewer::Show_AnimList()
|
||||
if (GUI::Button(pModel->Get_AnimList(i)))
|
||||
{
|
||||
pModel->Set_AnimationIndex(i);
|
||||
pModel->Set_CurrentTrackPosition(0.f);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -281,7 +293,7 @@ void CLevel_ObjectViewer::Show_ObjectList()
|
||||
}
|
||||
}
|
||||
|
||||
void CLevel_ObjectViewer::Object_Setting()
|
||||
void CLevel_ObjectViewer::Dummy_Object_Setting()
|
||||
{
|
||||
GUI::Begin("Object_Info");
|
||||
if (!m_Objects.empty())
|
||||
@@ -308,15 +320,20 @@ void CLevel_ObjectViewer::Object_Setting()
|
||||
}
|
||||
}
|
||||
GUI::End();
|
||||
}
|
||||
|
||||
void CLevel_ObjectViewer::Parts_Object_Setting()
|
||||
{
|
||||
GUI::Begin("PartsObject_Info");
|
||||
if (m_HumanRoot)
|
||||
{
|
||||
CModel* pModel = m_HumanRoot->Get_MainModel();
|
||||
if (pModel)
|
||||
{
|
||||
_float AnimTrack = pModel->Get_CurrentTrackPosition();
|
||||
GUI::DragFloat("AnimTrack", &AnimTrack);
|
||||
GUI::Button(pModel->Get_AnimList(pModel->Get_AnimIndex()));
|
||||
|
||||
_float KeyFrame = pModel->Get_CurrentTrackPosition();
|
||||
GUI::DragFloat("KeyFrame", &KeyFrame);
|
||||
|
||||
_float AnimSpeed = pModel->Get_AnimSpeed();
|
||||
GUI::DragFloat("AnimSpeed", &AnimSpeed, 0.1f);
|
||||
@@ -328,36 +345,64 @@ void CLevel_ObjectViewer::Object_Setting()
|
||||
pModel->Set_PlayAnim(bPlayAnim);
|
||||
}
|
||||
|
||||
if (GUI::Button("Add Event"))
|
||||
if (GUI::Button("Load KeyFrame"))
|
||||
{
|
||||
m_fAnimFrame = m_HumanRoot->Get_MainModel()->Get_CurrentTrackPosition();
|
||||
Load_KeyFrame();
|
||||
}
|
||||
|
||||
GUI::DragFloat("Anim Frame", &m_fAnimFrame);
|
||||
GUI::SameLine();
|
||||
if(GUI::Button("Event"))
|
||||
{
|
||||
static _char EventName[64] = {};
|
||||
|
||||
GUI::InputText("EventName", EventName, sizeof(EventName));
|
||||
GUI::SameLine();
|
||||
|
||||
if (GUI::Button("Save KeyFrame"))
|
||||
{
|
||||
if (m_HumanRoot && m_HumanRoot->Get_MainModel())
|
||||
{
|
||||
_float fKeyFrame = m_HumanRoot->Get_MainModel()->Get_CurrentTrackPosition();
|
||||
m_KeyFrame.push_back(fKeyFrame);
|
||||
m_Events.emplace_back(EventName);
|
||||
|
||||
FILE* fp = nullptr;
|
||||
fopen_s(&fp, "../Bin/Resources/Models/KeyFrame.bin", "wb");
|
||||
if (!fp) return;
|
||||
|
||||
_uint KeyFrameSize = (_uint)m_KeyFrame.size();
|
||||
|
||||
fwrite(&KeyFrameSize, sizeof(_uint), 1, fp);
|
||||
|
||||
for (size_t i = 0; i < m_KeyFrame.size(); i++)
|
||||
{
|
||||
_uint EventSize = (_uint)m_Events[i].size();
|
||||
fwrite(&m_KeyFrame[i], sizeof(_float), 1, fp);
|
||||
fwrite(&EventSize, sizeof(_uint), 1, fp);
|
||||
fwrite(&m_Events[i], sizeof(_string), 1, fp);
|
||||
}
|
||||
|
||||
|
||||
fclose(fp);
|
||||
|
||||
EventName[0] = '\0';
|
||||
}
|
||||
}
|
||||
|
||||
for (_uint i = 0; i < m_KeyFrame.size(); ++i)
|
||||
{
|
||||
ImDrawList* draw = ImGui::GetForegroundDrawList();
|
||||
ImVec2 center = ImGui::GetMainViewport()->GetCenter();
|
||||
float scale = 50.f;
|
||||
|
||||
draw->AddLine(center, ImVec2(center.x + scale, center.y), IM_COL32(255, 0, 0, 255), 2.0f);
|
||||
draw->AddLine(center, ImVec2(center.x, center.y - scale), IM_COL32(0, 255, 0, 255), 2.0f);
|
||||
draw->AddLine(center, ImVec2(center.x + scale * 0.5f, center.y + scale * 0.5f), IM_COL32(0, 0, 255, 255), 2.0f);
|
||||
GUI::DragFloat(m_Events[i].c_str(), &m_KeyFrame[i]);
|
||||
}
|
||||
|
||||
|
||||
if (GUI::Button("Delete"))
|
||||
{
|
||||
m_pGameInstance->Get_Layer(NEXT_LEVEL, TEXT("Layer_Root"))->Clear_Layer();
|
||||
m_HumanRoot = nullptr;
|
||||
m_KeyFrame.clear();
|
||||
}
|
||||
}
|
||||
|
||||
if (m_HumanRoot)
|
||||
|
||||
m_HumanRoot->Get_ModelParts(ENUM_CLASS(CRootModelPart::PARTSTYPE::HAIR))->Describe_Entity();
|
||||
|
||||
}
|
||||
|
||||
GUI::End();
|
||||
@@ -386,6 +431,30 @@ _wchar* CLevel_ObjectViewer::Save_ModelName(const _char* Category)
|
||||
return m_wszName;
|
||||
}
|
||||
|
||||
void CLevel_ObjectViewer::Load_KeyFrame()
|
||||
{
|
||||
FILE* fp = nullptr;
|
||||
fopen_s(&fp, "../Bin/Resources/Models/KeyFrame.bin", "rb");
|
||||
if (!fp) return;
|
||||
|
||||
_uint KeyFameSize = {};
|
||||
_uint EventLen = {};
|
||||
|
||||
fread(&KeyFameSize, sizeof(_uint), 1, fp);
|
||||
|
||||
for (size_t i = 0; i < KeyFameSize; i++)
|
||||
{
|
||||
fread(&m_fKeyFrame, sizeof(_float), 1, fp);
|
||||
fread(&EventLen, sizeof(_uint), 1, fp);
|
||||
fread(&m_strEvent, sizeof(_string), 1, fp);
|
||||
|
||||
m_Events.push_back(m_strEvent);
|
||||
m_KeyFrame.push_back(m_fKeyFrame);
|
||||
}
|
||||
|
||||
fclose(fp);
|
||||
}
|
||||
|
||||
HRESULT CLevel_ObjectViewer::Ready_Layer_Camera(const _wstring& strLayerTag)
|
||||
{
|
||||
CDebugCamera::CAMERA_DEBUG_DESC CameraDesc{};
|
||||
@@ -428,7 +497,7 @@ HRESULT CLevel_ObjectViewer::Ready_Layer_UI(const _wstring& strLayerTag)
|
||||
|
||||
HRESULT CLevel_ObjectViewer::Ready_Layer_Dummy(const _wstring& strLayerTag)
|
||||
{
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CDummy_Cube>(g_iStaticLevel, NEXT_LEVEL, LAYER_CUBE)))
|
||||
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer<CDummySkyBox>(g_iStaticLevel, NEXT_LEVEL, LAYER_CUBE)))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
#include "Head.h"
|
||||
#include "Body.h"
|
||||
#include "Hair.h"
|
||||
#include "Dummy_Goblin.h"
|
||||
#include "DummySkyBox.h"
|
||||
#include "DummyObject.h"
|
||||
#include <filesystem>
|
||||
@@ -50,6 +49,8 @@
|
||||
#include "MapObject_Static.h"
|
||||
#include "MapObject_LOD.h"
|
||||
#include "MapObject_Manager.h"
|
||||
#include "MapElement_Interactable.h"
|
||||
#include "MapElement_Static.h"
|
||||
#pragma endregion
|
||||
|
||||
|
||||
@@ -436,7 +437,7 @@ HRESULT CLoader::Loading_For_Effect()
|
||||
Asset_FileLoad("../Bin/Resources/Models/Effect/ParticleMesh", L"Prototype_Instance_Model_", [&](_wstring wstrFileName, const _char* pFilePath) {
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::EFFECT), wstrFileName,
|
||||
CInstance_Model::Create(m_pDevice, m_pContext, pFilePath, MODEL::NONANIM, XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixIdentity(), 0))))
|
||||
CInstance_Model::Create(m_pDevice, m_pContext, pFilePath, MODEL::NONANIM, XMMatrixScaling(0.1f, 0.1f, 0.1f) * XMMatrixIdentity(), 0))))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
@@ -713,16 +714,9 @@ HRESULT CLoader::Loading_For_ObjectViewer()
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_F_Hair1_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Human/Hair/FeMale/F_Hair1/F_Hair1.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
#pragma endregion
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GoblinHead_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin/GoblinHead.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GoblinBody_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin/GoblinBody.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
#pragma region MONSTER
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_TombProtector_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/TombProtector/TombProtector.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
@@ -732,6 +726,21 @@ HRESULT CLoader::Loading_For_ObjectViewer()
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Troll/Troll.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Dragon_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Dragon/Dragon.bin", XMMatrixScaling(0.0005f, 0.0005f, 0.0005f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
#pragma endregion
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Broom_Model"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Broom/Broom.bin", XMMatrixScaling(0.001f, 0.001f, 0.001f) * XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
/* For.Prototype_Component_SkyboxModel */
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_SkyboxModel"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::NONANIM, "../Bin/Resources/Models/SkyBox/SkyBox.fbx", XMMatrixIdentity()))))
|
||||
return E_FAIL;
|
||||
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Desc_Box"),
|
||||
CModel::Create(m_pDevice, m_pContext, MODEL::NONANIM, "../Bin/Resources/Models/Box/Box.bin", XMMatrixIdentity()))))
|
||||
@@ -767,8 +776,8 @@ HRESULT CLoader::Loading_For_ObjectViewer()
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CDummyObject>(g_iStaticLevel, CDummyObject::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
/* For.Prototype_GameObject_Dummy_Cube */
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CDummy_Cube>(g_iStaticLevel, CDummy_Cube::Create(m_pDevice, m_pContext))))
|
||||
/* For.Prototype_GameObject_DummySkyBox */
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CDummySkyBox>(g_iStaticLevel, CDummySkyBox::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
m_strMessage = TEXT("Loading Success!");
|
||||
@@ -875,6 +884,14 @@ HRESULT CLoader::Loading_For_MapViewer()
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CMapObject_LOD>(g_iStaticLevel, CMapObject_LOD::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
/* For.Prototype_GameObject_MapElement_Interactable */
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CMapElement_Interactable>(g_iStaticLevel, CMapElement_Interactable::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
/* For.Prototype_GameObject_MapElement_Static */
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CMapElement_Static>(g_iStaticLevel, CMapElement_Static::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
/* For.Prototype_GameObject_Terrain */
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CTerrain>(g_iStaticLevel, CTerrain::Create(m_pDevice, m_pContext))))
|
||||
return E_FAIL;
|
||||
|
||||
@@ -70,6 +70,7 @@ HRESULT CMapContainer::Save_PartObjects(tinyxml2::XMLDocument& Doc, tinyxml2::XM
|
||||
// <PartObject>
|
||||
tinyxml2::XMLElement* PartObject = Doc.NewElement("PartObject");
|
||||
PartObject->SetAttribute("Lod_Level", pMapObject->Get_LodLevel());
|
||||
PartObject->SetAttribute("Key_Index", pMapObject->Get_iKeyIndex());
|
||||
Container->InsertEndChild(PartObject);
|
||||
|
||||
for (_uint i = 0; i < pMapObject->Get_LodLevel() + 1; ++i)
|
||||
@@ -110,7 +111,6 @@ HRESULT CMapContainer::Save_PartObjects(tinyxml2::XMLDocument& Doc, tinyxml2::XM
|
||||
RotationElem->SetAttribute("y", vRotation.y);
|
||||
RotationElem->SetAttribute("z", vRotation.z);
|
||||
PartObject->InsertEndChild(RotationElem);
|
||||
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
||||
@@ -13,6 +13,14 @@ CMapElement::CMapElement(const CMapElement& rhs)
|
||||
{
|
||||
}
|
||||
|
||||
const _wstring& CMapElement::Get_PrototypeTag(_uint iIndex)
|
||||
{
|
||||
if (m_iMaxLodLevel < iIndex)
|
||||
return m_ModelPrototypeTags[0];
|
||||
|
||||
return m_ModelPrototypeTags[iIndex];
|
||||
}
|
||||
|
||||
void CMapElement::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -2,6 +2,9 @@
|
||||
#include "MapElement_Interactable.h"
|
||||
|
||||
#include "GameInstance.h"
|
||||
#include "Terrain.h"
|
||||
#include "Layer.h"
|
||||
#include "VIBuffer_Terrain.h"
|
||||
|
||||
CMapElement_Interactable::CMapElement_Interactable(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CMapElement{ pDevice, pContext }
|
||||
@@ -20,12 +23,33 @@ HRESULT CMapElement_Interactable::Initialize_Prototype()
|
||||
|
||||
HRESULT CMapElement_Interactable::Initialize(void* pArg)
|
||||
{
|
||||
MAPOBJECT_LOD_DESC* pDesc = static_cast<MAPOBJECT_LOD_DESC*>(pArg);
|
||||
|
||||
m_iMaxLodLevel = pDesc->iMaxLodLevel;
|
||||
|
||||
for (_uint i = 0; i < m_iMaxLodLevel + 1; i++)
|
||||
{
|
||||
m_ModelPrototypeTags.push_back(pDesc->ModelPrototypeTags[i]);
|
||||
//m_ModelPathIndices.push_back((*pDesc->pModelPathIndices)[i]);
|
||||
}
|
||||
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Components(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
#ifdef _DEBUG
|
||||
m_bSelected = false;
|
||||
m_vPosition = pDesc->vPosition;
|
||||
m_vScale = pDesc->vScale;
|
||||
m_vRotation = pDesc->vRotation;
|
||||
|
||||
m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&m_vPosition), 1.f));
|
||||
m_pTransformCom->Set_Scale(m_vScale);
|
||||
m_pTransformCom->Rotation(XMConvertToRadians(m_vRotation.x), XMConvertToRadians(m_vRotation.y), XMConvertToRadians(m_vRotation.z));
|
||||
#endif // _DEBUG
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -58,6 +82,9 @@ void CMapElement_Interactable::Late_Update(_float fTimeDelta)
|
||||
|
||||
HRESULT CMapElement_Interactable::Render()
|
||||
{
|
||||
if (FAILED(Bind_ShaderResources()))
|
||||
return E_FAIL;
|
||||
|
||||
_uint iNumMeshes = m_pModelComs[m_iLodIndex]->Get_NumMeshes();
|
||||
|
||||
for (_uint i = 0; i < iNumMeshes; i++)
|
||||
@@ -96,6 +123,23 @@ HRESULT CMapElement_Interactable::Ready_Components(void* pArg)
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
for (_uint i = 0; i < m_iMaxLodLevel + 1; ++i)
|
||||
{
|
||||
CModel* pModel = { nullptr };
|
||||
|
||||
/* Com_Model */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_ModelPrototypeTags[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,
|
||||
reinterpret_cast<CComponent**>(&m_pShaderCom))))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -147,6 +191,10 @@ CGameObject* CMapElement_Interactable::Clone(void* pArg, CGameObject* pOwner)
|
||||
void CMapElement_Interactable::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pShaderCom);
|
||||
for (auto& pModel : m_pModelComs)
|
||||
SAFE_RELEASE(pModel);
|
||||
}
|
||||
|
||||
void CMapElement_Interactable::Describe_Entity()
|
||||
@@ -165,7 +213,7 @@ void CMapElement_Interactable::Describe_Entity()
|
||||
GUI::InputFloat("Y##Position", &m_vPosition.y, 0.1f, 1.f);
|
||||
GUI::InputFloat("Z##Position", &m_vPosition.z, 0.1f, 1.f);
|
||||
|
||||
/*if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_pGameInstance->Key_Pressing(DIK_LSHIFT))
|
||||
if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_pGameInstance->Key_Pressing(DIK_LSHIFT))
|
||||
{
|
||||
CTerrain* pTerrain = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Terrain"))->Get_Object<CTerrain>();
|
||||
if (nullptr != pTerrain)
|
||||
@@ -173,7 +221,7 @@ void CMapElement_Interactable::Describe_Entity()
|
||||
pTerrain->Get_Component<CVIBuffer_Terrain>()->Picking(pTerrain->Get_Component<CTransform>(), m_vPosition);
|
||||
}
|
||||
|
||||
}*/
|
||||
}
|
||||
|
||||
GUI::Text("----- Rotation ----");
|
||||
GUI::InputFloat("X##Rotation", &m_vRotation.x, 10.f, 45.f);
|
||||
|
||||
@@ -3,6 +3,10 @@
|
||||
|
||||
#include "GameInstance.h"
|
||||
|
||||
#include "Terrain.h"
|
||||
#include "Layer.h"
|
||||
#include "VIBuffer_Terrain.h"
|
||||
|
||||
CMapElement_Static::CMapElement_Static(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CMapElement{ pDevice, pContext }
|
||||
{
|
||||
@@ -20,12 +24,33 @@ HRESULT CMapElement_Static::Initialize_Prototype()
|
||||
|
||||
HRESULT CMapElement_Static::Initialize(void* pArg)
|
||||
{
|
||||
MAPOBJECT_LOD_DESC* pDesc = static_cast<MAPOBJECT_LOD_DESC*>(pArg);
|
||||
|
||||
m_iMaxLodLevel = pDesc->iMaxLodLevel;
|
||||
|
||||
for (_uint i = 0; i < m_iMaxLodLevel + 1; i++)
|
||||
{
|
||||
m_ModelPrototypeTags.push_back(pDesc->ModelPrototypeTags[i]);
|
||||
//m_ModelPathIndices.push_back((*pDesc->pModelPathIndices)[i]);
|
||||
}
|
||||
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Components(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
#ifdef _DEBUG
|
||||
m_bSelected = false;
|
||||
m_vPosition = pDesc->vPosition;
|
||||
m_vScale = pDesc->vScale;
|
||||
m_vRotation = pDesc->vRotation;
|
||||
|
||||
m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&m_vPosition), 1.f));
|
||||
m_pTransformCom->Set_Scale(m_vScale);
|
||||
m_pTransformCom->Rotation(XMConvertToRadians(m_vRotation.x), XMConvertToRadians(m_vRotation.y), XMConvertToRadians(m_vRotation.z));
|
||||
#endif // _DEBUG
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -58,6 +83,9 @@ void CMapElement_Static::Late_Update(_float fTimeDelta)
|
||||
|
||||
HRESULT CMapElement_Static::Render()
|
||||
{
|
||||
if (FAILED(Bind_ShaderResources()))
|
||||
return E_FAIL;
|
||||
|
||||
_uint iNumMeshes = m_pModelComs[m_iLodIndex]->Get_NumMeshes();
|
||||
|
||||
for (_uint i = 0; i < iNumMeshes; i++)
|
||||
@@ -95,6 +123,23 @@ HRESULT CMapElement_Static::Ready_Components(void* pArg)
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
for (_uint i = 0; i < m_iMaxLodLevel + 1; ++i)
|
||||
{
|
||||
CModel* pModel = { nullptr };
|
||||
|
||||
/* Com_Model */
|
||||
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_ModelPrototypeTags[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,
|
||||
reinterpret_cast<CComponent**>(&m_pShaderCom))))
|
||||
return E_FAIL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -146,6 +191,10 @@ CGameObject* CMapElement_Static::Clone(void* pArg, CGameObject* pOwner)
|
||||
void CMapElement_Static::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pShaderCom);
|
||||
for (auto& pModel : m_pModelComs)
|
||||
SAFE_RELEASE(pModel);
|
||||
}
|
||||
|
||||
void CMapElement_Static::Describe_Entity()
|
||||
@@ -164,7 +213,7 @@ void CMapElement_Static::Describe_Entity()
|
||||
GUI::InputFloat("Y##Position", &m_vPosition.y, 0.1f, 1.f);
|
||||
GUI::InputFloat("Z##Position", &m_vPosition.z, 0.1f, 1.f);
|
||||
|
||||
/*if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_pGameInstance->Key_Pressing(DIK_LSHIFT))
|
||||
if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_pGameInstance->Key_Pressing(DIK_LSHIFT))
|
||||
{
|
||||
CTerrain* pTerrain = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Terrain"))->Get_Object<CTerrain>();
|
||||
if (nullptr != pTerrain)
|
||||
@@ -172,7 +221,7 @@ void CMapElement_Static::Describe_Entity()
|
||||
pTerrain->Get_Component<CVIBuffer_Terrain>()->Picking(pTerrain->Get_Component<CTransform>(), m_vPosition);
|
||||
}
|
||||
|
||||
}*/
|
||||
}
|
||||
|
||||
GUI::Text("----- Rotation ----");
|
||||
GUI::InputFloat("X##Rotation", &m_vRotation.x, 10.f, 45.f);
|
||||
|
||||
@@ -57,6 +57,11 @@ _wstring CMapObject::Get_PrototypeTag(_uint iLodIndex)
|
||||
return _wstring();
|
||||
}
|
||||
|
||||
_uint CMapObject::Get_LodLevel()
|
||||
{
|
||||
return m_iMaxLodLevel;
|
||||
}
|
||||
|
||||
HRESULT CMapObject::Initialize_Prototype()
|
||||
{
|
||||
return S_OK;
|
||||
|
||||
@@ -32,9 +32,7 @@ HRESULT CMapObject_LOD::Initialize(void* pArg)
|
||||
for (_uint i = 0; i < m_iMaxLodLevel + 1; i++)
|
||||
{
|
||||
m_ModelPrototypeTags.push_back(pDesc->ModelPrototypeTags[i]);
|
||||
}
|
||||
for (_uint i = 0; i < pDesc->ModelPrototypeTags.size(); ++i) {
|
||||
m_ModelPathIndices.push_back((*pDesc->pModelPathIndices)[i]);
|
||||
//m_ModelPathIndices.push_back((*pDesc->pModelPathIndices)[i]);
|
||||
}
|
||||
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
#include "MapObject_LOD.h"
|
||||
#include "MapObject_Static.h"
|
||||
#include "BuildingContainer.h"
|
||||
#include "MapElement_Static.h"
|
||||
#include "MapElement_Interactable.h"
|
||||
|
||||
|
||||
CMapObject_Manager::CMapObject_Manager(ID3D11Device * pDevice, ID3D11DeviceContext * pContext)
|
||||
@@ -20,6 +22,7 @@ CMapObject_Manager::CMapObject_Manager(const CMapObject_Manager& rhs)
|
||||
, m_ModelPrototypeTags{ rhs.m_ModelPrototypeTags }
|
||||
, m_LODModelPrototypeTags{ rhs.m_LODModelPrototypeTags }
|
||||
, m_ModelPrototypePaths{ rhs.m_ModelPrototypePaths }
|
||||
, m_PartObjectKeyCount{ rhs.m_PartObjectKeyCount }
|
||||
{
|
||||
}
|
||||
|
||||
@@ -32,6 +35,10 @@ HRESULT CMapObject_Manager::Initialize_Prototype(vector<_wstring>& ModelPrototyp
|
||||
{
|
||||
m_LODModelPrototypeTags.push_back(ModelPrototypeTags[i]);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_PartObjectKeyCount.emplace(ModelPrototypeTags[i], 0);
|
||||
}
|
||||
|
||||
m_ModelPrototypeTags.push_back(ModelPrototypeTags[i]);
|
||||
m_ModelPrototypePaths.push_back(ModelPrototypePaths[i]);
|
||||
@@ -65,20 +72,34 @@ void CMapObject_Manager::Priority_Update(_float fTimeDelta)
|
||||
void CMapObject_Manager::Update(_float fTimeDelta)
|
||||
{
|
||||
GUI::Begin("File");
|
||||
const char* ModeNames[3] =
|
||||
{
|
||||
"CONTAINER",
|
||||
"ELEMENT_STATIC",
|
||||
"ELEMENT_INTERACT"
|
||||
};
|
||||
GUI::Combo("MODE", (_int*)(&m_eType), ModeNames, IM_ARRAYSIZE(ModeNames));
|
||||
|
||||
GUI::InputText("MapFileName", m_szSaveFileName, MAX_PATH);
|
||||
if (GUI::Button("Save_Map"))
|
||||
{
|
||||
Save_MapData("Test");
|
||||
Save_MapData(m_szSaveFileName);
|
||||
|
||||
}
|
||||
if (GUI::Button("Load_Map"))
|
||||
{
|
||||
Load_MapData("Test");
|
||||
Load_MapData(m_szSaveFileName);
|
||||
|
||||
}
|
||||
|
||||
GUI::InputText("Containter Name", m_szSaveContainerName, MAX_PATH);
|
||||
if (GUI::Button("Save_Container"))
|
||||
|
||||
if (ADD_TYPE::CONTAINER == m_eType)
|
||||
{
|
||||
Save_ContainerData("ContainerTest", m_szSaveContainerName);
|
||||
if (GUI::Button("Save_Container"))
|
||||
{
|
||||
Save_ContainerData("ContainerTest", m_szSaveContainerName);
|
||||
}
|
||||
}
|
||||
if (GUI::Button("Load_Container"))
|
||||
{
|
||||
@@ -90,9 +111,15 @@ void CMapObject_Manager::Update(_float fTimeDelta)
|
||||
|
||||
Update_ObjectList();
|
||||
|
||||
Update_Edit();
|
||||
if (ADD_TYPE::CONTAINER != m_eType)
|
||||
{
|
||||
Update_Edit();
|
||||
}
|
||||
|
||||
Update_ContainerObject();
|
||||
if (ADD_TYPE::CONTAINER == m_eType)
|
||||
{
|
||||
Update_ContainerObject();
|
||||
}
|
||||
|
||||
for (auto* pObject : m_MapObjects)
|
||||
{
|
||||
@@ -148,22 +175,13 @@ HRESULT CMapObject_Manager::Save_MapData(const _char* pFileName)
|
||||
|
||||
tinyxml2::XMLError loadResult = doc.LoadFile(strPath.c_str());
|
||||
|
||||
tinyxml2::XMLElement* land = {};
|
||||
tinyxml2::XMLElement* container = {};
|
||||
doc.Clear();
|
||||
doc.InsertFirstChild(doc.NewDeclaration());
|
||||
|
||||
if (loadResult != tinyxml2::XML_SUCCESS)
|
||||
{
|
||||
doc.InsertFirstChild(doc.NewDeclaration());
|
||||
|
||||
land = doc.NewElement("Land");
|
||||
doc.InsertEndChild(land);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
land = doc.FirstChildElement("Land");
|
||||
}
|
||||
tinyxml2::XMLElement* land = doc.NewElement("Land");
|
||||
doc.InsertEndChild(land);
|
||||
|
||||
#pragma region SAVE_BUILDING
|
||||
CLayer* pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Building"));
|
||||
|
||||
if (nullptr == pLayer)
|
||||
@@ -171,7 +189,6 @@ HRESULT CMapObject_Manager::Save_MapData(const _char* pFileName)
|
||||
|
||||
const list<CGameObject*>* pList = pLayer->Get_Objects();
|
||||
|
||||
|
||||
for (auto pGamObject : *pList)
|
||||
{
|
||||
CBuildingContainer* pContainerObject = dynamic_cast<CBuildingContainer*>(pGamObject);
|
||||
@@ -196,7 +213,6 @@ HRESULT CMapObject_Manager::Save_MapData(const _char* pFileName)
|
||||
vRotation.y = XMConvertToDegrees(vRotation.y);
|
||||
vRotation.z = XMConvertToDegrees(vRotation.z);
|
||||
|
||||
|
||||
#pragma region CONTAINER_TRANSFORM
|
||||
tinyxml2::XMLElement* Position = doc.NewElement("Position");
|
||||
Position->SetAttribute("x", vPosition.x);
|
||||
@@ -217,16 +233,148 @@ HRESULT CMapObject_Manager::Save_MapData(const _char* pFileName)
|
||||
container->InsertEndChild(Rotation);
|
||||
#pragma endregion
|
||||
|
||||
|
||||
|
||||
#pragma region SAVE_PARTOBJECT
|
||||
|
||||
if (FAILED(pContainerObject->Save_PartObjects(doc, container)))
|
||||
return E_FAIL;
|
||||
#pragma endregion
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
// ÀúÀå
|
||||
#pragma region ELEMENT_STATIC
|
||||
pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Element_Static"));
|
||||
|
||||
if (nullptr != pLayer)
|
||||
{
|
||||
const list<CGameObject*>* pList = pLayer->Get_Objects();
|
||||
|
||||
for (auto pGamObject : *pList)
|
||||
{
|
||||
CMapElement* pElement = dynamic_cast<CMapElement*>(pGamObject);
|
||||
|
||||
if (nullptr == pElement)
|
||||
return E_FAIL;
|
||||
|
||||
_uint iLodLevel = pElement->Get_LodLevel();
|
||||
|
||||
tinyxml2::XMLElement* object = doc.NewElement("Object");
|
||||
object->SetAttribute("Type", ENUM_CLASS(MAPOBJECT_TYPE::ELEMENT_STATIC));
|
||||
object->SetAttribute("Lod_Level", iLodLevel);
|
||||
land->InsertEndChild(object);
|
||||
|
||||
#pragma region PROTOTYPETAG
|
||||
for (_uint i = 0; i < iLodLevel + 1; ++i)
|
||||
{
|
||||
tinyxml2::XMLElement* prototype = doc.NewElement("PrototypeTag");
|
||||
prototype->SetText(CMyTools::ToString(pElement->Get_PrototypeTag(i)).c_str());
|
||||
object->InsertEndChild(prototype);
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
|
||||
#pragma region TRANSFORM
|
||||
_float3 vPosition = {};
|
||||
XMStoreFloat3(&vPosition, pGamObject->Get_Component<CTransform>()->Get_State(STATE::POSITION));
|
||||
|
||||
_float3 vScale = pGamObject->Get_Component<CTransform>()->Get_Scale();
|
||||
|
||||
_float3 vRotation = {};
|
||||
XMStoreFloat3(&vRotation, pGamObject->Get_Component<CTransform>()->Get_RollPitchYawVector());
|
||||
vRotation.x = XMConvertToDegrees(vRotation.x);
|
||||
vRotation.y = XMConvertToDegrees(vRotation.y);
|
||||
vRotation.z = XMConvertToDegrees(vRotation.z);
|
||||
|
||||
tinyxml2::XMLElement* Position = doc.NewElement("Position");
|
||||
Position->SetAttribute("x", vPosition.x);
|
||||
Position->SetAttribute("y", vPosition.y);
|
||||
Position->SetAttribute("z", vPosition.z);
|
||||
object->InsertEndChild(Position);
|
||||
|
||||
tinyxml2::XMLElement* Scale = doc.NewElement("Scale");
|
||||
Scale->SetAttribute("x", vScale.x);
|
||||
Scale->SetAttribute("y", vScale.y);
|
||||
Scale->SetAttribute("z", vScale.z);
|
||||
object->InsertEndChild(Scale);
|
||||
|
||||
tinyxml2::XMLElement* Rotation = doc.NewElement("Rotation");
|
||||
Rotation->SetAttribute("x", vRotation.x);
|
||||
Rotation->SetAttribute("y", vRotation.y);
|
||||
Rotation->SetAttribute("z", vRotation.z);
|
||||
object->InsertEndChild(Rotation);
|
||||
#pragma endregion
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
#pragma region ELEMENT_INTERACTABEL
|
||||
pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Element_Interactable"));
|
||||
|
||||
if (nullptr != pLayer)
|
||||
{
|
||||
const list<CGameObject*>* pList = pLayer->Get_Objects();
|
||||
|
||||
for (auto pGamObject : *pList)
|
||||
{
|
||||
CMapElement* pElement = dynamic_cast<CMapElement*>(pGamObject);
|
||||
|
||||
if (nullptr == pElement)
|
||||
return E_FAIL;
|
||||
|
||||
_uint iLodLevel = pElement->Get_LodLevel();
|
||||
|
||||
tinyxml2::XMLElement* object = doc.NewElement("Object");
|
||||
object->SetAttribute("Type", ENUM_CLASS(MAPOBJECT_TYPE::ELEMENT_INTERACT));
|
||||
object->SetAttribute("Lod_Level", iLodLevel);
|
||||
land->InsertEndChild(object);
|
||||
|
||||
#pragma region PROTOTYPETAG
|
||||
for (_uint i = 0; i < iLodLevel + 1; ++i)
|
||||
{
|
||||
tinyxml2::XMLElement* prototype = doc.NewElement("PrototypeTag");
|
||||
prototype->SetText(CMyTools::ToString(pElement->Get_PrototypeTag(i)).c_str());
|
||||
object->InsertEndChild(prototype);
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
#pragma region TRANSFORM
|
||||
_float3 vPosition = {};
|
||||
XMStoreFloat3(&vPosition, pGamObject->Get_Component<CTransform>()->Get_State(STATE::POSITION));
|
||||
|
||||
_float3 vScale = pGamObject->Get_Component<CTransform>()->Get_Scale();
|
||||
|
||||
_float3 vRotation = {};
|
||||
XMStoreFloat3(&vRotation, pGamObject->Get_Component<CTransform>()->Get_RollPitchYawVector());
|
||||
vRotation.x = XMConvertToDegrees(vRotation.x);
|
||||
vRotation.y = XMConvertToDegrees(vRotation.y);
|
||||
vRotation.z = XMConvertToDegrees(vRotation.z);
|
||||
|
||||
tinyxml2::XMLElement* Position = doc.NewElement("Position");
|
||||
Position->SetAttribute("x", vPosition.x);
|
||||
Position->SetAttribute("y", vPosition.y);
|
||||
Position->SetAttribute("z", vPosition.z);
|
||||
object->InsertEndChild(Position);
|
||||
|
||||
tinyxml2::XMLElement* Scale = doc.NewElement("Scale");
|
||||
Scale->SetAttribute("x", vScale.x);
|
||||
Scale->SetAttribute("y", vScale.y);
|
||||
Scale->SetAttribute("z", vScale.z);
|
||||
object->InsertEndChild(Scale);
|
||||
|
||||
tinyxml2::XMLElement* Rotation = doc.NewElement("Rotation");
|
||||
Rotation->SetAttribute("x", vRotation.x);
|
||||
Rotation->SetAttribute("y", vRotation.y);
|
||||
Rotation->SetAttribute("z", vRotation.z);
|
||||
object->InsertEndChild(Rotation);
|
||||
#pragma endregion
|
||||
|
||||
}
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
|
||||
// ÀúÀå
|
||||
if (doc.SaveFile(strPath.c_str()) != tinyxml2::XML_SUCCESS) {
|
||||
MSG_BOX("Failed to Save File");
|
||||
}
|
||||
@@ -235,11 +383,6 @@ HRESULT CMapObject_Manager::Save_MapData(const _char* pFileName)
|
||||
MSG_BOX("Succeed to Save File");
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
||||
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -300,12 +443,15 @@ HRESULT CMapObject_Manager::Save_ContainerData(const _char* pFileName, const _ch
|
||||
{
|
||||
// <PartObject>
|
||||
tinyxml2::XMLElement* PartObject = doc.NewElement("PartObject");
|
||||
PartObject->SetAttribute("Lod_Level", pMapObject->Get_LodLevel());
|
||||
_uint iLodLvel = pMapObject->Get_LodLevel();
|
||||
|
||||
PartObject->SetAttribute("Lod_Level", iLodLvel);
|
||||
PartObject->SetAttribute("Key_Index", pMapObject->Get_iKeyIndex());
|
||||
container->InsertEndChild(PartObject);
|
||||
|
||||
for (_uint i = 0; i < pMapObject->Get_LodLevel() + 1; ++i)
|
||||
{
|
||||
// <PrototypeTag>ÅØ½ºÆ®</PrototypeTag>
|
||||
// <PrototypeTag>ÅØ½ºÆ®</PrototypeTag>
|
||||
tinyxml2::XMLElement* proto = doc.NewElement("PrototypeTag");
|
||||
proto->SetText(CMyTools::ToString(pMapObject->Get_PrototypeTag(i)).c_str());
|
||||
PartObject->InsertEndChild(proto);
|
||||
@@ -352,7 +498,7 @@ HRESULT CMapObject_Manager::Save_ContainerData(const _char* pFileName, const _ch
|
||||
m_pSelectObject = nullptr;
|
||||
#pragma endregion
|
||||
|
||||
// ÀúÀå
|
||||
// ÀúÀå
|
||||
if (doc.SaveFile(strPath.c_str()) != tinyxml2::XML_SUCCESS) {
|
||||
MSG_BOX("Failed to Save File");
|
||||
}
|
||||
@@ -417,86 +563,96 @@ HRESULT CMapObject_Manager::Load_MapData(const _char* pFileName)
|
||||
for (auto* PartObject = Container->FirstChildElement("PartObject"); PartObject; PartObject = PartObject->NextSiblingElement("PartObject"))
|
||||
{
|
||||
_uint iLodLevel = {};
|
||||
_uint iKeyIndex = {};
|
||||
|
||||
PartObject->QueryUnsignedAttribute("Lod_Level", &iLodLevel);
|
||||
|
||||
#pragma region MAPOBJECT_STATIC
|
||||
if (0 == iLodLevel) /* MapObject_Static */
|
||||
{
|
||||
MAPOBJECT_STATIC_DESC Desc = {};
|
||||
string strTag = {};
|
||||
auto* PrototypeTag = PartObject->FirstChildElement("PrototypeTag");
|
||||
|
||||
strTag = PrototypeTag->GetText();
|
||||
|
||||
Desc.strModelPrototypeTag = CMyTools::ToWstring(strTag);
|
||||
|
||||
Desc.pParentTransform = pContainerObject->Get_Component<CTransform>();
|
||||
const string strKey = strTag;
|
||||
|
||||
/* Position */
|
||||
tinyxml2::XMLElement* Position = PartObject->FirstChildElement("Position");
|
||||
Position->QueryFloatAttribute("x", &Desc.vPosition.x);
|
||||
Position->QueryFloatAttribute("y", &Desc.vPosition.y);
|
||||
Position->QueryFloatAttribute("z", &Desc.vPosition.z);
|
||||
|
||||
/* Scale */
|
||||
tinyxml2::XMLElement* Scale = PartObject->FirstChildElement("Scale");
|
||||
Scale->QueryFloatAttribute("x", &Desc.vScale.x);
|
||||
Scale->QueryFloatAttribute("y", &Desc.vScale.y);
|
||||
Scale->QueryFloatAttribute("z", &Desc.vScale.z);
|
||||
|
||||
/* Rotation */
|
||||
tinyxml2::XMLElement* Rotation = PartObject->FirstChildElement("Rotation");
|
||||
Rotation->QueryFloatAttribute("x", &Desc.vRotation.x);
|
||||
Rotation->QueryFloatAttribute("y", &Desc.vRotation.y);
|
||||
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
|
||||
|
||||
pContainerObject->Add_Part<CMapObject_Static>(strKey, g_iStaticLevel, nullptr, &Desc);
|
||||
}
|
||||
#pragma endregion
|
||||
PartObject->QueryUnsignedAttribute("Key_Index", &iKeyIndex);
|
||||
|
||||
#pragma region MAPOBJECT_LOD
|
||||
else
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
string strTag = {};
|
||||
for (auto* PrototypeTag = PartObject->FirstChildElement("PrototypeTag"); PrototypeTag; PrototypeTag = PrototypeTag->NextSiblingElement("PrototypeTag"))
|
||||
{
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
string strTag = {};
|
||||
for (auto* PrototypeTag = PartObject->FirstChildElement("PrototypeTag"); PrototypeTag; PrototypeTag = PrototypeTag->NextSiblingElement("PrototypeTag"))
|
||||
{
|
||||
strTag = PrototypeTag->GetText();
|
||||
strTag = PrototypeTag->GetText();
|
||||
|
||||
Desc.ModelPrototypeTags.push_back(CMyTools::ToWstring(strTag));
|
||||
}
|
||||
|
||||
Desc.pParentTransform = pContainerObject->Get_Component<CTransform>();
|
||||
const string strKey = strTag;
|
||||
|
||||
/* Position */
|
||||
tinyxml2::XMLElement* Position = PartObject->FirstChildElement("Position");
|
||||
Position->QueryFloatAttribute("x", &Desc.vPosition.x);
|
||||
Position->QueryFloatAttribute("y", &Desc.vPosition.y);
|
||||
Position->QueryFloatAttribute("z", &Desc.vPosition.z);
|
||||
|
||||
/* Scale */
|
||||
tinyxml2::XMLElement* Scale = PartObject->FirstChildElement("Scale");
|
||||
Scale->QueryFloatAttribute("x", &Desc.vScale.x);
|
||||
Scale->QueryFloatAttribute("y", &Desc.vScale.y);
|
||||
Scale->QueryFloatAttribute("z", &Desc.vScale.z);
|
||||
|
||||
/* Rotation */
|
||||
tinyxml2::XMLElement* Rotation = PartObject->FirstChildElement("Rotation");
|
||||
Rotation->QueryFloatAttribute("x", &Desc.vRotation.x);
|
||||
Rotation->QueryFloatAttribute("y", &Desc.vRotation.y);
|
||||
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
|
||||
|
||||
pContainerObject->Add_Part<CMapObject_LOD>(strKey, g_iStaticLevel, nullptr, &Desc);
|
||||
Desc.ModelPrototypeTags.push_back(CMyTools::ToWstring(strTag));
|
||||
}
|
||||
|
||||
Desc.iMaxLodLevel = iLodLevel;
|
||||
Desc.pParentTransform = pContainerObject->Get_Component<CTransform>();
|
||||
const string strKey = CMyTools::ToString(Desc.ModelPrototypeTags.front()) + to_string(iKeyIndex);
|
||||
|
||||
/* Position */
|
||||
tinyxml2::XMLElement* Position = PartObject->FirstChildElement("Position");
|
||||
Position->QueryFloatAttribute("x", &Desc.vPosition.x);
|
||||
Position->QueryFloatAttribute("y", &Desc.vPosition.y);
|
||||
Position->QueryFloatAttribute("z", &Desc.vPosition.z);
|
||||
|
||||
/* Scale */
|
||||
tinyxml2::XMLElement* Scale = PartObject->FirstChildElement("Scale");
|
||||
Scale->QueryFloatAttribute("x", &Desc.vScale.x);
|
||||
Scale->QueryFloatAttribute("y", &Desc.vScale.y);
|
||||
Scale->QueryFloatAttribute("z", &Desc.vScale.z);
|
||||
|
||||
/* Rotation */
|
||||
tinyxml2::XMLElement* Rotation = PartObject->FirstChildElement("Rotation");
|
||||
Rotation->QueryFloatAttribute("x", &Desc.vRotation.x);
|
||||
Rotation->QueryFloatAttribute("y", &Desc.vRotation.y);
|
||||
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
|
||||
|
||||
CMapObject_LOD* pMapObject;
|
||||
|
||||
if (FAILED(pContainerObject->Add_Part<CMapObject_LOD>(strKey, g_iStaticLevel, &pMapObject, &Desc)))
|
||||
return E_FAIL;
|
||||
|
||||
pMapObject->Set_KeyIndex(iKeyIndex);
|
||||
|
||||
SAFE_RELEASE(pMapObject);
|
||||
#pragma endregion
|
||||
|
||||
}
|
||||
#pragma endregion
|
||||
}
|
||||
|
||||
for (auto* Object = root->FirstChildElement("Object"); Object; Object = Object->NextSiblingElement("Object"))
|
||||
{
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
|
||||
MAPOBJECT_TYPE eType = {};
|
||||
|
||||
Object->QueryUnsignedAttribute("Type", (_uint*)(&eType));
|
||||
Object->QueryUnsignedAttribute("Lod_Level", &Desc.iMaxLodLevel);
|
||||
|
||||
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);
|
||||
|
||||
string strTag = {};
|
||||
|
||||
for (auto* PrototypeTag = Object->FirstChildElement("PrototypeTag"); PrototypeTag; PrototypeTag = PrototypeTag->NextSiblingElement("PrototypeTag"))
|
||||
{
|
||||
strTag = PrototypeTag->GetText();
|
||||
|
||||
Desc.ModelPrototypeTags.push_back(CMyTools::ToWstring(strTag));
|
||||
}
|
||||
|
||||
if(MAPOBJECT_TYPE::ELEMENT_STATIC == eType)
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Static>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Static"), &Desc);
|
||||
else if(MAPOBJECT_TYPE::ELEMENT_INTERACT == eType)
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Interactable>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Interact"), &Desc);
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -568,48 +724,12 @@ HRESULT CMapObject_Manager::Load_ContainerData(const _char* pFileName, const _ch
|
||||
for (auto* PartObject = TargetContainer->FirstChildElement("PartObject"); PartObject; PartObject = PartObject->NextSiblingElement("PartObject"))
|
||||
{
|
||||
_uint iLodLevel = {};
|
||||
_uint iKeyIndex = {};
|
||||
|
||||
PartObject->QueryUnsignedAttribute("Lod_Level", &iLodLevel);
|
||||
|
||||
#pragma region MAPOBJECT_STATIC
|
||||
if (0 == iLodLevel) /* MapObject_Static */
|
||||
{
|
||||
MAPOBJECT_STATIC_DESC Desc = {};
|
||||
string strTag = {};
|
||||
auto* PrototypeTag = PartObject->FirstChildElement("PrototypeTag");
|
||||
|
||||
strTag = PrototypeTag->GetText();
|
||||
|
||||
Desc.strModelPrototypeTag = CMyTools::ToWstring(strTag);
|
||||
Desc.iMaxLodLevel = iLodLevel;
|
||||
Desc.pParentTransform = pContainerObject->Get_Component<CTransform>();
|
||||
const string strKey = strTag;
|
||||
|
||||
/* Position */
|
||||
tinyxml2::XMLElement* Position = PartObject->FirstChildElement("Position");
|
||||
Position->QueryFloatAttribute("x", &Desc.vPosition.x);
|
||||
Position->QueryFloatAttribute("y", &Desc.vPosition.y);
|
||||
Position->QueryFloatAttribute("z", &Desc.vPosition.z);
|
||||
|
||||
/* Scale */
|
||||
tinyxml2::XMLElement* Scale = PartObject->FirstChildElement("Scale");
|
||||
Scale->QueryFloatAttribute("x", &Desc.vScale.x);
|
||||
Scale->QueryFloatAttribute("y", &Desc.vScale.y);
|
||||
Scale->QueryFloatAttribute("z", &Desc.vScale.z);
|
||||
|
||||
/* Rotation */
|
||||
tinyxml2::XMLElement* Rotation = PartObject->FirstChildElement("Rotation");
|
||||
Rotation->QueryFloatAttribute("x", &Desc.vRotation.x);
|
||||
Rotation->QueryFloatAttribute("y", &Desc.vRotation.y);
|
||||
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
|
||||
|
||||
pContainerObject->Add_Part<CMapObject_Static>(strKey, g_iStaticLevel, nullptr, &Desc);
|
||||
}
|
||||
#pragma endregion
|
||||
PartObject->QueryUnsignedAttribute("Key_Index", &iKeyIndex);
|
||||
|
||||
#pragma region MAPOBJECT_LOD
|
||||
else
|
||||
{
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
string strTag = {};
|
||||
for (auto* PrototypeTag = PartObject->FirstChildElement("PrototypeTag"); PrototypeTag; PrototypeTag = PrototypeTag->NextSiblingElement("PrototypeTag"))
|
||||
@@ -620,7 +740,7 @@ HRESULT CMapObject_Manager::Load_ContainerData(const _char* pFileName, const _ch
|
||||
}
|
||||
Desc.iMaxLodLevel = iLodLevel;
|
||||
Desc.pParentTransform = pContainerObject->Get_Component<CTransform>();
|
||||
const string strKey = strTag;
|
||||
const string strKey = CMyTools::ToString(Desc.ModelPrototypeTags.front()) + to_string(iKeyIndex);
|
||||
|
||||
/* Position */
|
||||
tinyxml2::XMLElement* Position = PartObject->FirstChildElement("Position");
|
||||
@@ -641,7 +761,6 @@ HRESULT CMapObject_Manager::Load_ContainerData(const _char* pFileName, const _ch
|
||||
Rotation->QueryFloatAttribute("z", &Desc.vRotation.z);
|
||||
|
||||
pContainerObject->Add_Part<CMapObject_LOD>(strKey, g_iStaticLevel, nullptr, &Desc);
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
}
|
||||
@@ -661,69 +780,29 @@ void CMapObject_Manager::Update_PrototypeList()
|
||||
{
|
||||
auto& Tag = m_ModelPrototypeTags[i];
|
||||
|
||||
if (_wstring::npos != Tag.find(L"Lod")){
|
||||
if (_wstring::npos != Tag.find(L"Lod")) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (ImGui::Button(CMyTools::ToString(Tag).c_str()))
|
||||
{
|
||||
vector<_uint> LodModelIndices;
|
||||
|
||||
if(false == Find_Lod_Prototype(Tag, LodModelIndices))
|
||||
switch (m_eType)
|
||||
{
|
||||
MAPOBJECT_STATIC_DESC Desc = {};
|
||||
case Editor::CMapObject_Manager::ADD_TYPE::CONTAINER:
|
||||
Create_PartObject(Tag);
|
||||
break;
|
||||
|
||||
Desc.strModelPrototypeTag = Tag;
|
||||
Desc.pParentTransform = m_pTransformCom;
|
||||
Desc.vPosition = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.iModelPathIndex = i;
|
||||
case Editor::CMapObject_Manager::ADD_TYPE::ELEMENT_STATIC:
|
||||
Create_Elemnt_Static(Tag);
|
||||
break;
|
||||
|
||||
CMapObject_Static* pMapObject = { nullptr };
|
||||
const string strKey = CMyTools::ToString(Tag);
|
||||
|
||||
pMapObject = m_pGameInstance->Clone_Prototype<CMapObject_Static>(g_iStaticLevel, &Desc);
|
||||
|
||||
/* if(FAILED(m_pContainer->Add_Part<CMapObject_Static>(strKey, 0, &pMapObject, &Desc)))
|
||||
break;*/
|
||||
|
||||
m_MapObjects.push_back(pMapObject);
|
||||
}
|
||||
else
|
||||
{
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
|
||||
vector<_wstring> PrototypeTags;
|
||||
|
||||
PrototypeTags.push_back(Tag);
|
||||
Desc.iMaxLodLevel = 0;
|
||||
Desc.ModelPrototypeTags = PrototypeTags;
|
||||
Desc.pParentTransform = m_pTransformCom;
|
||||
Desc.vPosition = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.pModelPathIndices = &LodModelIndices;
|
||||
|
||||
CMapObject_LOD* pMapObject = { nullptr };
|
||||
const string strKey = CMyTools::ToString(Tag);
|
||||
|
||||
pMapObject = m_pGameInstance->Clone_Prototype<CMapObject_LOD>(g_iStaticLevel, &Desc);
|
||||
|
||||
//if (FAILED(m_pContainer->Add_Part<CMapObject_LOD>(strKey, 0, &pMapObject, &Desc)))
|
||||
// break;
|
||||
|
||||
m_MapObjects.push_back(pMapObject);
|
||||
|
||||
for (_uint i = 0; i < LodModelIndices.size(); ++i)
|
||||
{
|
||||
_wstring strLodTag = Tag + L"_Lod" + to_wstring(i + 1);
|
||||
|
||||
pMapObject->Add_LodModel(strLodTag.c_str());
|
||||
}
|
||||
|
||||
|
||||
case Editor::CMapObject_Manager::ADD_TYPE::ELEMENT_INTERACT:
|
||||
Create_Elemnt_Interact(Tag);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
GUI::End();
|
||||
@@ -732,10 +811,7 @@ void CMapObject_Manager::Update_PrototypeList()
|
||||
|
||||
void CMapObject_Manager::Update_ObjectList()
|
||||
{
|
||||
//CLayer* pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_MapObject"));
|
||||
|
||||
//if (nullptr == pLayer)
|
||||
// return;
|
||||
CLayer* pLayer = { nullptr };
|
||||
|
||||
//m_pMapObjects = pLayer->Get_Objects();
|
||||
|
||||
@@ -744,41 +820,93 @@ void CMapObject_Manager::Update_ObjectList()
|
||||
_uint iObjectIndex = {};
|
||||
string strSrc;
|
||||
|
||||
if (false == m_MapObjects.empty())
|
||||
if(ADD_TYPE::CONTAINER == m_eType)
|
||||
{
|
||||
for (auto pMapObject : m_MapObjects)
|
||||
if (false == m_MapObjects.empty())
|
||||
{
|
||||
CMapObject* pCurrentMapObject = static_cast<CMapObject*>(pMapObject);
|
||||
for (auto pMapObject : m_MapObjects)
|
||||
{
|
||||
CMapObject* pCurrentMapObject = static_cast<CMapObject*>(pMapObject);
|
||||
|
||||
if (nullptr == pCurrentMapObject)
|
||||
continue;
|
||||
|
||||
wstring strPrototypeTag = pCurrentMapObject->Get_PrototypeTag();
|
||||
|
||||
strSrc = CMyTools::ToString(strPrototypeTag) + to_string(iObjectIndex) + "##" + to_string(iObjectIndex++);
|
||||
|
||||
if (ImGui::Button(strSrc.c_str()))
|
||||
{
|
||||
m_pSelectObject = pCurrentMapObject;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ADD_TYPE::ELEMENT_STATIC == m_eType)
|
||||
pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Element_Static"));
|
||||
else if (ADD_TYPE::ELEMENT_INTERACT == m_eType)
|
||||
pLayer = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::MAP), TEXT("Layer_Element_Interact"));
|
||||
|
||||
if (nullptr == pLayer)
|
||||
{
|
||||
GUI::End();
|
||||
return;
|
||||
}
|
||||
|
||||
const list<class CGameObject*>* pObjectList = pLayer->Get_Objects();
|
||||
|
||||
for (auto pObject : *pObjectList)
|
||||
{
|
||||
CMapElement* pCurrentMapObject = static_cast<CMapElement*>(pObject);
|
||||
|
||||
if (nullptr == pCurrentMapObject)
|
||||
continue;
|
||||
|
||||
wstring strPrototypeTag = pCurrentMapObject->Get_PrototypeTag();
|
||||
wstring strPrototypeTag = pCurrentMapObject->Get_PrototypeTag(0);
|
||||
|
||||
strSrc = CMyTools::ToString(strPrototypeTag) + to_string(iObjectIndex) + "##" + to_string(iObjectIndex++);
|
||||
|
||||
if (ImGui::Button(strSrc.c_str()))
|
||||
{
|
||||
m_pSelectObject = pCurrentMapObject;
|
||||
m_pSelectElemnt = pCurrentMapObject;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
GUI::End();
|
||||
}
|
||||
|
||||
void CMapObject_Manager::Update_Edit()
|
||||
{
|
||||
GUI::Begin("Edit");
|
||||
if (m_pGameInstance->Mouse_Down(DIM_4))
|
||||
m_pSelectObject = nullptr;
|
||||
|
||||
if (nullptr != m_pSelectObject)
|
||||
if (ADD_TYPE::CONTAINER == m_eType)
|
||||
{
|
||||
m_pSelectObject->Describe_Entity();
|
||||
if (m_pSelectObject->isDead())
|
||||
if (m_pGameInstance->Mouse_Down(DIM_4))
|
||||
m_pSelectObject = nullptr;
|
||||
|
||||
if (nullptr != m_pSelectObject)
|
||||
{
|
||||
m_pSelectObject->Describe_Entity();
|
||||
if (m_pSelectObject->isDead())
|
||||
m_pSelectObject = nullptr;
|
||||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (m_pGameInstance->Mouse_Down(DIM_4))
|
||||
m_pSelectElemnt = nullptr;
|
||||
|
||||
if (nullptr != m_pSelectElemnt)
|
||||
{
|
||||
m_pSelectElemnt->Describe_Entity();
|
||||
if (m_pSelectElemnt->isDead())
|
||||
m_pSelectElemnt = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
GUI::End();
|
||||
@@ -823,12 +951,111 @@ void CMapObject_Manager::Update_ContainerObject()
|
||||
GUI::End();
|
||||
}
|
||||
|
||||
void CMapObject_Manager::Create_PartObject(_wstring& strPrototypeTag)
|
||||
{
|
||||
vector<_uint> LodModelIndices;
|
||||
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
|
||||
vector<_wstring> PrototypeTags;
|
||||
|
||||
Find_Lod_Prototype(strPrototypeTag, LodModelIndices);
|
||||
|
||||
PrototypeTags.push_back(strPrototypeTag);
|
||||
|
||||
for (_uint i = 0; i < LodModelIndices.size(); ++i)
|
||||
{
|
||||
_wstring strLodTag = strPrototypeTag + L"_Lod" + to_wstring(i + 1);
|
||||
PrototypeTags.push_back(strLodTag);
|
||||
}
|
||||
|
||||
Desc.iMaxLodLevel = (_uint)LodModelIndices.size() - 1;
|
||||
Desc.ModelPrototypeTags = PrototypeTags;
|
||||
Desc.pParentTransform = m_pTransformCom;
|
||||
Desc.vPosition = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.pModelPathIndices = &LodModelIndices;
|
||||
|
||||
CMapObject_LOD* pMapObject = { nullptr };
|
||||
const string strKey = CMyTools::ToString(strPrototypeTag);
|
||||
|
||||
pMapObject = m_pGameInstance->Clone_Prototype<CMapObject_LOD>(g_iStaticLevel, &Desc);
|
||||
pMapObject->Set_KeyIndex(Get_KeyCount(strPrototypeTag));
|
||||
|
||||
m_MapObjects.push_back(pMapObject);
|
||||
}
|
||||
|
||||
void CMapObject_Manager::Create_Elemnt_Static(_wstring& strPrototypeTag)
|
||||
{
|
||||
vector<_uint> LodModelIndices;
|
||||
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
|
||||
vector<_wstring> PrototypeTags;
|
||||
|
||||
Find_Lod_Prototype(strPrototypeTag, LodModelIndices);
|
||||
|
||||
PrototypeTags.push_back(strPrototypeTag);
|
||||
|
||||
for (_uint i = 0; i < LodModelIndices.size(); ++i)
|
||||
{
|
||||
_wstring strLodTag = strPrototypeTag + L"_Lod" + to_wstring(i + 1);
|
||||
PrototypeTags.push_back(strLodTag);
|
||||
}
|
||||
|
||||
Desc.iMaxLodLevel = (_uint)LodModelIndices.size() - 1;
|
||||
Desc.ModelPrototypeTags = PrototypeTags;
|
||||
Desc.pParentTransform = m_pTransformCom;
|
||||
Desc.vPosition = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.pModelPathIndices = &LodModelIndices;
|
||||
|
||||
CMapElement_Static* pMapObject = { nullptr };
|
||||
const string strKey = CMyTools::ToString(strPrototypeTag);
|
||||
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Static>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Static"), &Desc);
|
||||
}
|
||||
|
||||
void CMapObject_Manager::Create_Elemnt_Interact(_wstring& strPrototypeTag)
|
||||
{
|
||||
vector<_uint> LodModelIndices;
|
||||
|
||||
MAPOBJECT_LOD_DESC Desc = {};
|
||||
|
||||
vector<_wstring> PrototypeTags;
|
||||
|
||||
Find_Lod_Prototype(strPrototypeTag, LodModelIndices);
|
||||
|
||||
PrototypeTags.push_back(strPrototypeTag);
|
||||
|
||||
for (_uint i = 0; i < LodModelIndices.size(); ++i)
|
||||
{
|
||||
_wstring strLodTag = strPrototypeTag + L"_Lod" + to_wstring(i + 1);
|
||||
PrototypeTags.push_back(strLodTag);
|
||||
}
|
||||
|
||||
Desc.iMaxLodLevel = (_uint)LodModelIndices.size() - 1;
|
||||
Desc.ModelPrototypeTags = PrototypeTags;
|
||||
Desc.pParentTransform = m_pTransformCom;
|
||||
Desc.vPosition = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vRotation = _float3(0.f, 0.f, 0.f);
|
||||
Desc.vScale = _float3(1.f, 1.f, 1.f);
|
||||
Desc.pModelPathIndices = &LodModelIndices;
|
||||
|
||||
CMapElement_Interactable* pMapObject = { nullptr };
|
||||
const string strKey = CMyTools::ToString(strPrototypeTag);
|
||||
|
||||
m_pGameInstance->Add_GameObject_ToLayer<CMapElement_Interactable>(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Element_Interact"), &Desc);
|
||||
}
|
||||
|
||||
_bool CMapObject_Manager::Find_Lod_Prototype(_wstring strPrototypeTag, vector<_uint>& LodModelIndices)
|
||||
{
|
||||
// for (auto& Tag : m_LODModelPrototypeTags)
|
||||
for(_uint i = 0 ; i < m_ModelPrototypeTags.size(); ++i)
|
||||
{
|
||||
if (_wstring::npos != m_ModelPrototypeTags[i].find(strPrototypeTag))
|
||||
if (_wstring::npos != m_ModelPrototypeTags[i].find(strPrototypeTag) && 5 > (m_ModelPrototypeTags[i].size() - strPrototypeTag.size()))
|
||||
LodModelIndices.push_back(i);
|
||||
}
|
||||
if (0 < LodModelIndices.size()) {
|
||||
@@ -839,6 +1066,16 @@ _bool CMapObject_Manager::Find_Lod_Prototype(_wstring strPrototypeTag, vector<_u
|
||||
// return true;
|
||||
}
|
||||
|
||||
_uint CMapObject_Manager::Get_KeyCount(_wstring strPrototypeTag)
|
||||
{
|
||||
auto iter = m_PartObjectKeyCount.find(strPrototypeTag);
|
||||
|
||||
if (iter == m_PartObjectKeyCount.end())
|
||||
return 0;
|
||||
|
||||
return iter->second++;
|
||||
}
|
||||
|
||||
|
||||
CMapObject_Manager* CMapObject_Manager::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext, vector<_wstring>& ModelPrototypeTags, vector<filesystem::path>& ModelPrototypePaths)
|
||||
{
|
||||
|
||||
@@ -130,6 +130,7 @@ HRESULT CModelParts::Bind_ShaderResources()
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -101,17 +101,18 @@ void CRootModelPart::Change_Model(_uint iIndex)
|
||||
pModel->Set_CurrentTrackPosition(m_fTrackPosition);
|
||||
pModel->Play_Animation(0.f);
|
||||
|
||||
|
||||
if (iIndex == ENUM_CLASS(PARTSTYPE::HEAD))
|
||||
if (iIndex == ENUM_CLASS(PARTSTYPE::BODY))
|
||||
{
|
||||
Set_MainModel(m_ModelParts[iIndex]->Get_Component<CModel>());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void CRootModelPart::Set_Animation(_uint iAnimIndex)
|
||||
{
|
||||
m_pMainModel->Set_AnimationIndex(iAnimIndex);
|
||||
|
||||
m_pMainModel->Set_CurrentTrackPosition(0.f);
|
||||
m_pMainModel->Play_Animation(0.f);
|
||||
for (auto& PartObject : m_ModelParts)
|
||||
{
|
||||
CModel* pModel = PartObject->Get_Component<CModel>();
|
||||
@@ -119,6 +120,7 @@ void CRootModelPart::Set_Animation(_uint iAnimIndex)
|
||||
{
|
||||
pModel->Set_AnimationIndex(m_pMainModel->Get_AnimIndex());
|
||||
pModel->Set_CurrentTrackPosition(m_pMainModel->Get_CurrentTrackPosition());
|
||||
pModel->Play_Animation(0.f);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -139,12 +141,12 @@ HRESULT CRootModelPart::Ready_PartObjects()
|
||||
|
||||
CModelParts* pModelPartsObject = { nullptr };
|
||||
|
||||
if (FAILED(Add_PartObject<CHead>("Human_Head", ENUM_CLASS(LEVEL::STATIC), reinterpret_cast<CHead**>(&pModelPartsObject), &PartsDesc)))
|
||||
if (FAILED(Add_PartObject<CBody>("Human_Body", ENUM_CLASS(LEVEL::STATIC), reinterpret_cast<CBody**>(&pModelPartsObject), &PartsDesc)))
|
||||
return E_FAIL;
|
||||
|
||||
m_ModelParts.push_back(pModelPartsObject);
|
||||
|
||||
if (FAILED(Add_PartObject<CBody>("Human_Body", ENUM_CLASS(LEVEL::STATIC), reinterpret_cast<CBody**>(&pModelPartsObject), &PartsDesc)))
|
||||
if (FAILED(Add_PartObject<CHead>("Human_Head", ENUM_CLASS(LEVEL::STATIC), reinterpret_cast<CHead**>(&pModelPartsObject), &PartsDesc)))
|
||||
return E_FAIL;
|
||||
|
||||
m_ModelParts.push_back(pModelPartsObject);
|
||||
|
||||
@@ -7,8 +7,6 @@ NS_BEGIN(Editor)
|
||||
|
||||
class CBuildingContainer final : public CMapContainer
|
||||
{
|
||||
|
||||
|
||||
public:
|
||||
CBuildingContainer(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CBuildingContainer(const CBuildingContainer& rhs);
|
||||
|
||||
@@ -1,47 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include "Editor_Define.h"
|
||||
#include "GameObject.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
class CShader;
|
||||
class CModel;
|
||||
NS_END
|
||||
|
||||
NS_BEGIN(Editor)
|
||||
|
||||
class CDummy_Goblin final : public CGameObject
|
||||
{
|
||||
private:
|
||||
CDummy_Goblin(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CDummy_Goblin(const CDummy_Goblin& Prototype);
|
||||
virtual ~CDummy_Goblin() = 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;
|
||||
|
||||
private:
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
CModel* m_pModelCom = { nullptr };
|
||||
_bool m_bRimLight = { true };
|
||||
_float m_fRimLightPower = { 3.2f };
|
||||
_float m_fRimLightStrength = { 3.04f };
|
||||
_float3 m_vRimLightColor = { 69.f / 255.f, 5.f / 255.f, 10.f / 255.f };
|
||||
|
||||
private:
|
||||
HRESULT Ready_Components();
|
||||
HRESULT Bind_ShaderResources();
|
||||
|
||||
public:
|
||||
static CDummy_Goblin* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr) override;
|
||||
virtual void Free() override;
|
||||
virtual void Describe_Entity() override;
|
||||
};
|
||||
|
||||
NS_END
|
||||
@@ -1,47 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include "Editor_Define.h"
|
||||
#include "GameObject.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
class CShader;
|
||||
class CModel;
|
||||
NS_END
|
||||
|
||||
NS_BEGIN(Editor)
|
||||
|
||||
class CDummy_Goblin_Head final : public CGameObject
|
||||
{
|
||||
private:
|
||||
CDummy_Goblin_Head(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CDummy_Goblin_Head(const CDummy_Goblin_Head& Prototype);
|
||||
virtual ~CDummy_Goblin_Head() = 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;
|
||||
|
||||
private:
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
CModel* m_pModelCom = { nullptr };
|
||||
_bool m_bRimLight = { true };
|
||||
_float m_fRimLightPower = { 3.2f };
|
||||
_float m_fRimLightStrength = { 3.04f };
|
||||
_float3 m_vRimLightColor = { 69.f / 255.f, 5.f / 255.f, 10.f / 255.f };
|
||||
|
||||
private:
|
||||
HRESULT Ready_Components();
|
||||
HRESULT Bind_ShaderResources();
|
||||
|
||||
public:
|
||||
static CDummy_Goblin_Head* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr) override;
|
||||
virtual void Free() override;
|
||||
virtual void Describe_Entity() override;
|
||||
};
|
||||
|
||||
NS_END
|
||||
@@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "Editor_Define.h"
|
||||
#include "GameObject.h"
|
||||
#include "PartObject.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
class CInstance_Model;
|
||||
@@ -11,7 +11,7 @@ NS_END
|
||||
|
||||
NS_BEGIN(Editor)
|
||||
|
||||
class CEffectObject abstract : public CGameObject
|
||||
class CEffectObject abstract : public CPartObject
|
||||
{
|
||||
protected:
|
||||
CEffectObject(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
@@ -51,6 +51,13 @@ class CEffectObject abstract : public CGameObject
|
||||
_float2 m_vUVCutting = { 1.f ,1.f };
|
||||
_float2 m_vUVMaskCutting = { 1.f ,1.f };
|
||||
|
||||
_int m_iMaskMoveLerpOption = { 0 };
|
||||
_int m_iDiffuseMoveLerpOption = { 0 };
|
||||
_int m_iMaskNoiseMoveLerpOption = { 0 };
|
||||
_int m_iDiffuseNoiseMoveLerpOption = { 0 };
|
||||
_int m_iBlurWeight = { 0 };
|
||||
|
||||
|
||||
_bool m_isDiffuse = {};
|
||||
_bool m_isMasking = {};
|
||||
_bool m_isDissolve = {};
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "Editor_Define.h"
|
||||
#include "EffectObject.h"
|
||||
#include "ContainerObject.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
class CModel;
|
||||
@@ -10,7 +10,7 @@ NS_END
|
||||
|
||||
NS_BEGIN(Editor)
|
||||
|
||||
class CEffect_Editor final : public CEffectObject
|
||||
class CEffect_Editor final : public CContainerObject
|
||||
{
|
||||
private:
|
||||
CEffect_Editor(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
@@ -30,18 +30,24 @@ class CEffect_Editor final : public CEffectObject
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
virtual HRESULT Ready_Components(void* pArg) override;
|
||||
HRESULT Ready_Child();
|
||||
HRESULT Bind_ShaderResources() override;
|
||||
private:
|
||||
void ReadMaterials(const char* pDirectoryName);
|
||||
void ReadMaterial(_wstring wstrFileName, const char* pFilePath);
|
||||
|
||||
private:
|
||||
CGameObject* m_pEditEffect = { nullptr };
|
||||
map<_wstring, vector<pair<_wstring, _wstring>>> m_MatFiles = {}; // map<머테리얼 이름, vector<텍스쳐이름 , 텍스쳐 경로>>
|
||||
_string m_strCurrentEffectName = {};
|
||||
_uint m_iNumPart = { 0 };
|
||||
class CEditEffect* m_pEditEffect = { nullptr };
|
||||
map<_wstring, vector<pair<_wstring, _wstring>>> m_MatFiles = {}; // map<머테리얼 이름, vector<텍스쳐이름 , 텍스쳐 경로>>
|
||||
|
||||
public:
|
||||
static CEffect_Editor* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
|
||||
virtual void Free() override;
|
||||
void Describe_Entity() override;
|
||||
|
||||
|
||||
};
|
||||
|
||||
NS_END
|
||||
@@ -34,9 +34,12 @@ class CLevel_ObjectViewer final : public CLevel
|
||||
void Category_PartsModelList(const _char* Category, const _char* Layer);
|
||||
void Show_AnimList();
|
||||
void Show_ObjectList();
|
||||
void Object_Setting();
|
||||
void Dummy_Object_Setting();
|
||||
void Parts_Object_Setting();
|
||||
void Save_LayerName(const _char* Layer);
|
||||
_wchar* Save_ModelName(const _char* Category);
|
||||
void Load_KeyFrame();
|
||||
|
||||
|
||||
private:
|
||||
vector<CGameObject*> m_Objects;
|
||||
@@ -44,8 +47,10 @@ class CLevel_ObjectViewer final : public CLevel
|
||||
class CRootModelPart* m_HumanRoot = { nullptr };
|
||||
_int m_iObjectIndex = { 0 };
|
||||
_int m_iPartsObjectIndex = { 0 };
|
||||
|
||||
_float m_fAnimFrame = {};
|
||||
_float m_fKeyFrame = {};
|
||||
vector<_float> m_KeyFrame;
|
||||
vector<_string> m_Events;
|
||||
_string m_strEvent;
|
||||
_char m_szName[MAX_PATH];
|
||||
_wchar m_wszName[MAX_PATH];
|
||||
_wchar m_wszLayer[MAX_PATH];
|
||||
|
||||
@@ -17,6 +17,10 @@ class CMapElement abstract : public CGameObject
|
||||
CMapElement(const CMapElement& rhs);
|
||||
virtual ~CMapElement() = default;
|
||||
|
||||
public:
|
||||
_uint Get_LodLevel() const{ return m_iMaxLodLevel; }
|
||||
const _wstring& Get_PrototypeTag(_uint iIndex);
|
||||
|
||||
public:
|
||||
virtual void Priority_Update(_float fTimeDelta) override;
|
||||
virtual void Update(_float fTimeDelta) override;
|
||||
|
||||
@@ -25,7 +25,8 @@ class CMapObject abstract : public CPartObject
|
||||
|
||||
public:
|
||||
virtual _wstring Get_PrototypeTag(_uint iLodIndex = 0);
|
||||
virtual _uint Get_LodLevel() { return m_iMaxLodLevel; }
|
||||
_uint Get_LodLevel();
|
||||
_uint Get_iKeyIndex() const { return m_iKeyIndex; }
|
||||
|
||||
protected:
|
||||
|
||||
@@ -39,6 +40,7 @@ class CMapObject abstract : public CPartObject
|
||||
protected:
|
||||
_bool m_bSelected = {};
|
||||
|
||||
_uint m_iKeyIndex = {};
|
||||
_uint m_iMaxLodLevel = {};
|
||||
|
||||
_float3 m_vPosition = {};
|
||||
|
||||
@@ -23,12 +23,14 @@ class CMapObject_LOD final : public CMapObject // LOD
|
||||
public:
|
||||
virtual _wstring Get_PrototypeTag(_uint iLodIndex = 0);
|
||||
HRESULT Add_LodModel(const _tchar* pModelPrototypeTag);
|
||||
void Set_KeyIndex(_uint iIndex) {
|
||||
m_iKeyIndex = iIndex;
|
||||
}
|
||||
|
||||
private:
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
vector<CModel*> m_pModelComs;
|
||||
|
||||
_uint m_iMaxLodLevel = {};
|
||||
_uint m_iLodIndex = {};
|
||||
|
||||
vector<_wstring> m_ModelPrototypeTags;
|
||||
|
||||
@@ -12,6 +12,8 @@ NS_BEGIN(Editor)
|
||||
|
||||
class CMapObject_Manager final : public CGameObject
|
||||
{
|
||||
enum class ADD_TYPE {CONTAINER, ELEMENT_STATIC, ELEMENT_INTERACT};
|
||||
|
||||
private:
|
||||
CMapObject_Manager(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CMapObject_Manager(const CMapObject_Manager& Prototype);
|
||||
@@ -28,15 +30,20 @@ class CMapObject_Manager final : public CGameObject
|
||||
const filesystem::path Get_PrototypePath(_uint iModelIndex);
|
||||
|
||||
private:
|
||||
ADD_TYPE m_eType = {};
|
||||
|
||||
class CMapObject* m_pSelectObject = { nullptr };
|
||||
class CMapElement* m_pSelectElemnt = { nullptr };
|
||||
list<class CMapObject*> m_MapObjects = {};
|
||||
vector<_wstring> m_ModelPrototypeTags;
|
||||
map<_wstring, _uint> m_PartObjectKeyCount;
|
||||
vector<_wstring> m_LODModelPrototypeTags;
|
||||
vector<filesystem::path> m_ModelPrototypePaths;
|
||||
|
||||
_uint m_iContainerObjectIndex = {};
|
||||
|
||||
class CBuildingContainer* m_pContainer = { nullptr };
|
||||
_char m_szSaveFileName[MAX_PATH] = {};
|
||||
_char m_szSaveContainerName[MAX_PATH] = {};
|
||||
private:
|
||||
HRESULT Ready_Components();
|
||||
@@ -44,8 +51,9 @@ class CMapObject_Manager final : public CGameObject
|
||||
|
||||
#pragma region SAVE_LOAD
|
||||
HRESULT Save_MapData(const _char* pFileName);
|
||||
HRESULT Save_ContainerData(const _char* pFileName, const _char* pContainerName);
|
||||
HRESULT Load_MapData(const _char* pFileName);
|
||||
|
||||
HRESULT Save_ContainerData(const _char* pFileName, const _char* pContainerName);
|
||||
HRESULT Load_ContainerData(const _char* pFileName, const _char* pContainerName);
|
||||
#pragma endregion
|
||||
|
||||
@@ -54,8 +62,12 @@ class CMapObject_Manager final : public CGameObject
|
||||
void Update_Edit();
|
||||
void Update_ContainerObject();
|
||||
|
||||
_bool Find_Lod_Prototype(_wstring strPrototypeTag, vector<_uint>& LodModelIndices);
|
||||
void Create_PartObject(_wstring& strPrototypeTag);
|
||||
void Create_Elemnt_Static(_wstring& strPrototypeTag);
|
||||
void Create_Elemnt_Interact(_wstring& strPrototypeTag);
|
||||
|
||||
_bool Find_Lod_Prototype(_wstring strPrototypeTag, vector<_uint>& LodModelIndices);
|
||||
_uint Get_KeyCount(_wstring strPrototypeTag);
|
||||
public:
|
||||
static CMapObject_Manager* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext, vector<_wstring>& ModelPrototypeTags, vector<filesystem::path>& ModelPrototypePaths);
|
||||
virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr) override;
|
||||
|
||||
@@ -12,8 +12,7 @@ class CRootModelPart final : public CContainerObject
|
||||
{
|
||||
|
||||
public:
|
||||
enum class PARTSTYPE{HEAD,BODY,HAIR,END};
|
||||
|
||||
enum class PARTSTYPE{ BODY,HEAD,HAIR,END};
|
||||
public:
|
||||
void Set_PrototypeModelName(const _wchar* PrototypeModelName) { m_PrototypeModelName = PrototypeModelName; }
|
||||
void Set_ModelName(const _char* Name) { m_ModelName = Name; }
|
||||
|
||||
@@ -16,6 +16,7 @@ Texture2D g_Texture;
|
||||
float g_fLightRange;
|
||||
float g_fSpotInnerAngle;
|
||||
float g_fSpotOuterAngle;
|
||||
|
||||
vector g_vLightDir;
|
||||
vector g_vLightPos;
|
||||
vector g_vCamPosition;
|
||||
@@ -29,6 +30,7 @@ Texture2D g_ShadowTexture;
|
||||
Texture2D g_PreShadowTexture;
|
||||
Texture2D g_BlurTexture;
|
||||
Texture2D g_BlurXTexture;
|
||||
Texture2D g_BlurWeightTexture;
|
||||
|
||||
|
||||
|
||||
@@ -36,6 +38,8 @@ vector g_vLightDiffuse;
|
||||
vector g_vLightAmbient;
|
||||
vector g_vLightSpecular;
|
||||
|
||||
|
||||
|
||||
struct VS_IN
|
||||
{
|
||||
float3 vPosition : POSITION;
|
||||
@@ -219,13 +223,15 @@ PS_OUT_LIGHT PS_MAIN_SPOT(PS_IN In)
|
||||
return Out;
|
||||
}
|
||||
|
||||
float g_fWeights[13] =
|
||||
float g_fWeights[32] =
|
||||
{
|
||||
0.0090, 0.0218, 0.0448, 0.0784, 0.1169,
|
||||
0.1486, 0.1610, 0.1486, 0.1169, 0.0784,
|
||||
0.0448, 0.0218, 0.0090
|
||||
0.000400, 0.000700, 0.001200, 0.002000, 0.003200, 0.005000, 0.007500, 0.011000,
|
||||
0.015700, 0.021700, 0.029000, 0.037300, 0.046200, 0.055200, 0.063600, 0.070800,
|
||||
0.075900, 0.078500, 0.078500, 0.075900, 0.070800, 0.063600, 0.055200, 0.046200,
|
||||
0.037300, 0.029000, 0.021700, 0.015700, 0.011000, 0.007500, 0.005000, 0.003200
|
||||
};
|
||||
|
||||
|
||||
PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
{
|
||||
PS_OUT_BACKBUFFER Out;
|
||||
@@ -295,15 +301,31 @@ PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
|
||||
//{
|
||||
// Out.vBackBuffer *= 0.5f;
|
||||
//}
|
||||
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x;
|
||||
vTexcoord.y = In.vTexcoord.y + (float)i / g_vResolution.y;
|
||||
vTexcoord.y = In.vTexcoord.y + (float) i / g_vResolution.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurXTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBackBuffer += vColor;
|
||||
@@ -324,12 +346,32 @@ PS_OUT_BLUR_X PS_MAIN_BLUR_X(PS_IN In)
|
||||
float2 vTexcoord;
|
||||
float4 vColor = 0.f;
|
||||
|
||||
for (int i = -6; i < 7; ++i)
|
||||
//TODO 블러 조절 해보려햇는데 실패함..
|
||||
|
||||
//int iBlurWeight = g_BlurWeightTexture.Sample(ClampSampler, In.vTexcoord).r * 32.f;
|
||||
|
||||
//int iBlurMin;
|
||||
//int iBlurMax;
|
||||
|
||||
//if (iBlurWeight % 2 == 0)
|
||||
//{
|
||||
// iBlurMin = -1 * iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2;
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// iBlurMin = -iBlurWeight / 2;
|
||||
// iBlurMax = iBlurWeight / 2 + 1;
|
||||
//}
|
||||
|
||||
//[loop] // 변수로 루프돌리려면 반드시 필요함
|
||||
|
||||
for (int i = -15; i < 16; ++i)
|
||||
{
|
||||
vTexcoord.x = In.vTexcoord.x + (float) i / g_vResolution.x;
|
||||
vTexcoord.y = In.vTexcoord.y;
|
||||
|
||||
vColor += g_fWeights[i + 6] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
vColor += g_fWeights[i + 15] * g_BlurTexture.Sample(ClampSampler, vTexcoord);
|
||||
}
|
||||
|
||||
Out.vBlurX = vColor;
|
||||
|
||||
@@ -50,10 +50,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
|
||||
Out.vBackBuffer = float4(0.f, 0.f, 0.f, 0.f);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vDiffuseTexture = g_DiffuseTexture.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
vector vColorTexture = g_ColorTexture.Sample(ClampSampler, In.vTexcoord);
|
||||
|
||||
if (0.f == vColorTexture.a)
|
||||
{
|
||||
@@ -66,7 +63,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
switch (iOption)
|
||||
{
|
||||
case 1:
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
break;
|
||||
case 2:
|
||||
Out.vBackBuffer.rgb += vColorTexture.rgb;
|
||||
@@ -78,7 +75,7 @@ PS_OUT_BACKBUFFER PS_OUT_LASTCOLOR(PS_IN In)
|
||||
Out.vBackBuffer.rgb *= vColorTexture.rgb;
|
||||
break;
|
||||
case 5:
|
||||
Out.vBackBuffer.rgb /= vColorTexture.rgb;
|
||||
Out.vBackBuffer.rgb = vColorTexture.rgb;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
@@ -144,7 +144,8 @@ void CChannel::Update_TransformationMatirx(const vector<CBone*>& Bones, _float f
|
||||
}
|
||||
_matrix BoneTransformationMatrix = XMMatrixAffineTransformation(vScale, XMVectorSet(0.f, 0.f, 0.f, 1.f), vRotation, vTranslation);
|
||||
|
||||
Bones[m_iBoneIndex]->Set_TransformationMatrix(BoneTransformationMatrix);
|
||||
if(Bones.size()>m_iBoneIndex)
|
||||
Bones[m_iBoneIndex]->Set_TransformationMatrix(BoneTransformationMatrix);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -345,6 +345,7 @@ void CComputeShader::Free()
|
||||
Safe_Release(m_pOutputUAV[i]);
|
||||
Safe_Release(m_pOutputBuffer[i]);
|
||||
Safe_Release(m_pOutputSRV[i]);
|
||||
Safe_Release(m_pOutputStagingBuffer[i]);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include "Mesh.h"
|
||||
#include "GameInstance.h"
|
||||
#include "ComputeShader.h"
|
||||
#include "Bone.h"
|
||||
|
||||
CInstance_Model::CInstance_Model(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
:CComponent{ pDevice , pContext }
|
||||
@@ -427,6 +428,9 @@ void CInstance_Model::Free()
|
||||
for (auto& pMesh : m_Meshes)
|
||||
Safe_Release(pMesh);
|
||||
|
||||
for (auto& pBone : m_Bones)
|
||||
Safe_Release(pBone);
|
||||
|
||||
Safe_Release(m_pComputeShader);
|
||||
Safe_Release(m_pConstantBuffer);
|
||||
Safe_Release(m_pParticleValueBuffer);
|
||||
|
||||
@@ -113,8 +113,8 @@ void CRenderer::Render()
|
||||
Render_Effect();
|
||||
Render_NonLight();
|
||||
Render_Blend();
|
||||
Render_UI();
|
||||
Render_LastColor();
|
||||
Render_UI();
|
||||
|
||||
#ifdef _DEBUG
|
||||
if(m_pGameInstance->Key_Pressing(DIK_F10))
|
||||
@@ -301,6 +301,10 @@ void CRenderer::Render_Combined()
|
||||
if (FAILED(m_pGameInstance->Bind_RenderTarget(TEXT("Target_Blur_X"), m_pShader, "g_BlurXTexture"))) {
|
||||
return;
|
||||
}
|
||||
if (FAILED(m_pGameInstance->Bind_RenderTarget(TEXT("Target_Blur_Weight"), m_pShader, "g_BlurWeightTexture"))) {
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
m_pShader->Begin(ENUM_CLASS(SHADER_PASS_DEFERRED::COMBINED));
|
||||
@@ -379,6 +383,11 @@ void CRenderer::Render_Blur()
|
||||
return;
|
||||
}
|
||||
|
||||
if (FAILED(m_pGameInstance->Bind_RenderTarget(TEXT("Target_Blur_Weight"), m_pShader, "g_BlurWeightTexture"))) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
m_pShader->Begin(ENUM_CLASS(SHADER_PASS_DEFERRED::BLUR));
|
||||
|
||||
m_pVIBuffer->Bind_Resources();
|
||||
@@ -588,6 +597,12 @@ HRESULT CRenderer::Initialize()
|
||||
}
|
||||
|
||||
/* Target_Blur */
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_RenderTarget(TEXT("Target_Blur_Weight"), (_uint)Viewport.Width, (_uint)Viewport.Height,
|
||||
DXGI_FORMAT_R8G8B8A8_UNORM, _float4(0.0f, 0.0f, 0.0f, 1.0f)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_RenderTarget(TEXT("Target_Blur"), (_uint)Viewport.Width, (_uint)Viewport.Height,
|
||||
DXGI_FORMAT_R8G8B8A8_UNORM, _float4(0.0f, 0.0f, 0.0f, 0.0f)))) {
|
||||
return E_FAIL;
|
||||
@@ -648,6 +663,10 @@ HRESULT CRenderer::Initialize()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_MRT(TEXT("MRT_Blur"), TEXT("Target_Blur_Weight")))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
/* MRT_Blur_X */
|
||||
if (FAILED(m_pGameInstance->Add_MRT(TEXT("MRT_Blur_X"), TEXT("Target_Blur_X")))) {
|
||||
return E_FAIL;
|
||||
@@ -695,25 +714,27 @@ HRESULT CRenderer::Initialize()
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Specular"), 225.f, 225.f, 150.0f, 150.0f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Color"), 375.f, 225.f, 450.f, 450.0f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Color"),75.f , 1080 - 75.f, 150.f, 150.f))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Shadow"), Viewport.Width - 150.0f, 150.0f, 300.f, 300.f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_PreShadow"), Viewport.Width - 150.0f, Viewport.Height - 150.0f, 300.f, 300.f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
|
||||
if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Blur_Weight"), 75.f, 75.f, 150.0f, 150.0f))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Blur"), 150.0f, Viewport.Height - 150.0f, 300.f, 300.f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Blur"), 75.f, 225.f, 150.0f, 150.0f))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
//if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Blur_X"), Viewport.Width * 0.75f, Viewport.Height * 0.75f, Viewport.Width * 0.5f, Viewport.Height * 0.5f))) {
|
||||
// return E_FAIL;
|
||||
//}
|
||||
if (FAILED(m_pGameInstance->Ready_RenderTarget_Debug(TEXT("Target_Blur_X"), 225.f, 75.f, 150.0f, 150.0f))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ class ENGINE_DLL CGameInstance final : public CBase
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
void Asset_Description(_uint iLevel, const _char* pComponentName, CComponent** ppOut, void* pDesc, class CGameObject* pOwner = nullptr, _wstring wstrGroupName = L"")
|
||||
void Asset_Description(_uint iLevel, const _char* pComponentName, Engine::CComponent** ppOut, void* pDesc, class CGameObject* pOwner = nullptr, _wstring wstrGroupName = L"")
|
||||
{
|
||||
return m_pPrototype_Manager->CPrototype_Manager::Asset_Description<T>(iLevel, pComponentName, ppOut, pDesc, pOwner, wstrGroupName);
|
||||
}
|
||||
|
||||
@@ -96,7 +96,7 @@ class ENGINE_DLL CInstance_Model final : public CComponent
|
||||
HRESULT Create_SubResource_Buffer();
|
||||
|
||||
private:
|
||||
ID3D11Buffer* m_pVBInstance = { nullptr };
|
||||
ID3D11Buffer* m_pVBInstance = { nullptr };
|
||||
|
||||
INSTANCE_DESC m_InstanceDesc = {};
|
||||
|
||||
@@ -114,9 +114,9 @@ class ENGINE_DLL CInstance_Model final : public CComponent
|
||||
vector<class CBone*> m_Bones = {}; // 나중에 혹시 애님메쉬를 인스턴싱 할 일이 있을지도 모르니 남겨놓음
|
||||
|
||||
private:
|
||||
class CComputeShader* m_pComputeShader = {};
|
||||
ID3D11Buffer* m_pConstantBuffer = { nullptr }; // 컴퓨트 쉐이드 전용 상수버퍼
|
||||
ID3D11Buffer* m_pParticleValueBuffer = { nullptr }; // 컴퓨트 쉐이드 두번째 버퍼 (스피드, 로테이션)
|
||||
class CComputeShader* m_pComputeShader = {};
|
||||
ID3D11Buffer* m_pConstantBuffer = { nullptr }; // 컴퓨트 쉐이드 전용 상수버퍼
|
||||
ID3D11Buffer* m_pParticleValueBuffer = { nullptr }; // 컴퓨트 쉐이드 두번째 버퍼 (스피드, 로테이션)
|
||||
|
||||
public:
|
||||
#ifdef EDITOR_PROJECT
|
||||
|
||||
@@ -20,19 +20,19 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
virtual HRESULT Render_Indexed(_uint iMeshIndex, _uint IndexCount, _uint StartIndexLocation, _uint BaseVertexLocation);
|
||||
#pragma endregion
|
||||
#pragma region Animation
|
||||
void Change_AnimationIndex(_int iAnimationIndex, _bool bIsLoop, _float fLerpDuration, _bool bIgnoreCurrentIndex = false); // 애니메이션을 다른 인덱스로 변경함
|
||||
_bool Play_Animation(_float fTimeDelta); // 애니메이션에 델타타임을 넣어줌
|
||||
void RefreshAnim(); // 애님을 현재 애님의 초기상태로 되돌림
|
||||
void Change_AnimationIndex(_int iAnimationIndex, _bool bIsLoop, _float fLerpDuration, _bool bIgnoreCurrentIndex = false); // 애니메이션을 다른 인덱스로 변경함
|
||||
_bool Play_Animation(_float fTimeDelta); // 애니메이션에 델타타임을 넣어줌
|
||||
void RefreshAnim(); // 애님을 현재 애님의 초기상태로 되돌림
|
||||
void Set_AnimationIndex(_uint iIndex, _bool isLoop = true);
|
||||
void Stop_Animation(); // 애니메이션을 정지 (초기상태로)
|
||||
void Stop_Animation(); // 애니메이션을 정지 (초기상태로)
|
||||
_bool IsFinishedAnim() const { return m_bIsFinishedAnim; }
|
||||
_bool IsFinishedLerp() const { return m_bIsFinishedLerp; }
|
||||
_float Get_AnimProgressRatio();
|
||||
_int Get_AnimProgressPostion(const char* pAnimChannelName);
|
||||
_float Get_AnimEstimatedDuration();
|
||||
void Set_AnimProgressPostion(const _char* pChannelName, _uint iPosition);
|
||||
void Set_AnimPauseState(_bool bValue);// 애님을 현재상태로 정지
|
||||
void ReallocateResources(class CTransform* pTransform = nullptr); // 애님 이동의 대상 트랜스폼(이동시켜야할 트랜스폼)을 재지정함
|
||||
void Set_AnimPauseState(_bool bValue);// 애님을 현재상태로 정지
|
||||
void ReallocateResources(class CTransform* pTransform = nullptr); // 애님 이동의 대상 트랜스폼(이동시켜야할 트랜스폼)을 재지정함
|
||||
void Set_CurrentTrackPosition(_float TrackPosition);
|
||||
const _char* Get_AnimList(_uint iIndex);
|
||||
size_t Get_AnimSize() { return m_Animations.size(); }
|
||||
@@ -54,7 +54,7 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
const _float4x4* Get_BoneMatrixPtr(const _char* pBoneName) const;
|
||||
_int Get_RootBoneIndex() const { return m_iRootBoneIndex; }
|
||||
void Set_RootBoneIndex(_int iIndex) { m_iRootBoneIndex = iIndex; }
|
||||
static _int Get_BoneIndex(const _char* pBoneName, vector<class CBone*> Bones); // 본의 벡터와 이름을 넘겨주면 인덱스를 넘겨줌 ( n 순회 )
|
||||
static _int Get_BoneIndex(const _char* pBoneName, vector<class CBone*> Bones); // 본의 벡터와 이름을 넘겨주면 인덱스를 넘겨줌 ( n 순회 )
|
||||
_int Get_BoneIndex(const _char* pBoneName) const;
|
||||
_matrix Get_BoneMatrix(_uint iBoneIndex);
|
||||
#pragma endregion
|
||||
@@ -74,7 +74,7 @@ static _int Get_BoneIndex(const _char* pBoneName, vector<class CBone*> Bones); /
|
||||
HRESULT Ready_Materials_FromFile(const aiScene* pAIScene, const _char* pModelFilePath);
|
||||
HRESULT Ready_Animations(const aiScene* pAIScene);
|
||||
HRESULT Ready_Bones(const aiNode* pAINode, _int iParentIndex);
|
||||
// 바이너리
|
||||
// 바이너리
|
||||
_bool SaveAssimpModel(const _char* filename);
|
||||
_int SaveNodeRecursive(const aiNode* pAINode, std::vector<SaveNode>& outNodes, _int parentIndex);
|
||||
//
|
||||
@@ -88,49 +88,49 @@ static _int Get_BoneIndex(const _char* pBoneName, vector<class CBone*> Bones); /
|
||||
#endif
|
||||
|
||||
private:
|
||||
MODEL m_eType = {}; // 모델의 타입
|
||||
_float4x4 m_PreTransformMatrix = {}; // 사전에 루트본에 곱해줄 매트릭스
|
||||
MODEL m_eType = {}; // 모델의 타입
|
||||
_float4x4 m_PreTransformMatrix = {}; // 사전에 루트본에 곱해줄 매트릭스
|
||||
|
||||
_uint m_iNumMeshes = {}; // 메쉬의 갯수
|
||||
vector<class CMesh*> m_Meshes; // 메쉬의 벡터
|
||||
_uint m_iNumPhysXMeshes = {}; // 피직스 메쉬의 갯수
|
||||
vector<PSX::PxTriangleMesh*> m_TriMeshes = {}; // 피직스 메쉬의 갯수
|
||||
_uint m_iNumMeshes = {}; // 메쉬의 갯수
|
||||
vector<class CMesh*> m_Meshes; // 메쉬의 벡터
|
||||
_uint m_iNumPhysXMeshes = {}; // 피직스 메쉬의 갯수
|
||||
vector<PSX::PxTriangleMesh*> m_TriMeshes = {}; // 피직스 메쉬의 갯수
|
||||
|
||||
_uint m_iNumMaterials = {}; // 머테리얼의 갯수
|
||||
vector<class CMaterial*> m_Materials; // 머테리얼의 벡터
|
||||
_uint m_iNumMaterials = {}; // 머테리얼의 갯수
|
||||
vector<class CMaterial*> m_Materials; // 머테리얼의 벡터
|
||||
|
||||
vector<class CBone*> m_Bones; // 본의 벡터, 정렬순서는 루트본부터 트리의 마지막 노드까지
|
||||
vector<class CBone*> m_Bones; // 본의 벡터, 정렬순서는 루트본부터 트리의 마지막 노드까지
|
||||
|
||||
_int m_iCurrentAnimIndex = { -1 }; // 현재 선택된 애니메이션 ( m_Animations의 인덱스 )
|
||||
_uint m_iNumAnimations = {}; // 애니메이션의 종류
|
||||
_bool m_bIsLoop = { false }; // 루프애니메이션인지
|
||||
_bool m_bIsFinishedAnim = { false }; // 대상 애니메이션이 끝났는지
|
||||
_bool m_bIsFinishedLerp = { false }; // 럴프 애니메이션이 끝났는지
|
||||
_int m_iCurrentAnimIndex = { -1 }; // 현재 선택된 애니메이션 ( m_Animations의 인덱스 )
|
||||
_uint m_iNumAnimations = {}; // 애니메이션의 종류
|
||||
_bool m_bIsLoop = { false }; // 루프애니메이션인지
|
||||
_bool m_bIsFinishedAnim = { false }; // 대상 애니메이션이 끝났는지
|
||||
_bool m_bIsFinishedLerp = { false }; // 럴프 애니메이션이 끝났는지
|
||||
_bool m_bPlayAnim = { true };
|
||||
vector<class CAnimation*> m_Animations; // 애니메이션의 벡터,
|
||||
vector<class CAnimation*> m_Animations; // 애니메이션의 벡터,
|
||||
|
||||
class CLerpAnim* m_pLerpAnim = { nullptr }; // 럴프전용 애니메이션
|
||||
class CLerpAnim* m_pLerpAnim = { nullptr }; // 럴프전용 애니메이션
|
||||
|
||||
_int m_iRootBoneIndex = { -1 }; // 루트본의 인덱스
|
||||
_matrix m_PrevAnimationMatrix = XMMatrixIdentity(); // 루트본의 이전 위치
|
||||
_matrix m_DeltaAnimationMatrix = {}; // 루트본의 델타애니메이션
|
||||
class CTransform* m_pTransform = { nullptr }; // 모델 대상의 트랜스폼
|
||||
_int m_iRootBoneIndex = { -1 }; // 루트본의 인덱스
|
||||
_matrix m_PrevAnimationMatrix = XMMatrixIdentity(); // 루트본의 이전 위치
|
||||
_matrix m_DeltaAnimationMatrix = {}; // 루트본의 델타애니메이션
|
||||
class CTransform* m_pTransform = { nullptr }; // 모델 대상의 트랜스폼
|
||||
|
||||
|
||||
// 바이너리
|
||||
// 바이너리
|
||||
SaveModel* m_pSaveModel = { nullptr };
|
||||
list<SaveModel> m_SaveModel;
|
||||
//
|
||||
|
||||
private:
|
||||
// 바이너리
|
||||
// 바이너리
|
||||
virtual HRESULT Initialize_Prototype(MODEL eType, const _char* pModelFilePath, _fmatrix PreTransformMatrix);
|
||||
bool LoadData(const _char* filename);
|
||||
//
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
|
||||
private:
|
||||
// 바이너리
|
||||
// 바이너리
|
||||
HRESULT Ready_Meshes();
|
||||
HRESULT Ready_Materials(const _char* pModelFilePath);
|
||||
HRESULT Ready_Bones(const std::vector<SaveNode>& allNodes, _int currentIndex, _int parentIndex);
|
||||
@@ -138,7 +138,7 @@ static _int Get_BoneIndex(const _char* pBoneName, vector<class CBone*> Bones); /
|
||||
//
|
||||
|
||||
public:
|
||||
// 바이너리
|
||||
// 바이너리
|
||||
static CModel* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext, MODEL eType, const _char* pModelFilePath, _fmatrix PreTransformMatrix = XMMatrixIdentity());
|
||||
//
|
||||
virtual CComponent* Clone(void* pArg, class CGameObject* pOwner = nullptr);
|
||||
|
||||
@@ -71,7 +71,7 @@ class CPrototype_Manager final : public CBase
|
||||
//만들고 선택할 시에 내 ppOut에 클론하는 기능을 담당
|
||||
|
||||
template<typename T>
|
||||
void Asset_Description(_uint iLevel, const _char* pComponentName, CComponent** ppOut, void* pDesc, class CGameObject* pOwner = nullptr, _wstring wstrGroupName = L"")
|
||||
void Asset_Description(_uint iLevel, const _char* pComponentName, Engine::CComponent** ppOut, void* pDesc, class CGameObject* pOwner = nullptr, _wstring wstrGroupName = L"")
|
||||
{
|
||||
vector<const _char*> pComponentNames = {};
|
||||
vector<_string> strNames = {};
|
||||
@@ -131,26 +131,67 @@ class CPrototype_Manager final : public CBase
|
||||
return;
|
||||
}
|
||||
|
||||
static _int s_iCurrentItem = -1;
|
||||
static _int s_iCurrentItem = 0;
|
||||
static ImGuiTextFilter filter;
|
||||
|
||||
// 다른 어셋일 경우 콤보로 띄우기
|
||||
|
||||
if (GUI::Combo(pComponentName, &s_iCurrentItem, pComponentNames.data(), (_int)pComponentNames.size()))
|
||||
if(GUI::BeginCombo(pComponentName, (s_iCurrentItem >= 0 && s_iCurrentItem < pComponentNames.size())
|
||||
? pComponentNames[s_iCurrentItem] : "NONE"))
|
||||
{
|
||||
if (*ppOut != nullptr)
|
||||
Safe_Release(*ppOut);
|
||||
if (ImGui::IsWindowAppearing())
|
||||
{
|
||||
ImGui::SetKeyboardFocusHere();
|
||||
filter.Clear();
|
||||
}
|
||||
|
||||
_string strComponentName = pComponentNames[s_iCurrentItem];
|
||||
_wstring wstrComponentName = CMyTools::ToWstring(strComponentName);
|
||||
|
||||
auto iter = m_pAssets[iLevel].find(wstrComponentName);
|
||||
filter.Draw("##Filter", -FLT_MIN);
|
||||
|
||||
|
||||
for (_uint i = 0; i < pComponentNames.size(); i++)
|
||||
{
|
||||
bool is_selected = (s_iCurrentItem == i);
|
||||
|
||||
if (filter.PassFilter(pComponentNames[i]))
|
||||
{
|
||||
|
||||
if (GUI::Selectable(pComponentNames[i], is_selected))
|
||||
{
|
||||
s_iCurrentItem = i;
|
||||
}
|
||||
|
||||
if (is_selected)
|
||||
{
|
||||
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
GUI::EndCombo();
|
||||
}
|
||||
|
||||
if (GUI::Button("Select"))
|
||||
{
|
||||
auto iter = m_pAssets[iLevel].find(CMyTools::ToWstring(pComponentNames[s_iCurrentItem]));
|
||||
|
||||
if (iter == m_pAssets[iLevel].end()) {
|
||||
|
||||
|
||||
GUI::EndCombo();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (*ppOut != nullptr)
|
||||
Safe_Release(*ppOut);
|
||||
|
||||
*ppOut = iter->second->Clone(pDesc, pOwner);
|
||||
}
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -61,8 +61,9 @@ class CRenderer final : public CBase
|
||||
void Render_Effect();
|
||||
void Render_NonLight();
|
||||
void Render_Blend();
|
||||
void Render_UI();
|
||||
void Render_LastColor();
|
||||
void Render_UI();
|
||||
|
||||
|
||||
#ifdef _DEBUG
|
||||
private:
|
||||
|
||||