diff --git a/Jusin154_Team3D/Client/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl b/Jusin154_Team3D/Client/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
index bc248ab64..c2d688ad7 100644
--- a/Jusin154_Team3D/Client/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
+++ b/Jusin154_Team3D/Client/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
@@ -23,6 +23,7 @@ float g_fAlpha;
float g_fOwnerAlpha;
float g_fCanvasAlpha;
float g_fAngle;
+float g_fMapAngle;
float g_fCoolTime;
float g_fHp;
@@ -506,21 +507,14 @@ PS_OUT PS_Rotation(PS_IN In)
float2 center = float2(0.5f, 0.5f);
float2 uv = In.vTexcoord - center;
- uv *= sqrt(2.0f);
float2 Rotation = In.vTexcoord;
- Rotation.x = uv.x * cos(g_fAngle) - uv.y * sin(g_fAngle);
- Rotation.y = uv.x * sin(g_fAngle) + uv.y * cos(g_fAngle);
+ Rotation.x = uv.x * cos(g_fMapAngle) - uv.y * sin(g_fMapAngle);
+ Rotation.y = uv.x * sin(g_fMapAngle) + uv.y * cos(g_fMapAngle);
Rotation += center;
- float4 tex1 = g_Texture.Sample(ClampSampler, Rotation);
- float4 tex2 = g_Texture1.Sample(DefaultSampler, In.vTexcoord);
-
- tex1.rgb *= 0.4f;
+ float4 tex1 = g_Texture.Sample(ClampSampler , Rotation);
+
color = tex1;
- tex2.rgb *= 0.3f;
-
- if (tex2.a >= 0.9f)
- color = tex2;
color.a *= Alpha;
@@ -586,7 +580,7 @@ PS_OUT PS_SpellAnim(PS_IN In)
switch (g_iSpellType)
{
case 0:
- BGColor = float3(255.f, 255.f, 0.f) / 255.f;
+ BGColor = float3(220.f, 165.f, 70.f) / 255.f;
break;
case 1:
BGColor = float3(150.f, 120.f, 240.f) / 255.f;
@@ -1132,7 +1126,7 @@ PS_OUT PS_Spell_Header(PS_IN In)
switch (g_iSpellType)
{
case 0:
- BGColor = float3(255.f, 255.f, 0.f) / 255.f;
+ BGColor = float3(220.f, 165.f, 70.f) / 255.f;
break;
case 1:
BGColor = float3(150.f, 120.f, 240.f) / 255.f;
@@ -1155,11 +1149,12 @@ PS_OUT PS_Spell_Header(PS_IN In)
}
float4 tex1 = g_Texture.Sample(DefaultSampler, In.vTexcoord);
- Color = tex1;
-
+ Color.rgb = tex1.rgb * 0.8f;
+ Color.a = tex1.a;
+
Color.rgb *= BGColor;
- Color.a *= Alpha;
+ Color.a *= Alpha * 0.5f;
Out.vColor = Color;
@@ -1330,6 +1325,92 @@ PS_OUT PS_Loding_Screen(PS_IN In)
return Out;
}
+PS_OUT PS_Enemy_HpBer(PS_IN In)
+{
+ PS_OUT Out;
+
+ float Alpha = g_fAlpha * g_fOwnerAlpha * g_fCanvasAlpha;
+ float4 Color = float4(1.f, 1.f, 1.f, 1.f);
+ float4 Color1 = float4(1.f, 1.f, 1.f, 1.f);
+ float2 uv = In.vTexcoord;
+ float2 CurrentPixelPosition = uv * g_fCurrent_Size;
+ float OriginLeft = g_fNine_Slice.x;
+ float OriginRight = g_fNine_Slice.y;
+ float OriginTop = g_fNine_Slice.z;
+ float OriginBottom = g_fNine_Slice.w;
+
+ float CurrentLeft = OriginLeft;
+ float CurrentRight = g_fCurrent_Size.x - (g_fOrigin_Size.x - OriginRight);
+ float CurrentTop = OriginTop;
+ float CurrentBottom = g_fCurrent_Size.y - (g_fOrigin_Size.y - OriginBottom);
+
+ float2 Finaluv = In.vTexcoord;
+
+ if (CurrentPixelPosition.x < CurrentLeft)
+ {
+ Finaluv.x = CurrentPixelPosition.x / g_fOrigin_Size.x;
+ }
+ else if (CurrentPixelPosition.x > CurrentRight)
+ {
+ float dist = CurrentPixelPosition.x - CurrentRight;
+ Finaluv.x = (OriginRight + dist) / g_fOrigin_Size.x;
+ }
+ else
+ {
+ float scale = (CurrentPixelPosition.x - CurrentLeft) / (CurrentRight - CurrentLeft);
+ Finaluv.x = (OriginLeft / g_fOrigin_Size.x) + scale * ((OriginRight - OriginLeft) / g_fOrigin_Size.x);
+ }
+
+ if (CurrentPixelPosition.y < CurrentTop)
+ {
+ Finaluv.y = CurrentPixelPosition.y / g_fOrigin_Size.y;
+ }
+ else if (CurrentPixelPosition.y > CurrentBottom)
+ {
+ float dist = CurrentPixelPosition.y - CurrentBottom;
+ Finaluv.y = (OriginBottom + dist) / g_fOrigin_Size.y;
+ }
+ else
+ {
+ float scale = (CurrentPixelPosition.y - CurrentTop) / (CurrentBottom - CurrentTop);
+ Finaluv.y = (OriginTop / g_fOrigin_Size.y) + scale * ((OriginBottom - OriginTop) / g_fOrigin_Size.y);
+ }
+
+ float4 tex1 = g_Texture.Sample(DefaultSampler, Finaluv);
+ float4 tex2 = g_Texture1.Sample(DefaultSampler, Finaluv);
+
+ Color = tex1;
+
+ tex2.rgb *= float3(1.f, 0.f, 0.f);
+
+ if (In.vTexcoord.x >= g_fHp)
+ {
+ tex2.rgb = float3(0.f, 0.f, 0.f);
+ }
+
+ Color = lerp(Color, tex2, tex2.a);
+
+ if (Color.a <= 0.f)
+ discard;
+
+ if(g_iHover != 0)
+ {
+ float4 tex3 = g_Texture2.Sample(DefaultSampler, In.vTexcoord);
+
+ tex3.rgb *= float3(1.f, 0.f, 0.f);
+
+ if (g_fTime >= tex3.r)
+ {
+ Color.a *= tex3.r;
+ Color.rgb = float3(1.f, 0.f, 0.f);
+ }
+ }
+
+ Color.a *= Alpha;
+ Out.vColor = Color;
+ return Out;
+}
+
technique11 PosTexTechnique11
{
pass Default
@@ -1620,4 +1701,14 @@ technique11 PosTexTechnique11
PixelShader = compile ps_5_0 PS_Loding_Screen();
}
+ pass Enemy_HpBer
+ {
+ SetRasterizerState(RS_Default);
+ SetDepthStencilState(DSS_Default, 0);
+ SetBlendState(BS_AlphaBlend, float4(0.f, 0.f, 0.f, 0.f), 0xffffffff);
+ VertexShader = compile vs_5_0 VS_MAIN();
+ GeometryShader = NULL;
+ PixelShader = compile ps_5_0 PS_Enemy_HpBer();
+ }
+
}
diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj b/Jusin154_Team3D/Client/Default/Client.vcxproj
index c9a6c7f64..64c2faf8d 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj
@@ -160,12 +160,19 @@ call Update_Resources.bat
+
+
+
+
+
+
+
@@ -278,6 +285,7 @@ call Update_Resources.bat
+
@@ -299,12 +307,21 @@ call Update_Resources.bat
+
+
+
+
+
+
+
+
+
@@ -419,6 +436,7 @@ call Update_Resources.bat
+
@@ -434,7 +452,6 @@ call Update_Resources.bat
-
diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
index ee057fee4..ac1dc70bb 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
@@ -85,24 +85,6 @@
02.GameObjects\PhysX
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
04.Mechanic\State
@@ -157,9 +139,6 @@
02.GameObjects\Cameras\Camera_Gaze
-
- 02.GameObjects\NPC\Hostile\Monster\Goblin
-
02.GameObjects\NPC\Hostile\Monster
@@ -412,6 +391,51 @@
04.Mechanic\State\State_Combat\Dead
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel
+
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel\Enemy_HpBar
+
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel\Enemy_Info
+
+
+ 04.Mechanic\State\Movement\Shuffle
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Mage
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Warrior
+
+
+ 02.GameObjects\Item\Goblin_BattleAxe
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Player
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Hitbox
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Monster
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Hitbox
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Monster
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Player
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Monster\Troll
+
@@ -812,9 +836,6 @@
{27251db2-19f2-4492-a3a4-32c11526f413}
-
- {7e641382-9dfa-4da7-a8c8-a3ee06360e7a}
-
{b8c7e12b-da04-4d49-bc61-104649975d0b}
@@ -869,11 +890,53 @@
{c584798b-d7aa-4cb0-b6e8-c2aff73757ce}
+
+ {0ed6a11e-5d22-4b9f-a39c-f2319c27caf4}
+
{81add99f-7450-4730-8d3f-bf1de06b2b8d}
+
+ {5973b96c-42c3-4cda-9627-f741e12124cd}
+
+
+ {3e7156ab-9d1f-4b9b-b09d-5dd60638505e}
+
+
+ {2d99db17-8cc6-437a-84d6-dd21ee434c38}
+
+
+ {f28022fe-79c4-4623-af96-916e8828fedc}
+
+
+ {3246055a-734f-45e2-ab2f-437ec2ccf061}
+
+
+ {234b3dd8-4ec9-4e81-ac7f-4eacb8f53780}
+
+
+ {3f4bde42-c5a0-4c7a-8dde-23e0725534c9}
+
+
+ {085dcbe3-d24e-4f08-b1b5-562f8ea2ad88}
+
+
+ {dde4f316-300a-44e2-b0ed-6b215434f672}
+
+
+ {e8092e33-cd57-4c35-81e4-971d12dbfc3b}
+
+
+ {df2cce1e-7ac5-404d-922a-7f60ca0be9a4}
+
+
+ {a79cbab1-6a8a-4d88-8102-bc3462a4ffb0}
+
+
+ {e12337a6-7563-4615-a8d2-a2e2e1ba1ca8}
+
-
+
99.Define\00.DEFAULT
@@ -943,24 +1006,6 @@
02.GameObjects\PhysX
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\Behavior
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
-
- 02.GameObjects\PhysX\CallBack\HitReport
-
04.Mechanic\State
@@ -1018,12 +1063,6 @@
02.GameObjects\Cameras\Camera_Gaze
-
- 02.GameObjects\NPC\Hostile\Monster\Goblin
-
-
- 02.GameObjects\NPC\Hostile\Monster\Goblin
-
02.GameObjects\NPC\Hostile\Monster
@@ -1105,9 +1144,6 @@
02.GameObjects\UI\GamePlay_Canvas\Action_Panel\Potion
-
- 02.GameObjects\Item\Broom
-
04.Mechanic\State\Broom
@@ -1279,13 +1315,68 @@
02.GameObjects\UI\Screen\Logo\Logo_Text
+
+ 04.Mechanic\State\Movement\Shuffle
+
+
+ 02.GameObjects\Item\Broom
+
04.Mechanic\State\State_Combat\Dead
-
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Mage
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Mage
+
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel\Enemy_HpBar
+
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel\Enemy_Info
+
+
+ 02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Warrior
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Warrior
+
+
+ 02.GameObjects\Item\Goblin_BattleAxe
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Player
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Hitbox
+
+
+ 02.GameObjects\PhysX\CallBack\Behavior\Monster
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Hitbox
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Monster
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Player
+
+
+ 02.GameObjects\PhysX\CallBack\HitReport\Monster\Troll
+
+
99.Define\00.DEFAULT
-
\ No newline at end of file
+
+
\ No newline at end of file
diff --git a/Jusin154_Team3D/Client/Private/Bombard.cpp b/Jusin154_Team3D/Client/Private/Bombard.cpp
index fb5869804..b0869da87 100644
--- a/Jusin154_Team3D/Client/Private/Bombard.cpp
+++ b/Jusin154_Team3D/Client/Private/Bombard.cpp
@@ -88,6 +88,12 @@ void CBombard::Late_Update(_float fTimeDelta)
OnCollision(this);
}
+ if (false == m_bHit) {
+ _vector vStartPos = XMLoadFloat4(&m_vStartPos);
+ _vector vEndPos = XMLoadFloat4(&m_vEndPos);
+ SweepTarget(vStartPos, vEndPos, 0.125);
+ }
+
}
HRESULT CBombard::Pre_Setting(CGameObject* pObject, void* pArg)
diff --git a/Jusin154_Team3D/Client/Private/Broom.cpp b/Jusin154_Team3D/Client/Private/Broom.cpp
index 9a228ff4e..a56f998ac 100644
--- a/Jusin154_Team3D/Client/Private/Broom.cpp
+++ b/Jusin154_Team3D/Client/Private/Broom.cpp
@@ -203,9 +203,24 @@ void CBroom::Describe_Entity()
string AnimList = m_pModelCom->Get_AnimList(m_pModelCom->Get_AnimIndex());
GUI::Text(AnimList.c_str());
+ GUI::Text("AnimIndex %d", m_pModelCom->Get_AnimIndex());
GUI::Text("AnimTrack %.2f", m_pModelCom->Get_CurrentTrackPosition());
GUI::Text("AnimRatio %.2f", m_pModelCom->Get_CurrentTrackProgressRatio());
+ _float3 Pos;
+ XMStoreFloat3(&Pos, Get_WorldPostion());
+
+ float Pos3[3] = { Pos.x, Pos.y, Pos.z };
+ GUI::DragFloat3("Pos", Pos3);
+
+
+ _float RotR, RotU, RotL;
+ RotR = XMVectorGetX(m_pTransformCom->Get_State(STATE::RIGHT));
+ RotU = XMVectorGetY(m_pTransformCom->Get_State(STATE::UP));
+ RotL = XMVectorGetZ(m_pTransformCom->Get_State(STATE::LOOK));
+
+ float Rot3[3] = { RotR, RotU,RotL };
+ GUI::DragFloat3("Rot", Rot3);
}
diff --git a/Jusin154_Team3D/Client/Default/Broom_States.cpp b/Jusin154_Team3D/Client/Private/Broom_States.cpp
similarity index 81%
rename from Jusin154_Team3D/Client/Default/Broom_States.cpp
rename to Jusin154_Team3D/Client/Private/Broom_States.cpp
index 25a45f5b9..a6366459c 100644
--- a/Jusin154_Team3D/Client/Default/Broom_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Broom_States.cpp
@@ -220,59 +220,95 @@ HRESULT CBroom::Behavior_MoveExitCheck(_float fTimeDelta)
}
else {
pairAnimInfo = m_Animation[STATEANIM::BROOM_HOVER_STOP_B];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
}
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
}
- else
- {
- if (bFwd)
- {
- m_fTargetSpeed = m_fFlyMaxSpeed;
- m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fAccel;
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_B];
- Camera_InterpTurn(fTimeDelta);
- }
- else if (bLft)
- {
- m_fTargetSpeed = m_fTurnMaxSpeed;
- m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fTurnDecel;
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_LEFT_B];
- m_pTransformCom->Turn(-m_pTransformCom->Get_State(STATE::UP), fTimeDelta*0.1f);
- }
- else if (bRht)
- {
- m_fTargetSpeed = m_fTurnMaxSpeed;
- m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fTurnDecel;
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_RIGHT_B];
- m_pTransformCom->Turn(m_pTransformCom->Get_State(STATE::UP), fTimeDelta* 0.1f);
- }
- else if (bDown)
- {
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_DOWN_B];
- m_fTargetSpeed = m_fTurnMaxSpeed;
- m_fTurnSpeed += (m_fTargetSpeed - m_fTurnSpeed) * fTimeDelta * m_fAccel;
-
- m_pTransformCom->Go_LerpDown(m_fTurnSpeed, fTimeDelta);
- }
- else if (bUp)
- {
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_UP_B];
- m_fTargetSpeed = m_fTurnMaxSpeed;
- m_fTurnSpeed += (m_fTargetSpeed - m_fTurnSpeed) * fTimeDelta * m_fAccel;
-
- m_pTransformCom->Go_LerpUp(m_fTurnSpeed, fTimeDelta);
- }
- else {
- m_fTargetSpeed = m_fFlyMaxSpeed;
- m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fAccel;
- pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_B];
- }
+ else{
+ m_fTargetSpeed = m_fFlyMaxSpeed;
+ m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fAccel;
m_pTransformCom->Go_LerpStraight(m_fSpeed, fTimeDelta);
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ if (SUCCEEDED(InputAction()) || SUCCEEDED(InputMove()))
+ {
+ _float3 vInput = { 0.f, 0.f, 0.f };
+
+ if (bFwd) vInput.z += 1.f;
+ if (bLft) vInput.x -= 1.f;
+ if (bRht) vInput.x += 1.f;
+ if (bUp) vInput.y += 1.f;
+ if (bDown) vInput.y -= 1.f;
+
+ _bool bHasInput = !(vInput.x == 0 && vInput.y == 0 && vInput.z == 0);
+ _vector vDir = XMVector3Normalize(XMLoadFloat3(&vInput));
+
+ if (bUp || bDown)
+ {
+ m_fTargetSpeed = m_fTurnMaxSpeed;
+ m_fTurnSpeed += (m_fTurnMaxSpeed - m_fTurnSpeed) * fTimeDelta * m_fAccel;
+
+ if (bUp)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_UP_B];
+ m_pTransformCom->Go_LerpUp(m_fTurnSpeed, fTimeDelta);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+ else
+ {
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_DOWN_B];
+ m_pTransformCom->Go_LerpDown(m_fTurnSpeed, fTimeDelta);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+
+ }
+ }
+
+
+ if (vInput.x < 0.f)
+ {
+ m_pTransformCom->Turn(-m_pTransformCom->Get_State(STATE::UP), fTimeDelta * 0.1f);
+ }
+ else if (vInput.x > 0.f)
+ {
+ m_pTransformCom->Turn(m_pTransformCom->Get_State(STATE::UP), fTimeDelta * 0.1f);
+ }
+
+ _float ax = fabsf(vInput.x);
+ _float ay = fabsf(vInput.y);
+ _float az = fabsf(vInput.z);
+
+ if (ay > ax && ay > az)
+ {
+ if (vInput.y > 0)
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_UP_B];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_DOWN_B];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+ else if (az >= ax)
+ {
+ if (vInput.z > 0)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_B];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ Camera_InterpTurn(fTimeDelta);
+ }
+ }
+ else
+ {
+ if (vInput.x < 0)
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_LEFT_B];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_RIGHT_B];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::BROOM_FLY_B];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+
+
}
if (m_bHoverToggle && !SUCCEEDED(InputMove()) && !SUCCEEDED(InputAction()))
diff --git a/Jusin154_Team3D/Client/Private/BuildingContainer.cpp b/Jusin154_Team3D/Client/Private/BuildingContainer.cpp
index 872fedece..386cfd141 100644
--- a/Jusin154_Team3D/Client/Private/BuildingContainer.cpp
+++ b/Jusin154_Team3D/Client/Private/BuildingContainer.cpp
@@ -40,8 +40,9 @@ void CBuildingContainer::Late_Update(_float fTimeDelta)
if (m_pOcclusionQueryCom->isDraw())
__super::Late_Update(fTimeDelta);
}
- else
+ else{
__super::Late_Update(fTimeDelta);
+ }
m_pGameInstance->Add_RenderGroup(RENDER::OCCLUSION, this);
@@ -56,6 +57,18 @@ HRESULT CBuildingContainer::Render()
return S_OK;
}
+HRESULT CBuildingContainer::Render_Shadow()
+{
+ unordered_map<_string, CPartObject*>::iterator iter = m_PartObjects.begin();
+ for (; iter != m_PartObjects.end(); ++iter) {
+ CPartObject* pObject = (*iter).second;
+ if (FAILED(pObject->Render_Shadow())) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
HRESULT CBuildingContainer::Render_BoundingBox()
{
/* Begin_Query, End_Query 사이에 Render */
@@ -220,3 +233,4 @@ void CBuildingContainer::Describe_Entity()
}
#endif
+////////////////////////////////
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Troll_Behavior.cpp b/Jusin154_Team3D/Client/Private/CallBack_Troll_Behavior.cpp
new file mode 100644
index 000000000..dfc4f419a
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/CallBack_Troll_Behavior.cpp
@@ -0,0 +1,169 @@
+#include "pch.h"
+#include "CallBack_Troll_Behavior.h"
+#include "GameInstance.h"
+#include "Character_Controller.h"
+#include "RigidBody_Dynamic.h"
+#include "GameObject.h"
+
+CCallBack_Troll_Behavior::CCallBack_Troll_Behavior()
+{
+}
+
+CCallBack_Troll_Behavior::~CCallBack_Troll_Behavior()
+{
+}
+
+void CCallBack_Troll_Behavior::onShapeHit(const PSX::PxControllerShapeHit& hit)
+{
+ PSX::PxController* pController = hit.controller;
+ PSX::PxExtendedVec3 vWorldPos = hit.worldPos; // 접촉지점
+ PSX::PxVec3 vWorldNormal = hit.worldNormal; // 접촉노말
+ PSX::PxVec3 vDir = hit.dir; // 시도한 move 방향
+ _float fLength = hit.length; // 시도한 move 길이
+
+ PSX::PxShape* pShape = hit.shape;
+ PSX::PxRigidActor* pActor = hit.actor;
+
+ if (nullptr != pController && nullptr != pActor) {
+ PhsXUserData* pTargetActorData = static_cast(pActor->userData);
+ PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ if (nullptr == pTargetActorData) { // missing user data
+ return;
+ }
+
+ switch (pTargetActorData->eKind)
+ {
+ case PHYSX_KIND::BODY_STATIC:
+ {
+ switch ((PXOBJECT)pTargetActorData->iSubKind)
+ {
+ case PXOBJECT::TERRAIN:
+ //class CGameObject* pOwner = m_pController->Get_Owner();
+ //_vector vLook = pOwner->Get_Component()->Get_State(STATE::LOOK);
+ //_float fDot = XMVectorGetX(XMVector3Dot(XMLoadFloat3((_float3*)&vDir), vLook));
+ //if (fDot > cosf(XM_PIDIV4)) {
+ // CModel* pModel = pOwner->Get_Component();
+ // _uint iAnimIndex = pModel->Get_AnimIndex();
+ // if (STATEANIM::RUSH_LOOP == iAnimIndex) {
+ // CFSM* pFSM = pOwner->Get_Component();
+ // pFSM->Change_State(FSMSTATE::STOP);
+ // }
+ //}
+ break;
+ default:
+ break;
+ }
+ }
+ break;
+ case PHYSX_KIND::BODY_DYNAMIC:
+ {
+ switch (pTargetActorData->iSubKind)
+ {
+ case 0:
+ m_pController->ConvertToDO(*m_pPartDynamicBody);
+ m_pPartDynamicBody->Add_Force(XMVectorSet(vDir.x, vDir.y, vDir.z, 0.f) * fLength * 100.f, PSX::PxForceMode::eIMPULSE);
+ break;
+ default:
+ {
+ }
+ break;
+ }
+ } break;
+ case PHYSX_KIND::CCTActor:
+ assert(false);
+ break;
+ case PHYSX_KIND::OBSTACLEActor:
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+void CCallBack_Troll_Behavior::onControllerHit(const PSX::PxControllersHit& hit)
+{
+ PSX::PxController* pController = hit.controller;
+ PSX::PxExtendedVec3 vWorldPos = hit.worldPos; // 접촉지점
+ PSX::PxVec3 vWorldNormal = hit.worldNormal; // 접촉노말
+ PSX::PxVec3 vDir = hit.dir; // 시도한 move 방향
+ _float fLength = hit.length; // 시도한 move 길이
+
+ PSX::PxController* pOtherController = hit.other; // 다른 컨트롤러
+ PSX::PxActor* pActor = pOtherController->getActor();
+
+ ON_COLLISION_INFO CollisionDesc = {};
+
+ if (nullptr != pController && nullptr != pOtherController) {
+ PhsXUserData* pTargetActorData = static_cast(pActor->userData);
+ PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ assert(nullptr != pTargetActorData); // missing user data
+
+ switch (pTargetActorData->eKind)
+ {
+ case PHYSX_KIND::BODY_STATIC:
+ assert(false);
+ break;
+ case PHYSX_KIND::BODY_DYNAMIC:
+ assert(false);
+ break;
+ case PHYSX_KIND::CCTActor:
+ switch (pTargetActorData->iSubKind)
+ {
+ case ENUM_CLASS(PXOBJECT::PLAYER):
+ break;
+ default:
+ {
+ PSX::PxRigidDynamic* pDynamic = static_cast(pActor);
+ pDynamic->addForce(vDir * fLength * 100000.f, PSX::PxForceMode::eIMPULSE);
+ }
+ break;
+ }
+ break;
+ case PHYSX_KIND::OBSTACLEActor:
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+void CCallBack_Troll_Behavior::onObstacleHit(const PSX::PxControllerObstacleHit& hit)
+{
+ PSX::PxController* pController = hit.controller;
+ PSX::PxExtendedVec3 vWorldPos = hit.worldPos; // 접촉지점
+ PSX::PxVec3 vWorldNormal = hit.worldNormal; // 접촉노말
+ PSX::PxVec3 vDir = hit.dir; // 시도한 move 방향
+ _float fLength = hit.length; // 시도한 move 길이
+
+ const void* pOtherController = hit.userData; // 장애물
+
+ //switch (pOtherController.member)
+ //{
+ //default:
+ // break;
+ //}
+}
+
+HRESULT CCallBack_Troll_Behavior::Initialize(CCharacter_Controller* pController, CRigidBody_Dynamic* pPartDynamicObject)
+{
+ m_pController = pController;
+ m_pPartDynamicBody = pPartDynamicObject;
+ m_pGameInstance = CGameInstance::GetInstance();
+ SAFE_ADDREF(m_pController);
+ SAFE_ADDREF(m_pPartDynamicBody);
+ SAFE_ADDREF(m_pGameInstance);
+ return S_OK;
+}
+
+HRESULT CCallBack_Troll_Behavior::Finalize()
+{
+ SAFE_RELEASE(m_pGameInstance);
+ SAFE_RELEASE(m_pPartDynamicBody);
+ SAFE_RELEASE(m_pController);
+ return S_OK;
+}
+
+CCallBack_Troll_Behavior* CCallBack_Troll_Behavior::Create()
+{
+ return new CCallBack_Troll_Behavior();
+}
diff --git a/Jusin154_Team3D/Client/Private/Camera_Gaze.cpp b/Jusin154_Team3D/Client/Private/Camera_Gaze.cpp
index 122b65d28..fff36f194 100644
--- a/Jusin154_Team3D/Client/Private/Camera_Gaze.cpp
+++ b/Jusin154_Team3D/Client/Private/Camera_Gaze.cpp
@@ -1,5 +1,6 @@
#include "pch.h"
#include "Camera_Gaze.h"
+#include "InfoInstance.h"
CCamera_Gaze::CCamera_Gaze(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
: CCamera(pDevice, pContext)
@@ -7,7 +8,8 @@ CCamera_Gaze::CCamera_Gaze(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
}
CCamera_Gaze::CCamera_Gaze(const CCamera_Gaze& rhs)
- : CCamera(rhs)
+ : CCamera(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
diff --git a/Jusin154_Team3D/Client/Private/Decendo.cpp b/Jusin154_Team3D/Client/Private/Decendo.cpp
index 406a3e61f..618bc1b54 100644
--- a/Jusin154_Team3D/Client/Private/Decendo.cpp
+++ b/Jusin154_Team3D/Client/Private/Decendo.cpp
@@ -97,50 +97,6 @@ void CDecendo::Late_Update(_float fTimeDelta)
Get_PartObject()->Trail_Update(m_pProjectile->Get_Component()->Get_XMWorldMatrix(), fTimeDelta);
- _vector vStartPos = m_pProjectile->Get_WorldPostion();
-
- _vector vEndPos = XMLoadFloat4(&m_vTargetPos);
-
- _vector vDir2 = { vEndPos - vStartPos };
-
- _float fDistance = XMVectorGetX(XMVector3Length(vEndPos - vStartPos));
-
- PSX::PxSweepBuffer pxBuffer = {};
-
- _bool bHit = m_pGameInstance->SphereCast(0.2f, vStartPos, vDir2, fDistance, PSX::PxHitFlag::ePOSITION | PSX::PxHitFlag::eNORMAL, PSX::PxQueryFlag::eDYNAMIC, pxBuffer);
-
- if (bHit) {
- const PSX::PxSweepHit& hit = pxBuffer.block;
- PSX::PxRigidActor* pActor = hit.actor;
- PSX::PxShape* pShape = hit.shape;
-
- if (nullptr != pActor && nullptr != pActor->userData)
- {
- PhsXUserData* pUserData = static_cast(pActor->userData);
-
- switch (pUserData->eKind)
- {
- case PHYSX_KIND::CCTActor:
- {
- switch (PXOBJECT(pUserData->iSubKind))
- {
- case PXOBJECT::MONSTER:
- case PXOBJECT::GOBLIN_WARRIOR:
- {
- pUserData->pOwner->OnCollision(this);
- }
- break;
- case PXOBJECT::TROLL:
- {
- pUserData->pOwner->OnCollision(this);
- }
- break;
- }
- }
- }
- }
- }
-
XMStoreFloat4(&m_vEndPos, m_pProjectile->Get_WorldPostion());
_vector vDir = XMLoadFloat4(&m_vEndPos) - XMLoadFloat4(&m_vStartPos);
@@ -151,6 +107,12 @@ void CDecendo::Late_Update(_float fTimeDelta)
OnCollision();
}
+ if (false == m_bHit) {
+ _vector vStartPos = XMLoadFloat4(&m_vStartPos);
+ _vector vEndPos = XMLoadFloat4(&m_vEndPos);
+ SweepTarget(vStartPos, vEndPos, 0.2f);
+ }
+
__super::Late_Update(fTimeDelta);
}
diff --git a/Jusin154_Team3D/Client/Private/EffectPool.cpp b/Jusin154_Team3D/Client/Private/EffectPool.cpp
index d07197020..bfbf9fa75 100644
--- a/Jusin154_Team3D/Client/Private/EffectPool.cpp
+++ b/Jusin154_Team3D/Client/Private/EffectPool.cpp
@@ -44,9 +44,11 @@ HRESULT CEffectPool::Initialize(void* pArg)
return E_FAIL;
}
- //if (FAILED(Ready_Effect())) {
- // return E_FAIL;
- //}
+ if (FAILED(Ready_Effect())) {
+ return E_FAIL;
+ }
+
+
return S_OK;
}
@@ -122,12 +124,25 @@ HRESULT CEffectPool::Bind_ShaderResources()
HRESULT CEffectPool::Ready_Effect()
{
- if(FAILED(Create_Effect(SKILL_TYPE::JAP, 10, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
+#ifdef 기무리
+ if (FAILED(Create_Effect(SKILL_TYPE::JAP, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
CNomalJap* pEffect = nullptr;
pEffect = m_pGameInstance->Clone_Prototype(iPrototypeLevel, nullptr);
- return pEffect;}
+ return pEffect; }
+ ))) return E_FAIL;
+
+#endif // 기무리
+
+
+#ifndef 기무리
+ if (FAILED(Create_Effect(SKILL_TYPE::JAP, 10, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
+ CNomalJap* pEffect = nullptr;
+
+ pEffect = m_pGameInstance->Clone_Prototype(iPrototypeLevel, nullptr);
+
+ return pEffect; }
))) return E_FAIL;
@@ -224,6 +239,8 @@ HRESULT CEffectPool::Ready_Effect()
return pEffect; }
))) return E_FAIL;
+#endif // !기무리
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Effect_Container.cpp b/Jusin154_Team3D/Client/Private/Effect_Container.cpp
index d112eb2fe..7d150daea 100644
--- a/Jusin154_Team3D/Client/Private/Effect_Container.cpp
+++ b/Jusin154_Team3D/Client/Private/Effect_Container.cpp
@@ -315,13 +315,13 @@ _int CEffect_Container::CollisionCheck()
continue;
case PXOBJECT::MONSTER:
case PXOBJECT::GOBLIN_WARRIOR:
+ case PXOBJECT::GOBLIN_MAGICIAN:
case PXOBJECT::TROLL:
case PXOBJECT::WALL:
-
{
return i;
}
- break;
+ break;
default:
break;
}
@@ -347,6 +347,67 @@ _int CEffect_Container::CollisionCheck()
}
+void CEffect_Container::SweepTarget(_vector StartPos, _vector EndPos, _float fRadius)
+{
+ _vector vStartPos = StartPos;
+ _vector vEndPos = EndPos;
+ _vector vDir = { vEndPos - vStartPos };
+
+ _float fDistance = XMVectorGetX(XMVector3Length(vEndPos - vStartPos));
+
+ PSX::PxSweepBuffer pxBuffer = {};
+
+ _bool bHit = m_pGameInstance->SphereCast(fRadius, vStartPos, vDir, fDistance, PSX::PxHitFlag::ePOSITION | PSX::PxHitFlag::eNORMAL, PSX::PxQueryFlag::eDYNAMIC, pxBuffer);
+
+ if (bHit) {
+ const PSX::PxSweepHit& hit = pxBuffer.block;
+ PSX::PxRigidActor* pActor = hit.actor;
+ PSX::PxShape* pShape = hit.shape;
+ ON_COLLISION_INFO tagCollInfo = {};
+ memcpy_s(&tagCollInfo.vWorldPos, sizeof(tagCollInfo.vWorldPos), &hit.position, sizeof(hit.position));
+ memcpy_s(&tagCollInfo.vWorldNomal, sizeof(tagCollInfo.vWorldNomal), &hit.normal, sizeof(hit.normal));
+ XMStoreFloat4(&tagCollInfo.vHitDir, vDir);
+ tagCollInfo.fLength = fDistance;
+ tagCollInfo.pObject = m_pOwner->Get_Owner();
+
+
+ if (nullptr != pActor && nullptr != pActor->userData)
+ {
+ PhsXUserData* pUserData = static_cast(pActor->userData);
+
+ switch (pUserData->eKind)
+ {
+ case PHYSX_KIND::CCTActor:
+ {
+ switch (PXOBJECT(pUserData->iSubKind))
+ {
+ case PXOBJECT::MONSTER:
+ break;
+ case PXOBJECT::GOBLIN_WARRIOR:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ }
+ break;
+ case PXOBJECT::GOBLIN_MAGICIAN:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ }
+ break;
+ case PXOBJECT::TROLL:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ }
+ break;
+ }
+ }
+ }
+ }
+ }
+}
+
void CEffect_Container::Update_Event(_float fTimeDelta)
{
diff --git a/Jusin154_Team3D/Client/Private/Enemy_HpBar.cpp b/Jusin154_Team3D/Client/Private/Enemy_HpBar.cpp
new file mode 100644
index 000000000..6d97f4142
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Enemy_HpBar.cpp
@@ -0,0 +1,352 @@
+#include "pch.h"
+#include "Enemy_HpBar.h"
+#include "GameInstance.h"
+
+CEnemy_HpBar::CEnemy_HpBar(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CElementObject(pDevice, pContext)
+{
+}
+
+CEnemy_HpBar::CEnemy_HpBar(const CEnemy_HpBar& rhs)
+ :CElementObject(rhs)
+{
+}
+
+HRESULT CEnemy_HpBar::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_HpBar::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = 0.f;
+ Desc.fY = 40.f;
+ Desc.fSizeX = 128.f;
+ Desc.fSizeY = 20.f;
+
+ m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fTimeMult = 3.f;
+ m_fAlpha = 0.f;
+ m_fAlphaTime = 10.f;
+ m_vNine_Slice = _float4(15.f, 100.f, 5.f, 15.f);
+ m_fMaxHp = 200.f;
+ m_fCurrentHp = m_fMaxHp;
+ SizeUpX(360.f);
+ m_fMoveSpeed = 5.f;
+ m_bAnimation = false;
+ m_fLerpY = m_fSizeY;
+ return S_OK;
+}
+
+void CEnemy_HpBar::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_HpBar::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bFadeIn == true)
+ {
+ if (m_fAlpha <= 1.f)
+ {
+ m_fAlpha += fTimeDelta * m_fAlphaTime;
+ m_bHover = true;
+ }
+
+
+ if (m_fAlpha >= 1.f)
+ {
+ m_bFadeIn = false;
+ m_fAlpha = 1.f;
+ }
+ }
+
+ if (m_bFadeOut == true)
+ {
+ if (m_fAlpha >= 0.f)
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+
+ if (m_fAlpha <= 0.f)
+ {
+ m_bFadeOut = false;
+ m_bHover = false;
+ m_fAlpha = 0.f;
+ }
+ }
+
+ if (m_fCurrentHp < 0.f)
+ m_fCurrentHp = 0.f;
+ if (m_fDamage <= 0.f)
+ m_fDamage = 0.f;
+ m_fTargetHp = m_fMaxHp - m_fDamage;
+
+ if (m_fTargetHp < m_fCurrentHp)
+ Hit(fTimeDelta);
+ m_fHpBar = m_fCurrentHp / m_fMaxHp;
+
+ if (m_fHpBar <= 0.f)
+ {
+ m_bAnimation = true;
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_3))
+ {
+ Lerp_PosX(101.f);
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_K))
+ {
+ Set_FadeIn();
+ }
+ if (m_pGameInstance->Key_Down(DIK_L))
+ {
+ Set_FadeOut();
+ }
+ if (m_pGameInstance->Key_Down(DIK_J))
+ {
+ m_bAnimation = true;
+ m_bHover = true;
+ m_fTime = 0.f;
+ SizeUpdate(m_fLerpX, m_fLerpY);
+ }
+ if (m_bAnimation == true)
+ {
+ m_fTime += fTimeDelta * m_fTimeMult;
+ m_fSizeX += 3.f;
+ m_fSizeY += 3.f;
+ static_cast(m_pOwner)->Function_Callback(TEXT("Enemy_HpDie"));
+ }
+ if (m_fTime >= 0.9f)
+ {
+ m_bAnimation = false;
+ m_bHover = false;
+ m_fTime = 0.f;
+ SizeUpdate(m_fLerpX, m_fLerpY);
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_HpBar::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ if (m_bVisible) {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_HpBar::Render()
+{
+ if (m_bHover == true)
+ {
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ENEMY_HPBAR)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Bind_Resources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Render())) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+_vector CEnemy_HpBar::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+void CEnemy_HpBar::Lerp_PosX(_float X)
+{
+ m_fDamage += X;
+}
+
+void CEnemy_HpBar::Hit(_float fTimeDelta)
+{
+ m_fCurrentHp = CMyTools::Lerp_f1D(m_fCurrentHp, m_fTargetHp, fTimeDelta * m_fMoveSpeed);
+}
+
+void CEnemy_HpBar::SizeUpX(_float SizeX)
+{
+ m_fSizeX = SizeX;
+ m_fLerpX = SizeX;
+}
+
+void CEnemy_HpBar::Set_Enemt_Info(void* pArg)
+{
+ if(m_bAnimation == true)
+ {
+ return;
+ }
+ //m_fMaxHp
+ //m_fCurrentHp
+ Set_FadeIn();
+}
+
+HRESULT CEnemy_HpBar::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", &m_ViewMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", &m_ProjMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom->Bind_ShaderResource(m_pShaderCom, "g_Texture", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom1->Bind_ShaderResource(m_pShaderCom, "g_Texture1", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom2->Bind_ShaderResource(m_pShaderCom, "g_Texture2", 0)))
+ {
+ 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_fTime", &m_fTime, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAlpha", &m_fAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOwnerAlpha", &m_fOwnerAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCanvasAlpha", &m_fCanvasAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fNine_Slice", &m_vNine_Slice, sizeof(_float4))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOrigin_Size", &m_fOrigin_Size, sizeof(_float2))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCurrent_Size", &m_vScale, sizeof(_float2))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fHp", &m_fHpBar, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_iHover", &m_bAnimation, sizeof(_int))))
+ {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+HRESULT CEnemy_HpBar::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_Monster_HpBar"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_HUD_Monster_HealthMeterFill"), reinterpret_cast(&m_pDiffuse_TextureCom1), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_VFX_T_FlameNoise_E"), reinterpret_cast(&m_pDiffuse_TextureCom2), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, FX_UIEDITOR, (CComponent**)&m_pShaderCom, nullptr)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+CEnemy_HpBar* CEnemy_HpBar::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_HpBar* pInstance = new CEnemy_HpBar(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_HpBar");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_HpBar::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_HpBar* pInstance = new CEnemy_HpBar(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CSpell_Image");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_HpBar::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pDiffuse_TextureCom);
+ SAFE_RELEASE(m_pDiffuse_TextureCom1);
+ SAFE_RELEASE(m_pDiffuse_TextureCom2);
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+#ifdef _DEBUG
+void CEnemy_HpBar::Describe_Entity()
+{
+}
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Enemy_Info.cpp b/Jusin154_Team3D/Client/Private/Enemy_Info.cpp
new file mode 100644
index 000000000..5d1b0fc8d
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Enemy_Info.cpp
@@ -0,0 +1,263 @@
+#include "pch.h"
+#include "Enemy_Info.h"
+#include "GameInstance.h"
+
+CEnemy_Info::CEnemy_Info(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CElementObject(pDevice, pContext)
+{
+}
+
+CEnemy_Info::CEnemy_Info(const CEnemy_Info& rhs)
+ :CElementObject(rhs)
+{
+}
+
+HRESULT CEnemy_Info::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Info::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = -180.f;
+ Desc.fY = 40.f;
+ Desc.fSizeX = 50.f;
+ Desc.fSizeY = 50.f;
+
+ m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fTimeMult = 1.f;
+ m_fAlpha = 0.f;
+ m_fAlphaTime = 10.f;
+ m_fFontX = 952.f;
+ m_fFontY = 39.f;
+ m_fFontPos = _float2(1115.f, 0.f);
+ m_fFont2OffSet = 0.f;
+ m_pEnemy_Name = TEXT("나는 문어");
+ m_pLevel = TEXT("99");
+ m_bAnimation = false;
+ static_cast(m_pOwner)->Add_Function(TEXT("Enemy_HpDie"), [this](void* p) {this->Set_FadeOut(); });
+ return S_OK;
+}
+
+void CEnemy_Info::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_Info::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bFadeIn == true)
+ {
+ if (m_fAlpha <= 1.f)
+ {
+ m_fAlpha += fTimeDelta * m_fAlphaTime;
+ m_bHover = true;
+ }
+
+ if (m_fAlpha >= 1.f)
+ {
+ m_bFadeIn = false;
+ m_fAlpha = 1.f;
+ }
+ }
+
+ if (m_bFadeOut == true)
+ {
+ if (m_fAlpha >= 0.f)
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+
+ if (m_fAlpha <= 0.f)
+ {
+ m_bFadeOut = false;
+ m_bHover = false;
+ m_fAlpha = 0.f;
+ }
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_K))
+ {
+ Set_FadeIn();
+ }
+ if (m_pGameInstance->Key_Down(DIK_L))
+ {
+ Set_FadeOut();
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_Info::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ if (m_bVisible) {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_Info::Render()
+{
+ if (m_bHover == true)
+ {
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::DEFAULT)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Bind_Resources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Render())) {
+ return E_FAIL;
+ }
+
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("Font_size20"), m_pEnemy_Name.c_str()) - 29.f) * 0.5f;
+ m_fFont2OffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_pLevel.c_str()) - 13.f) * 0.5f;
+
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), m_pEnemy_Name.c_str(), _float2(m_fFontPos.x + m_fX - m_fFontOffSet, m_fFontPos.y + m_fY), XMVectorSet(1.f* m_fAlpha,1.f* m_fAlpha,1.f* m_fAlpha, m_fAlpha));
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_pLevel.c_str(), _float2(m_fFontX + m_fX - m_fFont2OffSet, m_fFontY + m_fY), XMVectorSet(0.f, (120.f / 255.f)* m_fAlpha, 0.f, m_fAlpha));
+ }
+
+ return S_OK;
+}
+
+_vector CEnemy_Info::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+HRESULT CEnemy_Info::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", &m_ViewMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", &m_ProjMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom->Bind_ShaderResource(m_pShaderCom, "g_Texture", 0)))
+ {
+ 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_fTime", &m_fTime, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAlpha", &m_fAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOwnerAlpha", &m_fOwnerAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCanvasAlpha", &m_fCanvasAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CEnemy_Info::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_HealthMeter_LevelBox"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, FX_UIEDITOR, (CComponent**)&m_pShaderCom, nullptr)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+void CEnemy_Info::Set_Info(_int Level, _wstring Name)
+{
+ if (m_bAnimation == true)
+ {
+ return;
+ }
+ m_pLevel = to_wstring(Level);
+ m_pEnemy_Name = Name;
+ Set_FadeIn();
+}
+
+CEnemy_Info* CEnemy_Info::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_Info* pInstance = new CEnemy_Info(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_Info");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_Info::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_Info* pInstance = new CEnemy_Info(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CSpell_Image");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_Info::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pDiffuse_TextureCom);
+
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+#ifdef _DEBUG
+void CEnemy_Info::Describe_Entity()
+{
+}
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Enemy_Panel.cpp b/Jusin154_Team3D/Client/Private/Enemy_Panel.cpp
new file mode 100644
index 000000000..d6c0cf606
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Enemy_Panel.cpp
@@ -0,0 +1,163 @@
+#include "pch.h"
+#include "Enemy_Panel.h"
+#include "GameInstance.h"
+#include "Enemy_HpBar.h"
+#include "Enemy_Info.h"
+
+CEnemy_Panel::CEnemy_Panel(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CPanelObject(pDevice, pContext)
+{
+}
+
+CEnemy_Panel::CEnemy_Panel(const CEnemy_Panel& rhs)
+ :CPanelObject(rhs)
+{
+}
+
+HRESULT CEnemy_Panel::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = 960.f;
+ Desc.fY = 50.f;
+ Desc.fSizeX = 960.f;
+ Desc.fSizeY = 150.f;
+
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Element(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fAlpha = 1.f;
+ m_fCanvasAlpha = 1.f;
+ Visible(true);
+ ElementAllVisible(true);
+ return S_OK;
+}
+
+void CEnemy_Panel::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_Panel::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_Panel::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bVisible)
+ {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_Panel::Render()
+{
+ return S_OK;
+}
+
+_vector CEnemy_Panel::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+HRESULT CEnemy_Panel::Bind_ShaderResources()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Ready_Element(void* pArg)
+{
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_HpBar))))
+ {
+ return E_FAIL;
+ }
+ Add_Element(TEXT("Enemy_HpBar"), m_pEnemy_HpBar);
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_Info))))
+ {
+ return E_FAIL;
+ }
+ Add_Element(TEXT("Enemy_Info"), m_pEnemy_Info);
+
+ return S_OK;
+}
+
+CEnemy_Panel* CEnemy_Panel::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_Panel* pInstance = new CEnemy_Panel(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_Panel");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_Panel::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_Panel* pInstance = new CEnemy_Panel(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CEnemy_Panel");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_Panel::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+#ifdef _DEBUG
+void CEnemy_Panel::Describe_Entity()
+{
+}
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp b/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
index e42fc9290..6bd2f5bff 100644
--- a/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
+++ b/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
@@ -5,6 +5,7 @@
#include "MiniMap_Panel.h"
#include "Loading_Panel.h"
#include "Action_Panel.h"
+#include "Enemy_Panel.h"
//#include "Mouse_Cursor.h"
CGamePlay_Canvas::CGamePlay_Canvas(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
@@ -111,6 +112,12 @@ HRESULT CGamePlay_Canvas::Ready_Panel(void* pArg)
}
Add_Panel(TEXT("ActionPanel"), m_pAction_Panel);
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_Panel))))
+ {
+ return E_FAIL;
+ }
+ Add_Panel(TEXT("Enemy_Panel"), m_pEnemy_Panel);
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Goblin.cpp b/Jusin154_Team3D/Client/Private/Goblin.cpp
index bb92f4009..7430ececa 100644
--- a/Jusin154_Team3D/Client/Private/Goblin.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin.cpp
@@ -2,7 +2,11 @@
#include "Goblin.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
+#include "Layer.h"
+#include "Player.h"
#include "Goblin_Dagger.h"
+#include "Goblin_Spector.h"
#include "Effect_Container.h"
#pragma region STATE
@@ -14,6 +18,8 @@
#include "State_Combat.h"
#pragma endregion
+#include "EffectParts.h"
+
CGoblin::CGoblin(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
: CMonster(pDevice, pContext)
@@ -43,23 +49,23 @@ HRESULT CGoblin::Initialize(void* pArg)
Add_FSM();
- Set_Anim();
+Set_Anim();
- {
- CFSM::FSM_DESC FSMDesc{};
- FSMDesc.pStates = &m_States;
- FSMDesc.pStateMask = &m_iStateMask;
+{
+ CFSM::FSM_DESC FSMDesc{};
+ FSMDesc.pStates = &m_States;
+ FSMDesc.pStateMask = &m_iStateMask;
- m_pFSM->Bind_States(FSMDesc);
- m_pFSM->Change_State(FSMSTATE::IDLE);
- }
+ m_pFSM->Bind_States(FSMDesc);
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+}
- m_pCallBack_Behavior->Initialize(m_pCharacter_Controller, m_pRigidBody);
- m_pCallBack_HitReport->Initialize(m_pCharacter_Controller, m_pRigidBody);
+m_pCallBack_Behavior->Initialize(m_pCharacter_Controller, m_pRigidBody);
+m_pCallBack_HitReport->Initialize(m_pCharacter_Controller, m_pRigidBody);
- m_pCharacter_Controller->Set_Position(XMVectorSet(m_pGameInstance->Random_Float(-20.f, 20.f), 0.f, m_pGameInstance->Random_Float(-20.f, 20.f), 1.f));
+m_pCharacter_Controller->Set_Position(XMVectorSet(-40.f, 5.f, -20.f, 1.f));
- return S_OK;
+return S_OK;
}
void CGoblin::Priority_Update(_float fTimeDelta)
@@ -83,7 +89,7 @@ void CGoblin::Update(_float fTimeDelta)
m_pCharacter_Controller->Move(fTimeDelta);
m_vStunTimer.x = 0.f;
}
- else {
+ else if (true == m_pRigidBody->IsActive()) {
if (0.f == m_vStunTimer.x) {
PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
@@ -103,6 +109,8 @@ void CGoblin::Update(_float fTimeDelta)
for (_uint i = 0; i < ENUM_CLASS(GOBLIN_SKILL::END); i++)
m_fSkillCoolTime[i] = max(0.f, m_fSkillCoolTime[i] - fTimeDelta);
+
+
}
void CGoblin::Late_Update(_float fTimeDelta)
@@ -111,18 +119,19 @@ void CGoblin::Late_Update(_float fTimeDelta)
if (true == m_pCharacter_Controller->IsActive()) {
m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_FootPosition());
}
- else {
+ else if (true == m_pRigidBody->IsActive()) {
m_pTransformCom->Set_WorldMatrix(m_pRigidBody->Get_FootPositionPxTransform());
}
-
- m_pTransformCom->LookAt_Horizontal(XMLoadFloat4(&m_vTargetPos));
+ if (true == m_bLookAt) {
+ m_pTransformCom->LookAt_Horizontal(XMLoadFloat4(&m_vTargetPos));
+ }
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+ m_pGameInstance->Add_RenderGroup(RENDER::SHADOW, this);
}
HRESULT CGoblin::Render()
{
-
if (!m_bVisible)
return S_OK;
if (FAILED(Bind_ShaderResources())) {
@@ -134,6 +143,9 @@ HRESULT CGoblin::Render()
if (true == m_bDrawOutLine) {
iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::OUTLINE_WRITE);
}
+ if (FAILED(Render_DeadDisolve())) {
+ return E_FAIL;
+ }
for (_uint i = 0; i < iNumMeshes; i++)
{
if (FAILED(m_pModelCom->Bind_BoneMatrices(i, m_pShaderCom, "g_BoneMatrices"))) {
@@ -163,12 +175,52 @@ HRESULT CGoblin::Render()
return E_FAIL;
}
}
- else {
+ else if (true == m_pRigidBody->IsActive()){
if (FAILED(m_pRigidBody->Render())) {
return E_FAIL;
}
}
#endif
+
+
+ if (0.f < m_fDeadRatio) {
+ _bool bDisolve = false;
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool)))) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
+HRESULT CGoblin::Render_Shadow()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", &m_pGameInstance->Get_ShadowDesc()->fFar, sizeof(_float)))) {
+ 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_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::SHADOW)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
return S_OK;
}
@@ -201,11 +253,15 @@ void CGoblin::OnCollision(CGameObject* pOther, void* pDesc)
m_eHitSpell = STATEANIM::TUMBLE2;
break;
case ENUM_CLASS(SKILL_TYPE::JAP):
+ {
m_eHitSpell = STATEANIM::HIT_LEVIOSO;
- if (true == Get_Damage(60.f)) {
+ _float fSkillRatio = m_pInfoInstance->Get_Spell_Info(ENUM_CLASS(SKILL_TYPE::JAP)).fSpell_Damage;
+ _float fCoefficient = CollisionDesc->pObject->Get_Component()->Get_Stat(ENUM_CLASS(STAT::MAGIC));
+ if (true == Get_Damage(fSkillRatio * fCoefficient)) {
m_pFSM->Change_State(FSMSTATE::DEAD);
return;
}
+ }
break;
case ENUM_CLASS(SKILL_TYPE::LEVIOSO):
m_eHitSpell = STATEANIM::HIT_LEVIOSO;
@@ -289,10 +345,55 @@ HRESULT CGoblin::Ready_Parts()
{
return E_FAIL;
}
-
-
Get_PartObject()->Set_Visible(false);
+
+ CGoblin_Spector::GOBLIN_SPECTOR_DESC Goblin_SpectorDesc{};
+
+ Goblin_SpectorDesc.pParentTransform = m_pTransformCom;
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER, &Goblin_SpectorDesc,this))) {
+ return E_FAIL;
+ }
+
+#pragma region EFFECT
+ /* EFFECT */
+
+ CPartObject::PARTOBJECT_DESC PartsDesc{};
+
+ PartsDesc.pParentTransform = m_pTransformCom;
+
+ if (FAILED(Add_PartObject("Goblin_Particle",g_iStaticLevel, &m_pGoblin_Particle, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pGoblin_Particle->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle", static_cast(NEXT_LEVEL));
+ m_pGoblin_Particle->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+
+ if (FAILED(Add_PartObject("Goblin_Particle2", g_iStaticLevel, &m_pGoblin_Particle2, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pGoblin_Particle2->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2", static_cast(NEXT_LEVEL));
+ m_pGoblin_Particle2->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+ if (FAILED(Add_PartObject("Goblin_Smoke", g_iStaticLevel, &m_pSmoke, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pSmoke->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke", static_cast(NEXT_LEVEL));
+ m_pSmoke->FollowParants(m_pModelCom->Get_BoneMatrixPtr("Spine2"));
+
+
+#pragma endregion
+ return S_OK;
+
return S_OK;
}
@@ -351,6 +452,9 @@ void CGoblin::Free()
SAFE_RELEASE(m_pCharacter_Controller);
SAFE_RELEASE(m_pRigidBody);
+ SAFE_RELEASE(m_pSmoke);
+ SAFE_RELEASE(m_pGoblin_Particle);
+ SAFE_RELEASE(m_pGoblin_Particle2);
Safe_Delete(m_pCallBack_Behavior);
Safe_Delete(m_pCallBack_HitReport);
}
@@ -380,6 +484,14 @@ void CGoblin::Describe_Entity()
m_pCharacter_Controller->Set_Position(XMLoadFloat3(&Pos));
}
+ XMFLOAT3 f3;
+ XMStoreFloat3(&f3, m_vOriginPos);
+
+ GUI::Text("Origin: %.2f, %.2f, %.2f", f3.x, f3.y, f3.z);
+
+ m_fLength = XMVectorGetX(XMVector2Length(m_pTransformCom->Get_State(STATE::POSITION) - m_vOriginPos));
+
+ GUI::Text("Length %.2f", m_fLength);
GUI::TextColored(ImVec4(1.f, 0.f, 0.f, 1.f), "Distance %.2f", m_fTargetDistance);
diff --git a/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp b/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp
new file mode 100644
index 000000000..c83e46c8d
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp
@@ -0,0 +1,180 @@
+#include "pch.h"
+#include "Goblin_BattleAxe.h"
+
+#include "GameInstance.h"
+#include "TrailObject.h"
+#include "EffectParts.h"
+
+CGoblin_BattleAxe::CGoblin_BattleAxe(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CPartObject(pDevice, pContext)
+{
+}
+
+CGoblin_BattleAxe::CGoblin_BattleAxe(const CGoblin_BattleAxe& Prototype)
+ : CPartObject(Prototype)
+{
+}
+
+HRESULT CGoblin_BattleAxe::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_BattleAxe::Initialize(void* pArg)
+{
+ GOBLIN_BATTLEAXE_DESC* pDesc = static_cast (pArg);
+ m_pSocketMatrices = pDesc->pSocketMatrices;
+
+ if (FAILED(__super::Initialize(pArg))) {
+ return E_FAIL;
+ }
+
+
+ if (FAILED(Ready_Components())) {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_BattleAxe::Priority_Update(_float fTimeDelta)
+{
+ m_pModelCom->Combined_BoneMatrix();
+ _matrix socketMatrix = {};
+
+ socketMatrix = XMLoadFloat4x4(m_pSocketMatrices);
+
+ for (int i = 0; i < 3; ++i) {
+ socketMatrix.r[i] = XMVector3Normalize(socketMatrix.r[i]);
+ }
+
+ m_pTransformCom->Set_WorldMatrix(socketMatrix * XMLoadFloat4x4(m_pParentTransformCom->Get_WorldMatrixPtr()));
+
+#ifdef _DEBUG
+ Describe_Entity();
+
+#endif // _DEBUG
+}
+
+void CGoblin_BattleAxe::Update(_float fTimeDelta)
+{
+
+
+}
+
+void CGoblin_BattleAxe::Late_Update(_float fTimeDelta)
+{
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CGoblin_BattleAxe::Render()
+{
+ if (!m_pModelCom)
+ return S_OK;
+
+ if (!m_bVisible)
+ return S_OK;
+
+ 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_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_MESH::DEFAULT)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+HRESULT CGoblin_BattleAxe::Ready_Components()
+{
+ __super::Ready_Components(nullptr);
+
+ /* Com_Model */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_Goblin_BattleAxe_Model"),
+ reinterpret_cast(&m_pModelCom))))
+ return E_FAIL;
+
+ /* Com_Shader */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_MESH,
+ reinterpret_cast(&m_pShaderCom))))
+ return E_FAIL;
+
+ return S_OK;
+}
+
+HRESULT CGoblin_BattleAxe::Bind_ShaderResources()
+{
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_WorldMatrix", m_pTransformCom->Get_WorldMatrixPtr()))) {
+ 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;
+ }
+
+ return S_OK;
+}
+
+
+CGoblin_BattleAxe* CGoblin_BattleAxe::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_BattleAxe* pInstance = new CGoblin_BattleAxe(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_BattleAxe");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CGoblin_BattleAxe::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_BattleAxe* pInstance = new CGoblin_BattleAxe(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_BattleAxe");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CGoblin_BattleAxe::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pModelCom);
+
+}
+#ifdef _DEBUG
+
+void CGoblin_BattleAxe::Describe_Entity()
+{
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp b/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
index a444f8a1d..9000f9a41 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
@@ -38,7 +38,7 @@ HRESULT CGoblin_Dagger::Initialize(void* pArg)
void CGoblin_Dagger::Priority_Update(_float fTimeDelta)
{
- m_pModelCom->Combined_BoneMatrix();
+ //m_pModelCom->Combined_BoneMatrix();
if (m_bAttach)
{
_matrix socketMatrix = {};
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp b/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp
new file mode 100644
index 000000000..c7d1b8020
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp
@@ -0,0 +1,426 @@
+#include "pch.h"
+#include "Goblin_Mage.h"
+
+#include "Layer.h"
+#include "EffectPool.h"
+#include "GameInstance.h"
+#include "InfoInstance.h"
+#include "Goblin_Dagger.h"
+#include "Effect_Container.h"
+#include "Wand.h"
+
+#pragma region STATE
+#include "State_Idle.h"
+#include "State_Dodge.h"
+#include "State_Jump.h"
+#include "State_Land.h"
+#include "State_Move.h"
+#include "State_Combat.h"
+#pragma endregion
+
+
+CGoblin_Mage::CGoblin_Mage(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CMonster(pDevice, pContext)
+{
+}
+
+CGoblin_Mage::CGoblin_Mage(const CGoblin_Mage& Prototype)
+ : CMonster(Prototype)
+{
+}
+
+HRESULT CGoblin_Mage::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Mage::Initialize(void* pArg)
+{
+ if (FAILED(__super::Initialize(pArg)))
+ return E_FAIL;
+
+ if (FAILED(Ready_Components()))
+ return E_FAIL;
+
+ if (FAILED(Ready_Parts()))
+ return E_FAIL;
+
+ Add_FSM();
+
+ Set_Anim();
+
+ {
+ CFSM::FSM_DESC FSMDesc{};
+ FSMDesc.pStates = &m_States;
+ FSMDesc.pStateMask = &m_iStateMask;
+
+ m_pFSM->Bind_States(FSMDesc);
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ }
+
+ m_pCallBack_Behavior->Initialize(m_pCharacter_Controller, m_pRigidBody);
+ m_pCallBack_HitReport->Initialize(m_pCharacter_Controller, m_pRigidBody);
+
+ m_pEffectPool = m_pGameInstance->Get_Layer(NEXT_LEVEL, TEXT("Layer_EffectPool"))->Get_Object();
+ SAFE_ADDREF(m_pEffectPool);
+
+ m_pCharacter_Controller->Set_Position(XMVectorSet(m_pGameInstance->Random_Float(-20.f, 20.f), 0.f, m_pGameInstance->Random_Float(-20.f, 20.f), 1.f));
+
+ return S_OK;
+}
+
+void CGoblin_Mage::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CGoblin_Mage::Update(_float fTimeDelta)
+{
+ __super::Update(fTimeDelta);
+
+ m_pFSM->Update_State(fTimeDelta);
+
+ m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
+
+ Play_Event();
+
+ GUI::Text("%d", m_pCharacter_Controller->IsActive());
+ GUI::Text("%f %f", m_vStunTimer.x, m_vStunTimer.y);
+ if (true == m_pCharacter_Controller->IsActive()) {
+ m_pCharacter_Controller->Move(fTimeDelta);
+ m_vStunTimer.x = 0.f;
+ }
+ else if (true == m_pRigidBody->IsActive()) {
+ if (0.f == m_vStunTimer.x) {
+ PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
+ PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
+ m_pCharacter_Controller->Set_Position(XMLoadFloat3((_float3*)&pxTransform.p));
+ //m_pCharacter_Controller->Move(fTimeDelta);
+ }
+ m_vStunTimer.x += fTimeDelta;
+ m_pTransformCom->Set_WorldMatrix(m_pRigidBody->Get_Actor()->getGlobalPose());
+ if (m_vStunTimer.y < m_vStunTimer.x) {
+ m_pRigidBody->ConvertToCCT(*m_pCharacter_Controller);
+ }
+ }
+#ifdef _DEBUG
+ Describe_Entity();
+#endif // _DEBUG
+
+ for (_uint i = 0; i < ENUM_CLASS(GOBLIN_SKILL::END); i++){
+ m_fSkillCoolTime[i] = max(0.f, m_fSkillCoolTime[i] - fTimeDelta);
+ }
+
+}
+
+void CGoblin_Mage::Late_Update(_float fTimeDelta)
+{
+ __super::Late_Update(fTimeDelta);
+ if (true == m_pCharacter_Controller->IsActive()) {
+ m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_FootPosition());
+ }
+ else if (true == m_pRigidBody->IsActive()) {
+ m_pTransformCom->Set_WorldMatrix(m_pRigidBody->Get_FootPositionPxTransform());
+ }
+ if (true == m_bLookAt) {
+ m_pTransformCom->LookAt_Horizontal(XMLoadFloat4(&m_vTargetPos));
+ }
+
+ m_pTransformCom->LookAt_Horizontal(XMLoadFloat4(&m_vTargetPos));
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+ m_pGameInstance->Add_RenderGroup(RENDER::SHADOW, this);
+}
+
+HRESULT CGoblin_Mage::Render()
+{
+
+ if (!m_bVisible)
+ return S_OK;
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+ _uint iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::DEFAULT);
+ if (true == m_bDrawOutLine) {
+ iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::OUTLINE_WRITE);
+ }
+ 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))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(iShaderPass))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ if (m_bDrawOutLine) {
+ Render_OutLine();
+ }
+
+#ifdef _DEBUG
+ if (true == m_pCharacter_Controller->IsActive()) {
+ if (FAILED(m_pCharacter_Controller->Render())) {
+ return E_FAIL;
+ }
+ }
+ else if (true == m_pRigidBody->IsActive()) {
+ if (FAILED(m_pRigidBody->Render())) {
+ return E_FAIL;
+ }
+ }
+#endif
+
+
+ if (0.f < m_fDeadRatio) {
+ _bool bDisolve = false;
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool)))) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
+HRESULT CGoblin_Mage::Render_Shadow()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", &m_pGameInstance->Get_ShadowDesc()->fFar, sizeof(_float)))) {
+ 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_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::SHADOW)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Mage::OnCollision(CGameObject* pOther, void* pDesc)
+{
+ ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
+
+ _uint iSkillType = dynamic_cast(pOther)->Get_SkillType();
+ switch (iSkillType)
+ {
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ m_eHitSpell = STATEANIM::KNOCKDOWN_FWD;
+ break;
+ case ENUM_CLASS(SKILL_TYPE::FLIPENDO):
+ m_eHitSpell = STATEANIM::TUMBLE2;
+ break;
+ case ENUM_CLASS(SKILL_TYPE::JAP):
+ {
+ m_eHitSpell = STATEANIM::HIT_LEVIOSO;
+ _float fSkillRatio = m_pInfoInstance->Get_Spell_Info(ENUM_CLASS(SKILL_TYPE::JAP)).fSpell_Damage;
+ _float fCoefficient = CollisionDesc->pObject->Get_Component()->Get_Stat(ENUM_CLASS(STAT::MAGIC));
+ if (true == Get_Damage(fSkillRatio * fCoefficient)) {
+ m_pFSM->Change_State(FSMSTATE::DEAD);
+ return;
+ }
+ }
+ break;
+ case ENUM_CLASS(SKILL_TYPE::LEVIOSO):
+ m_eHitSpell = STATEANIM::HIT_LEVIOSO;
+ break;
+ default:
+ m_eHitSpell = STATEANIM::KNOCKDOWN_FWD;
+ break;
+ }
+ if (!m_pFSM->IsEnable(FSMSTATE::BLINK)){
+ m_pFSM->Change_State(FSMSTATE::HIT);
+ }
+}
+
+void CGoblin_Mage::OnHit(CGameObject* pOther, CGameObject* pCaller)
+{
+}
+
+HRESULT CGoblin_Mage::Ready_Components()
+{
+ CTransform::TRANSFORM_DESC Desc = {};
+
+ Desc.fSpeedPerSec = 10.f;
+ Desc.fRotationPerSec = XMConvertToRadians(180.0f);
+ Desc.fRadius = 10.f;
+
+ __super::Ready_Components(&Desc);
+
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Goblin_Mage_Model");
+
+ /* Com_Model */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_strModelPrototypeTag,
+ reinterpret_cast(&m_pModelCom)))) {
+ return E_FAIL;
+ }
+
+ { // CCT
+ CCharacter_Controller::Character_Controller_DESC Desc{};
+
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::GOBLIN_MAGICIAN);
+ Desc.pTransform = m_pTransformCom;
+ Desc.eBodyType = ACTOR::CAPSULE;
+ Desc.fContactOffset = 0.3f;
+ Desc.fMaterial = { 1.2f, 1.0f, 0.0f };
+ Desc.bAutoStepping = { false };
+ Desc.fStepOffset = { 0.05f };
+ Desc.fRadius = 0.6f;
+ Desc.fHeight = 0.7f;
+ Desc.pCallback_HitReport = m_pCallBack_HitReport = CCallBack_Monster_HitReport::Create();
+ Desc.pCallback_Behavior = m_pCallBack_Behavior = CCallBack_Monster_Behavior::Create();
+ Desc.eClimbingMode = PSX::PxCapsuleClimbingMode::eEASY;
+ Desc.fWalkableSlope = 45.f;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_CCT_CAPSULE"), (CComponent**)&m_pCharacter_Controller, &Desc))) {
+ return E_FAIL;
+ }
+ }
+ m_pCharacter_Controller->Set_Position(m_pTransformCom->Get_State(STATE::POSITION));
+ { // DO
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::GOBLIN_MAGICIAN);
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_BOX"), (CComponent**)&m_pRigidBody, &Desc))) {
+ return E_FAIL;
+ }
+ m_pGameInstance->Detach_Actor(*m_pRigidBody->Get_Actor());
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("STAT_GOBLIN"), (CComponent**)&m_pStat))) {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Mage::Ready_Parts()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Mage::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;
+ }
+ return S_OK;
+}
+
+CGoblin_Mage* CGoblin_Mage::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Mage* pInstance = new CGoblin_Mage(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Mage");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+CGameObject* CGoblin_Mage::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Mage* pInstance = new CGoblin_Mage(*this);
+
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Mage");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CGoblin_Mage::Free()
+{
+ __super::Free();
+
+ if (nullptr != m_pCallBack_Behavior) {
+ m_pCallBack_Behavior->Finalize();
+ }
+ if (nullptr != m_pCallBack_HitReport) {
+ m_pCallBack_HitReport->Finalize();
+ }
+
+ SAFE_RELEASE(m_pCharacter_Controller);
+ SAFE_RELEASE(m_pRigidBody);
+ SAFE_RELEASE(m_pEffectPool);
+ Safe_Delete(m_pCallBack_Behavior);
+ Safe_Delete(m_pCallBack_HitReport);
+}
+#ifdef _DEBUG
+
+void CGoblin_Mage::Describe_Entity()
+{
+ GUI::Begin("Goblin");
+
+ GUI::Checkbox("LookAt", &m_bLookAt);
+
+ string AnimList = m_pModelCom->Get_AnimList(m_pModelCom->Get_AnimIndex());
+ GUI::Text(AnimList.c_str());
+
+ GUI::Text("AnimTrack %.2f", m_pModelCom->Get_CurrentTrackPosition());
+ GUI::Text("AnimRatio %.2f", m_pModelCom->Get_CurrentTrackProgressRatio());
+
+ _float4 vMomentum = {};
+ XMStoreFloat4(&vMomentum, m_pTransformCom->Get_CurrentMomentum());
+ GUI::Text("%.2f %.2f %.2f %.2f ", vMomentum.x, vMomentum.y, vMomentum.z, vMomentum.w);
+
+ _float3 Pos;
+ XMStoreFloat3(&Pos, Get_WorldPostion());
+
+ if (GUI::DragFloat3("Pos", (_float*)&Pos))
+ {
+ m_pCharacter_Controller->Set_Position(XMLoadFloat3(&Pos));
+ }
+
+ XMFLOAT3 f3;
+ XMStoreFloat3(&f3, m_vOriginPos);
+
+ GUI::Text("Origin: %.2f, %.2f, %.2f", f3.x, f3.y, f3.z);
+
+ m_fLength = XMVectorGetX(XMVector2Length(m_pTransformCom->Get_State(STATE::POSITION) - m_vOriginPos));
+
+ GUI::Text("Length %.2f", m_fLength);
+
+ GUI::TextColored(ImVec4(1.f, 0.f, 0.f, 1.f), "Distance %.2f", m_fTargetDistance);
+
+
+ GUI::End();
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp b/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp
new file mode 100644
index 000000000..6379d113e
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp
@@ -0,0 +1,586 @@
+#include "pch.h"
+#include "Goblin_Mage.h"
+
+#include "GameInstance.h"
+#include "EffectPool.h"
+#include "Player.h"
+
+#pragma region STATE
+#include "State_Idle.h"
+#include "State_Dead.h"
+#include "State_Move.h"
+#include "State_Combat.h"
+#include "State_Spell.h"
+#include "State_LightAttack.h"
+#include "State_Blink.h"
+#include "State_Hit.h"
+#pragma endregion
+
+
+void CGoblin_Mage::Behavior_IdleEnter()
+{
+ m_pFSM->Enable_State(FSMSTATE::IDLE);
+ pair<_uint, _bool> pairAnimInfo = m_Animation[STATEANIM::IDLE];
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+}
+
+HRESULT CGoblin_Mage::Behavior_IdleExitCheck()
+{
+ if (m_fTargetDistance <= 20.f && m_fTargetDistance != 0.f)
+ {
+ m_vOriginPos = m_pTransformCom->Get_State(STATE::POSITION);
+ m_pEffectPool->Use_Skill(SKILL_TYPE::PROTEGO, this);
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ }
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_IdleExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::IDLE);
+}
+
+void CGoblin_Mage::Behavior_MoveEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::MOVE);
+
+ m_pFSM->Enable_State(FSMSTATE::JOG);
+
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+
+}
+
+HRESULT CGoblin_Mage::Behavior_MoveExitCheck()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+
+ if (m_fTargetDistance <= 15.f && m_fTargetDistance != 0.f)
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_MoveExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::MOVE | FSMSTATE::SPRINT | FSMSTATE::JOG | FSMSTATE::WALK);
+}
+
+void CGoblin_Mage::Behavior_CombatEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::COMBAT);
+
+ m_bLookAt = true;
+
+}
+
+HRESULT CGoblin_Mage::Behavior_CombatExitCheck(_float fTimeDelta)
+{
+ m_bLookAt = true;
+
+ if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance > 20.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ return E_FAIL;
+ }
+
+
+ if (m_fTargetDistance <= 7.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::BLINK);
+ }
+ else if (m_fTargetDistance <= 15.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SPELL)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::SPELL);
+ }
+ else if (m_fTargetDistance <= 15.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::LIGHTATTACK)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::LIGHT_ATTACK);
+ }
+ else {
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ }
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_CombatExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::COMBAT);
+}
+
+void CGoblin_Mage::Behavior_SpellEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ pairAnimInfo = m_Animation[STATEANIM::SPELL_CHARGE];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+}
+
+HRESULT CGoblin_Mage::Behavior_SpellExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ if (iCurrAnimIndex == m_Animation[STATEANIM::SPELL_CHARGE].first)
+ {
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ pairAnimInfo = m_Animation[STATEANIM::SPELL];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SPELL)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SPELL)];
+ }
+ return S_OK;
+ }
+
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_bLookAt = true;
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_SpellExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::SPELL);
+}
+
+void CGoblin_Mage::Behavior_LightAttackEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ pairAnimInfo = m_Animation[STATEANIM::LIGHT_ATTACK];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::LIGHTATTACK)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::LIGHTATTACK)];
+}
+
+HRESULT CGoblin_Mage::Behavior_LightAttackExitCheck(_float fTimeDelta)
+{
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_bLookAt = true;
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_LightAttackExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::LIGHT_ATTACK);
+}
+
+void CGoblin_Mage::Behavior_BlinkEnter()
+{
+
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::BLINK);
+
+ pairAnimInfo = m_Animation[STATEANIM::BLINK_START];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_bVisible = false;
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)];
+ _vector vPos = Get_WorldPostion();
+ _vector vLook =m_pTransformCom->Get_State(STATE::LOOK);
+ vLook = XMVectorSetY(vLook, 0.f);
+ vLook = XMVector3Normalize(vLook);
+
+ _float randAngleDeg = m_pGameInstance->Real_Random_Float(-60.f, 60.f);
+ _float randAngleRad = XMConvertToRadians(randAngleDeg);
+
+ _matrix rot = XMMatrixRotationY(randAngleRad);
+ _vector offsetDir = XMVector3TransformNormal(vLook, rot);
+
+ _float randDist = m_pGameInstance->Real_Random_Float(-5.f, -3.f);
+
+ _vector vFinalPos = vPos + offsetDir * randDist;
+
+ m_pCharacter_Controller->Set_Position(vFinalPos); }
+ , 0.99f);
+}
+
+HRESULT CGoblin_Mage::Behavior_BlinkExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ m_fTpTime += fTimeDelta;
+ if (m_fTpTime >= 1.5f)
+ {
+ m_bVisible = true;
+ m_fTpTime = 0.f;
+ pairAnimInfo = m_Animation[STATEANIM::BLINK];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+
+ if (m_pModelCom->IsFinishedAnim() && iCurrAnimIndex == m_Animation[STATEANIM::BLINK].first)
+ {
+ m_bLookAt = true;
+ m_fTpTime = 0.f;
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_BlinkExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::BLINK);
+}
+
+void CGoblin_Mage::Behavior_HitEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::HIT);
+
+ switch (m_eHitSpell)
+ {
+ case STATEANIM::KNOCKDOWN_FWD:
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_FWD];
+ break;
+ case STATEANIM::TUMBLE2:
+ pairAnimInfo = m_Animation[STATEANIM::TUMBLE2];
+ break;
+ case STATEANIM::HIT_LEVIOSO:
+ {
+ pairAnimInfo = m_Animation[STATEANIM::HIT_LEVIOSO];
+ break;
+ }
+ default:
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_FWD];
+ break;
+ }
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+}
+
+HRESULT CGoblin_Mage::Behavior_HitExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::KNOCKDOWN_FWD].first)
+ {
+ if (m_pModelCom->Get_CurrentTrackProgressRatio() >= 0.5f)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_FWD_SPLT];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ }
+ }
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::HIT_LEVIOSO].first)
+ {
+ _vector vDir = m_pTransformCom->Get_State(STATE::UP);
+ vDir = XMVector4Normalize(vDir);
+ _vector vPos = m_pCharacter_Controller->Get_Position();
+ m_fAirTime += fTimeDelta;
+ _vector Force = vDir * fTimeDelta;
+ if (m_fAirTime < 1.3f) {
+ m_pCharacter_Controller->Set_Position(vPos + Force);
+ }
+ else {
+ m_pCharacter_Controller->Set_Position(vPos);
+ }
+ m_pCharacter_Controller->SetGravity(false);
+
+ if (m_pModelCom->Get_CurrentTrackProgressRatio() >= 0.31f)
+ {
+ m_fAirTime = 0.f;
+ m_pCharacter_Controller->SetGravity(true);
+ pairAnimInfo = m_Animation[STATEANIM::LAND];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ }
+ }
+
+
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_bLookAt = true;
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ return E_FAIL;
+ }
+ return E_FAIL;
+}
+
+void CGoblin_Mage::Behavior_HitExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::HIT);
+}
+
+void CGoblin_Mage::Behavior_DeadEnter()
+{
+ m_bLookAt = false;
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::DEAD);
+ PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
+ PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
+ m_pCharacter_Controller->Set_Position(XMLoadFloat3((_float3*)&pxTransform.p));
+ m_pRigidBody->SetActive(false);
+ m_pCharacter_Controller->SetActive(false);
+
+ _bool bStrongerKnockDown = { false };
+
+ switch (m_eHitSpell)
+ {
+ case STATEANIM::KNOCKDOWN_FWD:
+ bStrongerKnockDown = true;
+ break;
+ case STATEANIM::TUMBLE2:
+ bStrongerKnockDown = true;
+ break;
+ default:
+ break;
+ }
+
+ _float fabsRadius = fabsf(m_fHitRadius);
+ _uint iState = { UINT_MAX };
+
+ if (fabsRadius > 135.f) {
+ iState = STATEANIM::DEAD_FWD;
+ }
+ else if (fabsRadius < 45.f) {
+ iState = STATEANIM::DEAD_BWD;
+ }
+ else {
+ if (m_fHitRadius < 0.f) {
+ iState = STATEANIM::DEAD_L;
+ }
+ else {
+ iState = STATEANIM::DEAD_R;
+ }
+ }
+ pairAnimInfo = m_Animation[iState + bStrongerKnockDown];
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+}
+
+HRESULT CGoblin_Mage::Behavior_DeadExitCheck(_float fTimeDelta)
+{
+ if (FLT_EPSILON > m_pModelCom->Get_CurrentTrackProgressRatio()) {
+ return E_PENDING;
+ }
+ return S_OK;
+}
+
+void CGoblin_Mage::Behavior_DeadExit()
+{
+ m_bDead = true;
+}
+
+
+
+void CGoblin_Mage::Add_FSM()
+{
+#pragma region Behavior_Movement_NotFocus
+ {
+ CState_Idle::STATE_IDLE_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_IdleEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_IdleExitCheck(); };
+ Desc.funcExitEvent = [this]() { Behavior_IdleExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::IDLE, CState_Idle::Create(&Desc));
+ }
+ {
+ CState_Move::STATE_MOVE_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_MoveEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_MoveExitCheck(); };
+ Desc.funcExitEvent = [this]() { Behavior_MoveExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::MOVE, CState_Move::Create(&Desc));
+ }
+#pragma endregion
+#pragma region Behavior_Combat_NotFocus
+ {
+ CState_Combat::STATE_COMBAT_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_CombatEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_CombatExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_CombatExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::COMBAT, CState_Combat::Create(&Desc));
+ }
+
+ {
+ CState_Spell::STATE_SPELL_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_SpellEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_SpellExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_SpellExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::SPELL, CState_Spell::Create(&Desc));
+ }
+
+ {
+ CState_LightAttack::STATE_LIGHTATTACK_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_LightAttackEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_LightAttackExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_LightAttackExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::LIGHT_ATTACK, CState_LightAttack::Create(&Desc));
+ }
+
+ {
+ CState_Blink::STATE_BLINK_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_BlinkEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_BlinkExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_BlinkExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::BLINK, CState_Blink::Create(&Desc));
+ }
+
+#pragma endregion
+#pragma region Behavior_Combat_Focus
+ {
+ CState_Dead::STATE_DEAD_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_DeadEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_DeadExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_DeadExit(); };
+ Desc.funcLateUpdate = [this](_float fDeadRatio) {
+ m_fDeadRatio = fDeadRatio;
+ if (m_fDeadRatio > 1.f) {
+ m_bDead = true;
+ }
+ };
+ Desc.vDeadTimer.x = FLT_EPSILON5;
+ Desc.vDeadTimer.y = 2.f;
+ m_States.emplace(FSMSTATE::DEAD, CState_Dead::Create(&Desc));
+ }
+#pragma endregion
+
+#pragma region Hit
+ {
+ CState_Hit::STATE_HIT_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_HitEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_HitExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_HitExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::HIT, CState_Hit::Create(&Desc));
+ }
+
+#pragma endregion
+
+
+}
+
+void CGoblin_Mage::Set_Anim()
+{
+ m_Animation[STATEANIM::IDLE] = { 22,true };
+ m_Animation[STATEANIM::IDLE_TURN_BWD] = { 24, false };
+ m_Animation[STATEANIM::IDLE_TURN_L] = { 26, false };
+ m_Animation[STATEANIM::IDLE_TURN_R] = { 30, false };
+
+ m_Animation[STATEANIM::WALK_FWD] = { 45,true };
+ m_Animation[STATEANIM::WALK_START] = { 57,false };
+ m_Animation[STATEANIM::WALK_STOP] = { 58,false };
+ m_Animation[STATEANIM::WALK_BWD] = { 252, true };
+
+ m_Animation[STATEANIM::JOG_FWD] = { 147,true }; // 147
+ m_Animation[STATEANIM::JOG_START] = { 157,false };
+ m_Animation[STATEANIM::JOG_BWD] = { 146,false };
+
+ m_Animation[STATEANIM::SHUFFLE1] = { 203,false };
+ m_Animation[STATEANIM::SHUFFLE2] = { 204,false };
+ m_Animation[STATEANIM::SHUFFLE3] = { 205,false };
+ m_Animation[STATEANIM::SHUFFLE4] = { 206,false };
+
+ m_Animation[STATEANIM::DODGE_LEFT] = { 125, false };
+ m_Animation[STATEANIM::DODGE_RIGHT] = { 126, false };
+ m_Animation[STATEANIM::SPRINT] = { 90, true };
+
+ m_Animation[STATEANIM::SKILL] = { 85,false }; // 나이프 던지기
+ m_Animation[STATEANIM::BLINK_START] = { 428,false };
+ m_Animation[STATEANIM::BLINK] = { 426,false }; // 텔레포트
+ m_Animation[STATEANIM::SWING_FWD] = { 100,false }; // 도끼 스윙 444
+ m_Animation[STATEANIM::ATTACK_END] = { 76,false };
+
+
+ m_Animation[STATEANIM::SPELL_CHARGE] = { 437,false };
+ m_Animation[STATEANIM::SPELL] = { 435,false };
+ m_Animation[STATEANIM::LIGHT_ATTACK] = { 443,false };
+
+ m_Animation[STATEANIM::HIT_FWD] = { 353, false };
+ m_Animation[STATEANIM::HIT_BWD] = { 352, false };
+ m_Animation[STATEANIM::HIT_BWD2] = { 349, false };
+ m_Animation[STATEANIM::HIT_BWD3] = { 350, false };
+ m_Animation[STATEANIM::HIT_BWD4] = { 351, false };
+ m_Animation[STATEANIM::HIT_L] = { 354, false };
+ m_Animation[STATEANIM::HIT_R] = { 355, false };
+
+ m_Animation[STATEANIM::KNOCKDOWN_BWD] = { 374, false };
+ m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT] = { 375, false };
+ m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT_HOLD] = { 370, false };
+ m_Animation[STATEANIM::KNOCKDOWN_FWD] = { 371, false };
+ m_Animation[STATEANIM::KNOCKDOWN_FWD_SPLT] = { 372, false };
+ m_Animation[STATEANIM::KNOCKDOWN_FWD_SPLT_HOLD] = { 373, false };
+
+ m_Animation[STATEANIM::GETUP_BWD] = { 330, false };
+ m_Animation[STATEANIM::GETUP_FWD] = { 332, false };
+ m_Animation[STATEANIM::GETUP_L] = { 334, false };
+ m_Animation[STATEANIM::GETUP_L_FD] = { 336, false };
+ m_Animation[STATEANIM::GETUP_L_FU] = { 338, false };
+ m_Animation[STATEANIM::GETUP_R] = { 340, false };
+ m_Animation[STATEANIM::GETUP_R_FD] = { 342, false };
+ m_Animation[STATEANIM::GETUP_R_FU] = { 344, false };
+ m_Animation[STATEANIM::GETUP_SLOUCH] = { 346, false };
+
+ m_Animation[STATEANIM::KNOCKBACK] = { 377, true };
+ m_Animation[STATEANIM::KNOCKBACK2] = { 378, true };
+ m_Animation[STATEANIM::TUMBLE] = { 379, true };
+ m_Animation[STATEANIM::TUMBLE2] = { 380, true };// 원래 true 였음
+ m_Animation[STATEANIM::PETRIFICUSED_START] = { 383, false };
+
+ m_Animation[STATEANIM::LAND] = { 376, false };
+ m_Animation[STATEANIM::HIT_LEVIOSO] = { 381, false };
+
+ m_Animation[STATEANIM::DEAD_BWD] = { 317, false };
+ m_Animation[STATEANIM::DEAD_BWD2] = { 318, false };
+ m_Animation[STATEANIM::DEAD_FWD] = { 319, false };
+ m_Animation[STATEANIM::DEAD_FWD2] = { 320, false };
+ m_Animation[STATEANIM::DEAD_L] = { 321, false };
+ m_Animation[STATEANIM::DEAD_L2] = { 322, false };
+ m_Animation[STATEANIM::DEAD_R] = { 323, false };
+ m_Animation[STATEANIM::DEAD_R2] = { 324, false };
+
+ // Range 올려치기 어택 443
+ // 내려찍기 공격 시작모션 437
+ // 내려찍기 공격 435
+
+ // 쉴드 블럭
+
+ // 겁먹기 327 328
+
+
+
+
+ // idle break 137
+}
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Spector.cpp b/Jusin154_Team3D/Client/Private/Goblin_Spector.cpp
new file mode 100644
index 000000000..c30db5c0c
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Spector.cpp
@@ -0,0 +1,284 @@
+#include "pch.h"
+#include "Goblin_Spector.h"
+
+#include "GameInstance.h"
+#include "Goblin.h"
+#include "Effect_Container.h"
+#include "Goblin_BattleAxe.h"
+
+#include "EffectParts.h"
+
+
+CGoblin_Spector::CGoblin_Spector(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CMonster(pDevice, pContext)
+{
+}
+
+CGoblin_Spector::CGoblin_Spector(const CGoblin_Spector& Prototype)
+ : CMonster(Prototype)
+{
+}
+
+HRESULT CGoblin_Spector::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Spector::Initialize(void* pArg)
+{
+ GOBLIN_SPECTOR_DESC* pDesc = static_cast (pArg);
+ m_pParentTransformCom = pDesc->pParentTransform;
+ if (FAILED(__super::Initialize(pArg)))
+ return E_FAIL;
+
+ if (FAILED(Ready_Components()))
+ return E_FAIL;
+
+ if (FAILED(Ready_Parts()))
+ return E_FAIL;
+
+ m_pGoblin = dynamic_cast(m_pOwner);
+ SAFE_ADDREF(m_pGoblin);
+
+ m_vOriginScale = m_pTransformCom->Get_Scale();
+
+ return S_OK;
+}
+
+void CGoblin_Spector::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CGoblin_Spector::Update(_float fTimeDelta)
+{
+ __super::Update(fTimeDelta);
+
+ m_Offset = _float3(0.f, 0.3f, 0.f);
+
+ _matrix Offset = XMMatrixTranslation(m_Offset.x,
+ m_Offset.y, m_Offset.z);
+
+ m_pTransformCom->Set_WorldMatrix(Offset * XMLoadFloat4x4(m_pParentTransformCom->Get_WorldMatrixPtr()));
+
+ if (m_pGoblin->Get_Swing())
+ {
+ if (m_vScale.x <= 2.f)
+ {
+ m_vScale.x += fTimeDelta;
+ m_vScale.y += fTimeDelta;
+ m_vScale.z += fTimeDelta;
+ }
+ m_pTransformCom->Set_Scale(m_vScale);
+ m_pModelCom->Set_AnimationIndex(m_pGoblin->Get_Component()->Get_AnimIndex());
+ m_pModelCom->Set_CurrentTrackPosition(m_pGoblin->Get_Component()->Get_CurrentTrackPosition());
+ Get_PartObject()->Set_Visible(true);
+ m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
+ }
+ else {
+ Get_PartObject()->Set_Visible(false);
+ m_vScale = { 1.f,1.f,1.f };
+ m_pTransformCom->Set_Scale(m_vOriginScale);
+ m_pModelCom->Set_AnimationIndex(5);
+ }
+
+
+ Play_Event();
+
+#ifdef _DEBUG
+ Describe_Entity();
+#endif // _DEBUG
+
+}
+
+void CGoblin_Spector::Late_Update(_float fTimeDelta)
+{
+ __super::Late_Update(fTimeDelta);
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CGoblin_Spector::Render()
+{
+ if (!m_bVisible || !m_pGoblin->Get_Swing())
+ return S_OK;
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+ _uint iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::SPECTOR);
+ 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))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(iShaderPass))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Spector::OnCollision(CGameObject* pOther, void* pDesc)
+{
+
+}
+
+void CGoblin_Spector::OnHit(CGameObject* pOther, CGameObject* pCaller)
+{
+}
+
+HRESULT CGoblin_Spector::Ready_Components()
+{
+ CTransform::TRANSFORM_DESC Desc = {};
+
+ Desc.fSpeedPerSec = 10.f;
+ Desc.fRotationPerSec = XMConvertToRadians(180.0f);
+ Desc.fRadius = 10.f;
+
+ __super::Ready_Components(&Desc);
+
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Goblin_Spector_Model");
+
+ /* Com_Model */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_strModelPrototypeTag,
+ reinterpret_cast(&m_pModelCom)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("STAT_GOBLIN"), (CComponent**)&m_pStat))) {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CGoblin_Spector::Ready_Parts()
+{
+
+ CGoblin_BattleAxe::GOBLIN_BATTLEAXE_DESC Goblin_BattleAxe_Desc{};
+
+ Goblin_BattleAxe_Desc.pParentTransform = m_pTransformCom;
+ Goblin_BattleAxe_Desc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_RightHand");
+
+ if (FAILED(Add_PartObject("Goblin_BattleAxe", g_iStaticLevel, nullptr, &Goblin_BattleAxe_Desc)))
+ {
+ return E_FAIL;
+ }
+
+
+#pragma region EFFECT
+ /* EFFECT */
+
+ CPartObject::PARTOBJECT_DESC PartsDesc{};
+
+ PartsDesc.pParentTransform = m_pTransformCom;
+
+
+
+ if (FAILED(Add_PartObject("Goblin_Particle", g_iStaticLevel, &m_pGoblin_Particle, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pGoblin_Particle->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle", static_cast(NEXT_LEVEL));
+ m_pGoblin_Particle->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+
+ if (FAILED(Add_PartObject("Goblin_Particle2", g_iStaticLevel, &m_pGoblin_Particle2, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pGoblin_Particle2->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2", static_cast(NEXT_LEVEL));
+ m_pGoblin_Particle2->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+ if (FAILED(Add_PartObject("Goblin_Smoke", g_iStaticLevel, &m_pSmoke, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pSmoke->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke", static_cast(NEXT_LEVEL));
+ m_pSmoke->FollowParants(m_pModelCom->Get_BoneMatrixPtr("Spine2"));
+
+
+#pragma endregion
+ return S_OK;
+}
+
+HRESULT CGoblin_Spector::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;
+ }
+ return S_OK;
+}
+
+CGoblin_Spector* CGoblin_Spector::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Spector* pInstance = new CGoblin_Spector(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Spector");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+CGameObject* CGoblin_Spector::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Spector* pInstance = new CGoblin_Spector(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Spector");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CGoblin_Spector::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pSmoke);
+ SAFE_RELEASE(m_pGoblin_Particle);
+ SAFE_RELEASE(m_pGoblin_Particle2);
+ SAFE_RELEASE(m_pGoblin);
+}
+#ifdef _DEBUG
+
+void CGoblin_Spector::Describe_Entity()
+{
+
+ GUI::Begin("GoblinSpector");
+ _float3 vScale = m_pTransformCom->Get_Scale();
+ GUI::DragFloat3("Scale", (_float*)&vScale);
+
+ GUI::End();
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Goblin_States.cpp b/Jusin154_Team3D/Client/Private/Goblin_States.cpp
index e680861ed..65162b49c 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_States.cpp
@@ -1,6 +1,6 @@
#include "pch.h"
#include "Goblin.h"
-
+#include "InfoInstance.h"
#include "GameInstance.h"
#include "Player.h"
#include "Goblin_Dagger.h"
@@ -17,6 +17,7 @@
#include "State_Blink.h"
#include "State_Hit.h"
#include "State_Dead.h"
+#include "State_Shuffle.h"
#pragma endregion
@@ -31,7 +32,10 @@ void CGoblin::Behavior_IdleEnter()
HRESULT CGoblin::Behavior_IdleExitCheck()
{
if (m_fTargetDistance <= 20.f && m_fTargetDistance != 0.f)
+ {
+ m_vOriginPos = m_pTransformCom->Get_State(STATE::POSITION);
m_pFSM->Change_State(FSMSTATE::MOVE);
+ }
return E_FAIL;
}
@@ -45,22 +49,68 @@ void CGoblin::Behavior_MoveEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::MOVE);
-
+ m_bLookAt = true;
m_pFSM->Enable_State(FSMSTATE::JOG);
- pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
-
}
-HRESULT CGoblin::Behavior_MoveExitCheck()
+HRESULT CGoblin::Behavior_MoveExitCheck(_float fTimeDelta)
{
pair<_uint, _bool> pairAnimInfo = {};
_uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
- if (iCurrAnimIndex == m_Animation[STATEANIM::JOG_FWD].first) {
- if (m_fTargetDistance <= 15.f && m_fTargetDistance != 0.f)
- m_pFSM->Change_State(FSMSTATE::COMBAT);
+
+ if (m_fTargetDistance >= 6.f)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
+ else {
+ if (!m_bFirstMove)
+ {
+ _uint Rand = m_pGameInstance->Real_Random_Int(0, 3);
+
+ switch (Rand)
+ {
+ case 0:
+ pairAnimInfo = m_Animation[STATEANIM::JOG_112_L];
+ break;
+ case 1:
+ pairAnimInfo = m_Animation[STATEANIM::JOG_112_R];
+ break;
+ case 2:
+ if (iCurrAnimIndex == m_Animation[STATEANIM::JOG_90_R].first) {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_112_R];
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_90_L];
+ }
+ break;
+ case 3:
+ if (iCurrAnimIndex == m_Animation[STATEANIM::JOG_90_L].first) {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_112_L];
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_90_R];
+ }
+ break;
+ }
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 0.5f, true);
+
+ m_bFirstMove = true;
+ m_fMoveTime = 0.f;
+ return S_OK;
+ }
+ m_fMoveTime += fTimeDelta;
+
+ if (m_fMoveTime >= 2.5f)
+ {
+ m_bFirstMove = false;
+ m_fMoveTime = 0.f;
+ }
+ }
+
+ if (m_fTargetDistance <= 15.f && m_fTargetDistance >= 6.f && m_fTargetDistance !=0.f)
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
return E_FAIL;
}
@@ -74,9 +124,25 @@ void CGoblin::Behavior_CombatEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::COMBAT);
-
m_bLookAt = true;
- if (m_fTargetDistance <= 7.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SWING)] <= 0.f)
+}
+
+HRESULT CGoblin::Behavior_CombatExitCheck(_float fTimeDelta)
+{
+ m_bLookAt = true;
+
+ if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance > 20.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ return E_FAIL;
+ }
+
+ if (m_fTargetDistance <= 6.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SWING)] <= 0.f)
{
m_pFSM->Change_State(FSMSTATE::SWING);
}
@@ -89,23 +155,7 @@ void CGoblin::Behavior_CombatEnter()
m_pFSM->Change_State(FSMSTATE::BLINK);
}
else {
- pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- }
-}
-
-HRESULT CGoblin::Behavior_CombatExitCheck(_float fTimeDelta)
-{
- m_bLookAt = true;
-
- if (m_fTargetDistance > 20.f && m_fTargetDistance != 0.f)
m_pFSM->Change_State(FSMSTATE::MOVE);
- else if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
- m_pFSM->Change_State(FSMSTATE::IDLE);
- else
- {
- m_pFSM->Disable_State(FSMSTATE::COMBAT);
- m_pFSM->Change_State(FSMSTATE::COMBAT);
}
return E_FAIL;
@@ -122,17 +172,24 @@ void CGoblin::Behavior_SwingEnter()
m_pFSM->Enable_State(FSMSTATE::SWING);
pairAnimInfo = m_Animation[STATEANIM::SWING_FWD];
+
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SWING)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::SWING)];
Add_Event(pairAnimInfo.first,
[this]() {m_bStep = false; },
0.2f);
+
Add_Event(pairAnimInfo.first,
- [&]() {
- pairAnimInfo = m_Animation[STATEANIM::ATTACK_END];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true); },
- 0.4f);
+ [this]() {m_bSwing = true; },
+ 0.05f);
+
+ Add_Event(pairAnimInfo.first,
+ [&]() { m_bLookAt = true;
+ m_bStep = true;
+ m_bSwing = false;
+ m_pFSM->Change_State(FSMSTATE::SHUFFLE); },
+ 0.45f);
}
HRESULT CGoblin::Behavior_SwingExitCheck(_float fTimeDelta)
@@ -141,7 +198,7 @@ HRESULT CGoblin::Behavior_SwingExitCheck(_float fTimeDelta)
_uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
if (m_pFSM->IsEnable(FSMSTATE::SWING) && m_bStep)
{
- _float fDesiredRange = 1.f;
+ _float fDesiredRange = 2.f;
_float dist = m_fTargetDistance;
if (dist > fDesiredRange)
@@ -154,13 +211,6 @@ HRESULT CGoblin::Behavior_SwingExitCheck(_float fTimeDelta)
m_pTransformCom->AccumulateMomentum(vDistance * step *fTimeDelta*1.5f);
}
}
- if (m_pModelCom->IsFinishedAnim())
- {
- m_bLookAt = true;
- m_bStep = true;
- m_pFSM->Change_State(FSMSTATE::COMBAT);
- return E_FAIL;
- }
return E_FAIL;
}
@@ -208,27 +258,34 @@ void CGoblin::Behavior_ThrowExit()
void CGoblin::Behavior_BlinkEnter()
{
- m_bVisible = false;
+
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::BLINK);
- m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)];
- _vector vPlayerPos = XMLoadFloat4(&m_vTargetPos);
- _vector vPlayerLook = m_pTarget->Get_Component()->Get_State(STATE::LOOK);
- vPlayerLook = XMVectorSetY(vPlayerLook, 0.f);
- vPlayerLook = XMVector3Normalize(vPlayerLook);
- _float randAngleDeg = m_pGameInstance->Real_Random_Float(-60.f, 60.f);
- _float randAngleRad = XMConvertToRadians(randAngleDeg);
+ pairAnimInfo = m_Animation[STATEANIM::BLINK_START];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
- _matrix rot = XMMatrixRotationY(randAngleRad);
- _vector offsetDir = XMVector3TransformNormal(vPlayerLook, rot);
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_bVisible = false;
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::TP)];
+ _vector vPlayerPos = XMLoadFloat4(&m_vTargetPos);
+ _vector vPlayerLook = m_pTarget->Get_Component()->Get_State(STATE::LOOK);
+ vPlayerLook = XMVectorSetY(vPlayerLook, 1.f);
+ vPlayerLook = XMVector3Normalize(vPlayerLook);
- _float randDist = m_pGameInstance->Real_Random_Float(1.0f, 1.5f);
+ _float randAngleDeg = m_pGameInstance->Real_Random_Float(-60.f, 60.f);
+ _float randAngleRad = XMConvertToRadians(randAngleDeg);
- _vector vFinalPos = vPlayerPos + offsetDir * randDist;
+ _matrix rot = XMMatrixRotationY(randAngleRad);
+ _vector offsetDir = XMVector3TransformNormal(vPlayerLook, rot);
- m_pCharacter_Controller->Set_Position(vFinalPos);
+ _float randDist = m_pGameInstance->Real_Random_Float(5.f, 5.5f);
+ _vector vFinalPos = vPlayerPos + offsetDir * randDist;
+
+ m_pCharacter_Controller->Set_Position(vFinalPos); }
+ , 0.99f);
}
HRESULT CGoblin::Behavior_BlinkExitCheck(_float fTimeDelta)
@@ -260,11 +317,50 @@ void CGoblin::Behavior_BlinkExit()
m_pFSM->Disable_State(FSMSTATE::BLINK);
}
+void CGoblin::Behavior_ShuffleEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::SHUFFLE);
+ _uint iRand = m_pGameInstance->Real_Random_Int(0, 3);
+ switch (iRand)
+ {
+ case 0:
+ pairAnimInfo = m_Animation[STATEANIM::SHUFFLE1];
+ break;
+ case 1:
+ pairAnimInfo = m_Animation[STATEANIM::SHUFFLE2];
+ break;
+ case 2:
+ pairAnimInfo = m_Animation[STATEANIM::SHUFFLE3];
+ break;
+ case 3:
+ pairAnimInfo = m_Animation[STATEANIM::SHUFFLE4];
+ break;
+ }
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_pFSM->Change_State(FSMSTATE::COMBAT); },
+ 0.3f);
+}
+
+HRESULT CGoblin::Behavior_ShuffleExitCheck(_float fTimeDelta)
+{
+ return E_FAIL;
+}
+
+void CGoblin::Behavior_ShuffleExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::SHUFFLE);
+}
+
void CGoblin::Behavior_HitEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::HIT);
+ m_bLookAt = false;
switch (m_eHitSpell)
{
case STATEANIM::KNOCKDOWN_FWD:
@@ -341,8 +437,14 @@ void CGoblin::Behavior_HitExit()
void CGoblin::Behavior_DeadEnter()
{
+ m_bLookAt = false;
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::DEAD);
+ PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
+ PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
+ m_pCharacter_Controller->Set_Position(XMLoadFloat3((_float3*)&pxTransform.p));
+ m_pRigidBody->SetActive(false);
+ m_pCharacter_Controller->SetActive(false);
_bool bStrongerKnockDown = { false };
@@ -362,17 +464,17 @@ void CGoblin::Behavior_DeadEnter()
_uint iState = { UINT_MAX };
if (fabsRadius > 135.f) {
- iState = STATEANIM::DEAD_BWD;
+ iState = STATEANIM::DEAD_FWD;
}
else if (fabsRadius < 45.f) {
- iState = STATEANIM::DEAD_FWD;
+ iState = STATEANIM::DEAD_BWD;
}
else {
if (m_fHitRadius < 0.f) {
- iState = STATEANIM::DEAD_R;
+ iState = STATEANIM::DEAD_L;
}
else {
- iState = STATEANIM::DEAD_L;
+ iState = STATEANIM::DEAD_R;
}
}
pairAnimInfo = m_Animation[iState + bStrongerKnockDown];
@@ -382,8 +484,8 @@ void CGoblin::Behavior_DeadEnter()
HRESULT CGoblin::Behavior_DeadExitCheck(_float fTimeDelta)
{
- if (true == m_pModelCom->IsFinishedAnim()) {
- return E_FAIL;
+ if ( FLT_EPSILON > m_pModelCom->Get_CurrentTrackProgressRatio()) {
+ return E_PENDING;
}
return S_OK;
}
@@ -411,7 +513,7 @@ void CGoblin::Add_FSM()
CState_Move::STATE_MOVE_DESC Desc{};
Desc.pOwner = this;
Desc.funcEnterEvent = [this]() { Behavior_MoveEnter(); };
- Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_MoveExitCheck(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_MoveExitCheck(fTimedelta); };
Desc.funcExitEvent = [this]() { Behavior_MoveExit(); };
Desc.funcPriorityUpdate = nullptr;
Desc.funcLateUpdate = nullptr;
@@ -459,6 +561,17 @@ void CGoblin::Add_FSM()
Desc.funcLateUpdate = nullptr;
m_States.emplace(FSMSTATE::BLINK, CState_Blink::Create(&Desc));
}
+
+ {
+ CState_Shuffle::STATE_SHUFFLE_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_ShuffleEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_ShuffleExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_ShuffleExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::SHUFFLE, CState_Shuffle::Create(&Desc));
+ }
#pragma endregion
#pragma region Behavior_Combat_Focus
{
@@ -467,6 +580,14 @@ void CGoblin::Add_FSM()
Desc.funcEnterEvent = [this]() { Behavior_DeadEnter(); };
Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_DeadExitCheck(fTimedelta); };
Desc.funcExitEvent = [this]() { Behavior_DeadExit(); };
+ Desc.funcLateUpdate = [this](_float fDeadRatio) {
+ m_fDeadRatio = fDeadRatio;
+ if (m_fDeadRatio > 1.f) {
+ m_bDead = true;
+ }
+ };
+ Desc.vDeadTimer.x = FLT_EPSILON5;
+ Desc.vDeadTimer.y = 2.f;
m_States.emplace(FSMSTATE::DEAD, CState_Dead::Create(&Desc));
}
#pragma endregion
@@ -495,20 +616,30 @@ void CGoblin::Set_Anim()
m_Animation[STATEANIM::IDLE_TURN_L] = { 26, false };
m_Animation[STATEANIM::IDLE_TURN_R] = { 30, false };
- m_Animation[STATEANIM::WALK_FWD] = { 50,true };
+ m_Animation[STATEANIM::WALK_FWD] = { 45,true };
m_Animation[STATEANIM::WALK_START] = { 57,false };
m_Animation[STATEANIM::WALK_STOP] = { 58,false };
- m_Animation[STATEANIM::WALK_BWD] = { 49, true };
+ m_Animation[STATEANIM::WALK_BWD] = { 252, true };
- m_Animation[STATEANIM::JOG_FWD] = { 147,true };
+ m_Animation[STATEANIM::JOG_FWD] = { 147,true }; // 147
m_Animation[STATEANIM::JOG_START] = { 157,false };
- m_Animation[STATEANIM::JOG_BWD] = { 154,false };
+ m_Animation[STATEANIM::JOG_BWD] = { 146,false };
+ m_Animation[STATEANIM::JOG_112_L] = { 148,true };
+ m_Animation[STATEANIM::JOG_112_R] = { 152,true };
+ m_Animation[STATEANIM::JOG_90_L] = { 151,true };
+ m_Animation[STATEANIM::JOG_90_R] = { 155,true };
+
+ m_Animation[STATEANIM::SHUFFLE1] = { 203,false };
+ m_Animation[STATEANIM::SHUFFLE2] = { 204,false };
+ m_Animation[STATEANIM::SHUFFLE3] = { 205,false };
+ m_Animation[STATEANIM::SHUFFLE4] = { 206,false };
m_Animation[STATEANIM::DODGE_LEFT] = { 125, false };
m_Animation[STATEANIM::DODGE_RIGHT] = { 126, false };
m_Animation[STATEANIM::SPRINT] = { 90, true };
m_Animation[STATEANIM::SKILL] = { 85,false }; // 나이프 던지기
+ m_Animation[STATEANIM::BLINK_START] = { 428,false }; // 텔레포트
m_Animation[STATEANIM::BLINK] = { 426,false }; // 텔레포트
m_Animation[STATEANIM::SWING_FWD] = { 100,false }; // 도끼 스윙 444
m_Animation[STATEANIM::ATTACK_END] = { 76,false };
@@ -557,6 +688,7 @@ void CGoblin::Set_Anim()
m_Animation[STATEANIM::DEAD_R2] = { 324, false };
//Tp 426
+ // Tp Start 428
// 76 공격끝
@@ -584,4 +716,16 @@ void CGoblin::Set_Anim()
// 착지 376
//
+ // Shuffle1 211
+ // Shuffle2 215
+ // Shuffle3 219
+ // Shuffle4 223
+
+ //Jog 112도 L 148
+ //Jog 112도 R 152
+ // Jog 90 L 151
+ // Jog 90 R 155
+
+
+
}
diff --git a/Jusin154_Team3D/Client/Private/InstancedProp.cpp b/Jusin154_Team3D/Client/Private/InstancedProp.cpp
index 29f7ea3e8..195d5a2e6 100644
--- a/Jusin154_Team3D/Client/Private/InstancedProp.cpp
+++ b/Jusin154_Team3D/Client/Private/InstancedProp.cpp
@@ -44,6 +44,35 @@ HRESULT CInstancedProp::Render()
return S_OK;
}
+HRESULT CInstancedProp::Render_Shadow()
+{
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_WorldMatrix", m_pTransformCom->Get_WorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", &m_pGameInstance->Get_ShadowDesc()->fFar, sizeof(_float)))) {
+ return E_FAIL;
+ }
+
+ for (_uint i = 0; i < m_iNumMesh; i++)
+ {
+ if (FAILED(m_pVIBufferInstanceCom->Bind_Matrial(m_pShaderCom, i)))
+ return E_FAIL;
+
+ if (FAILED(m_pShaderCom->Begin(0)))
+ return E_FAIL;
+
+ m_pVIBufferInstanceCom->Render(i);
+ }
+
+ return S_OK;
+}
+
HRESULT CInstancedProp::Initialize_Prototype()
{
return S_OK;
diff --git a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
index c935d3d9f..6e1de08e8 100644
--- a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
@@ -19,6 +19,8 @@
#include "Player.h"
#include "Troll.h"
#include "Goblin.h"
+#include "Goblin_Mage.h"
+#include "Goblin_Spector.h"
#pragma endregion
@@ -174,7 +176,7 @@ HRESULT CLevel_GamePlay::Ready_Background()
isReady_Background = false;
#endif //
#ifdef 기무리
- isReady_Background = false;
+ isReady_Background = true;
#endif //
#ifdef 인혁
isReady_Background = false;
@@ -374,12 +376,16 @@ HRESULT CLevel_GamePlay::Ready_Layer_SkyBox(const _wstring& strLayerTag)
HRESULT CLevel_GamePlay::Ready_Layer_Monster()
{
- for (_uint i = 0; i < 1; ++i)
+ for (_uint i = 0; i < 5; ++i)
{
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
return E_FAIL;
}
}
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
+ return E_FAIL;
+ }
+
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/Level_Loading.cpp b/Jusin154_Team3D/Client/Private/Level_Loading.cpp
index 992ab1577..046004c60 100644
--- a/Jusin154_Team3D/Client/Private/Level_Loading.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_Loading.cpp
@@ -40,15 +40,17 @@ HRESULT CLevel_Loading::Initialize(LEVEL eNextLevelID)
void CLevel_Loading::Update(_float fTimeDelta)
{
- if (true == m_pLoader->isFinished() &&
- m_pGameInstance->Key_Down(DIK_F1))
+ if (true == m_pLoader->isFinished())
{
if (m_eNextLevelID != LEVEL::LOGO)
m_bNextLevel = true;
else
{
- static_cast(m_pIntro_Image)->Set_Hover(true);
- m_bDelay = true;
+ if (m_pGameInstance->Key_Down(DIK_F1))
+ {
+ static_cast(m_pIntro_Image)->Set_Hover(true);
+ m_bDelay = true;
+ }
}
}
diff --git a/Jusin154_Team3D/Client/Private/Level_Logo.cpp b/Jusin154_Team3D/Client/Private/Level_Logo.cpp
index 0579d24ac..9e0e471b9 100644
--- a/Jusin154_Team3D/Client/Private/Level_Logo.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_Logo.cpp
@@ -30,7 +30,7 @@ void CLevel_Logo::Update(_float fTimeDelta)
m_pGameInstance->Set_LevelToChange();
#endif // 기무리
- if (m_pGameInstance->Key_Up(DIK_F1))
+ if (m_pGameInstance->Key_Down(DIK_F1))
{
m_pGameInstance->Set_LevelToChange();
}
diff --git a/Jusin154_Team3D/Client/Private/Levioso.cpp b/Jusin154_Team3D/Client/Private/Levioso.cpp
index 92a800e41..6813d4568 100644
--- a/Jusin154_Team3D/Client/Private/Levioso.cpp
+++ b/Jusin154_Team3D/Client/Private/Levioso.cpp
@@ -101,6 +101,12 @@ void CLevioso::Late_Update(_float fTimeDelta)
OnCollision(this);
}
+ if (false == m_bHit) {
+ _vector vStartPos = XMLoadFloat4(&m_vStartPos);
+ _vector vEndPos = XMLoadFloat4(&m_vEndPos);
+ SweepTarget(vStartPos, vEndPos, 0.2f);
+ }
+
__super::Late_Update(fTimeDelta);
diff --git a/Jusin154_Team3D/Client/Private/Loader.cpp b/Jusin154_Team3D/Client/Private/Loader.cpp
index f84363b26..feb057d11 100644
--- a/Jusin154_Team3D/Client/Private/Loader.cpp
+++ b/Jusin154_Team3D/Client/Private/Loader.cpp
@@ -18,11 +18,14 @@
#include "Troll_Rock.h"
#include "Goblin_Dagger.h"
#include "Wand.h"
+#include "Goblin_BattleAxe.h"
#pragma region ACTOR
#include "Player.h"
#include "Goblin.h"
+#include "Goblin_Mage.h"
+#include "Goblin_Spector.h"
#include "Troll.h"
#pragma endregion
@@ -69,6 +72,10 @@
#include "Spell_UI.h"
#include "Magic_Item.h"
+#include "Enemy_Panel.h"
+#include "Enemy_HpBar.h"
+#include "Enemy_Info.h"
+
#include "Spell_Canvas.h"
#include "Spell_Panel.h"
#include "Current_Spell_Slot.h"
@@ -287,7 +294,7 @@ HRESULT CLoader::Loading_For_GamePlay()
isLoad_Background = false;
#endif //
#ifdef 기무리
- isLoad_Background = false;
+ isLoad_Background = true;
#endif //
#ifdef 인혁
isLoad_Background = false;
@@ -812,6 +819,12 @@ HRESULT CLoader::Loading_For_GamePlay()
{
return E_FAIL;
}
+#pragma region Global_SRV
+ {
+ m_pGameInstance->Load_GlobalSRV(TEXT("GLOBAL_DISOLVE_NOISE_05"), "../Bin/Resources/Textures/Effect/Noises/VFX_T_Noise05_D.png");
+ m_pGameInstance->Load_GlobalSRV(TEXT("GLOBAL_DISOLVE_BURN_VERTICAL"), "../Bin/Resources/Textures/Effect/Diffuse/drp_fire_Line_Vertical.png");
+ }
+#pragma endregion
//#pragma region UI_ANI
// if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Altering_Spell"),
// CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Altering_Spell\\Altering_Spell%d.png"), 349))))
@@ -1030,7 +1043,7 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
}
/* Terrain_AlphaMap */
- if(FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("HogsmeadeAlphaMap"),
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("HogsmeadeAlphaMap"),
CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::SINGLE, TEXT("../Bin/Resources/Textures/Terrain/Hogsmeade_AlphaMap.dds"), 0)))) {
return E_FAIL;
}
@@ -1328,8 +1341,16 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Mage_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Spector_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
+
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll.fbx", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
return E_FAIL;
}
@@ -1344,7 +1365,7 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Weapon_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.fbx", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.bin", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
return E_FAIL;
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Rock_Big_Model"),
@@ -1352,7 +1373,11 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Dagger_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::NONANIM, "../Bin/Resources/Models/Object/Goblin_Dagger/Goblin_Dagger.bin", XMMatrixScaling(0.0002f, 0.0002f, 0.0002f) * XMMatrixRotationX(XMConvertToRadians(90.f)) * XMMatrixIdentity()))))
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Goblin_Dagger/SK_WPN_GOB_SmallSword.bin", XMMatrixIdentity()))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_BattleAxe_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Goblin_BattleAxe/SK_WPN_GOB_BattleAxe01.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
return E_FAIL;
@@ -1567,6 +1592,19 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CNoMountIcon::Create(m_pDevice, m_pContext)))) {
return E_FAIL;
}
+
+ /* For.Prototype_GameObject_NoMountIcon*/
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_Panel::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ /* For.Prototype_GameObject_NoMountIcon*/
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_HpBar::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ /* For.Prototype_GameObject_NoMountIcon*/
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_Info::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
/* For.Prototype_GameObject_Spell_Canvas*/
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CSpell_Canvas::Create(m_pDevice, m_pContext))))
@@ -1816,6 +1854,14 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin::Create(m_pDevice, m_pContext))))
return E_FAIL;
+ /* For.Prototype_GameObject_Goblin_Mage */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Mage::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
+ /* For.Prototype_GameObject_Goblin_Spector */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Spector::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
/* For.Prototype_GameObject_Troll */
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CTroll::Create(m_pDevice, m_pContext))))
return E_FAIL;
@@ -1868,6 +1914,10 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Dagger::Create(m_pDevice, m_pContext))))
return E_FAIL;
+ /* For.Prototype_GameObject_Goblin_BattleAxe */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_BattleAxe::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
/* For.Prototype_GameObject_Broom */
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CBroom::Create(m_pDevice, m_pContext))))
return E_FAIL;
@@ -2033,7 +2083,7 @@ vector* APIENTRY Deferred_FolderLoad_Main(ID3D11Device* pDevice, I
if (strcmp(file.path().extension().string().c_str(), pFileExt)) { continue; }
FOLDER_LOAD* pContents = new FOLDER_LOAD;
-
+
{ // FOLDER_LOAD
_char szFilePath[MAX_PATH] = {};
strcpy_s(szFilePath, MAX_PATH, file.path().string().c_str());
@@ -2041,7 +2091,7 @@ vector* APIENTRY Deferred_FolderLoad_Main(ID3D11Device* pDevice, I
_wstring wstrFileName = L"Prototype_GameObject_" + file.path().stem().wstring();
CModel* pModel = CModel::Create(pDevice, pContext, MODEL::ENVIROMENT, szFilePath);
-
+
_uint iNumMesh = pModel->Get_NumMeshes();
{
diff --git a/Jusin154_Team3D/Client/Private/Loding_Panel.cpp b/Jusin154_Team3D/Client/Private/Loding_Panel.cpp
index 8424ed42e..cb6ce598a 100644
--- a/Jusin154_Team3D/Client/Private/Loding_Panel.cpp
+++ b/Jusin154_Team3D/Client/Private/Loding_Panel.cpp
@@ -41,7 +41,11 @@ HRESULT CLoding_Panel::Initialize(void* pArg)
m_fSortZ = 0.f;
m_iImageNum = 0;
//m_vImageposSi = _float4(0.f, 0.f, 1792.f, 1024.f);
-
+#ifdef _DEBUG
+ INHYUK = true;
+ human = 0;
+#endif // DEBUG
+
return S_OK;
}
void CLoding_Panel::Set_Image(_int Index)
@@ -54,6 +58,58 @@ void CLoding_Panel::Priority_Update(_float fTimeDelta)
void CLoding_Panel::Update(_float fTimeDelta)
{
+#ifdef _DEBUG
+ if (m_pGameInstance->Key_Down(DIK_M))
+ {
+ human++;
+ if (human > 4) // 4보다 크면 0으로
+ human = 0;
+ }
+ if (m_pGameInstance->Key_Down(DIK_N))
+ {
+ human--;
+ if (human < 0) // 0보다 작으면 4로
+ human = 4;
+ }
+ switch (human)
+ {
+ case 0:
+ INHYUK = true;
+ JINHO = false;
+ HYUNBIN = false;
+ NURI = false;
+ JINWOO = false;
+ break;
+ case 1:
+ INHYUK = false;
+ JINHO = true;
+ HYUNBIN = false;
+ NURI = false;
+ JINWOO = false;
+ break;
+ case 2:
+ INHYUK = false;
+ JINHO = false;
+ HYUNBIN = true;
+ NURI = false;
+ JINWOO = false;
+ break;
+ case 3:
+ INHYUK = false;
+ JINHO = false;
+ HYUNBIN = false;
+ NURI = true;
+ JINWOO = false;
+ break;
+ case 4:
+ INHYUK = false;
+ JINHO = false;
+ HYUNBIN = false;
+ NURI = false;
+ JINWOO = true;
+ break;
+ }
+#endif // DEBUG
}
void CLoding_Panel::Late_Update(_float fTimeDelta)
@@ -75,6 +131,20 @@ HRESULT CLoding_Panel::Render()
if (FAILED(m_pVIBufferCom->Render())) {
return E_FAIL;
}
+#ifdef _DEBUG
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("<- N M->."), _float2(100.f, 750.f));
+
+ if (INHYUK == true)
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("알고 계셨나요?\nUI의 생일은 28일 이랍니다."), _float2(100.f, 800.f));
+ if (JINHO == true)
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("알고 계셨나요?\n우리팀 맵툴은 최강 입니다."), _float2(100.f, 800.f));
+ if (HYUNBIN == true)
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("알고 계셨나요?\n이제 막 범인에서 벗어 났습니다."), _float2(100.f, 800.f));
+ if (NURI == true)
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("알고 계셨나요?\n이제 막 슬슬 범인 입니다."), _float2(100.f, 800.f));
+ if (JINWOO == true)
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("알고 계셨나요?\n그는 그림자의 군주입니다."), _float2(100.f, 800.f));
+#endif // DEBUG
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Magic_Item.cpp b/Jusin154_Team3D/Client/Private/Magic_Item.cpp
index 4b081f9ae..577303621 100644
--- a/Jusin154_Team3D/Client/Private/Magic_Item.cpp
+++ b/Jusin154_Team3D/Client/Private/Magic_Item.cpp
@@ -47,6 +47,10 @@ HRESULT CMagic_Item::Initialize(void* pArg)
m_iArratCount = 2;
Compute_UV(0);
Compute_Image();
+ m_fFontX = 1171.f;
+ m_fFontY = 870.f;
+ m_iPotionIndex = 0;
+ m_iPerPotionIndex = -1;
return S_OK;
}
@@ -132,6 +136,14 @@ void CMagic_Item::Update(_float fTimeDelta)
}
}
+ if (m_iPerPotionIndex != m_iPotionIndex)
+ {
+ m_strPotion = to_wstring(m_iPotionIndex);
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_strPotion.c_str()) - 13.f) * 0.5f;
+ m_iPerPotionIndex = m_iPotionIndex;
+ }
+
+
if (m_vUVScale.y <= 1)
{
m_vUVScale.y += fTimeDelta * (1.f / m_fCoolTime);
@@ -172,6 +184,7 @@ HRESULT CMagic_Item::Render()
{
return E_FAIL;
}
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_strPotion.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((208.f / 255.f) * m_fAlpha, (177.f / 255.f) * m_fAlpha, (52.f / 255.f) * m_fAlpha, m_fAlpha));
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/MainApp.cpp b/Jusin154_Team3D/Client/Private/MainApp.cpp
index 54b8bbf5e..b2b307ef3 100644
--- a/Jusin154_Team3D/Client/Private/MainApp.cpp
+++ b/Jusin154_Team3D/Client/Private/MainApp.cpp
@@ -97,6 +97,26 @@ void CMainApp::Compute_FrameCount()
HRESULT CMainApp::Ready_Default_Setting()
{
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size13"), TEXT("../Bin/Resources/Fonts/Font_size13.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size14"), TEXT("../Bin/Resources/Fonts/Font_size14.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size15"), TEXT("../Bin/Resources/Fonts/Font_size15.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size20"), TEXT("../Bin/Resources/Fonts/Font_size20.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size21"), TEXT("../Bin/Resources/Fonts/Font_size21.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size30"), TEXT("../Bin/Resources/Fonts/Font_size30.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("UI_size15"), TEXT("../Bin/Resources/Fonts/UI_size15.spritefont"))))
+ return E_FAIL;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/MapContainer.cpp b/Jusin154_Team3D/Client/Private/MapContainer.cpp
index 7cebfa2b1..65500e4dc 100644
--- a/Jusin154_Team3D/Client/Private/MapContainer.cpp
+++ b/Jusin154_Team3D/Client/Private/MapContainer.cpp
@@ -2,6 +2,7 @@
#include "MapContainer.h"
#include "PartObject.h"
#include "MapObject_Collision.h"
+#include "MapObject_Render.h"
//#include "MapObject_LOD.h"
@@ -62,21 +63,51 @@ HRESULT CMapContainer::Render()
return S_OK;
}
+HRESULT CMapContainer::Render_Shadow()
+{
+ unordered_map<_string, CPartObject*>::iterator iter = m_PartObjects.begin();
+ for (; iter != m_PartObjects.end(); ++iter) {
+ CPartObject* pObject = (*iter).second;
+ if (FAILED(pObject->Render_Shadow())) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
void CMapContainer::ReadyForPhysX()
{
- vector::iterator iter = m_ColiisonPartObjects.begin();
- for (; iter != m_ColiisonPartObjects.end(); ++iter) {
- CMapObject_Collision* pObject = static_cast(*iter);
- pObject->ReadyForPhysX();
+ if (true == m_bHasCollisionMesh) {
+ vector::iterator iter = m_ColiisonPartObjects.begin();
+ for (; iter != m_ColiisonPartObjects.end(); ++iter) {
+ CMapObject_Collision* pObject = static_cast(*iter);
+ pObject->ReadyForPhysX();
+ }
+ }
+ else {
+ unordered_map<_string, CPartObject*>::iterator iter = m_PartObjects.begin();
+ for (; iter != m_PartObjects.end(); ++iter) {
+ CMapObject_Render* pObject = static_cast((*iter).second);
+ pObject->ReadyForPhysX();
+ }
}
}
void CMapContainer::ConvertToPhysX()
{
- vector::iterator iter = m_ColiisonPartObjects.begin();
- for (; iter != m_ColiisonPartObjects.end(); ++iter) {
- CMapObject_Collision* pObject = static_cast(*iter);
- pObject->ConvertToPhysX();
+ if (true == m_bHasCollisionMesh) {
+ vector::iterator iter = m_ColiisonPartObjects.begin();
+ for (; iter != m_ColiisonPartObjects.end(); ++iter) {
+ CMapObject_Collision* pObject = static_cast(*iter);
+ pObject->ConvertToPhysX();
+ }
+ }
+ else {
+ unordered_map<_string, CPartObject*>::iterator iter = m_PartObjects.begin();
+ for (; iter != m_PartObjects.end(); ++iter) {
+ CMapObject_Render* pObject = static_cast((*iter).second);
+ pObject->ConvertToPhysX();
+ }
}
}
diff --git a/Jusin154_Team3D/Client/Private/MapObject_Collision.cpp b/Jusin154_Team3D/Client/Private/MapObject_Collision.cpp
index eb4ef3e79..a0565b10e 100644
--- a/Jusin154_Team3D/Client/Private/MapObject_Collision.cpp
+++ b/Jusin154_Team3D/Client/Private/MapObject_Collision.cpp
@@ -90,8 +90,22 @@ void CMapObject_Collision::ReadyForPhysX()
{
CModel* pModel = m_pModelComs[iIndexLOD];
- if (FAILED(pModel->Ready_PhysXMeshes(XMLoadFloat4x4(&m_CombinedWorldMatrix)))) {
- assert(false);
+ _matrix parentMatrix = m_pParentTransformCom->Get_XMWorldMatrix();
+ _matrix idenMatrix = XMMatrixIdentity();
+ _bool bSkip = { false };
+ for (_int i = 0; i < 4; ++i) {
+ if (false == XMVector4NearEqual(idenMatrix.r[i], parentMatrix.r[i], XMVectorReplicate(FLT_EPSILON5))) {
+ if (FAILED(pModel->Ready_PhysXMeshes(XMLoadFloat4x4(&m_CombinedWorldMatrix)))) {
+ assert(false);
+ }
+ bSkip = true;
+ break;
+ }
+ }
+ if (false == bSkip) {
+ if (FAILED(pModel->Ready_PhysXMeshes(m_pParentTransformCom->Get_XMWorldMatrix()))) {
+ assert(false);
+ }
}
}
}
diff --git a/Jusin154_Team3D/Client/Private/MapObject_Render.cpp b/Jusin154_Team3D/Client/Private/MapObject_Render.cpp
index 433cc9bf3..6cf5da9f2 100644
--- a/Jusin154_Team3D/Client/Private/MapObject_Render.cpp
+++ b/Jusin154_Team3D/Client/Private/MapObject_Render.cpp
@@ -75,7 +75,6 @@ void CMapObject_Render::Update(_float fTimeDelta)
void CMapObject_Render::Late_Update(_float fTimeDelta)
{
- //m_pGameInstance->Add_RenderGroup(RENDER::SHADOW, this);
if (m_pGameInstance->isIn_WorldFrustum(XMLoadFloat4(&m_vExtentPosition), m_fRadius)) {
m_fCamDepth = XMVectorGetX(XMVector3LengthSq(XMLoadFloat4(m_pGameInstance->Get_CamPosition()) - XMLoadFloat4(&m_vExtentPosition)));
@@ -142,7 +141,9 @@ HRESULT CMapObject_Render::Render_Shadow()
return E_FAIL;
}
- for (_uint i = 0; i < m_iNumMeshe; i++)
+ _uint iMeshes = m_pModelComs[0]->Get_NumMeshes();
+
+ for (_uint i = 0; i < iMeshes; i++)
{
if (FAILED(m_pModelComs[0]->Bind_Material(i, m_pShaderCom))) {
return E_FAIL;
@@ -160,6 +161,52 @@ HRESULT CMapObject_Render::Render_Shadow()
return S_OK;
}
+void CMapObject_Render::ReadyForPhysX()
+{
+ if (true == m_bConverted) {
+ return;
+ }
+ m_bConverted = true;
+
+ for (_uint iIndexLOD = 0; iIndexLOD < m_iMaxLodLevel + 1; ++iIndexLOD)
+ {
+ CModel* pModel = m_pModelComs[iIndexLOD];
+
+ if (FAILED(pModel->Ready_PhysXMeshes(XMLoadFloat4x4(&m_CombinedWorldMatrix)))) {
+ assert(false);
+ }
+ }
+}
+
+void CMapObject_Render::ConvertToPhysX()
+{
+ if (true == m_bReadyToCreatePhysX) {
+ return;
+ }
+ m_bReadyToCreatePhysX = true;
+
+ m_RigidBodies.resize(m_iMaxLodLevel + 1);
+ for (_uint iIndexLOD = 0; iIndexLOD < m_iMaxLodLevel + 1; ++iIndexLOD)
+ {
+ CModel* pModel = m_pModelComs[iIndexLOD];
+
+ _uint iNumMeshes = pModel->Get_NumMeshes();
+
+ for (_uint iIndex = 0; iIndex < iNumMeshes; ++iIndex)
+ {
+ _wstring wstrName = CMyTools::ToWstring(pModel->Get_MeshName(iIndex)) + to_wstring(iIndex);
+ CRigidBody_Static* pRigidBody = { nullptr };
+ CRigidBody_Static::RIGIDBODY_STATIC_DESC Desc = {};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::TERRAIN);
+ Desc.pMeshName = wstrName.c_str();
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, wstrName, (CComponent**)&pRigidBody, &Desc))) {
+ assert(false);
+ }
+ m_RigidBodies[iIndexLOD].push_back(pRigidBody);
+ }
+ }
+}
+
_wstring CMapObject_Render::Get_PrototypeTag(_uint iLodIndex)
{
if (m_iMaxLodLevel < iLodIndex)
@@ -260,6 +307,12 @@ void CMapObject_Render::Free()
SAFE_RELEASE(m_pShaderCom);
+ for (_uint i = 0; i < m_RigidBodies.size(); ++i) {
+ for (_uint j = 0; j < m_RigidBodies[i].size(); ++j) {
+ SAFE_RELEASE(m_RigidBodies[i][j]);
+ }
+ } m_RigidBodies.clear();
+
for (auto& pModel : m_pModelComs)
SAFE_RELEASE(pModel);
m_pModelComs.clear();
diff --git a/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp b/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
index 1216c67d9..ce437d74f 100644
--- a/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
+++ b/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "MiniMap_TrimBorder.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
CMiniMap_TrimBorder::CMiniMap_TrimBorder(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
@@ -8,7 +9,8 @@ CMiniMap_TrimBorder::CMiniMap_TrimBorder(ID3D11Device* pDevice, ID3D11DeviceCont
}
CMiniMap_TrimBorder::CMiniMap_TrimBorder(const CMiniMap_TrimBorder& rhs)
- :CElementObject(rhs)
+ :CElementObject(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
@@ -82,7 +84,7 @@ void CMiniMap_TrimBorder::Update(_float fTimeDelta)
m_fAlpha = 0.f;
}
}
-
+ m_fAngle = -atan2(m_pInfoInstance->Get_CameraCoordinateSystem().first.x, m_pInfoInstance->Get_CameraCoordinateSystem().first.z);
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
}
@@ -104,7 +106,7 @@ HRESULT CMiniMap_TrimBorder::Render()
if (FAILED(Bind_ShaderResources())) {
return E_FAIL;
}
- if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ALPHABLEND)))) {
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ROTATION)))) {
return E_FAIL;
}
if (FAILED(m_pVIBufferCom->Bind_Resources())) {
@@ -160,6 +162,10 @@ HRESULT CMiniMap_TrimBorder::Bind_ShaderResources()
{
return E_FAIL;
}
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fMapAngle", &m_fAngle, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Monster.cpp b/Jusin154_Team3D/Client/Private/Monster.cpp
index 7b4184203..223f90e9e 100644
--- a/Jusin154_Team3D/Client/Private/Monster.cpp
+++ b/Jusin154_Team3D/Client/Private/Monster.cpp
@@ -57,6 +57,34 @@ void CMonster::Late_Update(_float fTimeDelta)
__super::Late_Update(fTimeDelta);
}
+HRESULT CMonster::Render_DeadDisolve()
+{
+ if (FLT_EPSILON3 * 10 < m_fDeadRatio) {
+ _bool bDisolve = true;
+ _float fDisolveAmount = 0.1f;
+ _float fDisolveEdgeWidth = 0.1f;
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fDisolveRatio", &m_fDeadRatio, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fDisolveAmount", &fDisolveAmount, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fDisolveEdgeWidth", &fDisolveEdgeWidth, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_GlobalSRV(m_pShaderCom, TEXT("GLOBAL_DISOLVE_NOISE_05"), "g_DeadDisolveTexture"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_GlobalSRV(m_pShaderCom, TEXT("GLOBAL_DISOLVE_BURN_VERTICAL"), "g_DeadDisolveBurnTexture"))) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
HRESULT CMonster::Render_OutLine()
{
m_bDrawOutLine = false;
diff --git a/Jusin154_Team3D/Client/Private/MonsterInfo.cpp b/Jusin154_Team3D/Client/Private/MonsterInfo.cpp
index 51100c7b8..46ff3b6c5 100644
--- a/Jusin154_Team3D/Client/Private/MonsterInfo.cpp
+++ b/Jusin154_Team3D/Client/Private/MonsterInfo.cpp
@@ -3,6 +3,8 @@
#include "GameInstance.h"
#include "InfoInstance.h"
#include "Monster.h"
+#include "Layer.h"
+#include "Player.h"
CMonsterInfo::CMonsterInfo()
{
@@ -118,7 +120,19 @@ HRESULT CMonsterInfo::Refresh_LockOnMonsters()
_vector vMonsterPos;
_vector vToMonsterDir;
- _float fFovy = max(m_pGameInstance->Get_CameraFov() - XMConvertToRadians(30.f), XMConvertToRadians(20.f));
+ _bool Aim = false;
+ _float fFovy = 0.f;
+ if (m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::GAMEPLAY), LAYER_PLAYER) != nullptr)
+ {
+ Aim = m_pGameInstance->Get_Layer(ENUM_CLASS(LEVEL::GAMEPLAY), LAYER_PLAYER)->Get_Object()->Get_Aim();
+ }
+ if (Aim)
+ {
+ fFovy = max(m_pGameInstance->Get_CameraFov() - XMConvertToRadians(50.f), XMConvertToRadians(5.f));
+ }
+ else {
+ fFovy = max(m_pGameInstance->Get_CameraFov() - XMConvertToRadians(30.f), XMConvertToRadians(20.f));
+ }
{ // 뷰프러스텀 순회해서 가장 중앙에 근접한 몬스터 찾기
for (list::iterator iter = m_ActiveMonsters.begin(); iter != m_ActiveMonsters.end(); ++iter) {
diff --git a/Jusin154_Team3D/Client/Private/NomalJap.cpp b/Jusin154_Team3D/Client/Private/NomalJap.cpp
index 502976a40..41a6b1429 100644
--- a/Jusin154_Team3D/Client/Private/NomalJap.cpp
+++ b/Jusin154_Team3D/Client/Private/NomalJap.cpp
@@ -123,67 +123,15 @@ void CNomalJap::Late_Update(_float fTimeDelta)
return;
}
if (false == m_bHit) {
- SweepTarget();
+ _vector vStartPos = XMLoadFloat4(&m_vStartPos);
+ _vector vEndPos = m_pProjectile->Get_WorldPostion();
+ SweepTarget(vStartPos,vEndPos, 0.002f);
}
Get_PartObject()->Trail_Update(m_pProjectile->Get_Component()->Get_XMWorldMatrix(), fTimeDelta);
__super::Late_Update(fTimeDelta);
}
-void CNomalJap::SweepTarget()
-{
- _vector vStartPos = m_pProjectile->Get_WorldPostion();
- _vector vEndPos = XMLoadFloat4(&m_vTargetPos);
- _vector vDir = { vEndPos - vStartPos };
-
- _float fDistance = XMVectorGetX(XMVector3Length(vEndPos - vStartPos));
-
- PSX::PxSweepBuffer pxBuffer = {};
-
- _bool bHit = m_pGameInstance->SphereCast(0.002f, vStartPos, vDir, fDistance, PSX::PxHitFlag::ePOSITION | PSX::PxHitFlag::eNORMAL, PSX::PxQueryFlag::eDYNAMIC, pxBuffer);
-
- if (bHit) {
- const PSX::PxSweepHit& hit = pxBuffer.block;
- PSX::PxRigidActor* pActor = hit.actor;
- PSX::PxShape* pShape = hit.shape;
- ON_COLLISION_INFO tagCollInfo = {};
- memcpy_s(&tagCollInfo.vWorldPos, sizeof(tagCollInfo.vWorldPos), &hit.position, sizeof(hit.position));
- memcpy_s(&tagCollInfo.vWorldNomal, sizeof(tagCollInfo.vWorldNomal), &hit.normal, sizeof(hit.normal));
- XMStoreFloat4(&tagCollInfo.vHitDir, vDir);
- tagCollInfo.fLength = fDistance;
-
-
- if (nullptr != pActor && nullptr != pActor->userData)
- {
- PhsXUserData* pUserData = static_cast(pActor->userData);
-
- switch (pUserData->eKind)
- {
- case PHYSX_KIND::CCTActor:
- {
- switch (PXOBJECT(pUserData->iSubKind))
- {
- case PXOBJECT::MONSTER:
- break;
- case PXOBJECT::GOBLIN_WARRIOR:
- {
- pUserData->pOwner->OnCollision(this, &tagCollInfo);
- m_bHit = true;
- }
- break;
- case PXOBJECT::TROLL:
- {
- pUserData->pOwner->OnCollision(this, &tagCollInfo);
- m_bHit = true;
- }
- break;
- }
- }
- }
- }
- }
-}
-
HRESULT CNomalJap::Pre_Setting(CGameObject* pObject, void* pArg)
{
if (FAILED(__super::Pre_Setting(pObject, nullptr)))
diff --git a/Jusin154_Team3D/Client/Private/Player.cpp b/Jusin154_Team3D/Client/Private/Player.cpp
index ef120d229..facfcf06c 100644
--- a/Jusin154_Team3D/Client/Private/Player.cpp
+++ b/Jusin154_Team3D/Client/Private/Player.cpp
@@ -72,8 +72,6 @@ HRESULT CPlayer::Initialize(void* pArg)
Set_Anim();
- m_eSpell = STATEANIM::DESCENDO;
-
{
CFSM::FSM_DESC FSMDesc{};
FSMDesc.pStates = &m_States;
@@ -139,6 +137,15 @@ __super::Update(fTimeDelta);
m_pCharacter_Controller->Move(fTimeDelta);
m_pCallBack_HitReport->Set_CurrentSlop();
}
+ if (m_pGameInstance->Mouse_Down(DIM_RBUTTON))
+ m_pInfoInstance->Key_Input(ENUM_CLASS(KEYINPUT::DIM_RBUTTON_DOWN));
+ if (m_pGameInstance->Mouse_Up(DIM_RBUTTON))
+ {
+ m_pInfoInstance->Key_Input(ENUM_CLASS(KEYINPUT::DIM_RBUTTON_UP));
+ m_bAim = false;
+ }
+
+
}
void CPlayer::Late_Update(_float fTimeDelta)
@@ -158,6 +165,20 @@ void CPlayer::Late_Update(_float fTimeDelta)
m_pLockOnMonster = nullptr;
}
}
+ ////////////////////////////////////////////////////////////////////////////
+ _vector look = XMVector3Normalize(m_pTransformCom->Get_State(STATE::LOOK));
+
+ _vector worldUp = XMVectorSet(0.f, 1.f, 0.f, 0.f);
+
+ _vector right = XMVector3Normalize(XMVector3Cross(worldUp, look));
+ _vector up = XMVector3Normalize(XMVector3Cross(look, right));
+
+ m_pTransformCom->Set_State(STATE::RIGHT, right);
+ m_pTransformCom->Set_State(STATE::UP, up);
+ m_pTransformCom->Set_State(STATE::LOOK, look);
+ ////////////////////////////////////////////////////////////////////////////
+
+
}
HRESULT CPlayer::Render()
@@ -549,7 +570,8 @@ void CPlayer::Describe_Entity()
GUI::Text(AnimList.c_str());
GUI::Text("AnimTrack %.2f", m_pModelCom->Get_CurrentTrackPosition());
- GUI::Text("AnimRatio %.2f", m_pModelCom->Get_TrackProgressRatio(417));
+ GUI::Text("AnimRatio %.2f", m_pModelCom->Get_CurrentTrackProgressRatio());
+ GUI::Text("AnimSpeed %.2f", m_pModelCom->Get_AnimSpeed());
GUI::Checkbox("Render", &m_bVisible);
diff --git a/Jusin154_Team3D/Client/Private/Player_States.cpp b/Jusin154_Team3D/Client/Private/Player_States.cpp
index ea5fb25b6..77f672eed 100644
--- a/Jusin154_Team3D/Client/Private/Player_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Player_States.cpp
@@ -137,6 +137,7 @@ HRESULT CPlayer::InputAim()
if (m_pGameInstance->Mouse_Pressing(DIM_RBUTTON) ||
m_pGameInstance->Mouse_Pressing(DIM_LBUTTON))
{
+ if (m_pGameInstance->Mouse_Pressing(DIM_RBUTTON)) {m_bAim = true;}
return S_OK;
}
return E_FAIL;
@@ -307,16 +308,14 @@ void CPlayer::Behavior_MoveEnter()
if (true == m_bSprintToggle) {
m_pFSM->Enable_State(FSMSTATE::SPRINT);
m_bWalkToggle = false;
- if (true == bFoward) {
- pairAnimInfo = m_Animation[STATEANIM::SPRINT];
- }
+
+ pairAnimInfo = m_Animation[STATEANIM::SPRINT];
}
else if (true == m_bWalkToggle) {
m_pFSM->Enable_State(FSMSTATE::WALK);
m_bSprintToggle = false;
- if (true == bFoward) {
- pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
- }
+
+ pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
}
else
{
@@ -337,9 +336,9 @@ void CPlayer::Behavior_MoveEnter()
else if (true == m_bWalkToggle) {
m_pFSM->Enable_State(FSMSTATE::WALK);
m_bSprintToggle = false;
- if (true == bFoward) {
- pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
- }
+
+ pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
+
}
else {
m_pFSM->Enable_State(FSMSTATE::JOG);
@@ -359,6 +358,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
_vector xmvLook = XMVector4Normalize(XMVectorSetY(m_pTransformCom->Get_State(STATE::LOOK), 0.f));
_vector xmvRight = XMVector4Normalize(XMVectorSetY(m_pTransformCom->Get_State(STATE::RIGHT), 0.f));
_uint iCurrentAnimIndex = m_pModelCom->Get_AnimIndex();
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
if (SUCCEEDED(InputAction()) || SUCCEEDED(InputSpell())) {
if (m_pGameInstance->Key_Down(DIK_SPACE)) {
@@ -391,36 +391,38 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
else if (m_pGameInstance->Key_Down(DIK_B)) {
m_pFSM->Change_State(FSMSTATE::BROOM_RIDE);
}
- else if (m_pGameInstance->Key_Down(DIK_LSHIFT)) {
+ else if (m_pGameInstance->Key_Down(DIK_LSHIFT) && !m_pFSM->IsEnable(FSMSTATE::STOP)) {
m_bSprintToggle = !m_bSprintToggle;
m_bWalkToggle = false;
if (m_bSprintToggle)
{
m_pFSM->Enable_State(FSMSTATE::SPRINT);
- m_pFSM->Disable_State(FSMSTATE::JOG);
+ m_pFSM->Disable_State(FSMSTATE::WALK);
pairAnimInfo = m_Animation[STATEANIM::SPRINT];
}
else
{
m_pFSM->Enable_State(FSMSTATE::JOG);
m_pFSM->Disable_State(FSMSTATE::SPRINT);
+ m_pFSM->Disable_State(FSMSTATE::WALK);
pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
}
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
- else if (m_pGameInstance->Key_Down(DIK_C)) {
+ else if (m_pGameInstance->Key_Down(DIK_C) && !m_pFSM->IsEnable(FSMSTATE::STOP)) {
m_bWalkToggle = !m_bWalkToggle;
m_bSprintToggle = false;
if (m_bWalkToggle)
{
m_pFSM->Enable_State(FSMSTATE::WALK);
- m_pFSM->Disable_State(FSMSTATE::JOG);
+ m_pFSM->Disable_State(FSMSTATE::SPRINT);
pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
}
else
{
m_pFSM->Enable_State(FSMSTATE::JOG);
m_pFSM->Disable_State(FSMSTATE::WALK);
+ m_pFSM->Disable_State(FSMSTATE::SPRINT);
pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
}
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
@@ -465,9 +467,10 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
_float degree = XMConvertToDegrees(angle);
_bool bSkipAngleCheck = { false };
- if (m_pFSM->IsEnable(FSMSTATE::JOG | FSMSTATE::WALK)) {
+ if (m_pFSM->IsEnable(FSMSTATE::JOG | FSMSTATE::WALK| FSMSTATE::SPRINT)) {
if (iCurrentAnimIndex != m_Animation[STATEANIM::JOG_FWD].first &&
- iCurrentAnimIndex != m_Animation[STATEANIM::WALK_FWD].first) {
+ iCurrentAnimIndex != m_Animation[STATEANIM::WALK_FWD].first&&
+ iCurrentAnimIndex != m_Animation[STATEANIM::SPRINT].first) {
bSkipAngleCheck = true;
if (m_pModelCom->IsFinishedAnim() || m_pFSM->IsEnable(FSMSTATE::STOP) || SUCCEEDED(InputAim())) {
@@ -477,15 +480,19 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
}
if (!bSkipAngleCheck) {
_float absDir = fabsf(vDir);
- if (absDir < XMConvertToRadians(80.f)) {
- if (m_pFSM->IsEnable(FSMSTATE::JOG))
- {
- pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
- }
- if (m_pFSM->IsEnable(FSMSTATE::WALK))
+ if (absDir < XMConvertToRadians(85.f)) {
+ if (m_bWalkToggle)
{
pairAnimInfo = m_Animation[STATEANIM::WALK_FWD];
}
+ else if ( m_bSprintToggle)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::SPRINT];
+ }
+ else
+ {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+ }
}
else if (absDir < XMConvertToRadians(160.f)) {
if (cross > 0)
@@ -494,7 +501,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
{
pairAnimInfo = m_Animation[STATEANIM::JOG_AIM_LEFT];
}
- else if (m_pFSM->IsEnable(FSMSTATE::JOG))
+ else if (m_pFSM->IsEnable(FSMSTATE::JOG) && !m_pFSM->IsEnable(FSMSTATE::SPRINT))
{
if (degree > 35.f && degree < 55.f)
{
@@ -511,12 +518,15 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
}
else {
pairAnimInfo = m_Animation[STATEANIM::JOG_LEFT];
+ m_fAnimSpeed = 1.2f;
}
-
}
}
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+ }
- m_fAmount = 0.5f;
+ m_fAmount = 0.3f;
m_bRatio = true;
}
else {
@@ -524,7 +534,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
{
pairAnimInfo = m_Animation[STATEANIM::JOG_AIM_RIGHT];
}
- else if (m_pFSM->IsEnable(FSMSTATE::JOG))
+ else if (m_pFSM->IsEnable(FSMSTATE::JOG) && !m_pFSM->IsEnable(FSMSTATE::SPRINT))
{
if (degree < -35.f && degree > -55.f)
{
@@ -541,12 +551,15 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
}
else {
pairAnimInfo = m_Animation[STATEANIM::JOG_RIGHT];
+ m_fAnimSpeed = 1.2f;
}
-
}
}
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+ }
- m_fAmount = 0.5f;
+ m_fAmount = 0.3f;
m_bRatio = true;
}
}
@@ -555,7 +568,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
{
pairAnimInfo = m_Animation[STATEANIM::JOG_AIM_BWD];
}
- else if (m_pFSM->IsEnable(FSMSTATE::JOG))
+ else if (m_pFSM->IsEnable(FSMSTATE::JOG) && !m_pFSM->IsEnable(FSMSTATE::SPRINT))
{
if (m_pModelCom->IsFinishedAnim() && iCurrentAnimIndex == m_Animation[STATEANIM::JOG_BWD].first)
{
@@ -564,6 +577,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
else
{
pairAnimInfo = m_Animation[STATEANIM::JOG_BWD];
+ m_fAnimSpeed = 1.2f;
}
}
@@ -571,12 +585,17 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
{
pairAnimInfo = m_Animation[STATEANIM::WALK_BWD];
}
- m_fAmount = 0.5f;
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
+ }
+
+ m_fAmount = 0.3f;
m_bRatio = true;
}
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, m_fAmount, m_bRatio);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, m_fAmount, m_bRatio, m_fAnimSpeed);
m_fAmount = 1.f;
+ m_fAnimSpeed = 1.f;
}
}
@@ -591,10 +610,14 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
{
m_pFSM->Enable_State(FSMSTATE::STOP);
if (m_pFSM->IsEnable(FSMSTATE::WALK)) {
+ m_bWalkToggle = false;
+ m_pFSM->Disable_State(FSMSTATE::WALK);
pairAnimInfo = m_Animation[STATEANIM::WALK_STOP];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
else if (m_pFSM->IsEnable(FSMSTATE::SPRINT)) {
+ m_bSprintToggle = false;
+ m_pFSM->Disable_State(FSMSTATE::SPRINT);
pairAnimInfo = m_Animation[STATEANIM::JOG_STOP];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
@@ -618,10 +641,10 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
}
- else if (IsCurrentKeyFrame("TurnStop"))
+ else if (fRatio >= 0.2f)
{
- m_pFSM->Change_State(FSMSTATE::IDLE);
m_pFSM->Disable_State(FSMSTATE::STOP);
+ m_pFSM->Change_State(FSMSTATE::IDLE);
}
return S_OK;
@@ -632,7 +655,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta)
void CPlayer::Behavior_MoveExit()
{
- m_pFSM->Disable_State(FSMSTATE::MOVE | FSMSTATE::SPRINT | FSMSTATE::JOG | FSMSTATE::WALK);
+ m_pFSM->Disable_State(FSMSTATE::MOVE | FSMSTATE::SPRINT | FSMSTATE::JOG | FSMSTATE::WALK | FSMSTATE::STOP);
}
void CPlayer::Behavior_JumpEnter()
@@ -841,29 +864,6 @@ HRESULT CPlayer::Behavior_CombatExitCheck()
}
}
- if (m_pFSM->IsEnable(FSMSTATE::SPELL) && IsCurrentKeyFrame("Combat"))
- {
- if (m_eSpell != ENUM_CLASS(SKILL_TYPE::END))
- {
- switch (m_eSpell)
- {
- case ENUM_CLASS(SKILL_TYPE::ACCIO):
- pairAnimInfo = m_Animation[STATEANIM::ACCIO];
- break;
- case ENUM_CLASS(SKILL_TYPE::DESCENDO):
- pairAnimInfo = m_Animation[STATEANIM::DESCENDO];
- break;
- default:
- m_eSpell = ENUM_CLASS(SKILL_TYPE::END);
- return S_OK;
- break;
- }
-
- m_eSpell = ENUM_CLASS(SKILL_TYPE::END);
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- }
- }
-
if (m_pFSM->IsEnable(FSMSTATE::ANCIENT_THROW))
{
if (SUCCEEDED(InputMove()) && IsCurrentKeyFrame("Throw")) {
@@ -917,44 +917,55 @@ void CPlayer::Behavior_LightAttackEnter()
HRESULT CPlayer::Behavior_LightAttackExitCheck()
{
pair<_uint, _bool> pairAnimInfo;
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
if (m_pGameInstance->Mouse_Up(DIM_LBUTTON))
{
- _uint iIndex = m_pModelCom->Get_AnimIndex();
- if (m_Animation[STATEANIM::LIGHT_ATTACK].first <= iIndex && m_Animation[STATEANIM::LIGHT_ATTACK].first + 3 > iIndex) {
- _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
- if (fRatio >= 0.1f) {
- pairAnimInfo = m_Animation[STATEANIM::LIGHT_ATTACK];
- pairAnimInfo.first = iIndex + 1;
+ _uint iCurr = m_pModelCom->Get_AnimIndex();
+ _uint iStart = m_Animation[STATEANIM::LIGHT_ATTACK].first;
+
+ if (iCurr >= iStart && iCurr < iStart + 3)
+ {
+ _uint iNext = iCurr + 1;
+ pairAnimInfo = m_Animation[STATEANIM::LIGHT_ATTACK];
+ pairAnimInfo.first = iNext;
+
+ if (fRatio >= 0.2f)
+ {
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- Add_Event(pairAnimInfo.first,
+ Add_Event(iNext,
[this]() {
- _uint iIndex = m_pModelCom->Get_AnimIndex() - m_Animation[STATEANIM::LIGHT_ATTACK].first;
- m_pEffectPool->Use_Skill(SKILL_TYPE::JAP, Get_PartObject(), &iIndex); },
+ _uint comboIndex = m_pModelCom->Get_AnimIndex() - m_Animation[STATEANIM::LIGHT_ATTACK].first;
+ m_pEffectPool->Use_Skill(SKILL_TYPE::JAP, Get_PartObject(), &comboIndex);
+ },
0.05f);
- Add_Event(pairAnimInfo.first, [this]() { m_pEffectPool->Use_Skill(SKILL_TYPE::JAP_SIDE, Get_PartObject()); }, 0.0f);
+ Add_Event(iNext,
+ [this]() {m_pEffectPool->Use_Skill(SKILL_TYPE::JAP_SIDE,Get_PartObject());
+ },
+ 0.0f);
}
}
}
- if (SUCCEEDED(InputMove()) && IsCurrentKeyFrame("Combat")) {
+ if (SUCCEEDED(InputMove()) && fRatio >= 0.3f) {
m_pFSM->Change_State(FSMSTATE::MOVE);
return E_FAIL;
}
- if (m_pModelCom->IsFinishedAnim()) {
+ if (m_pModelCom->IsFinishedAnim())
+ {
if (SUCCEEDED(InputMove()))
{
m_pFSM->Change_State(FSMSTATE::MOVE);
return E_FAIL;
}
- else {
- m_pFSM->Change_State(FSMSTATE::IDLE);
- }
+
+ m_pFSM->Change_State(FSMSTATE::IDLE);
}
return E_FAIL;
+
}
void CPlayer::Behavior_LightAttackExit()
@@ -1062,15 +1073,21 @@ HRESULT CPlayer::Behavior_SpellExitCheck()
{
pair<_uint, _bool> pairAnimInfo;
_uint iIndex = m_pModelCom->Get_AnimIndex();
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
if (SUCCEEDED(InputSpell()))
{
- if (m_Animation[STATEANIM::SPELL].first <= iIndex && m_Animation[STATEANIM::SPELL].first + 3 > iIndex) {
- _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+ _uint iCurr = m_pModelCom->Get_AnimIndex();
+ _uint iStart = m_Animation[STATEANIM::SPELL].first;
- if (fRatio >= 0.15f) {
+ if (iCurr >= iStart && iCurr < iStart + 3)
+ {
+ if (fRatio >= 0.2f)
+ {
+ _uint iNext = iCurr + 1;
pairAnimInfo = m_Animation[STATEANIM::SPELL];
- pairAnimInfo.first = iIndex + 1;
+ pairAnimInfo.first = iNext;
+
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
if (m_eSpell != ENUM_CLASS(SKILL_TYPE::END))
@@ -1107,6 +1124,28 @@ HRESULT CPlayer::Behavior_SpellExitCheck()
}
}
+ if (m_pFSM->IsEnable(FSMSTATE::SPELL) && fRatio >= 0.3f)
+ {
+ if (m_eSpell != ENUM_CLASS(SKILL_TYPE::END))
+ {
+ switch (m_eSpell)
+ {
+ case ENUM_CLASS(SKILL_TYPE::ACCIO):
+ pairAnimInfo = m_Animation[STATEANIM::ACCIO];
+ break;
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ pairAnimInfo = m_Animation[STATEANIM::DESCENDO];
+ break;
+ default:
+ m_eSpell = ENUM_CLASS(SKILL_TYPE::END);
+ return S_OK;
+ break;
+ }
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ }
+ }
+
if (SUCCEEDED(InputMove()) && IsCurrentKeyFrame("Combat")) {
m_pFSM->Change_State(FSMSTATE::MOVE);
@@ -1499,7 +1538,7 @@ void CPlayer::Add_FSM()
_matrix BoneNoScale = XMMatrixRotationQuaternion(Rot) * XMMatrixTranslationFromVector(Trans);
- m_OffsetPos = { 0.f, 1.22f, 0.f };
+ m_OffsetPos = { 0.f, 1.4f, 0.f };
GUI::DragFloat3("BroomOffset", (_float*)&m_OffsetPos, 0.01f);
_matrix Offset = XMMatrixTranslation(m_OffsetPos.x,
@@ -1511,19 +1550,55 @@ void CPlayer::Add_FSM()
_matrix FinalWorld = FixRot * SocketWorld;
+ //_matrix PlayerWorld = XMLoadFloat4x4(m_pTransformCom->Get_WorldMatrixPtr());
+
+ //_matrix GoalWorld = FinalWorld;
+
+ //_vector CurS, CurR, CurT;
+ //_vector GoalS, GoalR, GoalT;
+
+ //XMMatrixDecompose(&CurS, &CurR, &CurT, PlayerWorld);
+ //XMMatrixDecompose(&GoalS, &GoalR, &GoalT, GoalWorld);
+
+ //_vector finalR = XMQuaternionSlerp(CurR, GoalR, fTimeDelta); // 8~12는 튐 방지
+ //_vector finalT = XMVectorLerp(CurT, GoalT, fTimeDelta);
+
+ //_matrix finalMat = XMMatrixAffineTransformation(GoalS, XMVectorZero(), finalR, finalT);
+
+ //m_pTransformCom->Set_WorldMatrix(finalMat);
+ //m_pCharacter_Controller->Set_Position(finalMat.r[3]);
+
+
_vector SourS, SourR, SourT;
_vector DestS, DestR, DestT;
XMMatrixDecompose(&SourS, &SourR, &SourT, FinalWorld);
XMMatrixDecompose(&DestS, &DestR, &DestT, m_pTransformCom->Get_XMWorldMatrix());
- _vector finalR = XMQuaternionSlerp(SourR, DestR, fTimeDelta * 10.f);
- _vector finalT = XMVectorLerp(SourT, DestT, fTimeDelta * 10.f);
+ _vector finalR = XMQuaternionSlerp(SourR, DestR, fTimeDelta);
+ _vector finalT = XMVectorLerp(SourT, DestT, fTimeDelta);
_matrix finalMat = XMMatrixAffineTransformation(DestS, XMVectorZero(), finalR, finalT);
m_pTransformCom->Set_WorldMatrix(finalMat);
m_pCharacter_Controller->Set_Position(finalMat.r[3]);
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
};
Desc.funcLateUpdate = nullptr;
m_States.emplace(FSMSTATE::BROOM_RIDE, CState_Broom_Ride::Create(&Desc));
diff --git a/Jusin154_Team3D/Client/Private/Potion.cpp b/Jusin154_Team3D/Client/Private/Potion.cpp
index 2d52f3062..235a2e4c6 100644
--- a/Jusin154_Team3D/Client/Private/Potion.cpp
+++ b/Jusin154_Team3D/Client/Private/Potion.cpp
@@ -42,6 +42,10 @@ HRESULT CPotion::Initialize(void* pArg)
m_fAlphaTime = 1.f;
m_vImageSlotPos = _float2(45.f, 45.f);
m_vImageSize = _float2(32.f, 32.f);
+ m_fFontX = 1163.f;
+ m_fFontY = 860.f;
+ m_iPotionIndex = 0;
+ m_iPerPotionIndex = -1;
return S_OK;
}
@@ -91,6 +95,12 @@ void CPotion::Update(_float fTimeDelta)
m_fTime = -1.f;
}
+ if (m_iPerPotionIndex != m_iPotionIndex)
+ {
+ m_strPotion = to_wstring(m_iPotionIndex);
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_strPotion.c_str()) - 13.f) * 0.5f;
+ m_iPerPotionIndex = m_iPotionIndex;
+ }
m_fTime += fTimeDelta * m_fTimeMult;
@@ -123,6 +133,7 @@ HRESULT CPotion::Render()
if (FAILED(m_pVIBufferCom->Render())) {
return E_FAIL;
}
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_strPotion.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((208.f / 255.f) * m_fAlpha, (177.f / 255.f) * m_fAlpha, (52.f / 255.f) * m_fAlpha, m_fAlpha));
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Skill_Data.cpp b/Jusin154_Team3D/Client/Private/Skill_Data.cpp
index 29603666b..ad7cbb26a 100644
--- a/Jusin154_Team3D/Client/Private/Skill_Data.cpp
+++ b/Jusin154_Team3D/Client/Private/Skill_Data.cpp
@@ -96,31 +96,35 @@ HRESULT CSkill_Data::Load_SpellInfo(const _char* pFilePath)
int id = 0;
pSpell->QueryIntAttribute("Spell_ID", &id);
- if (id < 0 || id > 34)
+ if (id >= 0 && id <= 34)
{
- pSpell = pSpell->NextSiblingElement("Spell");
- continue;
+ SpellInfo[id].iSpell_ID = id;
+ SpellInfo[id].pSpell_Name = CMyTools::ToWstring(pSpell->Attribute("Spell_Name"));
+ SpellInfo[id].pImage_Name = CMyTools::ToWstring(pSpell->Attribute("Image_Name"));
+ pSpell->QueryIntAttribute("Spell_Type", &SpellInfo[id].iSpell_Type);
+ SpellInfo[id].pType_Name = CMyTools::ToWstring(pSpell->Attribute("Type_Name"));
+ pSpell->QueryIntAttribute("Skill_Type", &SpellInfo[id].iSkill_Type);
+ pSpell->QueryFloatAttribute("Spell_Damage", &SpellInfo[id].fSpell_Damage);
+ pSpell->QueryFloatAttribute("Spell_Cooltime", &SpellInfo[id].fSpell_CoolTime);
+ pSpell->QueryFloatAttribute("Duration", &SpellInfo[id].fDuration);
+ pSpell->QueryIntAttribute("AnimNum", &SpellInfo[id].iAnimNum);
+ SpellInfo[id].pSpellInfo = CMyTools::ToWstring(pSpell->Attribute("SpellInfo"));
+ _int lock = 0, equip = 0, use = 0;
+ pSpell->QueryIntAttribute("Spell_Lock", &lock);
+ pSpell->QueryIntAttribute("Equip_Spell", &equip);
+ pSpell->QueryIntAttribute("Use_Skill", &use);
+ SpellInfo[id].bSpell_Lock = lock != 0;
+ SpellInfo[id].bEquip_Spell = equip != 0;
+ SpellInfo[id].bUse_Skill = use != 0;
+ pSpell->QueryFloatAttribute("Preview", &SpellInfo[id].fPreview);
+ pSpell->QueryFloatAttribute("Vidio", &SpellInfo[id].fVidio);
+
+ m_iSpell_Count++;
+ m_iSpell_CoolTime[id] = 1.2f;
}
- SpellInfo[id].iSpell_ID = id;
- SpellInfo[id].pSpell_Name = CMyTools::ToWstring(pSpell->Attribute("Spell_Name"));
- SpellInfo[id].pImage_Name = CMyTools::ToWstring(pSpell->Attribute("Image_Name"));
- pSpell->QueryIntAttribute("Spell_Type", &SpellInfo[id].iSpell_Type);
- pSpell->QueryIntAttribute("Skill_Type", &SpellInfo[id].iSkill_Type);
- pSpell->QueryFloatAttribute("Spell_Cooltime", &SpellInfo[id].fSpell_CoolTime);
- pSpell->QueryFloatAttribute("Duration", &SpellInfo[id].fDuration);
- pSpell->QueryIntAttribute("AnimNum", &SpellInfo[id].iAnimNum);
- SpellInfo[id].pSpellInfo = CMyTools::ToWstring(pSpell->Attribute("SpellInfo"));
- int lock = 0, equip = 0, use = 0;
- pSpell->QueryIntAttribute("Spell_Lock", &lock);
- pSpell->QueryIntAttribute("Equip_Spell", &equip);
- pSpell->QueryIntAttribute("Use_Skill", &use);
- SpellInfo[id].bSpell_Lock = lock != 0;
- SpellInfo[id].bEquip_Spell = equip != 0;
- SpellInfo[id].bUse_Skill = use != 0;
+ // 항상 다음 Spell로 이동
pSpell = pSpell->NextSiblingElement("Spell");
- m_iSpell_Count++;
- m_iSpell_CoolTime[id] = 1.2f;
}
return S_OK;
diff --git a/Jusin154_Team3D/Client/Private/Spell_Header.cpp b/Jusin154_Team3D/Client/Private/Spell_Header.cpp
index a7f4526f9..491322ec4 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Header.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Header.cpp
@@ -26,7 +26,7 @@ HRESULT CSpell_Header::Initialize(void* pArg)
Desc.fX = 600.f;
Desc.fY = -385.f;
Desc.fSizeX = 512.f;
- Desc.fSizeY = 64.f;
+ Desc.fSizeY = 80.f;
m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
@@ -48,6 +48,11 @@ HRESULT CSpell_Header::Initialize(void* pArg)
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
+ static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
+ m_fFontX = 920.f;
+ m_fFontY = 510.f;
+ m_fType = _float2(935.f, 550.f);
+ m_iPerSpellIndex = -1;
return S_OK;
}
@@ -76,6 +81,7 @@ void CSpell_Header::Update(_float fTimeDelta)
if (m_fAlpha >= 1.f)
{
m_bFadeIn = false;
+ m_bHover = true;
m_fAlpha = 1.f;
}
}
@@ -83,7 +89,10 @@ void CSpell_Header::Update(_float fTimeDelta)
if (m_bFadeOut == true)
{
if (m_fAlpha >= 0.f)
- m_fAlpha -= fTimeDelta * m_fAlphaTime;;
+ {
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+ m_bHover = false;
+ }
if (m_fAlpha <= 0.f)
{
@@ -92,9 +101,12 @@ void CSpell_Header::Update(_float fTimeDelta)
}
}
- if (m_iSpellType != -1)
+ if (m_iSpellType != -1 && m_iPerSpellIndex != m_iSpellType)
{
- m_iSkillType = m_pInfoInstance->Get_Spell_Info(m_iSpellType).iSpell_Type;
+ m_iSkillType = static_cast(m_pOwner)->Get_Info(m_iSpellType).iSpell_Type;
+ m_pSpell_Name = static_cast(m_pOwner)->Get_Info(m_iSpellType).pSpell_Name;
+ m_fSpell_Type = static_cast(m_pOwner)->Get_Info(m_iSpellType).pType_Name;
+ m_iPerSpellIndex = m_iSpellType;
}
m_fTime += fTimeDelta * m_fTimeMult;
@@ -128,6 +140,11 @@ HRESULT CSpell_Header::Render()
return E_FAIL;
}
+
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("Font_size20"), m_pSpell_Name.c_str()) - 53.f) * 0.5f;
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), m_pSpell_Name.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((215.f / 255.f) * m_fAlpha, (185.f / 255.f) * m_fAlpha, (95.f / 255.f) * m_fAlpha, m_fAlpha));
+ m_pGameInstance->Render_Text(TEXT("Font_size13"), m_fSpell_Type.c_str(), _float2(m_fType.x + m_fX, m_fType.y + m_fY), XMVectorSet(1.f * m_fAlpha, 1.f * m_fAlpha, 1.f * m_fAlpha, m_fAlpha));
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp b/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
index 1bd1c8aa5..c9f9518db 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
@@ -22,7 +22,7 @@ HRESULT CSpell_Header_Line::Initialize(void* pArg)
CUIObject::UIOBJECT_DESC Desc{};
Desc.fX = 600.f;
- Desc.fY = -345.f;
+ Desc.fY = -340.f;
Desc.fSizeX = 487.f;
Desc.fSizeY = 18.f;
m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
diff --git a/Jusin154_Team3D/Client/Private/Spell_Preview.cpp b/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
index 662d64f78..67c9c579e 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "Spell_Preview.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
CSpell_Preview::CSpell_Preview(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
@@ -9,7 +10,8 @@ CSpell_Preview::CSpell_Preview(ID3D11Device* pDevice, ID3D11DeviceContext* pCont
}
CSpell_Preview::CSpell_Preview(const CSpell_Preview& rhs)
- :CElementObject(rhs)
+ :CElementObject(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
@@ -43,12 +45,18 @@ HRESULT CSpell_Preview::Initialize(void* pArg)
m_fAlphaTime = 5.f;
m_vNine_Slice = _float4(50.f, 75.f, 30.f, 96.f);
m_fTopY = m_fY - m_vScale.y * 0.5f;
+ m_fPreviewOffSet = 0.f;
+ m_fOriginPerviewSize = 280.f;
SizeUpX(512.f);
- SizeUpY(270.f);
+ SizeUpY(m_fOriginPerviewSize);
m_iSpellType = ENUM_CLASS(SPELLTYPE::CONTROL);
m_fSortZ = 0.02f;
+ static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
+ m_fFontX = 740.f;
+ m_fFontY = 500.f;
+ m_iPerSpellIndex = -1;
return S_OK;
}
@@ -76,6 +84,7 @@ void CSpell_Preview::Update(_float fTimeDelta)
if (m_fAlpha >= 1.f)
{
m_bFadeIn = false;
+ m_bHover = true;
m_fAlpha = 1.f;
}
}
@@ -83,7 +92,10 @@ void CSpell_Preview::Update(_float fTimeDelta)
if (m_bFadeOut == true)
{
if (m_fAlpha >= 0.f)
- m_fAlpha -= fTimeDelta * m_fAlphaTime;;
+ {
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+ m_bHover = false;
+ }
if (m_fAlpha <= 0.f)
{
@@ -91,6 +103,15 @@ void CSpell_Preview::Update(_float fTimeDelta)
m_fAlpha = 0.f;
}
}
+
+ if (m_iSpellType != -1 && m_iPerSpellIndex != m_iSpellType)
+ {
+ m_pSpell_Info = static_cast(m_pOwner)->Get_Info(m_iSpellType).pSpellInfo;
+ m_fPreviewOffSet = static_cast(m_pOwner)->Get_Info(m_iSpellType).fPreview;
+ SizeUpY(m_fOriginPerviewSize + m_fPreviewOffSet);
+ m_iPerSpellIndex = m_iSpellType;
+ }
+
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
}
@@ -121,6 +142,10 @@ HRESULT CSpell_Preview::Render()
if (FAILED(m_pVIBufferCom->Render())) {
return E_FAIL;
}
+
+
+ m_pGameInstance->Render_Text(TEXT("Font_size14"), m_pSpell_Info.c_str(), _float2(m_fFontX + m_fX, (m_fFontY + m_fY) - m_fPreviewOffSet * 0.5f), XMVectorSet(1.f * m_fAlpha, 1.f * m_fAlpha, 1.f * m_fAlpha, m_fAlpha));
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp b/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
index be702f1fb..7521a2e79 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
@@ -44,6 +44,7 @@ HRESULT CSpell_Vidio_Border::Initialize(void* pArg)
m_fLerpX = m_fX;
m_fLerpY = 45;
m_bStart = false;
+
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
diff --git a/Jusin154_Team3D/Client/Private/State_Dead.cpp b/Jusin154_Team3D/Client/Private/State_Dead.cpp
index 14e11a7ec..ef3f575f7 100644
--- a/Jusin154_Team3D/Client/Private/State_Dead.cpp
+++ b/Jusin154_Team3D/Client/Private/State_Dead.cpp
@@ -15,7 +15,17 @@ void CState_Dead::Enter()
HRESULT CState_Dead::Update(_float fTimeDelta)
{
- if (E_FAIL == (__super::Update(fTimeDelta))) {
+ HRESULT hr = (__super::Update(fTimeDelta));
+ switch (hr)
+ {
+ case E_PENDING:
+ m_vDeadTimer.x += fTimeDelta;
+ break;
+ default:
+ break;
+ }
+ m_funcLateUpdate(m_vDeadTimer.x / m_vDeadTimer.y);
+ if (m_vDeadTimer.x >= m_vDeadTimer.y) {
return E_FAIL;
}
return S_OK;
@@ -33,7 +43,8 @@ HRESULT CState_Dead::Initialize(STATE_DEAD_DESC* pDesc)
}
m_pModel = m_pOwner->Get_Component();
m_pFSM = m_pOwner->Get_Component();
-
+ m_vDeadTimer = pDesc->vDeadTimer;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/State_Shuffle.cpp b/Jusin154_Team3D/Client/Private/State_Shuffle.cpp
new file mode 100644
index 000000000..d569201bd
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/State_Shuffle.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Shuffle.h"
+#include "GameInstance.h"
+#include "Unit.h"
+
+CState_Shuffle::CState_Shuffle()
+ :CState_Root()
+{
+}
+
+void CState_Shuffle::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Shuffle::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (E_FAIL == (__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_Shuffle::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Shuffle::Initialize(STATE_SHUFFLE_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_Shuffle* CState_Shuffle::Create(STATE_SHUFFLE_DESC* pDesc)
+{
+ CState_Shuffle* pInstance = new CState_Shuffle;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Shuffle::Free()
+{
+ __super::Free();
+}
+
+void CState_Shuffle::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Client/Private/StreetContainer.cpp b/Jusin154_Team3D/Client/Private/StreetContainer.cpp
index aeeb6d183..7030fd027 100644
--- a/Jusin154_Team3D/Client/Private/StreetContainer.cpp
+++ b/Jusin154_Team3D/Client/Private/StreetContainer.cpp
@@ -44,6 +44,18 @@ HRESULT CStreetContainer::Render()
return S_OK;
}
+HRESULT CStreetContainer::Render_Shadow()
+{
+ unordered_map<_string, CPartObject*>::iterator iter = m_PartObjects.begin();
+ for (; iter != m_PartObjects.end(); ++iter) {
+ CPartObject* pObject = (*iter).second;
+ if (FAILED(pObject->Render_Shadow())) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
HRESULT CStreetContainer::Initialize_Prototype()
{
return S_OK;
diff --git a/Jusin154_Team3D/Client/Private/Troll.cpp b/Jusin154_Team3D/Client/Private/Troll.cpp
index c5d8a6995..307db2b71 100644
--- a/Jusin154_Team3D/Client/Private/Troll.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll.cpp
@@ -4,6 +4,7 @@
#include "Troll_Weapon.h"
#include "Troll_Rock.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
#include "Effect_Container.h"
#include "EffectParts.h"
@@ -84,7 +85,7 @@ void CTroll::Update(_float fTimeDelta)
m_pCharacter_Controller->Move(fTimeDelta);
m_vStunTimer.x = 0.f;
}
- else {
+ else if (true == m_pRigidBody->IsActive()) {
if (0.f == m_vStunTimer.x) {
PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
@@ -97,7 +98,6 @@ void CTroll::Update(_float fTimeDelta)
m_pRigidBody->ConvertToCCT(*m_pCharacter_Controller);
}
}
-
#ifdef _DEBUG
Describe_Entity();
#endif // _DEBUG
@@ -106,6 +106,8 @@ void CTroll::Update(_float fTimeDelta)
for (_uint i = 0; i < ENUM_CLASS(TROLL_SKILL::END); i++)
m_fSkillCoolTime[i] = max(0.f, m_fSkillCoolTime[i] - fTimeDelta);
+
+
}
@@ -137,6 +139,7 @@ void CTroll::Late_Update(_float fTimeDelta)
m_fCross = XMVectorGetY(XMVector3Cross(vLook, vDir));
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+ m_pGameInstance->Add_RenderGroup(RENDER::SHADOW, this);
}
HRESULT CTroll::Render()
@@ -174,21 +177,53 @@ HRESULT CTroll::Render()
}
#ifdef _DEBUG
- if (true == m_pCharacter_Controller->IsActive()) {
- if (FAILED(m_pCharacter_Controller->Render())) {
- return E_FAIL;
- }
- }
- else {
- if (FAILED(m_pRigidBody->Render())) {
- return E_FAIL;
- }
- }
+ //if (true == m_pCharacter_Controller->IsActive()) {
+ // if (FAILED(m_pCharacter_Controller->Render())) {
+ // return E_FAIL;
+ // }
+ //}
+ //else {
+ // if (FAILED(m_pRigidBody->Render())) {
+ // return E_FAIL;
+ // }
+ //}
#endif
return S_OK;
}
+HRESULT CTroll::Render_Shadow()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", &m_pGameInstance->Get_ShadowDesc()->fFar, sizeof(_float)))) {
+ 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_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::SHADOW)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
_vector CTroll::Get_LockOnPos()
{
if (nullptr != m_pCharacter_Controller && true == m_pCharacter_Controller->IsActive()) {
@@ -203,10 +238,6 @@ _vector CTroll::Get_LockOnPos()
void CTroll::OnCollision(CGameObject* pOther, void* pDesc)
{
ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
- _vector vWorldPos = {}; // 접촉지점
- _vector vWorldNomal = {}; // 접촉노말
- _vector vHitDir = {}; // 시도한 move 방향
- _float fLength = {}; // 작용된 힘
_uint iSkillType = dynamic_cast(pOther)->Get_SkillType();
switch (iSkillType)
@@ -316,7 +347,7 @@ HRESULT CTroll::Ready_Parts()
- /*if (FAILED(Add_PartObject("Troll_Particle", g_iStaticLevel, &m_pTroll_Particle, &PartsDesc)))
+ if (FAILED(Add_PartObject("Troll_Particle", g_iStaticLevel, &m_pTroll_Particle, &PartsDesc)))
{
return E_FAIL;
}
@@ -350,7 +381,7 @@ HRESULT CTroll::Ready_Parts()
m_pLeft_Smoke->Load("../Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Smoke", static_cast(NEXT_LEVEL));
m_pLeft_Smoke->FollowParants(m_pModelCom->Get_BoneMatrixPtr("LeftArm"));
-*/
+
#pragma endregion
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Troll_States.cpp b/Jusin154_Team3D/Client/Private/Troll_States.cpp
index bd95cf27d..12e7b516d 100644
--- a/Jusin154_Team3D/Client/Private/Troll_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll_States.cpp
@@ -29,7 +29,7 @@ void CTroll::Behavior_IdleEnter()
HRESULT CTroll::Behavior_IdleExitCheck()
{
- if (m_fTargetDistance <= 19.f && m_fTargetDistance !=0)
+ if (m_fTargetDistance <= 18.f && m_fTargetDistance !=0)
m_pFSM->Change_State(FSMSTATE::MOVE);
return E_FAIL;
@@ -61,7 +61,7 @@ void CTroll::Behavior_IdleBreakEnter()
pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK4];
break;
}
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 0.5f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
HRESULT CTroll::Behavior_IdleBreakExitCheck()
@@ -82,12 +82,10 @@ void CTroll::Behavior_MoveEnter()
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::MOVE);
- if (m_pFSM->IsEnable_Previous(FSMSTATE::IDLE))
- {
- m_pFSM->Enable_State(FSMSTATE::JOG);
- pairAnimInfo = m_Animation[STATEANIM::JOG_START];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- }
+ m_pFSM->Enable_State(FSMSTATE::JOG);
+ pairAnimInfo = m_Animation[STATEANIM::JOG_START];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+
}
HRESULT CTroll::Behavior_MoveExitCheck(_float fTimeDelta)
@@ -100,14 +98,15 @@ HRESULT CTroll::Behavior_MoveExitCheck(_float fTimeDelta)
if (iCurrAnimIndex == m_Animation[STATEANIM::JOG_START].first)
{
- if (m_pModelCom->IsFinishedAnim())
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+ if (fRatio >= 0.9f)
{
pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
}
- if (m_fTargetDistance <= 19.f && m_fTargetDistance >= 14.f) {
+ if (m_fTargetDistance <= 18.f && m_fTargetDistance >= 14.f) {
m_pFSM->Change_State(FSMSTATE::COMBAT);
return E_FAIL;
}
@@ -136,7 +135,7 @@ HRESULT CTroll::Behavior_MoveExitCheck(_float fTimeDelta)
else
pairAnimInfo = m_Animation[STATEANIM::JOG_RIGHT_TURN];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
return S_OK;
}
@@ -146,8 +145,8 @@ HRESULT CTroll::Behavior_MoveExitCheck(_float fTimeDelta)
if (iCurrAnimIndex == m_Animation[STATEANIM::JOG_START].first)
{
- if (m_pModelCom->IsFinishedAnim())
- {
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+ if (fRatio >= 0.9f){
pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
@@ -161,7 +160,6 @@ HRESULT CTroll::Behavior_MoveExitCheck(_float fTimeDelta)
return S_OK;
}
-
if (m_fTargetDistance <= 6.f && m_fTargetDistance != 0.f)
m_pFSM->Change_State(FSMSTATE::COMBAT);
@@ -179,15 +177,32 @@ void CTroll::Behavior_CombatEnter()
m_pFSM->Enable_State(FSMSTATE::COMBAT);
m_bLookAt = true;
- if (m_fTargetDistance <= 6.f && m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SLAM)] <= 0.f)
+}
+
+HRESULT CTroll::Behavior_CombatExitCheck(_float fTimeDelta)
+{
+ m_bLookAt = true;
+
+ if (m_fTargetDistance > 30.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ return E_FAIL;
+ }
+
+ if (m_fTargetDistance <= 6.f && (m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SLAM)] <= 0.f) )
{
m_pFSM->Change_State(FSMSTATE::SLAM);
}
- else if (m_fTargetDistance <= 6.f && m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::BACKHAND_SWING)] <= 0.f)
+ else if (m_fTargetDistance <= 6.f && (m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::BACKHAND_SWING)] <= 0.f))
{
m_pFSM->Change_State(FSMSTATE::BACKHAND_SWING);
}
- else if (m_fTargetDistance <= 6.f && m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SWING)] <= 0.f)
+ else if (m_fTargetDistance <= 6.f && (m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SWING)] <= 0.f))
{
m_pFSM->Change_State(FSMSTATE::SWING);
}
@@ -204,16 +219,6 @@ void CTroll::Behavior_CombatEnter()
m_pFSM->Change_State(FSMSTATE::IDLEBREAK);
}
-}
-
-HRESULT CTroll::Behavior_CombatExitCheck(_float fTimeDelta)
-{
- m_bLookAt = true;
- if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
- m_pFSM->Change_State(FSMSTATE::MOVE);
- else if (m_fTargetDistance > 30.f && m_fTargetDistance != 0.f)
- m_pFSM->Change_State(FSMSTATE::IDLE);
-
return E_FAIL;
}
@@ -228,7 +233,7 @@ void CTroll::Behavior_RushEnter()
m_pFSM->Enable_State(FSMSTATE::RUSH);
pairAnimInfo = m_Animation[STATEANIM::RUSH_START];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
HRESULT CTroll::Behavior_RushExitCheck(_float fTimeDelta)
@@ -249,28 +254,30 @@ HRESULT CTroll::Behavior_RushExitCheck(_float fTimeDelta)
}
else {
m_fRushTime += fTimeDelta;
-
if (m_fRushTime >= 1.5f)
{
m_fRushTime = 0.f;
m_pFSM->Disable_State(FSMSTATE::RUSH);
pairAnimInfo = m_Animation[STATEANIM::RUSH_END];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
}
return S_OK;
}
if (iCurrAnimIndex == m_Animation[STATEANIM::RUSH_END].first)
{
- if (m_fCross > 0)
- pairAnimInfo = m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_L];
- else
- pairAnimInfo = m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_R];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ if (m_fDegree >= 90.f)
+ {
+ if (m_fCross > 0)
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_L];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_R];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- Add_Event(pairAnimInfo.first,
- [this]() {m_bLookAt = true; },
- 0.3f);
+ Add_Event(pairAnimInfo.first,
+ [this]() {m_bLookAt = true; },
+ 0.3f);
+ }
}
if (m_pModelCom->IsFinishedAnim())
@@ -291,7 +298,7 @@ void CTroll::Behavior_ThrowEnter()
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::THROW_ROCK);
pairAnimInfo = m_Animation[STATEANIM::THROW_ROCK_START];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
Add_Event(pairAnimInfo.first,
[this](){Get_PartObject()->Set_Visible(true);},
@@ -310,8 +317,9 @@ HRESULT CTroll::Behavior_ThrowExitCheck(_float fTimeDelta)
{
m_pFSM->Disable_State(FSMSTATE::THROW_ROCK);
pairAnimInfo = m_Animation[STATEANIM::THROW_ROCK];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::THROWROCK)] = m_fMaxSkillCoolTime[ENUM_CLASS(TROLL_SKILL::THROWROCK)];
+
Add_Event(pairAnimInfo.first,
[this]() {Get_PartObject()->Set_Attach(false); },
0.25f);
@@ -340,7 +348,8 @@ void CTroll::Behavior_SwingEnter()
m_pFSM->Enable_State(FSMSTATE::SWING);
pairAnimInfo = m_Animation[STATEANIM::SWING_FWD];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+
m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SWING)] =
m_fMaxSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SWING)];
@@ -375,8 +384,8 @@ void CTroll::Behavior_SlamEnter()
m_pFSM->Enable_State(FSMSTATE::SLAM);
pairAnimInfo = m_Animation[STATEANIM::SLAM];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SLAM)] =
m_fMaxSkillCoolTime[ENUM_CLASS(TROLL_SKILL::SLAM)];
@@ -407,8 +416,10 @@ void CTroll::Behavior_BackHandSwingEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
m_pFSM->Enable_State(FSMSTATE::BACKHAND_SWING);
+
pairAnimInfo = m_Animation[STATEANIM::BACKHAND_SWING_JOG];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+
m_fSkillCoolTime[ENUM_CLASS(TROLL_SKILL::BACKHAND_SWING)] =
m_fMaxSkillCoolTime[ENUM_CLASS(TROLL_SKILL::BACKHAND_SWING)];
@@ -441,7 +452,7 @@ void CTroll::Behavior_HitEnter()
_uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
pair<_uint, _bool> pairAnimInfo;
- m_bLookAt = true;
+ m_bLookAt = false;
if (iCurrAnimIndex == m_Animation[STATEANIM::SLAM].first)
{
pairAnimInfo = m_Animation[STATEANIM::HIT_FACE];
@@ -480,6 +491,7 @@ HRESULT CTroll::Behavior_HitExitCheck()
if (m_pModelCom->IsFinishedAnim()) {
m_pFSM->Change_State(FSMSTATE::COMBAT);
+ m_bLookAt = true;
return E_FAIL;
}
return E_FAIL;
@@ -614,10 +626,10 @@ void CTroll::Set_Anim()
m_Animation[STATEANIM::IDLE] = { 16,true };
m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_R] = { 7,false };
m_Animation[STATEANIM::IDLE_COMBAT_TURN_BWD_L] = { 8,false };
- m_Animation[STATEANIM::IDLE_BREAK1] = { 11,false };
- m_Animation[STATEANIM::IDLE_BREAK2] = { 141,false };
- m_Animation[STATEANIM::IDLE_BREAK3] = { 14,false };
- m_Animation[STATEANIM::IDLE_BREAK4] = { 143,false };
+ m_Animation[STATEANIM::IDLE_BREAK1] = { 11,false }; // 땅2번구르기
+ m_Animation[STATEANIM::IDLE_BREAK2] = { 141,false }; // 방망이
+ m_Animation[STATEANIM::IDLE_BREAK3] = { 14,false }; // 땅구르기
+ m_Animation[STATEANIM::IDLE_BREAK4] = { 143,false }; // 소리지르기
m_Animation[STATEANIM::WALK_FWD] = { 22,true };
diff --git a/Jusin154_Team3D/Client/Private/Troll_Weapon.cpp b/Jusin154_Team3D/Client/Private/Troll_Weapon.cpp
index c23f31333..faf2b8ecd 100644
--- a/Jusin154_Team3D/Client/Private/Troll_Weapon.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll_Weapon.cpp
@@ -38,7 +38,8 @@ HRESULT CTroll_Weapon::Initialize(void* pArg)
}
void CTroll_Weapon::Priority_Update(_float fTimeDelta)
-{
+{
+ m_pModelCom->Combined_BoneMatrix();
_matrix socketMatrix = {};
socketMatrix = XMLoadFloat4x4(m_pSocketMatrices);
@@ -57,7 +58,7 @@ void CTroll_Weapon::Priority_Update(_float fTimeDelta)
void CTroll_Weapon::Update(_float fTimeDelta)
{
- m_pModelCom->Combined_BoneMatrix();
+
}
diff --git a/Jusin154_Team3D/Client/Private/Wand.cpp b/Jusin154_Team3D/Client/Private/Wand.cpp
index 9e277efc1..7a4582a3c 100644
--- a/Jusin154_Team3D/Client/Private/Wand.cpp
+++ b/Jusin154_Team3D/Client/Private/Wand.cpp
@@ -44,17 +44,6 @@ HRESULT CWand::Initialize(void* pArg)
void CWand::Priority_Update(_float fTimeDelta)
{
- _matrix socketMatrix = {};
-
- socketMatrix = XMLoadFloat4x4(m_pSocketMatrices);
-
- for (int i = 0; i < 3; ++i) {
- socketMatrix.r[i] = XMVector3Normalize(socketMatrix.r[i]);
- }
-
- m_pTransformCom->Set_WorldMatrix(socketMatrix * XMLoadFloat4x4(m_pParentTransformCom->Get_WorldMatrixPtr()));
- XMStoreFloat4x4(&m_pWandTipMatrix, XMLoadFloat4x4(m_pModelCom->Get_BoneMatrixPtr("Effect")) * m_pTransformCom->Get_XMWorldMatrix());
-
#ifdef _DEBUG
Describe_Entity();
@@ -69,7 +58,17 @@ void CWand::Update(_float fTimeDelta)
void CWand::Late_Update(_float fTimeDelta)
{
- m_pGameInstance->Add_RenderGroup(RENDER::BLEND, this);
+ _matrix socketMatrix = {};
+
+ socketMatrix = XMLoadFloat4x4(m_pSocketMatrices);
+
+ for (int i = 0; i < 3; ++i) {
+ socketMatrix.r[i] = XMVector3Normalize(socketMatrix.r[i]);
+ }
+
+ m_pTransformCom->Set_WorldMatrix(socketMatrix * XMLoadFloat4x4(m_pParentTransformCom->Get_WorldMatrixPtr()));
+ XMStoreFloat4x4(&m_pWandTipMatrix, XMLoadFloat4x4(m_pModelCom->Get_BoneMatrixPtr("Effect")) * m_pTransformCom->Get_XMWorldMatrix());
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
}
HRESULT CWand::Render()
diff --git a/Jusin154_Team3D/Client/Public/BuildingContainer.h b/Jusin154_Team3D/Client/Public/BuildingContainer.h
index 0c33ad548..9d4933b4d 100644
--- a/Jusin154_Team3D/Client/Public/BuildingContainer.h
+++ b/Jusin154_Team3D/Client/Public/BuildingContainer.h
@@ -30,6 +30,7 @@ class CBuildingContainer final : public CMapContainer // OCCLUSION CONTAINER
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow()override;
virtual HRESULT Render_BoundingBox() override;
private:
diff --git a/Jusin154_Team3D/Client/Public/CallBack_Troll_Behavior.h b/Jusin154_Team3D/Client/Public/CallBack_Troll_Behavior.h
new file mode 100644
index 000000000..df57611c1
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/CallBack_Troll_Behavior.h
@@ -0,0 +1,42 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "GameObject.h"
+
+NS_BEGIN(Client)
+
+class CCallBack_Troll_Behavior final : public PSX::PxUserControllerHitReport
+{
+ // 구현 예시
+ // CCT는 RigidBody의 PxSimulationEventCallback에 안걸리고, 이 전용 콜백에서 처리되는 구조임
+ //
+ // PxUserControllerHitReport = "무엇과 부딪혔는지 알려줌(이벤트 알림)"
+ // PxControllerBehaviorCallback = "부딪힌 것에 대해 어떤 행동 정책을 쓸지 물어봄(질의)"
+ // PxSimulationEventCallback = "씬 전체에 대한 글로벌 콜백(일반 물리 이벤트)"
+private:
+ CCallBack_Troll_Behavior();
+public:
+ ~CCallBack_Troll_Behavior();
+
+public:
+ // PxUserControllerHitReport을(를) 통해 상속됨
+ // 충돌알림!!
+ // 주인이 되는 CCT가 이 물체에 대해 어떻게 반응해야 할까?
+ virtual void onShapeHit(const PSX::PxControllerShapeHit& hit) override; // statc, rigid 등과 부딪힌 경우
+
+ virtual void onControllerHit(const PSX::PxControllersHit& hit) override; // 다른 CCT와 부딪힌 경우
+
+ virtual void onObstacleHit(const PSX::PxControllerObstacleHit& hit) override; // 사용자 정의 장애물과 부딪힌 경우
+
+public:
+ HRESULT Initialize(CCharacter_Controller* pController, CRigidBody_Dynamic* pPartDynamicObject);
+ HRESULT Finalize();
+private:
+ CCharacter_Controller* m_pController = { nullptr };
+ CRigidBody_Dynamic* m_pPartDynamicBody = { nullptr };
+ CGameInstance* m_pGameInstance = { nullptr };
+
+public:
+ static CCallBack_Troll_Behavior* Create();
+};
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Camera_Debug.h b/Jusin154_Team3D/Client/Public/Camera_Debug.h
index d1cb8c255..b5183c874 100644
--- a/Jusin154_Team3D/Client/Public/Camera_Debug.h
+++ b/Jusin154_Team3D/Client/Public/Camera_Debug.h
@@ -29,6 +29,7 @@ class CCamera_Debug final : public CCamera
_float m_fMouseSensor = {};
_float4x4 m_matInitial = {};
+
private:
virtual HRESULT Initialize_Prototype() override;
virtual HRESULT Initialize(void* pArg) override;
diff --git a/Jusin154_Team3D/Client/Public/Camera_Gaze.h b/Jusin154_Team3D/Client/Public/Camera_Gaze.h
index d78c1563a..67544ab4a 100644
--- a/Jusin154_Team3D/Client/Public/Camera_Gaze.h
+++ b/Jusin154_Team3D/Client/Public/Camera_Gaze.h
@@ -32,11 +32,16 @@ class CCamera_Gaze final : public CCamera
virtual HRESULT Ready_Components(void* pArg) override;
HRESULT Bind_ShaderResources() override;
+private:
+ CInfoInstance* m_pInfoInstance = { nullptr };
+
+
public:
static CCamera_Gaze* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, CGameObject* pOwner) override;
virtual void Free() override;
+
#ifdef _DEBUG
void Describe_Entity() override;
diff --git a/Jusin154_Team3D/Client/Public/Client_Enum.h b/Jusin154_Team3D/Client/Public/Client_Enum.h
index 7c11e701d..50d625d3c 100644
--- a/Jusin154_Team3D/Client/Public/Client_Enum.h
+++ b/Jusin154_Team3D/Client/Public/Client_Enum.h
@@ -6,13 +6,13 @@ namespace Client
enum class MAPOBJECT_TYPE { CONTAINER, ELEMENT_STATIC, ELEMENT_INTERACT };
enum class MAPOBJECT_RENDER_TYPE { NORMAL, DECAL, GLASS };
- enum class SHADER_PASS_ANIM { DEFAULT, SHADOW, CAPTURE, BLUR, HAIR, EYELASH, OUTLINE_WRITE, OUTLINE_READ, END };
+ enum class SHADER_PASS_ANIM { DEFAULT, SHADOW, CAPTURE, BLUR, HAIR, EYELASH, OUTLINE_WRITE, OUTLINE_READ,SPECTOR, END };
enum class SHADER_PASS_MESH { DEFAULT, SHADOW, SKYBOX, ALPHABLEND, EFFECT_ALPHABLEND, EFFECT_BLEND, EFFECT_ALPHABLEND_CULL, EFFECT_BLEND_CULL, CAPTURE, BLUR, EFFECT_ALPHABLEND_UVMOVE, MAPTOOL, GLASS, OUTLINE_WRITE, OUTLINE_READ, BLOOM, END };
enum class SHADER_PASS_NORTEX { DEFAULT, TERRAIN, ENV_TERRAIN_ANISO, SHADOW, END };
enum class SHADER_PASS_PARTICLE { EXPLOSION, END };
enum class SHADER_PASS_POSTEX { DEFAULT, SCISSOR, UI, UVMOVE, TRAIL, TRAIL_BLEND, TRAILWB_FOR_BLEND, TRAIL_BLUR, TRAIL_BLOOM, END };
enum class SHADER_PASS_INSTANCE_MODEL { DEFAULT, NON_NOMALMAP, BLUR, WEIGHTBLEND, NON_WORLD, NON_WORLD_BLUR, BLEND, BLEND_NOWORLD, BLOOM, BLOOM_NOWORLD, BLUR_NO_EMMISVE, BLUR_NO_WORLD_NO_EMISSIVE, WEIGHTBLEND_FOR_BLEND, END };
- enum class SHADER_PASS_UIEDITOR { DEFAULT, LOGO, LOGO_TEXT, LOGO_GLOW, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, SPELL_DRAG, CAMERA_LOCKON, LODING_SCREEN, END };
+ enum class SHADER_PASS_UIEDITOR { DEFAULT, LOGO, LOGO_TEXT, LOGO_GLOW, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, SPELL_DRAG, CAMERA_LOCKON, LODING_SCREEN, ENEMY_HPBAR, END };
enum class SHADER_PASS_UIINTANCE { DEFAULT, ALPHABLEND, UVALPHABLEND, MAGIC_METER, SPELL_LIST, EESSENTIAL_SPELL_SOLT, EESSENTIAL_SPELL, COLOR, SPELL_HOVER, SPELL_SLOT_EFFECT, SPELL_SLOT, END };
enum class UI_STATE { GAMEPLAYER, SPELL, POTION, INVENTORY, END };
@@ -39,6 +39,7 @@ namespace Client
INPUT_1 = 1, INPUT_2, INPUT_3, INPUT_4,
INPUT_T, INPUT_G,
INPUT_TAB,
+ DIM_RBUTTON_UP, DIM_RBUTTON_DOWN,
END
};
enum class MOUSEINPUT { LBUTTON, RBUTTON };
diff --git a/Jusin154_Team3D/Client/Public/Client_Struct.h b/Jusin154_Team3D/Client/Public/Client_Struct.h
index 3c87189db..a3c50003b 100644
--- a/Jusin154_Team3D/Client/Public/Client_Struct.h
+++ b/Jusin154_Team3D/Client/Public/Client_Struct.h
@@ -22,7 +22,9 @@ namespace Client
_wstring pSpell_Name;
_wstring pImage_Name;
_int iSpell_Type{};
+ _wstring pType_Name;
_int iSkill_Type{};
+ _float fSpell_Damage{};
_float fSpell_CoolTime{};
_float fDuration{};
_int iAnimNum{};
@@ -30,5 +32,7 @@ namespace Client
_bool bSpell_Lock = false;
_bool bEquip_Spell = false;
_bool bUse_Skill = false;
+ _float fPreview{};
+ _float fVidio{};
}SPELL_INFO;
};
diff --git a/Jusin154_Team3D/Client/Public/Effect_Container.h b/Jusin154_Team3D/Client/Public/Effect_Container.h
index e8951b667..b190a0fcc 100644
--- a/Jusin154_Team3D/Client/Public/Effect_Container.h
+++ b/Jusin154_Team3D/Client/Public/Effect_Container.h
@@ -37,6 +37,7 @@ class CEffect_Container abstract : public CContainerObject
void Update_Event(_float fTimeDelta);
HRESULT Reset_EffectParts();
_int CollisionCheck();
+ void SweepTarget(_vector StartPos, _vector EndPos, _float fRadius);
protected:
_float4 m_vStartPos = {};
@@ -44,7 +45,7 @@ class CEffect_Container abstract : public CContainerObject
PSX::PxSweepBufferN<12> m_Hitbuffer = {};
protected:
_wstring m_wstrEffectName = {};
-
+ _bool m_bHit = { false };
_bool m_isLoop = {};
_float m_fAccTime = {};
diff --git a/Jusin154_Team3D/Client/Public/Enemy_HpBar.h b/Jusin154_Team3D/Client/Public/Enemy_HpBar.h
new file mode 100644
index 000000000..74d34a964
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Enemy_HpBar.h
@@ -0,0 +1,61 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "ElementObject.h"
+
+NS_BEGIN(Engine)
+class CGameObject;
+NS_END
+
+NS_BEGIN(Client)
+
+class CEnemy_HpBar final : public CElementObject
+{
+private:
+ CEnemy_HpBar(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CEnemy_HpBar(const CEnemy_HpBar& rhs);
+ virtual ~CEnemy_HpBar() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta);
+ virtual void Update(_float fTimeDelta);
+ virtual void Late_Update(_float fTimeDelta);
+ virtual HRESULT Render() override;
+ virtual _vector Get_WorldPostion() override;
+ virtual void Lerp_PosX(_float X) override;
+
+public:
+ void Hit(_float fTimeDelta);
+ virtual void SizeUpX(_float SizeX) override;
+
+ void Set_Enemt_Info(void* pArg);
+private:
+ virtual HRESULT Bind_ShaderResources() override;
+ virtual HRESULT Ready_Components(void* pArg) override;
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+
+private:
+ CTexture* m_pDiffuse_TextureCom = { nullptr };
+ CTexture* m_pDiffuse_TextureCom1 = { nullptr };
+ CTexture* m_pDiffuse_TextureCom2 = { nullptr };
+ CShader* m_pShaderCom = { nullptr };
+ CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
+
+ _float m_fMaxHp{};
+ _float m_fCurrentHp{};
+ _float m_fHpBar{};
+ _float m_fDamage{};
+ _float m_fTargetHp{};
+
+ _bool m_bAnimation = { false };
+public:
+ static CEnemy_HpBar* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ void Describe_Entity() override;
+#endif // _DEBUG
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Enemy_Info.h b/Jusin154_Team3D/Client/Public/Enemy_Info.h
new file mode 100644
index 000000000..8a754a07a
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Enemy_Info.h
@@ -0,0 +1,56 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "ElementObject.h"
+
+NS_BEGIN(Engine)
+class CGameObject;
+NS_END
+
+NS_BEGIN(Client)
+
+
+class CEnemy_Info final : public CElementObject
+{
+private:
+ CEnemy_Info(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CEnemy_Info(const CEnemy_Info& rhs);
+ virtual ~CEnemy_Info() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta);
+ virtual void Update(_float fTimeDelta);
+ virtual void Late_Update(_float fTimeDelta);
+ virtual HRESULT Render() override;
+ virtual _vector Get_WorldPostion() override;
+
+private:
+ virtual HRESULT Bind_ShaderResources() override;
+ virtual HRESULT Ready_Components(void* pArg) override;
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+
+public:
+ void Set_Info(_int Level, _wstring Name);
+
+private:
+ CTexture* m_pDiffuse_TextureCom = { nullptr };
+ CShader* m_pShaderCom = { nullptr };
+ CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
+
+ _float2 m_fFontPos{};
+ _float m_fFont2OffSet{};
+ _wstring m_pEnemy_Name;
+ _wstring m_pLevel;
+ _bool m_bAnimation = {false};
+
+public:
+ static CEnemy_Info* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ void Describe_Entity() override;
+#endif // _DEBUG
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Enemy_Panel.h b/Jusin154_Team3D/Client/Public/Enemy_Panel.h
new file mode 100644
index 000000000..13cc34ad9
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Enemy_Panel.h
@@ -0,0 +1,49 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "PanelObject.h"
+
+NS_BEGIN(Engine)
+class CGameObject;
+NS_END
+
+NS_BEGIN(Client)
+
+
+class CEnemy_Panel final : public CPanelObject
+{
+private:
+ CEnemy_Panel(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CEnemy_Panel(const CEnemy_Panel& rhs);
+ virtual ~CEnemy_Panel() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta);
+ virtual void Update(_float fTimeDelta);
+ virtual void Late_Update(_float fTimeDelta);
+ virtual HRESULT Render() override;
+ virtual _vector Get_WorldPostion() override;
+
+private:
+ virtual HRESULT Bind_ShaderResources() override;
+ virtual HRESULT Ready_Components(void* pArg) override;
+ virtual HRESULT Ready_Element(void* pArg) override;
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+
+private:
+ CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
+
+ CGameObject* m_pEnemy_HpBar = { nullptr };
+ CGameObject* m_pEnemy_Info = { nullptr };
+
+public:
+ static CEnemy_Panel* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ void Describe_Entity() override;
+#endif // _DEBUG
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/GamePlay_Canvas.h b/Jusin154_Team3D/Client/Public/GamePlay_Canvas.h
index 941a2de85..65099efe7 100644
--- a/Jusin154_Team3D/Client/Public/GamePlay_Canvas.h
+++ b/Jusin154_Team3D/Client/Public/GamePlay_Canvas.h
@@ -39,6 +39,7 @@ class CGamePlay_Canvas final : public CCanvasObject
CGameObject* m_pMinimap_Panel = { nullptr };
CGameObject* m_pLoading_Panel = { nullptr };
CGameObject* m_pAction_Panel = { nullptr };
+ CGameObject* m_pEnemy_Panel = { nullptr };
public:
static CGamePlay_Canvas* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
diff --git a/Jusin154_Team3D/Client/Public/Goblin.h b/Jusin154_Team3D/Client/Public/Goblin.h
index 3e467c587..73f9e6682 100644
--- a/Jusin154_Team3D/Client/Public/Goblin.h
+++ b/Jusin154_Team3D/Client/Public/Goblin.h
@@ -26,10 +26,11 @@ class CGoblin final : public CMonster
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow() override;
virtual _vector Get_LockOnPos() override;
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override;
-
+ _bool Get_Swing() { return m_bSwing; }
private:
CCallBack_Monster_Behavior* m_pCallBack_Behavior = { nullptr };
@@ -40,6 +41,11 @@ class CGoblin final : public CMonster
_float2 m_vStunTimer = { 0.f, 4.f };
_uint iIndex;
+
+ class CEffectParts* m_pSmoke = { nullptr };
+ class CEffectParts* m_pGoblin_Particle = { nullptr };
+ class CEffectParts* m_pGoblin_Particle2 = { nullptr };
+
private:
virtual HRESULT Initialize_Prototype() override;
virtual HRESULT Initialize(void* pArg) override;
@@ -61,18 +67,23 @@ class CGoblin final : public CMonster
virtual void Set_Anim();
_float m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::END)] = {};
- _float m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::END)] = { 5.f,2.f,15.f };
+ _float m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::END)] = { 6.f,2.f,15.f };
- _bool m_bStep = { false };
- _float m_fTpTime = {};
- _float m_fAirTime = {};
+ _bool m_bStep = { false };
+ _float m_fTpTime = {};
+ _float m_fAirTime = {};
+ _vector m_vOriginPos = {};
+ _float m_fLength = {};
+ _bool m_bSwing = { false };
+ _float m_fMoveTime = {};
+ _bool m_bFirstMove = {};
void Behavior_IdleEnter();
HRESULT Behavior_IdleExitCheck();
void Behavior_IdleExit();
void Behavior_MoveEnter();
- HRESULT Behavior_MoveExitCheck();
+ HRESULT Behavior_MoveExitCheck(_float fTimeDelta);
void Behavior_MoveExit();
void Behavior_CombatEnter();
@@ -92,6 +103,10 @@ class CGoblin final : public CMonster
HRESULT Behavior_BlinkExitCheck(_float fTimeDelta);
void Behavior_BlinkExit();
+ void Behavior_ShuffleEnter();
+ HRESULT Behavior_ShuffleExitCheck(_float fTimeDelta);
+ void Behavior_ShuffleExit();
+
void Behavior_HitEnter();
HRESULT Behavior_HitExitCheck(_float fTimeDelta);
void Behavior_HitExit();
diff --git a/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h b/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h
new file mode 100644
index 000000000..5f2edcb42
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h
@@ -0,0 +1,48 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "PartObject.h"
+
+NS_BEGIN(Client)
+
+class CGoblin_BattleAxe final : public CPartObject
+{
+public:
+ typedef struct tagGoblinBattleAxe : public CPartObject::PARTOBJECT_DESC
+ {
+ const _float4x4* pSocketMatrices = { };
+ }GOBLIN_BATTLEAXE_DESC;
+private:
+ CGoblin_BattleAxe(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_BattleAxe(const CGoblin_BattleAxe& Prototype);
+ virtual ~CGoblin_BattleAxe() = 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;
+public:
+
+private:
+ const _float4x4* m_pSocketMatrices = { };
+ CShader* m_pShaderCom = { nullptr };
+ CModel* m_pModelCom = { nullptr };
+
+private:
+ HRESULT Ready_Components();
+ HRESULT Bind_ShaderResources();
+
+public:
+ static CGoblin_BattleAxe* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr)override;
+ virtual void Free() override;
+
+#ifdef _DEBUG
+ void Describe_Entity() override;
+#endif // _DEBUG
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Goblin_Mage.h b/Jusin154_Team3D/Client/Public/Goblin_Mage.h
new file mode 100644
index 000000000..0d6026f22
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_Mage.h
@@ -0,0 +1,108 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "Monster.h"
+#include "CallBack_Monster_Behavior.h"
+#include "CallBack_Monster_HitReport.h"
+
+NS_BEGIN(Client)
+
+class CGoblin_Mage final : public CMonster
+{
+ enum class GOBLIN_SKILL
+ {
+ SPELL,
+ LIGHTATTACK,
+ TP,
+ END
+ };
+private:
+ CGoblin_Mage(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_Mage(const CGoblin_Mage& Prototype);
+ virtual ~CGoblin_Mage() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta) override;
+ virtual void Update(_float fTimeDelta) override;
+ virtual void Late_Update(_float fTimeDelta) override;
+ virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow() override;
+ virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
+ virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override;
+
+
+private:
+ CCallBack_Monster_Behavior* m_pCallBack_Behavior = { nullptr };
+ CCallBack_Monster_HitReport* m_pCallBack_HitReport = { nullptr };
+
+ CCharacter_Controller* m_pCharacter_Controller = { nullptr };
+ CRigidBody_Dynamic* m_pRigidBody = { nullptr };
+ _float2 m_vStunTimer = { 0.f, 4.f };
+ _uint iIndex;
+
+private:
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+ HRESULT Ready_Components();
+ HRESULT Ready_Parts();
+ HRESULT Bind_ShaderResources();
+
+public:
+ static CGoblin_Mage* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ virtual void Describe_Entity() override;
+
+#endif // _DEBUG
+
+private:
+ virtual void Add_FSM();
+ virtual void Set_Anim();
+
+ _float m_fSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::END)] = {};
+ _float m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_SKILL::END)] = { 20.f,20.f,20.f };
+
+ _bool m_bStep = { false };
+ _float m_fTpTime = {};
+ _float m_fAirTime = {};
+ _vector m_vOriginPos = {};
+ _float m_fLength = {};
+ _bool m_bShield = { false };
+
+ void Behavior_IdleEnter();
+ HRESULT Behavior_IdleExitCheck();
+ void Behavior_IdleExit();
+
+ void Behavior_MoveEnter();
+ HRESULT Behavior_MoveExitCheck();
+ void Behavior_MoveExit();
+
+ void Behavior_CombatEnter();
+ HRESULT Behavior_CombatExitCheck(_float fTimeDelta);
+ void Behavior_CombatExit();
+
+ void Behavior_SpellEnter();
+ HRESULT Behavior_SpellExitCheck(_float fTimeDelta);
+ void Behavior_SpellExit();
+
+ void Behavior_LightAttackEnter();
+ HRESULT Behavior_LightAttackExitCheck(_float fTimeDelta);
+ void Behavior_LightAttackExit();
+
+ void Behavior_BlinkEnter();
+ HRESULT Behavior_BlinkExitCheck(_float fTimeDelta);
+ void Behavior_BlinkExit();
+
+ void Behavior_HitEnter();
+ HRESULT Behavior_HitExitCheck(_float fTimeDelta);
+ void Behavior_HitExit();
+
+ void Behavior_DeadEnter();
+ HRESULT Behavior_DeadExitCheck(_float fTimeDelta);
+ void Behavior_DeadExit();
+private:
+ class CEffectPool* m_pEffectPool = nullptr;
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Goblin_Spector.h b/Jusin154_Team3D/Client/Public/Goblin_Spector.h
new file mode 100644
index 000000000..dc83d6452
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_Spector.h
@@ -0,0 +1,74 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "Monster.h"
+#include "CallBack_Monster_Behavior.h"
+#include "CallBack_Monster_HitReport.h"
+
+NS_BEGIN(Engine)
+class CTransform;
+NS_END
+
+NS_BEGIN(Client)
+
+class CGoblin_Spector final : public CMonster
+{
+public:
+ typedef struct tagSpector
+ {
+ CTransform* pParentTransform = { nullptr };
+ }GOBLIN_SPECTOR_DESC;
+private:
+ CGoblin_Spector(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_Spector(const CGoblin_Spector& Prototype);
+ virtual ~CGoblin_Spector() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta) override;
+ virtual void Update(_float fTimeDelta) override;
+ virtual void Late_Update(_float fTimeDelta) override;
+ virtual HRESULT Render() override;
+ virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
+ virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override;
+
+
+private:
+ class CGoblin* m_pGoblin = { nullptr };
+ CTransform* m_pParentTransformCom = { nullptr };
+ _uint iIndex;
+ _float3 m_Offset = {};
+ _float3 m_vOriginScale = {};
+ _float3 m_vScale = { 1.f, 1.f, 1.f };
+
+
+
+ class CEffectParts* m_pSmoke = { nullptr };
+ class CEffectParts* m_pGoblin_Particle = { nullptr };
+ class CEffectParts* m_pGoblin_Particle2 = { nullptr };
+
+private:
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+ HRESULT Ready_Components();
+ HRESULT Ready_Parts();
+ HRESULT Bind_ShaderResources();
+
+public:
+ static CGoblin_Spector* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, CGameObject* pOwner = nullptr) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ virtual void Describe_Entity() override;
+
+#endif // _DEBUG
+
+
+ _bool m_bStep = { false };
+ _float m_fTpTime = {};
+ _float m_fAirTime = {};
+ _vector m_vOriginPos = {};
+ _float m_fLength = {};
+
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/InstancedProp.h b/Jusin154_Team3D/Client/Public/InstancedProp.h
index 1b9ea73c5..accf7104a 100644
--- a/Jusin154_Team3D/Client/Public/InstancedProp.h
+++ b/Jusin154_Team3D/Client/Public/InstancedProp.h
@@ -29,6 +29,7 @@ class CInstancedProp final : public CGameObject
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow()override;
private:
_uint m_iNumMesh = {};
diff --git a/Jusin154_Team3D/Client/Public/Level_Loading.h b/Jusin154_Team3D/Client/Public/Level_Loading.h
index b4016e7ac..ce3481472 100644
--- a/Jusin154_Team3D/Client/Public/Level_Loading.h
+++ b/Jusin154_Team3D/Client/Public/Level_Loading.h
@@ -20,7 +20,7 @@ class CLevel_Loading final : public CLevel
private:
SHADOW_LIGHT_DESC m_ShadowDesc = {};
LEVEL m_eNextLevelID = { LEVEL::END };
- class CLoader* m_pLoader = { nullptr };
+ class CLoader* m_pLoader = { nullptr };
_float m_fTimeDelta{};
_bool m_bDelay = { false };
diff --git a/Jusin154_Team3D/Client/Public/Loding_Panel.h b/Jusin154_Team3D/Client/Public/Loding_Panel.h
index 2636f47d6..729621f8d 100644
--- a/Jusin154_Team3D/Client/Public/Loding_Panel.h
+++ b/Jusin154_Team3D/Client/Public/Loding_Panel.h
@@ -46,6 +46,16 @@ class CLoding_Panel final : public CUIObject
_int m_iImageNum{};
_float4 m_vImageposSi{};
+
+#ifdef _DEBUG
+ _bool INHYUK = { false };
+ _bool JINHO = { false };
+ _bool HYUNBIN = { false };
+ _bool NURI = { false };
+ _bool JINWOO = { false };
+ _int human{};
+#endif
+
public:
static CLoding_Panel* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Magic_Item.h b/Jusin154_Team3D/Client/Public/Magic_Item.h
index fb685bca1..e2df4a2e4 100644
--- a/Jusin154_Team3D/Client/Public/Magic_Item.h
+++ b/Jusin154_Team3D/Client/Public/Magic_Item.h
@@ -51,6 +51,10 @@ class CMagic_Item final : public CElementObject
_float2 m_vImagePos1 = {};
_float2 m_vImageSize2 = {};
_float2 m_vImagePos2 = {};
+
+ _int m_iPotionIndex{};
+ _int m_iPerPotionIndex{};
+ _wstring m_strPotion;
public:
static CMagic_Item* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/MapContainer.h b/Jusin154_Team3D/Client/Public/MapContainer.h
index 18467ba0e..91b96e6e8 100644
--- a/Jusin154_Team3D/Client/Public/MapContainer.h
+++ b/Jusin154_Team3D/Client/Public/MapContainer.h
@@ -25,6 +25,7 @@ class CMapContainer abstract : public CContainerObject
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow() override;
void ReadyForPhysX();
void ConvertToPhysX();
@@ -42,7 +43,7 @@ class CMapContainer abstract : public CContainerObject
if (nullptr == pPartObject) {
return E_FAIL;
}
-
+ m_bHasCollisionMesh = true;
m_ColiisonPartObjects.push_back(pPartObject);
return S_OK;
@@ -54,8 +55,8 @@ class CMapContainer abstract : public CContainerObject
virtual HRESULT Ready_Components(void* pArg) override;
protected:
- _uint m_iMaxLodLevel = {};
-
+ _uint m_iMaxLodLevel = {};
+ _bool m_bHasCollisionMesh = { false };
vector m_ColiisonPartObjects = {};
public:
diff --git a/Jusin154_Team3D/Client/Public/MapObject_Render.h b/Jusin154_Team3D/Client/Public/MapObject_Render.h
index 2db8dae73..682b567aa 100644
--- a/Jusin154_Team3D/Client/Public/MapObject_Render.h
+++ b/Jusin154_Team3D/Client/Public/MapObject_Render.h
@@ -24,6 +24,8 @@ class CMapObject_Render final : public CMapPartObject // Render PartObject
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
virtual HRESULT Render_Shadow() override;
+ void ReadyForPhysX();
+ void ConvertToPhysX();
public:
virtual _wstring Get_PrototypeTag(_uint iLodIndex = 0);
@@ -33,12 +35,15 @@ class CMapObject_Render final : public CMapPartObject // Render PartObject
MAPOBJECT_RENDER_TYPE m_Type = {};
CShader* m_pShaderCom = { nullptr };
vector m_pModelComs;
+ vector> m_RigidBodies;
_uint m_iLodIndex = {};
_uint m_iShaderPass = {};
_uint m_iNumMeshe = {};
_float m_fRadius = { 0.f };
+ _bool m_bReadyToCreatePhysX = { false };
+ _bool m_bConverted = { false };
vector<_wstring> m_ModelPrototypeTags;
diff --git a/Jusin154_Team3D/Client/Public/MiniMap_TrimBorder.h b/Jusin154_Team3D/Client/Public/MiniMap_TrimBorder.h
index de0a7da6e..b7c742a50 100644
--- a/Jusin154_Team3D/Client/Public/MiniMap_TrimBorder.h
+++ b/Jusin154_Team3D/Client/Public/MiniMap_TrimBorder.h
@@ -37,7 +37,7 @@ class CMiniMap_TrimBorder final : public CElementObject
CShader* m_pShaderCom = { nullptr };
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
-
+ CInfoInstance* m_pInfoInstance = { nullptr };
public:
static CMiniMap_TrimBorder* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Monster.h b/Jusin154_Team3D/Client/Public/Monster.h
index 84679bd8d..dbb7ef481 100644
--- a/Jusin154_Team3D/Client/Public/Monster.h
+++ b/Jusin154_Team3D/Client/Public/Monster.h
@@ -16,6 +16,7 @@ class CMonster abstract : public CUnit
virtual void Priority_Update(_float fTimeDelta) override;
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
+ virtual HRESULT Render_DeadDisolve();
virtual HRESULT Render_OutLine() override;
virtual void Set_DrawOutLine();
_float4 Get_TargetPos() { return m_vTargetPos; }
@@ -29,6 +30,7 @@ class CMonster abstract : public CUnit
_float4 m_vTargetPos = { };
_float3 m_vToTargetDir = { };
_float m_fTargetDistance = { FLT_MAX };
+ _float m_fDeadRatio = { 0.f };
_bool m_bDrawOutLine = { false };
_bool m_bLookAt = { true };
diff --git a/Jusin154_Team3D/Client/Public/NomalJap.h b/Jusin154_Team3D/Client/Public/NomalJap.h
index 0dbdfa863..f599fc6a6 100644
--- a/Jusin154_Team3D/Client/Public/NomalJap.h
+++ b/Jusin154_Team3D/Client/Public/NomalJap.h
@@ -30,7 +30,6 @@ class CNomalJap final : public CEffect_Container
HRESULT Ready_Child();
HRESULT Bind_ShaderResources() override;
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr) override;
- void SweepTarget();
private:
class CInfoInstance* m_pInfoInstance = { nullptr };
_wstring m_wstrEffectName = {};
@@ -57,7 +56,6 @@ class CNomalJap final : public CEffect_Container
_float m_fAngularSpeed = {};
_float m_fLinearSpeed = 35.f;
_float m_fTimeRate = {};
- _bool m_bHit = { false };
/*좌우 무빙 관련 변수들*/
_float3 m_vRotateRight = {};
diff --git a/Jusin154_Team3D/Client/Public/Player.h b/Jusin154_Team3D/Client/Public/Player.h
index 8c7e76025..ec5292d95 100644
--- a/Jusin154_Team3D/Client/Public/Player.h
+++ b/Jusin154_Team3D/Client/Public/Player.h
@@ -20,7 +20,7 @@ class CPlayer final : public CUnit
virtual HRESULT Render_Shadow() override;
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override;
-
+ _bool Get_Aim() { return m_bAim; }
#ifdef _DEBUG
void Render_CameraCoordinateSystem();
#endif // _DEBUG
@@ -84,8 +84,6 @@ class CPlayer final : public CUnit
virtual void Reset_Sprint() { m_bSprintToggle = false; }
virtual void Reset_Walk() { m_bWalkToggle = false; }
-
-
private:
// UI 연동 추가
void Get_Spell(_int SkillIndex);
@@ -94,13 +92,20 @@ class CPlayer final : public CUnit
virtual void Add_FSM();
virtual void Set_Anim();
- function m_InputAction = nullptr;
- _int m_eUIState = { };
+ void Reset_LightCombo() { m_iLightCombo = 0; }
+ _uint Next_LightCombo() { return ++m_iLightCombo; }
+ void Set_LightCombo(_uint LightCombo) { m_iLightCombo = LightCombo; }
- _float3 m_OffsetPos = {};
- _float m_fAmount = { 1.f };
- _float m_fInputTime = {};
- _bool m_bRatio = { false };
+ function m_InputAction = nullptr;
+ _int m_eUIState = { };
+ _uint m_iLightCombo = { 0 };
+
+ _float3 m_OffsetPos = {};
+ _float m_fAmount = { 1.f };
+ _float m_fInputTime = {};
+ _bool m_bRatio = { false };
+ _bool m_bAim = { false };
+ _float m_fAnimSpeed = {};
HRESULT InputAction();
HRESULT InputMove();
diff --git a/Jusin154_Team3D/Client/Public/Potion.h b/Jusin154_Team3D/Client/Public/Potion.h
index 80231f230..6753becd7 100644
--- a/Jusin154_Team3D/Client/Public/Potion.h
+++ b/Jusin154_Team3D/Client/Public/Potion.h
@@ -42,6 +42,10 @@ class CPotion final : public CElementObject
_float2 m_vImageSlotPos{};
_float2 m_vImageSize{};
+
+ _int m_iPotionIndex{};
+ _int m_iPerPotionIndex{};
+ _wstring m_strPotion;
public:
static CPotion* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Skill_Data.h b/Jusin154_Team3D/Client/Public/Skill_Data.h
index 796b904d3..cbdeff071 100644
--- a/Jusin154_Team3D/Client/Public/Skill_Data.h
+++ b/Jusin154_Team3D/Client/Public/Skill_Data.h
@@ -35,9 +35,9 @@ class CSkill_Data final : public CBase
private:
CInfoInstance* m_pInfoInstance = { nullptr };
- _int m_iSpell_Count{};
- SPELL_INFO SpellInfo[34] = {};
- _float m_iSpell_CoolTime[34] = {};
+ _int m_iSpell_Count{};
+ SPELL_INFO SpellInfo[34] = {};
+ _float m_iSpell_CoolTime[34] = {};
_bool m_bNoCool = { false };
diff --git a/Jusin154_Team3D/Client/Public/Spell_Header.h b/Jusin154_Team3D/Client/Public/Spell_Header.h
index d65b41934..30cd3f56c 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Header.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Header.h
@@ -38,7 +38,12 @@ class CSpell_Header final : public CElementObject
CShader* m_pShaderCom = { nullptr };
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
- _int m_iSkillType{};
+ _wstring m_pSpell_Name;
+ _wstring m_fSpell_Type;
+
+ _float2 m_fType{};
+
+ _int m_iPerSpellIndex{};
public:
static CSpell_Header* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_Preview.h b/Jusin154_Team3D/Client/Public/Spell_Preview.h
index 5952a2c80..726018f46 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Preview.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Preview.h
@@ -35,6 +35,8 @@ class CSpell_Preview final : public CElementObject
virtual HRESULT Initialize(void* pArg) override;
private:
+ CInfoInstance* m_pInfoInstance = { nullptr };
+
CTexture* m_pDiffuse_TextureCom = { nullptr };
CTexture* m_pDiffuse_TextureCom1 = { nullptr };
CTexture* m_pDiffuse_TextureCom2 = { nullptr };
@@ -42,10 +44,13 @@ class CSpell_Preview final : public CElementObject
CShader* m_pShaderCom = { nullptr };
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
+ _wstring m_pSpell_Info;
-
+ _float m_fOriginPerviewSize{};
+ _float m_fPreviewOffSet{};
_float4 m_vHeaderBack{};
+ _int m_iPerSpellIndex{};
public:
static CSpell_Preview* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h b/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
index de678b1f4..65534bc16 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
@@ -39,6 +39,7 @@ class CSpell_Vidio_Border final : public CElementObject
_float m_fStertTimer{};
_int m_iPerIndex{};
+
_bool m_bStart = { false };
public:
diff --git a/Jusin154_Team3D/Client/Public/State_Dead.h b/Jusin154_Team3D/Client/Public/State_Dead.h
index 5dea32e2b..fb79fec0f 100644
--- a/Jusin154_Team3D/Client/Public/State_Dead.h
+++ b/Jusin154_Team3D/Client/Public/State_Dead.h
@@ -8,7 +8,8 @@ class CState_Dead final : public CState_Root
{
public:
typedef struct tagLand : public CState_Root::STATE_ROOT_DESC {
-
+ _float2 vDeadTimer = { 0.f, 2.f };
+ function funcLateUpdate = { nullptr };
}STATE_DEAD_DESC;
private:
CState_Dead();
@@ -21,7 +22,8 @@ class CState_Dead final : public CState_Root
private:
HRESULT Initialize(STATE_DEAD_DESC* pDesc);
-
+ _float2 m_vDeadTimer = { 0.f, 2.f };
+ function m_funcLateUpdate = { nullptr };
public:
static CState_Dead* Create(STATE_DEAD_DESC* pDesc);
virtual void Free() override;
diff --git a/Jusin154_Team3D/Client/Public/State_Shuffle.h b/Jusin154_Team3D/Client/Public/State_Shuffle.h
new file mode 100644
index 000000000..33ff9d64f
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/State_Shuffle.h
@@ -0,0 +1,36 @@
+#pragma once
+#include "Client_Define.h"
+#include "State_Root.h"
+
+NS_BEGIN(Client)
+
+class CState_Shuffle final : public CState_Root
+{
+public:
+ typedef struct tagShuffle : public CState_Root::STATE_ROOT_DESC {
+ function funcPriorityUpdate = { nullptr };
+ function funcLateUpdate = { nullptr };
+ }STATE_SHUFFLE_DESC;
+public:
+ CState_Shuffle();
+ virtual ~CState_Shuffle() = default;
+
+public:
+ virtual void Enter();
+ virtual HRESULT Update(_float fTimeDelta);
+ virtual void Exit();
+
+private:
+ function m_funcPriorityUpdate = { nullptr };
+ function m_funcLateUpdate = { nullptr };
+
+private:
+ HRESULT Initialize(STATE_SHUFFLE_DESC* pDesc);
+
+public:
+ static CState_Shuffle* Create(STATE_SHUFFLE_DESC* pDesc);
+ virtual void Free() override;
+ virtual void Describe_Entity();
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/StreetContainer.h b/Jusin154_Team3D/Client/Public/StreetContainer.h
index 5bda61ca5..0b012f0f5 100644
--- a/Jusin154_Team3D/Client/Public/StreetContainer.h
+++ b/Jusin154_Team3D/Client/Public/StreetContainer.h
@@ -17,6 +17,7 @@ class CStreetContainer final : public CMapContainer // NON OCCLUSION CONTAINER
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow() override;
private:
virtual HRESULT Initialize_Prototype() override;
diff --git a/Jusin154_Team3D/Client/Public/Troll.h b/Jusin154_Team3D/Client/Public/Troll.h
index b9d80b1b0..a718d0f88 100644
--- a/Jusin154_Team3D/Client/Public/Troll.h
+++ b/Jusin154_Team3D/Client/Public/Troll.h
@@ -29,6 +29,7 @@ class CTroll final : public CMonster
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_Shadow() override;
virtual _vector Get_LockOnPos() override;
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override;
diff --git a/Jusin154_Team3D/Client/Public/Wand.h b/Jusin154_Team3D/Client/Public/Wand.h
index 192c3b779..0ec4ef4b9 100644
--- a/Jusin154_Team3D/Client/Public/Wand.h
+++ b/Jusin154_Team3D/Client/Public/Wand.h
@@ -34,7 +34,7 @@ class CWand final : public CPartObject
CModel* m_pModelCom = { nullptr };
_float4x4 m_pWandTipMatrix = {};
-
+ _float3 m_Offset = {};
#ifdef _DEBUG
unique_ptr m_pGripShape = { nullptr };
unique_ptr m_pSubShape = { nullptr };
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Decendo/Decendo_Proj_Blur.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Decendo/Decendo_Proj_Blur.bin
index 40d7aa507..34a8f8fe4 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Decendo/Decendo_Proj_Blur.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Decendo/Decendo_Proj_Blur.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:095202f43eb3cb685e4232432b23281a820807754eabad1074ca3ebdcca05e92
+oid sha256:22ba13040b9bd24959b0fd0b1d9f1af6932c5b802964199d6482264fd2cd7a63
size 1027
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoBottom.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoBottom.bin
new file mode 100644
index 000000000..af6286a93
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoBottom.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:544382ad6f97afecabc855f8dc86814c9ea6bbaee482d0287d0322e46952c804
+size 1073
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoCircle.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoCircle.bin
new file mode 100644
index 000000000..009e7163d
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoCircle.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4fe532820dc147021997dd1b5a9c395e9e7ba0d8e206b0b9e1ab80cc68172f1d
+size 1121
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoSphere.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoSphere.bin
new file mode 100644
index 000000000..b68fb28ba
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinProtego/ProtegoSphere.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:72db8483c996edbc3ca3f5de53be4d9ab2855eaf7984eb76d7b4ed6ce369406d
+size 1096
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle.bin
new file mode 100644
index 000000000..b845844bf
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:930799fefb3bca8cd3001418a2342fcdc74e35b1975ef54dbd0a129a5551abca
+size 1241
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2.bin
new file mode 100644
index 000000000..befeb53ad
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a8f9f0d8399e20f3811226000130a5dc004b351195afea93185d568e95bf645a
+size 1182
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke.bin
new file mode 100644
index 000000000..ea061c68e
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b6485f8ea045d881466f2da3b6b77b0827dea289c5fe71244f12f5ef9bb41b11
+size 1121
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Trail_R.trail b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Trail_R.trail
new file mode 100644
index 000000000..e397ae5f6
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Trail_R.trail differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/GoblinProtego.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/GoblinProtego.bin
new file mode 100644
index 000000000..85dbfaf1a
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/GoblinProtego.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:61d710662d0b5a36853d8c07a94deb5fb707601ffa2f2a4bfe17f31e9207720c
+size 232
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollNomalSmoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollNomalSmoke.bin
new file mode 100644
index 000000000..d6d8920d1
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollNomalSmoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:406299999af5b183256e32dae361e753570530919726c8d248137ae60a30cd39
+size 152
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollRush.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollRush.bin
new file mode 100644
index 000000000..4cd07bb23
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollRush.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cd6069fb16443fb38c1b59472360ca064aef911b01498044011e994181dd06f4
+size 70
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollSwing.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollSwing.bin
new file mode 100644
index 000000000..d75706c04
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/MonsterPackage/TrollSwing.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a63cdeb3c40d3f7a719be9698dab4e1692883cbffa52f690d98bbff336fa7c57
+size 137
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoCircle.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoCircle.bin
index 1dc126b14..6e1706733 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoCircle.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoCircle.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:e51ef5ceb2e67e3f28a71ac406b7b954971793218cf087a6b21980d2645c5beb
+oid sha256:e3e7e86c3f29daa14d846f99ec1909b675486e4d9945212b2fbdd63dfaf134d9
size 1121
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoHit_Lay.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoHit_Lay.bin
index 46f1fbd37..deb461ee3 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoHit_Lay.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoHit_Lay.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:bf42c45bcf958ab7ff58983cc1e7e27cb6f7f42f181b1eb3bdcde8249ada8727
+oid sha256:3dcf0889c738365e99b0ec40c7b9fd70122e5aaab650430bd9b307621d522045
size 1068
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoSphere.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoSphere.bin
index e4911bf16..0df571232 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoSphere.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Protego/ProtegoSphere.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:4654728d937fa4bd660d9cea86dbbf3255a10d8e26c18192fe0af843c9071423
+oid sha256:59d896365c898d5aa7d774f308f01e1b8d6da47f63f4a142eeb3d3d805a88ddb
size 1096
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/NomalSmoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/NomalSmoke.bin
new file mode 100644
index 000000000..6d34d30df
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/NomalSmoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fbb5a0c4ac4ac92472e290518a55aed3a0fcbecb82a1ed9b216048ec8ec2e6c1
+size 1081
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/Rock_PT_15.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/Rock_PT_15.bin
new file mode 100644
index 000000000..5cdad11d7
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollNomalSmoke/Rock_PT_15.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:63f6f81087a07cb00f8b487dd2820270c4794a1387b4ed13d8c937e027acd6e7
+size 1023
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollRush/HitSmoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollRush/HitSmoke.bin
new file mode 100644
index 000000000..77a9bdde3
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollRush/HitSmoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fc390eae893f71f844682d29d5e0957f84084e1e71fd3ccc276dc5df56fd3193
+size 1089
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Pyosik.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Pyosik.bin
new file mode 100644
index 000000000..c447e575b
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Pyosik.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fe33a34188cfe88af0b057e74bf3a74f968bbdf30955fbea4d6dddedc9b762f8
+size 1074
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle.bin
new file mode 100644
index 000000000..ee80e72e5
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b1b50f6d7e8ce495956a0db039b5411ae820f3c0b6f708c0b70781600e89b643
+size 1241
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle2.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle2.bin
new file mode 100644
index 000000000..5b70c9a35
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle2.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4530b2d6177a830637d49060b0f3bb84a20d6e46da9ac243f77bb1c45a662a3a
+size 1182
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Smoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Smoke.bin
new file mode 100644
index 000000000..1a916f96b
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Smoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fdac73008a58068ff482eb3361bc7a044fff87c43ad129628d0fe4e47c976c10
+size 1121
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Trail.trail b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Trail.trail
new file mode 100644
index 000000000..bad634117
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Trail.trail differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Rock_PT_25.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Rock_PT_25.bin
new file mode 100644
index 000000000..39a5eb571
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Rock_PT_25.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:86ddfc69f4752004c34ba936aac4548a6596bea57fbcf36bc1e60eac2bf95111
+size 1031
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Smoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Smoke.bin
new file mode 100644
index 000000000..3cb7b5d0e
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/Troll/TrollSwing/Smoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8f7dd07558998c717ae52e92bfc6d277cefc72d8f36a1e10d01ce6c97678c216
+size 1074
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/JapSideEffect/Wand_Light_R.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/JapSideEffect/Wand_Light_R.bin
new file mode 100644
index 000000000..a8ddfaad5
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/JapSideEffect/Wand_Light_R.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7b748cd2ce1cd65dd20995dab60f9c55b9923087964fcef3f22a223a48b5edd9
+size 888
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Pyosik.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Pyosik.bin
new file mode 100644
index 000000000..7635c9f53
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Pyosik.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42d86dd5971770a03c318e6c9d807493303f65884522eb57ec985633436b6b0f
+size 882
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Particle.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Particle.bin
new file mode 100644
index 000000000..eb266de99
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Particle.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5518cb1b28a4f3fb3d527bf3ef1149e0b0d5f88afd540dc584787f21e5c5b9fb
+size 1003
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Smoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Smoke.bin
new file mode 100644
index 000000000..f8ef9cf2d
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Smoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:041c2dfcbd450946046b2c5df7fe04bf860d35ea8fe3264190427df569aec78c
+size 879
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Trail.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Trail.bin
new file mode 100644
index 000000000..63eb8ae60
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSide/Troll_Trail.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:767dd41e7bf0f2c92d803c1d8d4de0a49f49d4c89868dd77881cca013aeb67d1
+size 384
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Rock_PT_25.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Rock_PT_25.bin
new file mode 100644
index 000000000..cf4364b4d
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Rock_PT_25.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ddb0eabe19d693cc93216d6de214126fee23994be866294843b695694c1ea1e5
+size 831
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Smoke.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Smoke.bin
new file mode 100644
index 000000000..06d624b3b
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/Troll/TrollSwing/Smoke.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f3728fedc4291ed12aaf3ad416d3a00774e1a2cd52524ac720fe1a95aaa6af35
+size 882
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/WandParticle/WandParticle_W0.bin b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/WandParticle/WandParticle_W0.bin
new file mode 100644
index 000000000..b8bdf5cc0
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Effect/임시공간/WandParticle/WandParticle_W0.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1c0775bbc89659643b4a32490db3400029b5008dd14013c385e4a310521616ed
+size 867
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml
index 7b45bee9a..9501aabdc 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml
@@ -1,5 +1,5 @@
-
-
-
+
+
+
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Data.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Data.xml
new file mode 100644
index 000000000..d1182dea5
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Data.xml
@@ -0,0 +1,3 @@
+
+ ¸¶Ʈ, ǪµåÄÚƮ, ÀǷù¸ÅÀå
+
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
index 8d0130895..a5487a058 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
@@ -1,36 +1,191 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size13.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size13.spritefont
new file mode 100644
index 000000000..343439d0d
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size13.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size14.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size14.spritefont
new file mode 100644
index 000000000..ea3fa21b1
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size14.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size15.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size15.spritefont
new file mode 100644
index 000000000..4dcd04233
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size15.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size20.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size20.spritefont
new file mode 100644
index 000000000..14658ce64
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size20.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size21.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size21.spritefont
new file mode 100644
index 000000000..e9c3d4178
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size21.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size30.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size30.spritefont
new file mode 100644
index 000000000..8edb425e2
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/Font_size30.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Fonts/UI_size15.spritefont b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/UI_size15.spritefont
new file mode 100644
index 000000000..69bc98fd5
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Fonts/UI_size15.spritefont differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector.bin
new file mode 100644
index 000000000..dae868946
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2ae507a8d2e877c8eee91c619519a27cd2f9c8fe216f1fd8b4a8412ab3f8b2c
+size 1268799
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector_Anim.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector_Anim.bin
new file mode 100644
index 000000000..d8e60b0d5
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector_Anim.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b984576a89953bcb47b335afe7902e425c1bb137ffc3926e9252e7a50c580c83
+size 38425807
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/SK_GOB_M_Specter_Master_Anim.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/SK_GOB_M_Specter_Master_Anim.fbx
new file mode 100644
index 000000000..e5979a3ae
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/GoblinSpector/SK_GOB_M_Specter_Master_Anim.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4bb13c980e9ace1700522e6b04d389db881b06fe625172a9d85536ad6c446bad
+size 125990796
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage.bin
new file mode 100644
index 000000000..95b9fb57f
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:620afbbab73effa2c5e7adf737fe8d0cad99055a5102b3da749409f7f4499982
+size 1308608
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.bin
new file mode 100644
index 000000000..0d773ac44
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b1aef095b49c93110e90a0af543657e5dfa54fc5aa5e29db4c9427868cb70132
+size 31859991
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.fbx
new file mode 100644
index 000000000..c3b8caccc
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5d935ffb4ab4ef97b917b52e018524381136334111404f41639e82922bedb62b
+size 70692588
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.bin
new file mode 100644
index 000000000..485554d3c
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:63ccfb2aba0013eb8a23eb0c10f50ce4ebd87d648ad8fc2a101c239af72a3f00
+size 3137030
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.fbx
new file mode 100644
index 000000000..727550f1a
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim2.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4765ba7bfae18977c47a70884487775ebccee38f12fd3bae3ffc1a5df0b851d8
+size 3716236
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.bin
new file mode 100644
index 000000000..758ea3491
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a892908214bf58639166edacddc6fc5ee1ba8b67924182db1d6f04ae1518bd01
+size 3101748
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.fbx
new file mode 100644
index 000000000..1374ec9d0
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage_Anim3.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:027d965b9d0c145f0e085383a61dc1ee25b5fb6a351b66fe25da2f5cd1ed56d8
+size 3314620
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/teroll1234.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/teroll1234.bin
new file mode 100644
index 000000000..400f47ee8
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/teroll1234.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:62cc099ed295d989f363f1cb09d528d755327a09e83513887c5cdcb6a4213afb
+size 44266214
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.bin
new file mode 100644
index 000000000..e5aaccbbf
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:83960820cbce3567145434d63887252639deb0b836109c7ece3656d2df4a4d2a
+size 5154581
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.fbx
index 4ed5bba04..866d6ed22 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:33783d796335f0fdefff1f06f34cec423975b05d8147e4316902ac73d9dcf200
-size 135867852
+oid sha256:62c113acb5e15bab839185ad00acf6ede4587fcf44874078ce738d0475fec203
+size 2138700
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll1234.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll1234.fbx
new file mode 100644
index 000000000..4ed5bba04
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll1234.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:33783d796335f0fdefff1f06f34cec423975b05d8147e4316902ac73d9dcf200
+size 135867852
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.bin
new file mode 100644
index 000000000..6b31d54a7
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:79915c33216333ffe8df447e667428f4b5657ff782257a5f38baec6bb74c3890
+size 38582704
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.fbx
new file mode 100644
index 000000000..fcda4d970
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/SubTroll/troll_Anim.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5deae579f7148d2b5f0903a497b1e7934e9bcb3af966a4c20e8feaa24ea1fc04
+size 111182908
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_BattleAxe/SK_WPN_GOB_BattleAxe01.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_BattleAxe/SK_WPN_GOB_BattleAxe01.bin
new file mode 100644
index 000000000..013c53717
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_BattleAxe/SK_WPN_GOB_BattleAxe01.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c3d49a44f7e1ac09e7f6515f5bb9536ace861d91f48f1363f4dd1c843ddb6efa
+size 146389
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_Dagger/SK_WPN_GOB_SmallSword.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_Dagger/SK_WPN_GOB_SmallSword.bin
new file mode 100644
index 000000000..470f226db
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Goblin_Dagger/SK_WPN_GOB_SmallSword.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:40d27f6e472f28a616616df2d40d24749875230c9d16c2d2a37d5df156d9528d
+size 86496
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.bin
new file mode 100644
index 000000000..d48b0e456
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d722e69450996491225d93959ac93358367de99d24046163d475ee6e69b34e49
+size 275869
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/T_Troll_ArmoredTroll_Body_Corruption_A.dds b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/T_Troll_ArmoredTroll_Body_Corruption_A.dds
new file mode 100644
index 000000000..9865fd7a8
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/SubTroll_Weapon/T_Troll_ArmoredTroll_Body_Corruption_A.dds differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Troll_Weapon/SK_WPN_Troll_Club07.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Troll_Weapon/SK_WPN_Troll_Club07.bin
new file mode 100644
index 000000000..b67d7cecc
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Object/Troll_Weapon/SK_WPN_Troll_Club07.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e3d6d4a8aa630f162940bc9cb975110b19b17b9c8a9e34dae9a25741d6d6beb0
+size 275600
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Engine_Shader_Functions.hlsli b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Engine_Shader_Functions.hlsli
index e1180fbcb..f408fe02c 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Engine_Shader_Functions.hlsli
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Engine_Shader_Functions.hlsli
@@ -375,4 +375,21 @@ float3 Filmic_ToneMapper(float3 vColor)
}
+float4 ApplyDissolve(Texture2D DisolveTexture, float fDisolveRatio, float fDisolveAmount, float fDisolveEdgeWidth, float4 vDisolveEdgeColor, float4 vMtrlDiffuse, float2 vTexcoord)
+{
+ float4 vDisolve = DisolveTexture.Sample(DefaultSampler, vTexcoord);
+ float fDisolveValue = vDisolve.r;
+
+ float fDisolveThreshold = saturate(fDisolveRatio + fDisolveAmount);
+
+ clip(fDisolveValue - fDisolveThreshold); // 진짜 잘려나감
+
+ float edgeWidth = max(fDisolveEdgeWidth, FLT_EPSILON5); // 불타는 라인
+ float edgeFactor = smoothstep(fDisolveThreshold, fDisolveThreshold + edgeWidth, fDisolveValue);
+
+ vMtrlDiffuse.rgb = lerp(vDisolveEdgeColor.rgb, vMtrlDiffuse.rgb, edgeFactor);
+
+ return vMtrlDiffuse;
+}
+
#endif // ENGINE_SHADER_FUNCTIONS_HLSLI
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Deferred.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Deferred.hlsl
index f9ef153d5..d190bd600 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Deferred.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Deferred.hlsl
@@ -569,8 +569,8 @@ PS_OUT_BACKBUFFER PS_MAIN_COMBINED(PS_IN In)
vPreShadowTexcoord.y = (vPreShadowPosition.y / vPreShadowPosition.w) * -0.5f + 0.5f;
/* 광원의 NDC에서 샘플링 */
- float fVisibility_Dynamic_Near = ShadowVisibility_hwPCF(g_ShadowNearTexture, vPosition, float2(g_iMaxShadowWidth, g_iMaxShadowHeight), 0.0005f);
- float fVisibility_Static = ShadowVisibility_hwPCF(g_PreShadowTexture, vPreShadowPosition, float2(g_iMaxShadowWidth, g_iMaxShadowHeight), 0.0005f);
+ float fVisibility_Dynamic_Near = ShadowVisibility_hwPCF(g_ShadowNearTexture, vPosition, float2(g_iMaxShadowWidth, g_iMaxShadowHeight), 0.005f);
+ float fVisibility_Static = ShadowVisibility_hwPCF(g_PreShadowTexture, vPreShadowPosition, float2(g_iMaxShadowWidth, g_iMaxShadowHeight), 0.005f);
Out.vBackBuffer.rgb *= lerp(0.25f, 1.f, lerp(fVisibility_Dynamic_Near, fVisibility_Static, vDepthDesc.y));
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Particle_Compute.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Particle_Compute.hlsl
index c0ce8251b..bd75f7635 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Particle_Compute.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Particle_Compute.hlsl
@@ -43,9 +43,12 @@ struct ParticleValue
float3 vDeltaSize;
float2 vDelay;
+
bool isCompareStop;
float fCollisionTime;
float fDropAttenuation;
+
+ float3 vVelocity;
};
@@ -108,6 +111,8 @@ void CS_MAIN(
float fGravity = particleValue.fGravity;
float fOnlyDropY = 0.f;
+ float fRatio = particle.vLifeTime.x / particle.vLifeTime.y;
+
particleValue.vDelay.x += fTimeDelta;
if (particleValue.vDelay.x < particleValue.vDelay.y)
@@ -144,8 +149,14 @@ void CS_MAIN(
if (particle.vLifeTime.x >= particle.vLifeTime.y)
{
+ particleValue.isCompareStop = false;
+ particleValue.fCollisionTime = 0.f;
+
if (isLoop == false)
{
+ g_VBInstanceOutput[iIndex] = particle;
+ g_ParticleValueOutput[iIndex] = particleValue;
+
return ;
}
//초기화
@@ -157,8 +168,7 @@ void CS_MAIN(
particle.vLifeTime.x = 0.f;
particleValue.vAniIndex.x = 0.f;
particleValue.vDelay.x = 0.f;
- particleValue.isCompareStop = false;
- particleValue.fCollisionTime = 0.f;
+
g_VBInstanceOutput[iIndex] = particle;
g_ParticleValueOutput[iIndex] = particleValue;
@@ -168,17 +178,11 @@ void CS_MAIN(
if (isDrop == true)
- {
+ {
if (particleValue.isCompareStop == true) // 지면에 부딪혔을 때
{
- // 내 현재 시간의 비례
- // 0.0 ~ 3
- // 2초에 부딧혓으면
- // 2 - 2 / 3 - 2
- // 0 ~ 1 cos(0) * - 1
-
- float fRatio = saturate((particle.vLifeTime.x - particleValue.fCollisionTime) / (particle.vLifeTime.y - particleValue.fCollisionTime));
+ fRatio = saturate((particle.vLifeTime.x - particleValue.fCollisionTime) / (particle.vLifeTime.y - particleValue.fCollisionTime));
fGravity *= (2.f * fRatio - 1.f) / particleValue.fDropAttenuation;
}
@@ -187,8 +191,7 @@ void CS_MAIN(
fOnlyDropY = particle.vTranslation.y;
}
-
-
+
if (isMoveForward)
{
float fTime = (particle.vLifeTime.x / particle.vLifeTime.y);
@@ -274,7 +277,7 @@ void CS_MAIN(
}
- if (isDetphCompareStop)
+ if (isDetphCompareStop == true)
{
float2 vTexcoord;
@@ -301,7 +304,7 @@ void CS_MAIN(
float fOldViewZ = vDepthDesc.y * fFar;
- if (vProjPos.w >= fOldViewZ)
+ if (vProjPos.w >= fOldViewZ && particle.vLifeTime.x >= 0.2f)
{
if (particleValue.isCompareStop == false)
{
@@ -319,6 +322,10 @@ void CS_MAIN(
}
+ /*가속력*/
+ if (length(particleValue.vVelocity) > FLT_EPSILON5)
+ particle.vTranslation.xyz += fRatio * particleValue.vVelocity;
+
if (isSizeMove == true)
{
float3 CurLength =
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
index bc248ab64..c2d688ad7 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UIEditor.hlsl
@@ -23,6 +23,7 @@ float g_fAlpha;
float g_fOwnerAlpha;
float g_fCanvasAlpha;
float g_fAngle;
+float g_fMapAngle;
float g_fCoolTime;
float g_fHp;
@@ -506,21 +507,14 @@ PS_OUT PS_Rotation(PS_IN In)
float2 center = float2(0.5f, 0.5f);
float2 uv = In.vTexcoord - center;
- uv *= sqrt(2.0f);
float2 Rotation = In.vTexcoord;
- Rotation.x = uv.x * cos(g_fAngle) - uv.y * sin(g_fAngle);
- Rotation.y = uv.x * sin(g_fAngle) + uv.y * cos(g_fAngle);
+ Rotation.x = uv.x * cos(g_fMapAngle) - uv.y * sin(g_fMapAngle);
+ Rotation.y = uv.x * sin(g_fMapAngle) + uv.y * cos(g_fMapAngle);
Rotation += center;
- float4 tex1 = g_Texture.Sample(ClampSampler, Rotation);
- float4 tex2 = g_Texture1.Sample(DefaultSampler, In.vTexcoord);
-
- tex1.rgb *= 0.4f;
+ float4 tex1 = g_Texture.Sample(ClampSampler , Rotation);
+
color = tex1;
- tex2.rgb *= 0.3f;
-
- if (tex2.a >= 0.9f)
- color = tex2;
color.a *= Alpha;
@@ -586,7 +580,7 @@ PS_OUT PS_SpellAnim(PS_IN In)
switch (g_iSpellType)
{
case 0:
- BGColor = float3(255.f, 255.f, 0.f) / 255.f;
+ BGColor = float3(220.f, 165.f, 70.f) / 255.f;
break;
case 1:
BGColor = float3(150.f, 120.f, 240.f) / 255.f;
@@ -1132,7 +1126,7 @@ PS_OUT PS_Spell_Header(PS_IN In)
switch (g_iSpellType)
{
case 0:
- BGColor = float3(255.f, 255.f, 0.f) / 255.f;
+ BGColor = float3(220.f, 165.f, 70.f) / 255.f;
break;
case 1:
BGColor = float3(150.f, 120.f, 240.f) / 255.f;
@@ -1155,11 +1149,12 @@ PS_OUT PS_Spell_Header(PS_IN In)
}
float4 tex1 = g_Texture.Sample(DefaultSampler, In.vTexcoord);
- Color = tex1;
-
+ Color.rgb = tex1.rgb * 0.8f;
+ Color.a = tex1.a;
+
Color.rgb *= BGColor;
- Color.a *= Alpha;
+ Color.a *= Alpha * 0.5f;
Out.vColor = Color;
@@ -1330,6 +1325,92 @@ PS_OUT PS_Loding_Screen(PS_IN In)
return Out;
}
+PS_OUT PS_Enemy_HpBer(PS_IN In)
+{
+ PS_OUT Out;
+
+ float Alpha = g_fAlpha * g_fOwnerAlpha * g_fCanvasAlpha;
+ float4 Color = float4(1.f, 1.f, 1.f, 1.f);
+ float4 Color1 = float4(1.f, 1.f, 1.f, 1.f);
+ float2 uv = In.vTexcoord;
+ float2 CurrentPixelPosition = uv * g_fCurrent_Size;
+ float OriginLeft = g_fNine_Slice.x;
+ float OriginRight = g_fNine_Slice.y;
+ float OriginTop = g_fNine_Slice.z;
+ float OriginBottom = g_fNine_Slice.w;
+
+ float CurrentLeft = OriginLeft;
+ float CurrentRight = g_fCurrent_Size.x - (g_fOrigin_Size.x - OriginRight);
+ float CurrentTop = OriginTop;
+ float CurrentBottom = g_fCurrent_Size.y - (g_fOrigin_Size.y - OriginBottom);
+
+ float2 Finaluv = In.vTexcoord;
+
+ if (CurrentPixelPosition.x < CurrentLeft)
+ {
+ Finaluv.x = CurrentPixelPosition.x / g_fOrigin_Size.x;
+ }
+ else if (CurrentPixelPosition.x > CurrentRight)
+ {
+ float dist = CurrentPixelPosition.x - CurrentRight;
+ Finaluv.x = (OriginRight + dist) / g_fOrigin_Size.x;
+ }
+ else
+ {
+ float scale = (CurrentPixelPosition.x - CurrentLeft) / (CurrentRight - CurrentLeft);
+ Finaluv.x = (OriginLeft / g_fOrigin_Size.x) + scale * ((OriginRight - OriginLeft) / g_fOrigin_Size.x);
+ }
+
+ if (CurrentPixelPosition.y < CurrentTop)
+ {
+ Finaluv.y = CurrentPixelPosition.y / g_fOrigin_Size.y;
+ }
+ else if (CurrentPixelPosition.y > CurrentBottom)
+ {
+ float dist = CurrentPixelPosition.y - CurrentBottom;
+ Finaluv.y = (OriginBottom + dist) / g_fOrigin_Size.y;
+ }
+ else
+ {
+ float scale = (CurrentPixelPosition.y - CurrentTop) / (CurrentBottom - CurrentTop);
+ Finaluv.y = (OriginTop / g_fOrigin_Size.y) + scale * ((OriginBottom - OriginTop) / g_fOrigin_Size.y);
+ }
+
+ float4 tex1 = g_Texture.Sample(DefaultSampler, Finaluv);
+ float4 tex2 = g_Texture1.Sample(DefaultSampler, Finaluv);
+
+ Color = tex1;
+
+ tex2.rgb *= float3(1.f, 0.f, 0.f);
+
+ if (In.vTexcoord.x >= g_fHp)
+ {
+ tex2.rgb = float3(0.f, 0.f, 0.f);
+ }
+
+ Color = lerp(Color, tex2, tex2.a);
+
+ if (Color.a <= 0.f)
+ discard;
+
+ if(g_iHover != 0)
+ {
+ float4 tex3 = g_Texture2.Sample(DefaultSampler, In.vTexcoord);
+
+ tex3.rgb *= float3(1.f, 0.f, 0.f);
+
+ if (g_fTime >= tex3.r)
+ {
+ Color.a *= tex3.r;
+ Color.rgb = float3(1.f, 0.f, 0.f);
+ }
+ }
+
+ Color.a *= Alpha;
+ Out.vColor = Color;
+ return Out;
+}
+
technique11 PosTexTechnique11
{
pass Default
@@ -1620,4 +1701,14 @@ technique11 PosTexTechnique11
PixelShader = compile ps_5_0 PS_Loding_Screen();
}
+ pass Enemy_HpBer
+ {
+ SetRasterizerState(RS_Default);
+ SetDepthStencilState(DSS_Default, 0);
+ SetBlendState(BS_AlphaBlend, float4(0.f, 0.f, 0.f, 0.f), 0xffffffff);
+ VertexShader = compile vs_5_0 VS_MAIN();
+ GeometryShader = NULL;
+ PixelShader = compile ps_5_0 PS_Enemy_HpBer();
+ }
+
}
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UI_Instance.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UI_Instance.hlsl
index 88deb62b4..832d2e2a0 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UI_Instance.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_UI_Instance.hlsl
@@ -239,7 +239,7 @@ PS_OUT PS_Color_Image(PS_IN In)
switch (In.vBaseColor)
{
case 0:
- BGColor = float3(255.f, 255.f, 0.f) / 255.f;
+ BGColor = float3(220.f, 165.f, 70.f) / 255.f;
break;
case 1:
BGColor = float3(150.f, 120.f, 240.f) / 255.f;
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxAnimMesh.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxAnimMesh.hlsl
index 71249a77c..8ffe32f47 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxAnimMesh.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxAnimMesh.hlsl
@@ -5,6 +5,7 @@ matrix g_WorldMatrix, g_ViewMatrix, g_ProjMatrix;
bool g_bRimLight;
bool g_bUseNormalMap;
+bool g_bDisolve;
float g_fFar;
float g_LifeRatio;
@@ -16,6 +17,11 @@ float3 g_vOutLineColor;
float g_fOutLineScale;
float g_fOutLineThickness;
float g_fOutLinePower;
+float g_fDisolveRatio;
+float g_fDisolveAmount;
+float g_fDisolveEdgeWidth;
+
+vector g_vDisolveEdgeColor;
vector g_vCamPosition;
Texture2D g_DiffuseTexture;
@@ -27,6 +33,9 @@ Texture2D g_TransmissionTexture;
Texture2D g_EmissiveTexture;
Texture2D g_AmbientTexture;
Texture2D g_AmbientOcclusionTexture;
+Texture2D g_UnknownTexture;
+Texture2D g_DeadDisolveTexture;
+Texture2D g_DeadDisolveBurnTexture;
bool g_bBinded_Texture[AI_TEXTURE_TYPE_MAX * 27];
@@ -257,6 +266,11 @@ PS_OUT PS_MAIN(PS_IN In)
float4 vMtrlDiffuse = g_DiffuseTexture.Sample(AnisoTropy_BLUR_Sampler, In.vTexcoord);
float4 vSurface = g_SurfaceParamsTexture.Sample(AnisoTropy_BLUR_Sampler, In.vTexcoord);
+ if (true == g_bDisolve)
+ {
+ float4 vBurnColor = g_DeadDisolveBurnTexture.Sample(DefaultSampler, In.vTexcoord);
+ vMtrlDiffuse = ApplyDissolve(g_DeadDisolveTexture, g_fDisolveRatio, g_fDisolveAmount, g_fDisolveEdgeWidth, vBurnColor, vMtrlDiffuse, In.vTexcoord);
+ }
//if (AlmostEqual7(g_bBinded_Texture[AI_TEXTURE_TYPE_TRANSMISSION], true))
//{
// float4 vTransmission = g_TransmissionTexture.Sample(AnisoTropy_BLUR_Sampler, In.vTexcoord);
@@ -466,6 +480,49 @@ PS_OUT PS_EYELASH(PS_IN In)
return Out;
}
+PS_OUT PS_SPECTOR_MAIN(PS_IN In)
+{
+ PS_OUT Out;
+
+ float4 vMtrlDiffuse = g_EmissiveTexture.Sample(AnisoTropy_BLUR_Sampler, In.vTexcoord);
+ float4 vSurface = g_SurfaceParamsTexture.Sample(AnisoTropy_BLUR_Sampler, In.vTexcoord);
+ if (vMtrlDiffuse.a < 0.2f)
+ {
+ discard;
+ }
+ if (vMtrlDiffuse.r > 0.3f)
+ {
+ vMtrlDiffuse.rgb *= float3(2.f, 1.f, 1.f);
+ }
+
+ float3 vNormalDecoded = DecodeNormalFromRG(g_NormalTexture, AnisoTropy_BLUR_Sampler, In.vTexcoord);
+ float3x3 WorldMatrix = float3x3(In.vTangent, In.vBinormal * -1.f, In.vNormal);
+
+ float3 vNormal = normalize(mul(vNormalDecoded, WorldMatrix));
+
+ if (true == g_bRimLight)
+ {
+ float fRimLight = GetRimLight(g_vCamPosition.xyz, In.vWorldPos.xyz, vNormal, g_fRimPower, g_fRimStrength);
+ vMtrlDiffuse.xyz = (vMtrlDiffuse.xyz * (1 - fRimLight)) + g_vRimColor * fRimLight;
+ }
+
+ Out.vAlbedo = vMtrlDiffuse;
+ Out.vNormal = float4(vNormal * 0.5f + 0.5f, 0.f);
+ float fSurfaceParam = g_fUsingSurfaceParams;
+ if (true == AlmostEqual7(g_fUsingSurfaceParams, 0.f))
+ {
+ fSurfaceParam = 0;
+ }
+ Out.vDepth = float4((In.vProjPos.z / In.vProjPos.w), // NDC 깊이 ( 0~ 1)
+ (In.vProjPos.w / g_fFar), // 뷰 스페이스 Z
+ fSurfaceParam, // 서페이스 파라미터
+ 1.f);
+ Out.vColor = float4(0.f, 0.f, 0.f, 1.f);
+ Out.vSurface = vSurface;
+
+ return Out;
+}
+
technique11 DefaultTechnique
{
@@ -547,4 +604,14 @@ technique11 DefaultTechnique
GeometryShader = NULL;
PixelShader = compile ps_5_0 PS_MAIN_OUTLINE();
}
+
+ pass SpectorPass // 8
+ {
+ SetRasterizerState(RS_Default);
+ SetDepthStencilState(DSS_Default, 0);
+ SetBlendState(BS_None, float4(0.f, 0.f, 0.f, 0.f), 0xffffffff);
+ VertexShader = compile vs_5_0 VS_MAIN();
+ GeometryShader = NULL;
+ PixelShader = compile ps_5_0 PS_SPECTOR_MAIN();
+ }
}
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxMesh.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxMesh.hlsl
index ace4eb606..4d1c3d973 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxMesh.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxMesh.hlsl
@@ -5,6 +5,7 @@ matrix g_WorldMatrix, g_ViewMatrix, g_ProjMatrix;
bool g_bUVTargetDiffuse;
bool g_bAdditiveDisolve;
+bool g_bDisolve;
float g_LifeRatio;
float g_fFar;
@@ -34,6 +35,7 @@ Texture2D g_TransmissionTexture;
Texture2D g_EmissiveTexture;
Texture2D g_AmbientTexture;
Texture2D g_AmbientOcclusionTexture;
+Texture2D g_UnknownTexture;
bool g_bBinded_Texture[AI_TEXTURE_TYPE_MAX * 27];
@@ -46,6 +48,7 @@ Texture2D g_GlassTexture;
TextureCube g_CubeTexture;
Texture2D g_NormalLargeTexture;
Texture2D g_NormalSubTexture;
+Texture2D g_DeadDisolveTexture;
float g_fNormalValue1;
float g_fNormalValue2;
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxModelInstance.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxModelInstance.hlsl
index 87fde2ea8..83525fbfa 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxModelInstance.hlsl
+++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_VtxModelInstance.hlsl
@@ -35,6 +35,9 @@ struct ParticleValue
bool isCompareStop;
float fCollisionTime;
float fDropAttenuation;
+
+ float3 vVelocity;
+
};
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_HUD_Monster_HealthMeterFill.png b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_HUD_Monster_HealthMeterFill.png
new file mode 100644
index 000000000..2c701689f
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_HUD_Monster_HealthMeterFill.png differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_Monster_HpBar.png b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_Monster_HpBar.png
new file mode 100644
index 000000000..97144ff30
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Action/UI_T_Monster_HpBar.png differ
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Textures/Effect/Diffuse/drp_fire_Line_Vertical.png b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Effect/Diffuse/drp_fire_Line_Vertical.png
new file mode 100644
index 000000000..1f93aa267
Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Textures/Effect/Diffuse/drp_fire_Line_Vertical.png differ
diff --git a/Jusin154_Team3D/Editor/Default/Editor.vcxproj b/Jusin154_Team3D/Editor/Default/Editor.vcxproj
index 3126bd39d..f1479f203 100644
--- a/Jusin154_Team3D/Editor/Default/Editor.vcxproj
+++ b/Jusin154_Team3D/Editor/Default/Editor.vcxproj
@@ -176,7 +176,16 @@ call Update_Shaders.bat
-
+
+
+
+
+
+
+
+
+
+
@@ -223,6 +232,9 @@ call Update_Shaders.bat
+
+
+
@@ -342,6 +354,10 @@ call Update_Shaders.bat
+
+
+
+
@@ -354,7 +370,16 @@ call Update_Shaders.bat
-
+
+
+
+
+
+
+
+
+
+
@@ -401,6 +426,9 @@ call Update_Shaders.bat
+
+
+
@@ -523,6 +551,11 @@ call Update_Shaders.bat
Create
+
+
+
+
+
diff --git a/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters b/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
index c378901cd..7b349ef5f 100644
--- a/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
+++ b/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
@@ -484,9 +484,6 @@
{c70a2ce4-8664-45e0-b594-4f416829dab8}
-
- {3a12f2c2-0472-41b7-99ce-2c2f17f26e92}
-
{ebad2fd8-622f-4c17-9ba3-b0c4bd366c05}
@@ -511,12 +508,45 @@
{d8a5038f-4f2c-4226-85ba-9202f11f822d}
+
+ {ea790bf9-9ca6-4c51-820b-ed2c70f86104}
+
+
+ {33ba73e0-b4a1-4ebf-9b99-8856c7e1078c}
+
+
+ {e30ca8e3-8c89-4a08-b413-169ff1d5ff22}
+
{4b6ac1df-5642-42f1-a492-5c2ca2433559}
{df91c194-9910-489b-a9bb-724e1c1f4440}
+
+ {2e89850b-eb23-46a7-9c3b-9c2965aa0b76}
+
+
+ {ed83440e-f038-4fe2-b005-4ba4093e8462}
+
+
+ {d5debb7c-5bea-456a-8c70-f44b5fc9e51e}
+
+
+ {5d93fa49-8e72-4182-a4ad-c4aef00000b8}
+
+
+ {0df28480-a5ca-4895-b8f4-2bac1a7454ea}
+
+
+ {7363a82f-1bdf-4107-b824-a5326a7d2075}
+
+
+ {4556b8c9-e689-435e-8775-48d0c45a942f}
+
+
+ {3a12f2c2-0472-41b7-99ce-2c2f17f26e92}
+
@@ -975,8 +1005,8 @@
50.UI\Mouse_Cursor
-
- 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Attack
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\TrollSwing
50.UI\Loding_Canvas
@@ -1005,6 +1035,54 @@
02.GameObjects\Env\03.MapElement\Lake
+
+ 02.GameObjects\Monster\Troll
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Rock
+
+
+ 02.GameObjects\Monster\Troll\Weapon
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Nomal_Smoke
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Rush_Hit
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Goblin_Protego
+
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel
+
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel\Enemy_HpBar
+
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel\Enemy_Info
+
@@ -1462,8 +1540,8 @@
50.UI\Mouse_Cursor
-
- 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Attack
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\TrollSwing
50.UI\Loding_Canvas
@@ -1486,12 +1564,63 @@
50.UI\Logo\Logo_Glow
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel
+
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel\Enemy_HpBar
+
+
+ 50.UI\GamePlay_Canvas\Enemy_Panel\Enemy_Info
+
02.GameObjects\Env\07.Unified
02.GameObjects\Env\03.MapElement\Lake
+
+ 02.GameObjects\Monster\Troll
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Rock
+
+
+ 02.GameObjects\Monster\Troll\Weapon
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Monster\Troll\Troll_State
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Nomal_Smoke
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Troll_Rush_Hit
+
+
+ 02.GameObjects\Layer_Effect\Effect\Monster_Effect\Goblin_Protego
+
diff --git a/Jusin154_Team3D/Editor/Default/Emart.xml b/Jusin154_Team3D/Editor/Default/Emart.xml
new file mode 100644
index 000000000..d1182dea5
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Default/Emart.xml
@@ -0,0 +1,3 @@
+
+ ¸¶Ʈ, ǪµåÄÚƮ, ÀǷù¸ÅÀå
+
diff --git a/Jusin154_Team3D/Editor/Private/CamPosition_Shoulder.cpp b/Jusin154_Team3D/Editor/Private/CamPosition_Shoulder.cpp
index af9f8046e..031a3d922 100644
--- a/Jusin154_Team3D/Editor/Private/CamPosition_Shoulder.cpp
+++ b/Jusin154_Team3D/Editor/Private/CamPosition_Shoulder.cpp
@@ -98,7 +98,7 @@ void CCamPosition_Shoulder::Update(_float fTimeDelta)
if (m_pGameInstance->Key_Up(DIK_GRAVE)) {
m_bMovable = !m_bMovable;
}
- if (m_pGameInstance->Mouse_Down(DIM_RBUTTON)) {
+ if (m_pGameInstance->Mouse_Down(DIM_MBUTTON)) {
m_pGameInstance->Toggle_MouseCenter();
}
if (m_pGameInstance->Key_Up(DIK_P)) {
diff --git a/Jusin154_Team3D/Editor/Private/CameraLockOn.cpp b/Jusin154_Team3D/Editor/Private/CameraLockOn.cpp
index 14335c131..0ce47f2ce 100644
--- a/Jusin154_Team3D/Editor/Private/CameraLockOn.cpp
+++ b/Jusin154_Team3D/Editor/Private/CameraLockOn.cpp
@@ -47,7 +47,7 @@ void CCameraLockOn::Priority_Update(_float fTimeDelta)
void CCameraLockOn::Update(_float fTimeDelta)
{
- if (m_pGameInstance->Mouse_Pressing(DIM_RBUTTON))
+ if (m_pGameInstance->Mouse_Pressing(DIM_MBUTTON))
{
m_bHover = true;
}
diff --git a/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp b/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp
index d37e0cb12..66e018e39 100644
--- a/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp
+++ b/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp
@@ -29,7 +29,7 @@ void CCamera_Debug::Update(_float fTimeDelta)
if (m_pGameInstance->Key_Up(DIK_GRAVE)) {
m_bMovable = !m_bMovable;
}
- if (m_pGameInstance->Mouse_Down(DIM_RBUTTON)) {
+ if (m_pGameInstance->Mouse_Down(DIM_MBUTTON)) {
m_pGameInstance->Toggle_MouseCenter();
}
if (m_bMovable) {
diff --git a/Jusin154_Team3D/Editor/Private/Dummy_PhysXEffectHitBox.cpp b/Jusin154_Team3D/Editor/Private/Dummy_PhysXEffectHitBox.cpp
index 4e185c42b..b93c839fe 100644
--- a/Jusin154_Team3D/Editor/Private/Dummy_PhysXEffectHitBox.cpp
+++ b/Jusin154_Team3D/Editor/Private/Dummy_PhysXEffectHitBox.cpp
@@ -83,6 +83,7 @@ HRESULT CDummy_PhysXEffectHitBox::Ready_Components(void* pArg)
if (FAILED(__super::Ready_Components(pArg))) {
return E_FAIL;
}
+
PHYSXDUMMY_DESC* pDesc = static_cast(pArg);
m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&pDesc->vPos), 1.f));
m_pTransformCom->Rotation(pDesc->vRotRPY.x, pDesc->vRotRPY.y, pDesc->vRotRPY.z);
diff --git a/Jusin154_Team3D/Editor/Private/EditEffect.cpp b/Jusin154_Team3D/Editor/Private/EditEffect.cpp
index f26f7d07d..07c5b6615 100644
--- a/Jusin154_Team3D/Editor/Private/EditEffect.cpp
+++ b/Jusin154_Team3D/Editor/Private/EditEffect.cpp
@@ -420,9 +420,8 @@ void CEditEffect::Describe_Entity()
{
//여기서 모델, 텍스쳐, 선택할 수 있도록 함
-
const char* pLerp[] = { "Linear" , "EaseInQuad", "EaseOutQuad", "EaseInCubic" , "EaseOutCubic" , "EaseInOutSin" , "EaseInBack" , "Expo" , "Circle" };
- const char* pRenderNames[] = { "PRIORITY" , "SHADOW", "NONBLEND", "DECAL", "BLUR" , "NONLIGHT" ,"EFFECT", "BLEND" ,"BLOOM" , "UI", "OCCLUSION" , "PRESHADOW"};
+ const char* pRenderNames[] = { "PRIORITY" , "SHADOW", "NONBLEND", "DECAL", "BLUR" , "NONLIGHT" ,"EFFECT", "BLEND" ,"BLOOM" , "UI", "OCCLUSION" , "PRESHADOW", "UI_OVERLAY"};
const char* pEffectType[] = { "EFFECT" , "TRAIL" };
const char* pShaderPass[] = { "DEFAULT" , "NON_NOMALMAP" , "BLUR" , "WEIGHTBLEND" , "NON_WORLD" , "NON_WORLD_BLUR", "BLEND", "BLEND_NOWORLD", "BLOOM" ,"BLOOM_NOWORLD" ,"BLUR_NO_EMMISVE", "BLUR_NO_WORLD_NO_EMISSIVE","WEIGHTBLEND_FOR_BLEND" , "DEPTH_STOP" };
const char* pBloomType[] = { "NONE" , "BASIC" , "MUILTY"};
@@ -432,6 +431,22 @@ void CEditEffect::Describe_Entity()
_int iCurrentBloomType = static_cast<_int>(m_EffectInfo.eBloomType);
_int iCurrentPass = static_cast<_int>(m_EffectInfo.eShaderPass);
+
+ GUI::InputTextMultiline("BONE NAME", m_szBuffer, sizeof(m_szBuffer), ImVec2(250, 25));
+
+ m_strBoneName = m_szBuffer;
+
+ if(GUI::Button("Stick Bone"))
+ {
+ CModel* pModel = m_pOwner->Get_Component();
+
+ if (pModel != nullptr)
+ {
+ FollowParants(pModel->Get_BoneMatrixPtr(m_strBoneName.c_str()));
+ }
+
+ }
+
if (ImGui::Combo("Render Order", &iCurrentItem, pRenderNames, ENUM_CLASS(RENDER::END)))
{
m_EffectInfo.eRenderOrder = static_cast(iCurrentItem);
diff --git a/Jusin154_Team3D/Editor/Private/EffectObject.cpp b/Jusin154_Team3D/Editor/Private/EffectObject.cpp
index e28214b90..eede58fa7 100644
--- a/Jusin154_Team3D/Editor/Private/EffectObject.cpp
+++ b/Jusin154_Team3D/Editor/Private/EffectObject.cpp
@@ -715,9 +715,34 @@ HRESULT CEffectObject::LoadPre(const _char* pFilePath, LEVEL eLevel)
}
#endif // _DEBUG
+void CEffectObject::FollowParants(const _float4x4* pParantsMat)
+{
+ if (pParantsMat == nullptr)
+ return;
+
+
+ m_pPerentMatrix = pParantsMat;
+ m_bVisible = true;
+}
+
+
HRESULT CEffectObject::Bind_ShaderResources()
{
+ if (m_pPerentMatrix != nullptr)
+ {
+
+ _matrix socketMatrix = XMLoadFloat4x4(m_pPerentMatrix);
+
+ for (int i = 0; i < 3; ++i) {
+ socketMatrix.r[i] = XMVector3Normalize(socketMatrix.r[i]);
+ }
+ socketMatrix = socketMatrix * m_pParentTransformCom->Get_XMWorldMatrix();
+
+ m_pTransformCom->Set_State(STATE::POSITION, socketMatrix.r[3]);
+ }
+
+
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
return E_FAIL;
diff --git a/Jusin154_Team3D/Editor/Private/EffectPool.cpp b/Jusin154_Team3D/Editor/Private/EffectPool.cpp
index 850d18000..6db712412 100644
--- a/Jusin154_Team3D/Editor/Private/EffectPool.cpp
+++ b/Jusin154_Team3D/Editor/Private/EffectPool.cpp
@@ -16,6 +16,10 @@
#include "DecendoSide.h"
#include "NomalJapSide.h"
+#include "Troll_Rush_Hit.h"
+#include "Troll_Nomal_Smoke.h"
+#include "TrollSwing.h"
+
CEffectPool::CEffectPool(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
: CGameObject(pDevice, pContext)
{
@@ -40,9 +44,11 @@ HRESULT CEffectPool::Initialize(void* pArg)
if (FAILED(Ready_Components()))
return E_FAIL;
- if (FAILED(Ready_Effect()))
- return E_FAIL;
+ //if (FAILED(Ready_Effect()))
+ // return E_FAIL;
+ if (FAILED(Ready_MonsterEffect()))
+ return E_FAIL;
return S_OK;
}
@@ -216,6 +222,40 @@ HRESULT CEffectPool::Ready_Effect()
return S_OK;
}
+HRESULT CEffectPool::Ready_MonsterEffect()
+{
+
+
+ if (FAILED(Create_Effect(SKILL_TYPE::TROLL_ATTACK, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
+
+ CTrollSwing* pEffect = nullptr;
+
+ pEffect = m_pGameInstance->Clone_Prototype(iPrototypeLevel, nullptr);
+
+ return pEffect; }
+ ))) return E_FAIL;
+
+ if (FAILED(Create_Effect(SKILL_TYPE::TROLL_NOMAL_SMOKE, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
+
+ CTroll_Nomal_Smoke* pEffect = nullptr;
+
+ pEffect = m_pGameInstance->Clone_Prototype(iPrototypeLevel, nullptr);
+
+ return pEffect; }
+ ))) return E_FAIL;
+
+ if (FAILED(Create_Effect(SKILL_TYPE::TROLL_RUSH_HIT, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel) -> CEffect_Container* {
+
+ CTroll_Rush_Hit* pEffect = nullptr;
+
+ pEffect = m_pGameInstance->Clone_Prototype(iPrototypeLevel, nullptr);
+
+ return pEffect; }
+ ))) return E_FAIL;
+
+ return S_OK;
+}
+
HRESULT CEffectPool::Use_Skill(SKILL_TYPE eType, CGameObject* pOwner, void* pArg)
{
if (pOwner == nullptr)
diff --git a/Jusin154_Team3D/Editor/Private/Enemy_HpBar.cpp b/Jusin154_Team3D/Editor/Private/Enemy_HpBar.cpp
new file mode 100644
index 000000000..92c48c8aa
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/Enemy_HpBar.cpp
@@ -0,0 +1,350 @@
+#include "pch.h"
+#include "Enemy_HpBar.h"
+#include "GameInstance.h"
+
+CEnemy_HpBar::CEnemy_HpBar(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CElementObject(pDevice, pContext)
+{
+}
+
+CEnemy_HpBar::CEnemy_HpBar(const CEnemy_HpBar& rhs)
+ :CElementObject(rhs)
+{
+}
+
+HRESULT CEnemy_HpBar::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_HpBar::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = 0.f;
+ Desc.fY = 40.f;
+ Desc.fSizeX = 128.f;
+ Desc.fSizeY = 20.f;
+
+ m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fTimeMult = 3.f;
+ m_fAlpha = 0.f;
+ m_fAlphaTime = 10.f;
+ m_vNine_Slice = _float4(15.f, 100.f, 5.f, 15.f);
+ m_fMaxHp = 200.f;
+ m_fCurrentHp = m_fMaxHp;
+ SizeUpX(360.f);
+ m_fMoveSpeed = 5.f;
+ m_bAnimation = false;
+ m_fLerpY = m_fSizeY;
+ return S_OK;
+}
+
+void CEnemy_HpBar::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_HpBar::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bFadeIn == true)
+ {
+ if (m_fAlpha <= 1.f)
+ {
+ m_fAlpha += fTimeDelta * m_fAlphaTime;
+ m_bHover = true;
+ }
+
+
+ if (m_fAlpha >= 1.f)
+ {
+ m_bFadeIn = false;
+ m_fAlpha = 1.f;
+ }
+ }
+
+ if (m_bFadeOut == true)
+ {
+ if (m_fAlpha >= 0.f)
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+
+ if (m_fAlpha <= 0.f)
+ {
+ m_bFadeOut = false;
+ m_bHover = false;
+ m_fAlpha = 0.f;
+ }
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_3))
+ {
+ Lerp_PosX(101.f);
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_K))
+ {
+ Set_FadeIn();
+ }
+ if (m_pGameInstance->Key_Down(DIK_L))
+ {
+ Set_FadeOut();
+ }
+ if (m_pGameInstance->Key_Down(DIK_J))
+ {
+ m_bAnimation = true;
+ m_bHover = true;
+ m_fTime = 0.f;
+ SizeUpdate(m_fLerpX, m_fLerpY);
+ }
+
+ if (m_fCurrentHp < 0.f)
+ m_fCurrentHp = 0.f;
+ if (m_fDamage <= 0.f)
+ m_fDamage = 0.f;
+ m_fTargetHp = m_fMaxHp - m_fDamage;
+
+ if (m_fTargetHp < m_fCurrentHp)
+ Hit(fTimeDelta);
+ m_fHpBar = m_fCurrentHp / m_fMaxHp;
+
+ if (m_fHpBar <= 0.f)
+ {
+ m_bAnimation = true;
+ }
+ if (m_bAnimation == true)
+ {
+ m_fTime += fTimeDelta * m_fTimeMult;
+ m_fSizeX += 3.f;
+ m_fSizeY += 3.f;
+ static_cast(m_pOwner)->Function_Callback(TEXT("Enemy_HpDie"));
+ }
+ if (m_fTime >= 0.9f)
+ {
+ m_bAnimation = false;
+ m_bHover = false;
+ m_fTime = 0.f;
+ SizeUpdate(m_fLerpX, m_fLerpY);
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_HpBar::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ if (m_bVisible) {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_HpBar::Render()
+{
+ if (m_bHover == true)
+ {
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ENEMY_HPBAR)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Bind_Resources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Render())) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+_vector CEnemy_HpBar::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+void CEnemy_HpBar::Lerp_PosX(_float X)
+{
+ m_fDamage += X;
+}
+
+void CEnemy_HpBar::Hit(_float fTimeDelta)
+{
+ m_fCurrentHp = CMyTools::Lerp_f1D(m_fCurrentHp, m_fTargetHp, fTimeDelta * m_fMoveSpeed);
+}
+
+void CEnemy_HpBar::SizeUpX(_float SizeX)
+{
+ m_fSizeX = SizeX;
+ m_fLerpX = SizeX;
+}
+
+void CEnemy_HpBar::Set_Enemt_Info(void* pArg)
+{
+ if(m_bAnimation == true)
+ {
+ return;
+ }
+ //m_fMaxHp
+ //m_fCurrentHp
+ Set_FadeIn();
+}
+
+HRESULT CEnemy_HpBar::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", &m_ViewMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", &m_ProjMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom->Bind_ShaderResource(m_pShaderCom, "g_Texture", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom1->Bind_ShaderResource(m_pShaderCom, "g_Texture1", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom2->Bind_ShaderResource(m_pShaderCom, "g_Texture2", 0)))
+ {
+ 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_fTime", &m_fTime, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAlpha", &m_fAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOwnerAlpha", &m_fOwnerAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCanvasAlpha", &m_fCanvasAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fNine_Slice", &m_vNine_Slice, sizeof(_float4))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOrigin_Size", &m_fOrigin_Size, sizeof(_float2))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCurrent_Size", &m_vScale, sizeof(_float2))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fHp", &m_fHpBar, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_iHover", &m_bAnimation, sizeof(_int))))
+ {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+HRESULT CEnemy_HpBar::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(ENUM_CLASS(LEVEL::UI), TEXT("Prototype_Texture_UI_T_Monster_HpBar"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(ENUM_CLASS(LEVEL::UI), TEXT("Prototype_Texture_UI_T_HUD_Monster_HealthMeterFill"), reinterpret_cast(&m_pDiffuse_TextureCom1), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(ENUM_CLASS(LEVEL::UI), TEXT("Prototype_Texture_VFX_T_FlameNoise_E"), reinterpret_cast(&m_pDiffuse_TextureCom2), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, FX_UIEDITOR, (CComponent**)&m_pShaderCom, nullptr)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+CEnemy_HpBar* CEnemy_HpBar::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_HpBar* pInstance = new CEnemy_HpBar(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_HpBar");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_HpBar::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_HpBar* pInstance = new CEnemy_HpBar(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CSpell_Image");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_HpBar::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pDiffuse_TextureCom);
+ SAFE_RELEASE(m_pDiffuse_TextureCom1);
+ SAFE_RELEASE(m_pDiffuse_TextureCom2);
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+void CEnemy_HpBar::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/Enemy_Info.cpp b/Jusin154_Team3D/Editor/Private/Enemy_Info.cpp
new file mode 100644
index 000000000..541783764
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/Enemy_Info.cpp
@@ -0,0 +1,261 @@
+#include "pch.h"
+#include "Enemy_Info.h"
+#include "GameInstance.h"
+
+CEnemy_Info::CEnemy_Info(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CElementObject(pDevice, pContext)
+{
+}
+
+CEnemy_Info::CEnemy_Info(const CEnemy_Info& rhs)
+ :CElementObject(rhs)
+{
+}
+
+HRESULT CEnemy_Info::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Info::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = -180.f;
+ Desc.fY = 40.f;
+ Desc.fSizeX = 50.f;
+ Desc.fSizeY = 50.f;
+
+ m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fTimeMult = 1.f;
+ m_fAlpha = 0.f;
+ m_fAlphaTime = 10.f;
+ m_fFontX = 952.f;
+ m_fFontY = 39.f;
+ m_fFontPos = _float2(1115.f, 0.f);
+ m_fFont2OffSet = 0.f;
+ m_pEnemy_Name = TEXT("나는 문어");
+ m_pLevel = TEXT("99");
+ m_bAnimation = false;
+ static_cast(m_pOwner)->Add_Function(TEXT("Enemy_HpDie"), [this](void* p) {this->Set_FadeOut(); });
+ return S_OK;
+}
+
+void CEnemy_Info::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_Info::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bFadeIn == true)
+ {
+ if (m_fAlpha <= 1.f)
+ {
+ m_fAlpha += fTimeDelta * m_fAlphaTime;
+ m_bHover = true;
+ }
+
+ if (m_fAlpha >= 1.f)
+ {
+ m_bFadeIn = false;
+ m_fAlpha = 1.f;
+ }
+ }
+
+ if (m_bFadeOut == true)
+ {
+ if (m_fAlpha >= 0.f)
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+
+ if (m_fAlpha <= 0.f)
+ {
+ m_bFadeOut = false;
+ m_bHover = false;
+ m_fAlpha = 0.f;
+ }
+ }
+
+ if (m_pGameInstance->Key_Down(DIK_K))
+ {
+ Set_FadeIn();
+ }
+ if (m_pGameInstance->Key_Down(DIK_L))
+ {
+ Set_FadeOut();
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_Info::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ if (m_bVisible) {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_Info::Render()
+{
+ if (m_bHover == true)
+ {
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::DEFAULT)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Bind_Resources())) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Render())) {
+ return E_FAIL;
+ }
+
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("Font_size20"), m_pEnemy_Name.c_str()) - 29.f) * 0.5f;
+ m_fFont2OffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_pLevel.c_str()) - 13.f) * 0.5f;
+
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), m_pEnemy_Name.c_str(), _float2(m_fFontPos.x + m_fX - m_fFontOffSet, m_fFontPos.y + m_fY), XMVectorSet(1.f* m_fAlpha,1.f* m_fAlpha,1.f* m_fAlpha, m_fAlpha));
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_pLevel.c_str(), _float2(m_fFontX + m_fX - m_fFont2OffSet, m_fFontY + m_fY), XMVectorSet(0.f, (120.f / 255.f)* m_fAlpha, 0.f, m_fAlpha));
+ }
+
+ return S_OK;
+}
+
+_vector CEnemy_Info::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+HRESULT CEnemy_Info::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", &m_ViewMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", &m_ProjMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom->Bind_ShaderResource(m_pShaderCom, "g_Texture", 0)))
+ {
+ 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_fTime", &m_fTime, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAlpha", &m_fAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOwnerAlpha", &m_fOwnerAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCanvasAlpha", &m_fCanvasAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CEnemy_Info::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(ENUM_CLASS(LEVEL::UI), TEXT("Prototype_Texture_UI_T_HealthMeter_LevelBox"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, FX_UIEDITOR, (CComponent**)&m_pShaderCom, nullptr)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+void CEnemy_Info::Set_Info(_int Level, _wstring Name)
+{
+ if (m_bAnimation == true)
+ {
+ return;
+ }
+ m_pLevel = to_wstring(Level);
+ m_pEnemy_Name = Name;
+ Set_FadeIn();
+}
+
+CEnemy_Info* CEnemy_Info::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_Info* pInstance = new CEnemy_Info(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_Info");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_Info::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_Info* pInstance = new CEnemy_Info(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CSpell_Image");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_Info::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pDiffuse_TextureCom);
+
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+void CEnemy_Info::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/Enemy_Panel.cpp b/Jusin154_Team3D/Editor/Private/Enemy_Panel.cpp
new file mode 100644
index 000000000..786190f82
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/Enemy_Panel.cpp
@@ -0,0 +1,161 @@
+#include "pch.h"
+#include "Enemy_Panel.h"
+#include "GameInstance.h"
+#include "Enemy_HpBar.h"
+#include "Enemy_Info.h"
+
+CEnemy_Panel::CEnemy_Panel(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CPanelObject(pDevice, pContext)
+{
+}
+
+CEnemy_Panel::CEnemy_Panel(const CEnemy_Panel& rhs)
+ :CPanelObject(rhs)
+{
+}
+
+HRESULT CEnemy_Panel::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = 960.f;
+ Desc.fY = 50.f;
+ Desc.fSizeX = 960.f;
+ Desc.fSizeY = 150.f;
+
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Element(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fAlpha = 1.f;
+ m_fCanvasAlpha = 1.f;
+ Visible(true);
+ ElementAllVisible(true);
+ return S_OK;
+}
+
+void CEnemy_Panel::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CEnemy_Panel::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ __super::Update(fTimeDelta);
+}
+
+void CEnemy_Panel::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bVisible)
+ {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ __super::Late_Update(fTimeDelta);
+ }
+}
+
+HRESULT CEnemy_Panel::Render()
+{
+ return S_OK;
+}
+
+_vector CEnemy_Panel::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+HRESULT CEnemy_Panel::Bind_ShaderResources()
+{
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CEnemy_Panel::Ready_Element(void* pArg)
+{
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_HpBar))))
+ {
+ return E_FAIL;
+ }
+ Add_Element(TEXT("Enemy_HpBar"), m_pEnemy_HpBar);
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_Info))))
+ {
+ return E_FAIL;
+ }
+ Add_Element(TEXT("Enemy_Info"), m_pEnemy_Info);
+
+ return S_OK;
+}
+
+CEnemy_Panel* CEnemy_Panel::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CEnemy_Panel* pInstance = new CEnemy_Panel(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CEnemy_Panel");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CEnemy_Panel::Clone(void* pArg, CGameObject* pOwner)
+{
+ CEnemy_Panel* pInstance = new CEnemy_Panel(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CEnemy_Panel");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CEnemy_Panel::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+void CEnemy_Panel::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp b/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
index fe9d06fe4..2ebae093f 100644
--- a/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
+++ b/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
@@ -7,6 +7,7 @@
#include "Loading_Panel.h"
#include "Action_Panel.h"
#include "Mouse_Cursor.h"
+#include "Enemy_Panel.h"
CGamePlay_Canvas::CGamePlay_Canvas(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CCanvasObject(pDevice, pContext)
@@ -116,6 +117,11 @@ HRESULT CGamePlay_Canvas::Ready_Panel(void* pArg)
}
Add_Panel(TEXT("ActionPanel"), m_pAction_Panel);
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pEnemy_Panel))))
+ {
+ return E_FAIL;
+ }
+ Add_Panel(TEXT("Enemy_Panel"), m_pEnemy_Panel);
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Goblin.cpp b/Jusin154_Team3D/Editor/Private/Goblin.cpp
index e3cba447f..773e4fe8c 100644
--- a/Jusin154_Team3D/Editor/Private/Goblin.cpp
+++ b/Jusin154_Team3D/Editor/Private/Goblin.cpp
@@ -2,6 +2,7 @@
#include "Goblin.h"
#include "GameInstance.h"
+#include "EditEffect.h"
#pragma region STATE
#include "State_Idle.h"
@@ -36,6 +37,9 @@ HRESULT CGoblin::Initialize(void* pArg)
if (FAILED(Ready_Components()))
return E_FAIL;
+ if (FAILED(Ready_Parts()))
+ return E_FAIL;
+
Add_FSM();
Set_Anim();
@@ -61,11 +65,15 @@ HRESULT CGoblin::Initialize(void* pArg)
void CGoblin::Priority_Update(_float fTimeDelta)
{
+ __super::Priority_Update(fTimeDelta);
+
m_pTransformCom->RewindMomentum();
}
void CGoblin::Update(_float fTimeDelta)
{
+ __super::Update(fTimeDelta);
+
m_pFSM->Update_State(fTimeDelta);
m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
@@ -169,6 +177,50 @@ HRESULT CGoblin::Ready_Components()
return S_OK;
}
+HRESULT CGoblin::Ready_Parts()
+{
+#pragma region EFFECT
+ /* EFFECT */
+
+ CPartObject::PARTOBJECT_DESC PartsDesc{};
+
+ PartsDesc.pParentTransform = m_pTransformCom;
+
+
+
+ if (FAILED(Add_PartObject("Goblin_Particle", ENUM_CLASS(LEVEL::EFFECT), &m_pTroll_Particle, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pTroll_Particle->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle", static_cast(NEXT_LEVEL));
+ m_pTroll_Particle->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+
+ if (FAILED(Add_PartObject("Goblin_Particle2", ENUM_CLASS(LEVEL::EFFECT), &m_pTroll_Particle2, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pTroll_Particle2->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Particle2", static_cast(NEXT_LEVEL));
+ m_pTroll_Particle2->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightShoulder"));
+
+
+ if (FAILED(Add_PartObject("Goblin_Smoke", ENUM_CLASS(LEVEL::EFFECT), &m_pRight_Smoke, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pRight_Smoke->Load("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Smoke", static_cast(NEXT_LEVEL));
+ m_pRight_Smoke->FollowParants(m_pModelCom->Get_BoneMatrixPtr("Spine2"));
+
+
+#pragma endregion
+ return S_OK;
+}
+
+
HRESULT CGoblin::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
@@ -226,8 +278,37 @@ void CGoblin::Free()
SAFE_RELEASE(m_pRigidBody);
Safe_Delete(m_pCallBack_Behavior);
Safe_Delete(m_pCallBack_HitReport);
+
+ SAFE_RELEASE(m_pTroll_Particle);
+ SAFE_RELEASE(m_pTroll_Particle2);
+ SAFE_RELEASE(m_pRight_Smoke);
+ SAFE_RELEASE(m_pLeft_Smoke);
}
void CGoblin::Describe_Entity()
{
+ for (auto& pComponent : m_Components)
+ {
+ if (GUI::TreeNode(typeid(*pComponent).name()))
+ {
+ pComponent->Describe_Entity();
+
+ GUI::TreePop();
+ }
+ }
+
+ _uint iIndex = {};
+
+ for (auto& pParts : m_PartObjects)
+ {
+ _string strName = to_string(iIndex++) + " : " + typeid(*pParts.second).name();
+
+ if (GUI::TreeNode(strName.c_str()))
+ {
+ pParts.second->Describe_Entity();
+
+ GUI::TreePop();
+ }
+ }
+
}
diff --git a/Jusin154_Team3D/Editor/Private/Goblin_Protego.cpp b/Jusin154_Team3D/Editor/Private/Goblin_Protego.cpp
new file mode 100644
index 000000000..23d3b8844
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/Goblin_Protego.cpp
@@ -0,0 +1,202 @@
+#include "pch.h"
+#include "Goblin_Protego.h"
+
+#include "GameInstance.h"
+#include "EditEffect.h"
+
+
+CGoblin_Protego::CGoblin_Protego(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CEffect_Container{ pDevice, pContext }
+{
+}
+
+CGoblin_Protego::CGoblin_Protego(const CGoblin_Protego& rhs)
+ : CEffect_Container(rhs)
+{
+}
+
+HRESULT CGoblin_Protego::Initialize_Prototype()
+{
+
+ return S_OK;
+
+}
+
+HRESULT CGoblin_Protego::Initialize(void* pArg)
+{
+ if (FAILED(__super::Initialize(pArg)))
+ return E_FAIL;
+
+ if (FAILED(Ready_Components(pArg)))
+ return E_FAIL;
+
+ if (FAILED(Load_Package("../Bin/Resources/Data/Effect/MonsterPackage/GoblinProtego")))
+ return E_FAIL;
+
+ m_pSphere = Get_PartObject("ProtegoSphere");
+ m_pBottom = Get_PartObject("ProtegoBottom");
+ m_pCircle = Get_PartObject("ProtegoCircle");
+
+ SAFE_ADDREF(m_pSphere);
+ SAFE_ADDREF(m_pBottom);
+ SAFE_ADDREF(m_pCircle);
+
+ m_wstrEffectName = L"Goblin_Protego";
+
+
+ m_fAmountSize = 0.1f;
+ m_fSpeed = 5.f;
+
+ m_fDuration = 3.f;
+
+ return S_OK;
+}
+
+void CGoblin_Protego::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+
+}
+
+void CGoblin_Protego::Update(_float fTimeDelta)
+{
+ if (m_bVisible == false)
+ return;
+
+ m_pSphere->Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+ m_pBottom->Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+ m_pCircle-> Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+
+ __super::Update(fTimeDelta);
+
+ Update_Event(fTimeDelta);
+
+
+
+ /* 시작 사이즈 러프 */
+ if (m_fSizeAccTime > XM_PIDIV2)
+ return;
+
+ m_fSizeAccTime += fTimeDelta * m_fSpeed;
+
+ _float fSize = 1 + sinf(m_fSizeAccTime) * m_fAmountSize;
+ _float3 vSize = _float3(fSize, fSize, fSize);
+
+ m_pSphere->Get_Component()->Set_Scale(vSize);
+ m_pCircle->Get_Component()->Set_Scale(vSize);
+}
+
+void CGoblin_Protego::Late_Update(_float fTimeDelta)
+{
+ if (m_bVisible == false)
+ return;
+
+ __super::Late_Update(fTimeDelta);
+
+
+}
+
+HRESULT CGoblin_Protego::Pre_Setting(CGameObject* pObject, void* pArg)
+{
+ if (FAILED(__super::Pre_Setting(pObject, nullptr)))
+ return E_FAIL;
+
+ m_pSphere->Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+ m_pBottom->Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+ m_pCircle->Get_Component()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
+
+ m_pSphere->Set_Visible(true);
+ m_pCircle->Set_Visible(true);
+ m_pBottom->Set_Visible(true);
+
+
+ _float3 vSize = _float3(1.f, 1.f, 1.f);
+ m_pSphere->Get_Component()->Set_Scale(vSize);
+ m_pCircle->Get_Component()->Set_Scale(vSize);
+
+ m_fSizeAccTime = 0.f;
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Protego::Ready_Components(void* pArg)
+{
+ if (FAILED(__super::Ready_Components(pArg))) {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Protego::Ready_Child()
+{
+ return S_OK;
+}
+
+CGoblin_Protego* CGoblin_Protego::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Protego* pInstance = new CGoblin_Protego(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Protego");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+
+CGameObject* CGoblin_Protego::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Protego* pInstance = new CGoblin_Protego(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Protego");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CGoblin_Protego::OnCollision(CGameObject* pOther, void* pDesc)
+{
+ //CTransform* pOtherTransform = p
+ ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
+
+}
+
+void CGoblin_Protego::Free()
+{
+ __super::Free();
+
+ //if(m_pPhysHitBox != nullptr)
+ // if (m_pPhysHitBox->Get_Depth() == false)
+ // SAFE_RELEASE(m_pPhysHitBox);
+
+ SAFE_RELEASE(m_pSphere);
+ SAFE_RELEASE(m_pBottom);
+ SAFE_RELEASE(m_pCircle);
+
+}
+#ifdef _DEBUG
+
+void CGoblin_Protego::Describe_Entity()
+{
+ GUI::Begin("PROTEGO");
+
+ GUI::DragFloat("fAmountSize" ,&m_fAmountSize);
+ GUI::DragFloat("fSpeed" , &m_fSpeed);
+
+ GUI::End();
+}
+
+#endif // _DEBUG
+
+HRESULT CGoblin_Protego::Bind_ShaderResources()
+{
+ return S_OK;
+}
+
+
diff --git a/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp b/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
index c5ddcdc85..c433af4f4 100644
--- a/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
+++ b/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
@@ -187,6 +187,7 @@ void CIMGUIUI::Update(_float fTimeDelta)
m_iSpellType = static_cast(m_pElementObject)->Get_SkillType();
m_iSkillType = static_cast(m_pElementObject)->Get_SpellType();
m_fCoolTime = static_cast(m_pElementObject)->Get_CoolTime();
+ m_fFontPos = static_cast(m_pElementObject)->Get_Font();
}
GUI::Begin("Current_CanvasObject_Info");
if (m_pUI_Manager != nullptr)
@@ -482,6 +483,17 @@ void CIMGUIUI::Update(_float fTimeDelta)
{
static_cast(m_pElementObject)->Set_CoolTime(m_fCoolTime);
}
+
+ GUI::Text("FontPosX %.1f", m_fFontPos.x);
+ GUI::Text("FontPosY %.1f", m_fFontPos.y);
+ if (GUI::SliderFloat("FontX", &m_fFontX, -1920.f, 1920.f))
+ {
+ static_cast(m_pElementObject)->Set_FontX(m_fFontX);
+ }
+ if (GUI::SliderFloat("FontY", &m_fFontY, -1080.f, 1080.f))
+ {
+ static_cast(m_pElementObject)->Set_FontY(m_fFontY);
+ }
}
GUI::End();
}
diff --git a/Jusin154_Team3D/Editor/Private/Level_EffectViewer.cpp b/Jusin154_Team3D/Editor/Private/Level_EffectViewer.cpp
index 76ad4faff..9fd2eb7b0 100644
--- a/Jusin154_Team3D/Editor/Private/Level_EffectViewer.cpp
+++ b/Jusin154_Team3D/Editor/Private/Level_EffectViewer.cpp
@@ -18,6 +18,7 @@
#include "InfoInstance.h"
#include "Goblin.h"
#include "Terrain.h"
+#include "Troll.h"
CLevel_EffectViewer::CLevel_EffectViewer(ID3D11Device* pDevice, ID3D11DeviceContext* pContext, LEVEL eLevelID)
: CLevel{ pDevice, pContext, ENUM_CLASS(eLevelID) }
@@ -45,7 +46,16 @@ HRESULT CLevel_EffectViewer::Initialize()
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Terrain"))))
+ CTerrain::TERRAIN_DESC Desc = {};
+ /* Hogsmeade */
+
+ Desc.isEdit = false;
+ Desc.iAlphaSizeX = 2048;
+ Desc.iAlphaSizeY = 2048;
+ Desc.vPosition = _float3(-194, 18.5f, -153.f);
+ Desc.strBufferTag = TEXT("Prototype_Component_VIBuffer_Terrain_Hogsmeade");
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Terrain"), &Desc)))
return E_FAIL;
@@ -70,14 +80,17 @@ HRESULT CLevel_EffectViewer::Initialize()
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Monster"))))
return E_FAIL;
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Monster"))))
+ return E_FAIL;
+
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_Sky")))){
return E_FAIL;
}
- ZeroMemory(&m_PlaneData, sizeof(m_PlaneData));
- m_PlaneData.eKind = PHYSX_KIND::BODY_STATIC;
- m_PlaneData.iSubKind = ENUM_CLASS(PXOBJECT::TERRAIN);
- m_pGameInstance->Add_Editor_Plane(m_PlaneData);
+ //ZeroMemory(&m_PlaneData, sizeof(m_PlaneData));
+ //m_PlaneData.eKind = PHYSX_KIND::BODY_STATIC;
+ //m_PlaneData.iSubKind = ENUM_CLASS(PXOBJECT::TERRAIN);
+ //m_pGameInstance->Add_Editor_Plane(m_PlaneData);
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Loader.cpp b/Jusin154_Team3D/Editor/Private/Loader.cpp
index 7f6c426f1..b0150972c 100644
--- a/Jusin154_Team3D/Editor/Private/Loader.cpp
+++ b/Jusin154_Team3D/Editor/Private/Loader.cpp
@@ -51,6 +51,10 @@
#include "GamePlay_Canvas.h"
+#include "Enemy_Panel.h"
+#include "Enemy_HpBar.h"
+#include "Enemy_Info.h"
+
#include "Mission_Panel.h"
#include "MissionBanner_Border.h"
#include "MissionBanner_Key.h"
@@ -139,6 +143,13 @@
#include "DecendoSide.h"
#include "NomalJapSide.h"
+#include "TrollSwing.h"
+#include "Troll_Nomal_Smoke.h"
+#include "Troll_Rush_Hit.h"
+
+#include "Troll.h"
+#include "Troll_Rock.h"
+#include "Troll_Weapon.h"
#pragma endregion
#pragma region PHYSX_HEADER
@@ -888,6 +899,19 @@ HRESULT CLoader::Loading_For_UI()
return E_FAIL;
}
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_Panel::Create(m_pDevice, m_pContext))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_HpBar::Create(m_pDevice, m_pContext))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CEnemy_Info::Create(m_pDevice, m_pContext))))
+ {
+ return E_FAIL;
+ }
+
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CLoading_Panel::Create(m_pDevice, m_pContext))))
{
return E_FAIL;
@@ -1312,9 +1336,22 @@ HRESULT CLoader::Loading_For_Effect()
Safe_Delete(pResult);
}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Weapon_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Object/SubTroll_Weapon/SK_WPN_Troll_Club07.fbx", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Troll_Rock_Big_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::NONANIM, "../Bin/Resources/Models/Object/Troll_Rock/Troll_Rock_Big.bin", XMMatrixScaling(0.00004f, 0.00004f, 0.00004f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
+
{
CVIBuffer_Terrain* pTerrain = CVIBuffer_Terrain::Create(m_pDevice, m_pContext, "Hogsmeade_HeightMap.bin", 512, 512);
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_VIBuffer_Terrain"), pTerrain))) {
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_VIBuffer_Terrain_Hogsmeade"), pTerrain))) {
return E_FAIL;
}
pTerrain->ConvertToHeightField(TEXT("Hogsmeade_HeightMap"));
@@ -1390,6 +1427,17 @@ HRESULT CLoader::Loading_For_Effect()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin::Create(m_pDevice, m_pContext))))
return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CTroll::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CTroll_Rock::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CTroll_Weapon::Create(m_pDevice, m_pContext))))
+ return E_FAIL;
+
+
/* For.Prototype_GameObject_DummySkyBox */
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CDummySkyBox::Create(m_pDevice, m_pContext))))
return E_FAIL;
@@ -1425,6 +1473,15 @@ HRESULT CLoader::Loading_For_Effect()
return E_FAIL;
}
+ if (FAILED(m_pGameInstance->Add_Prototype(NEXT_LEVEL, CTrollSwing::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Prototype(NEXT_LEVEL, CTroll_Nomal_Smoke::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Prototype(NEXT_LEVEL, CTroll_Rush_Hit::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
/* For.Prototype_GameObject_Wand */
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CWand::Create(m_pDevice, m_pContext))))
@@ -1468,7 +1525,6 @@ HRESULT CLoader::Loading_For_Effect()
-
m_strMessage = TEXT("Loading Success!");
m_isFinished = true;
@@ -1740,6 +1796,7 @@ HRESULT CLoader::Loading_For_Bloom()
TEXT("Prototype_Component_SubTroll_Model")
));
+
#pragma endregion
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Desc_Box"),
CModel::Create(m_pDevice, m_pContext, MODEL::NONANIM, "../Bin/Resources/Models/Box/Box.bin", XMMatrixScaling(10.f, 10.f, 10.f) * XMMatrixIdentity())))) {
@@ -1972,10 +2029,11 @@ HRESULT CLoader::Loading_For_ObjectViewer()
m_strMessage = TEXT("Model Loading..");
- /*if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_SK_GenericDarkWizard_14_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::ANIM_LOCAL, "C:/MeshTable\\Game\\RiggedObjects\\Characters\\Human\\Body\\Generic_M\\SK_GenericDarkWizard_14.fbx", XMMatrixIdentity())))) {
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_SK_WPN_GOB_SmallSword_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM_LOCAL, "C:/MeshTable\\Game\\RiggedObjects\\Props\\Weapons\\Goblins\\SK_WPN_GOB_SmallSword.fbx", XMMatrixIdentity())))) {
return E_FAIL;
- }*/
+ }
// Heavy Wall
CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
@@ -2007,6 +2065,16 @@ HRESULT CLoader::Loading_For_ObjectViewer()
}
vector*>> futures = {};
+ futures.emplace_back(Deferred_ModelLoad(
+ MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll.bin", XMMatrixIdentity(),
+ TEXT("Prototype_Component_troll_Model")
+ ));
+
+ //futures.emplace_back(Deferred_ModelLoad(
+ // MODEL::ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll_Anim.fbx", XMMatrixIdentity(),
+ // TEXT("Prototype_Component_troll_Model")
+ //));
+
#pragma region BODY
futures.emplace_back(Deferred_ModelLoad(
@@ -2085,6 +2153,20 @@ HRESULT CLoader::Loading_For_ObjectViewer()
TEXT("Prototype_Component_Goblin_Model")
));
+ futures.emplace_back(Deferred_ModelLoad(
+ MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin_Mage/GoblinMage.bin", XMMatrixRotationY(XMConvertToRadians(180.f))* XMMatrixIdentity(),
+ TEXT("Prototype_Component_GoblinMage_Model")
+ ));
+
+ //futures.emplace_back(Deferred_ModelLoad(
+ // MODEL::ANIM, "../Bin/Resources/Models/Monster/GoblinSpector/SK_GOB_M_Specter_Master.bin", XMMatrixRotationY(XMConvertToRadians(180.f))* XMMatrixIdentity(),
+ // TEXT("Prototype_Component_SK_GOB_M_Specter_Master_Model")
+ //));
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GoblinSpector_Anim_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector_Anim.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
+
futures.emplace_back(Deferred_ModelLoad(
MODEL::ANIM, "../Bin/Resources/Models/Monster/TombProtector/TombProtector.bin", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixIdentity(),
TEXT("Prototype_Component_TombProtector_Model")
@@ -2101,6 +2183,11 @@ HRESULT CLoader::Loading_For_ObjectViewer()
#pragma endregion
+ futures.emplace_back(Deferred_ModelLoad(
+ MODEL::ANIM, "../Bin/Resources/Models/Monster/SubTroll/troll_Anim.fbx", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f)* XMMatrixIdentity(),
+ TEXT("Prototype_Component_SubTroll_Model")
+ ));
+
futures.emplace_back(Deferred_ModelLoad(
MODEL::ANIM, "../Bin/Resources/Models/Object/Troll_Weapon/Troll_Weapon.bin", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixIdentity(),
TEXT("Prototype_Component_Troll_Weapon_Model")
@@ -2158,6 +2245,7 @@ HRESULT CLoader::Loading_For_ObjectViewer()
Safe_Delete(pResult);
}
+
m_strMessage = TEXT("Shader Loading..");
m_strMessage = TEXT("Prototype Loading..");
diff --git a/Jusin154_Team3D/Editor/Private/Logo.cpp b/Jusin154_Team3D/Editor/Private/Logo.cpp
index a781aa041..8e45de98b 100644
--- a/Jusin154_Team3D/Editor/Private/Logo.cpp
+++ b/Jusin154_Team3D/Editor/Private/Logo.cpp
@@ -72,6 +72,7 @@ HRESULT CLogo::Render()
if (FAILED(m_pVIBufferCom->Render())) {
return E_FAIL;
}
+ m_pGameInstance->Render_Text(TEXT("Font_size13"), TEXT("Font_Test"), _float2(0.f, 0.f));
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Magic_Item.cpp b/Jusin154_Team3D/Editor/Private/Magic_Item.cpp
index beefb262a..56307c4b4 100644
--- a/Jusin154_Team3D/Editor/Private/Magic_Item.cpp
+++ b/Jusin154_Team3D/Editor/Private/Magic_Item.cpp
@@ -47,6 +47,10 @@ HRESULT CMagic_Item::Initialize(void* pArg)
m_iArratCount = 2;
Compute_UV(0);
Compute_Image();
+ m_fFontX = 1171.f;
+ m_fFontY = 870.f;
+ m_iPotionIndex = 0;
+ m_iPerPotionIndex = -1;
return S_OK;
}
@@ -137,6 +141,13 @@ void CMagic_Item::Update(_float fTimeDelta)
m_vUVScale.y += fTimeDelta * (1.f / m_fCoolTime);
}
+ if (m_iPerPotionIndex != m_iPotionIndex)
+ {
+ m_strPotion = to_wstring(m_iPotionIndex);
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_strPotion.c_str()) - 13.f) * 0.5f;
+ m_iPerPotionIndex = m_iPotionIndex;
+ }
+
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
}
@@ -173,6 +184,9 @@ HRESULT CMagic_Item::Render()
return E_FAIL;
}
+
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_strPotion.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((208.f / 255.f) * m_fAlpha, (177.f / 255.f) * m_fAlpha, (52.f / 255.f)* m_fAlpha, m_fAlpha));
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/MainApp.cpp b/Jusin154_Team3D/Editor/Private/MainApp.cpp
index d44d6ef57..89d201689 100644
--- a/Jusin154_Team3D/Editor/Private/MainApp.cpp
+++ b/Jusin154_Team3D/Editor/Private/MainApp.cpp
@@ -83,6 +83,27 @@ void CMainApp::Compute_FrameCount()
HRESULT CMainApp::Ready_Default_Setting()
{
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size13"), TEXT("../Bin/Resources/Fonts/Font_size13.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size14"), TEXT("../Bin/Resources/Fonts/Font_size14.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size15"), TEXT("../Bin/Resources/Fonts/Font_size15.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size20"), TEXT("../Bin/Resources/Fonts/Font_size20.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size21"), TEXT("../Bin/Resources/Fonts/Font_size21.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("Font_size30"), TEXT("../Bin/Resources/Fonts/Font_size30.spritefont"))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Font(TEXT("UI_size15"), TEXT("../Bin/Resources/Fonts/UI_size15.spritefont"))))
+ return E_FAIL;
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Monster.cpp b/Jusin154_Team3D/Editor/Private/Monster.cpp
index 0c427ed3f..5132f867a 100644
--- a/Jusin154_Team3D/Editor/Private/Monster.cpp
+++ b/Jusin154_Team3D/Editor/Private/Monster.cpp
@@ -2,6 +2,7 @@
#include "Monster.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
#include "Player.h"
CMonster::CMonster(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
@@ -10,7 +11,8 @@ CMonster::CMonster(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
}
CMonster::CMonster(const CMonster& Prototype)
- : CUnit(Prototype)
+ : CUnit(Prototype),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
@@ -21,59 +23,171 @@ HRESULT CMonster::Initialize_Prototype()
HRESULT CMonster::Initialize(void* pArg)
{
- if (FAILED(__super::Initialize(pArg)))
+ if (FAILED(__super::Initialize(pArg))) {
return E_FAIL;
+ }
- //m_pPlayerTransform = static_cast(pArg)->Get_Component();
- //SAFE_ADDREF(m_pPlayerTransform);
+ m_pInfoInstance->Regist_ActiveMonster(this);
return S_OK;
}
void CMonster::Priority_Update(_float fTimeDelta)
{
-
+ m_pTransformCom->RewindMomentum();
+ __super::Priority_Update(fTimeDelta);
}
void CMonster::Update(_float fTimeDelta)
{
-
+ _vector vCurrentPos = Get_WorldPostion();
+ pair pairTarget = m_pInfoInstance->Get_NearestPlayerAlly(vCurrentPos);
+ if (nullptr != pairTarget.first) {
+ Set_Target(*pairTarget.first, *pairTarget.second);
+ }
+ if (nullptr != m_pTarget && m_pTarget->isDead()) {
+ SAFE_RELEASE(m_pTarget);
+ m_fTargetDistance = { FLT_MAX };
+ }
+ __super::Update(fTimeDelta);
}
void CMonster::Late_Update(_float fTimeDelta)
{
- //m_fTargetDistance = m_pTransformCom->TargetDis(m_pPlayerTransform->Get_State(STATE::POSITION));
+ __super::Late_Update(fTimeDelta);
}
-HRESULT CMonster::Render()
+HRESULT CMonster::Render_OutLine()
{
+ m_bDrawOutLine = false;
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ GUI::SetNextItemWidth(80.f);
+ static _float3 vOutLineColor = _float3(1.f, 0.960784376f, 0.933333397f);
+ static _float fOutLineThickness = { 5.f }; // 카메라로부터 거리가 멀어지면 늘어나게끔 바꾸는걸 추천함
+ static _float fOutLineScale = { 1.f };
+ static _float fOutLinePower = { 1.f };
+ GUI::ColorPicker3("vOutLineColor", (_float*)&vOutLineColor);
+ GUI::SliderFloat("Thickness", &fOutLineThickness, 0.1f, 2.f, "%.1f");
+ GUI::SliderFloat("Scale", &fOutLineScale, 0.1f, 2.f, "%.1f");
+ GUI::SliderFloat("Power", &fOutLinePower, 0.1f, 2.f, "%.1f");
+ Compute_Depth();
+ _float fRatio = (m_fCamDepth / *m_pGameInstance->Get_CurrentCameraFar());
+ fOutLineThickness = CMyTools::Lerp_f1D(2.f, 6.f, fRatio);
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_vOutLineColor", &vOutLineColor, sizeof(_float3)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineThickness", &(fOutLineThickness), sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineScale", &(fOutLineScale), sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLinePower", &(fOutLinePower), sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_vCamPosition", m_pGameInstance->Get_CamPosition(), sizeof(_float4)))) {
+ 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))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::OUTLINE_READ)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
return S_OK;
}
-HRESULT CMonster::Ready_Components(void*pArg)
+void CMonster::Set_DrawOutLine()
+{
+ m_bDrawOutLine = true;
+}
+
+_bool CMonster::Get_Damage(_float fDamage)
+{
+ return m_pStat->Get_Damage(fDamage);
+}
+
+_float2 CMonster::Get_Hp()
+{
+ return { m_pStat->Get_Stat(ENUM_CLASS(STAT::HP)), m_pStat->Get_Stat(ENUM_CLASS(STAT::MAXHP)) };
+}
+
+HRESULT CMonster::Ready_Components(void* pArg)
{
__super::Ready_Components(pArg);
/* Com_Shader */
if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_ANIMMESH,
- reinterpret_cast(&m_pShaderCom))))
+ reinterpret_cast(&m_pShaderCom)))) {
return E_FAIL;
+ }
return S_OK;
}
-HRESULT CMonster::Bind_ShaderResources()
+void CMonster::Set_Target(CUnit& pTarget, CTransform& pTransform)
{
- return S_OK;
+ SAFE_RELEASE(m_pTarget);
+ m_pTarget = &pTarget;
+ SAFE_ADDREF(m_pTarget);
+
+ _vector vTargetPos = pTransform.Get_State(STATE::POSITION);
+ _vector vToTargetDir = vTargetPos - Get_WorldPostion();
+ XMStoreFloat4(&m_vTargetPos, vTargetPos);
+ XMStoreFloat3(&m_vToTargetDir, XMVector3Normalize(vToTargetDir));
+ m_fTargetDistance = XMVectorGetX(XMVector3Length(vToTargetDir));
}
void CMonster::Free()
{
__super::Free();
- SAFE_RELEASE(m_pPlayerTransform);
+ SAFE_RELEASE(m_pStat);
+ SAFE_RELEASE(m_pTarget);
+ if (nullptr != m_pInfoInstance) {
+ CInfoInstance* pInfo = m_pInfoInstance;
+ m_pInfoInstance = nullptr;
+ pInfo->Deregist_ActiveMonster(this);
+ }
}
+#ifdef _DEBUG
void CMonster::Describe_Entity()
{
+ _bool isToggle = { true };
+
+ if (ImGui::TreeNode("ANIM STATE")) {
+
+ for (auto& pState : m_States)
+ {
+ if (ImGui::Button(to_string(pState.first).c_str()))
+ {
+ m_pFSM->Change_State(pState.first);
+ }
+
+ }
+
+ GUI::Text(to_string(m_pModelCom->Get_CurrentTrackProgressRatio()).c_str());
+
+ ImGui::TreePop();
+ }
}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Editor/Private/Player.cpp b/Jusin154_Team3D/Editor/Private/Player.cpp
index e446ce8c8..67a100789 100644
--- a/Jusin154_Team3D/Editor/Private/Player.cpp
+++ b/Jusin154_Team3D/Editor/Private/Player.cpp
@@ -284,7 +284,6 @@ HRESULT CPlayer::Ready_Components()
if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_CCT_CAPSULE"), (CComponent**)&m_pCharacter_Controller, &Desc))) {
return E_FAIL;
}
- m_pCharacter_Controller->SetGravity(false);
}
{ // DO
diff --git a/Jusin154_Team3D/Editor/Private/Potion.cpp b/Jusin154_Team3D/Editor/Private/Potion.cpp
index 8005fa92f..dc8502e44 100644
--- a/Jusin154_Team3D/Editor/Private/Potion.cpp
+++ b/Jusin154_Team3D/Editor/Private/Potion.cpp
@@ -40,8 +40,12 @@ HRESULT CPotion::Initialize(void* pArg)
m_fTimeMult = 3.f;
m_fAlpha = 1.f;
m_fAlphaTime = 1.f;
- m_vImageSlotPos = _float2(45.f,45.f);
- m_vImageSize = _float2(32.f,32.f);
+ m_vImageSlotPos = _float2(45.f, 45.f);
+ m_vImageSize = _float2(32.f, 32.f);
+ m_fFontX = 1163.f;
+ m_fFontY = 860.f;
+ m_iPotionIndex = 0;
+ m_iPerPotionIndex = -1;
return S_OK;
}
@@ -92,6 +96,13 @@ void CPotion::Update(_float fTimeDelta)
}
+ if (m_iPerPotionIndex != m_iPotionIndex)
+ {
+ m_strPotion = to_wstring(m_iPotionIndex);
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("UI_size15"), m_strPotion.c_str()) - 13.f) * 0.5f;
+ m_iPerPotionIndex = m_iPotionIndex;
+ }
+
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
@@ -124,6 +135,8 @@ HRESULT CPotion::Render()
return E_FAIL;
}
+ m_pGameInstance->Render_Text(TEXT("UI_size15"), m_strPotion.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((208.f / 255.f) * m_fAlpha, (177.f / 255.f) * m_fAlpha, (52.f / 255.f)* m_fAlpha, m_fAlpha));
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Protego.cpp b/Jusin154_Team3D/Editor/Private/Protego.cpp
index 5b189510c..2ab5a7648 100644
--- a/Jusin154_Team3D/Editor/Private/Protego.cpp
+++ b/Jusin154_Team3D/Editor/Private/Protego.cpp
@@ -30,7 +30,6 @@ HRESULT CProtego::Initialize(void* pArg)
if (FAILED(Ready_Components(pArg)))
return E_FAIL;
-
if (FAILED(Load_Package("../Bin/Resources/Data/Effect/Package/Protego")))
return E_FAIL;
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Anim.cpp b/Jusin154_Team3D/Editor/Private/Spell_Anim.cpp
index b283adec6..2fbcf87d7 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Anim.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Anim.cpp
@@ -104,6 +104,11 @@ void CSpell_Anim::Update(_float fTimeDelta)
m_iCurrentFrame = 0;
}
+ if (m_iPerSpell != -1)
+ {
+ m_fY = m_fOrigin_Position.y + static_cast(m_pOwner)->Get_Info(m_iPerSpell).fVidio;
+ }
+
__super::Update(fTimeDelta);
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Data.cpp b/Jusin154_Team3D/Editor/Private/Spell_Data.cpp
index 2d61fc8c4..20157c07d 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Data.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Data.cpp
@@ -51,16 +51,22 @@ HRESULT CSpell_Data::Initialize(void* pArg)
pInfo[id].pSpell_Name = CMyTools::ToWstring(pSpell->Attribute("Spell_Name"));
pInfo[id].pImage_Name = CMyTools::ToWstring(pSpell->Attribute("Image_Name"));
pSpell->QueryIntAttribute("Spell_Type", &pInfo[id].iSpell_Type);
+ pInfo[id].pType_Name = CMyTools::ToWstring(pSpell->Attribute("Type_Name"));
pSpell->QueryIntAttribute("Skill_Type", &pInfo[id].iSkill_Type);
+ pSpell->QueryFloatAttribute("Spell_Damage", &pInfo[id].fSpell_Damage);
pSpell->QueryFloatAttribute("Spell_Cooltime", &pInfo[id].fSpell_CoolTime);
pSpell->QueryFloatAttribute("Duration", &pInfo[id].fDuration);
pSpell->QueryIntAttribute("AnimNum", &pInfo[id].iAnimNum);
pInfo[id].pSpellInfo = CMyTools::ToWstring(pSpell->Attribute("SpellInfo"));
- int lock = 0, equip = 0;
+ _int lock = 0, equip = 0, use = 0;
pSpell->QueryIntAttribute("Spell_Lock", &lock);
pSpell->QueryIntAttribute("Equip_Spell", &equip);
+ pSpell->QueryIntAttribute("Use_Skill", &use);
pInfo[id].bSpell_Lock = lock != 0;
pInfo[id].bEquip_Spell = equip != 0;
+ pInfo[id].bUse_Skill = use != 0;
+ pSpell->QueryFloatAttribute("Preview", &pInfo[id].fPreview);
+ pSpell->QueryFloatAttribute("Vidio", &pInfo[id].fVidio);
pSpell = pSpell->NextSiblingElement("Spell");
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Header.cpp b/Jusin154_Team3D/Editor/Private/Spell_Header.cpp
index 190672a47..793d83cf4 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Header.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Header.cpp
@@ -24,7 +24,7 @@ HRESULT CSpell_Header::Initialize(void* pArg)
Desc.fX = 600.f;
Desc.fY = -385.f;
Desc.fSizeX = 512.f;
- Desc.fSizeY = 64.f;
+ Desc.fSizeY = 80.f;
m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
@@ -46,6 +46,10 @@ HRESULT CSpell_Header::Initialize(void* pArg)
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
+ m_fFontX = 920.f;
+ m_fFontY = 510.f;
+ m_fType = _float2(935.f, 550.f);
+ m_iPerSpellIndex = -1;
return S_OK;
}
@@ -69,6 +73,7 @@ void CSpell_Header::Update(_float fTimeDelta)
if (m_fAlpha <= 1.f)
{
m_fAlpha += fTimeDelta * m_fAlphaTime;
+ m_bHover = true;
}
if (m_fAlpha >= 1.f)
@@ -81,18 +86,24 @@ void CSpell_Header::Update(_float fTimeDelta)
if (m_bFadeOut == true)
{
if (m_fAlpha >= 0.f)
- m_fAlpha -= fTimeDelta * m_fAlphaTime;;
+ {
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+ }
if (m_fAlpha <= 0.f)
{
m_bFadeOut = false;
m_fAlpha = 0.f;
+ m_bHover = false;
}
}
- if (m_iSpellType != -1)
+ if (m_iSpellType != -1 && m_iPerSpellIndex != m_iSpellType)
{
m_iSkillType = static_cast(m_pOwner)->Get_Info(m_iSpellType).iSpell_Type;
+ m_pSpell_Name = static_cast(m_pOwner)->Get_Info(m_iSpellType).pSpell_Name;
+ m_fSpell_Type = static_cast(m_pOwner)->Get_Info(m_iSpellType).pType_Name;
+ m_iPerSpellIndex = m_iSpellType;
}
m_fTime += fTimeDelta * m_fTimeMult;
@@ -126,6 +137,11 @@ HRESULT CSpell_Header::Render()
return E_FAIL;
}
+
+ m_fFontOffSet = (m_pGameInstance->FontSizeX(TEXT("Font_size20"), m_pSpell_Name.c_str()) - 53.f) * 0.5f;
+ m_pGameInstance->Render_Text(TEXT("Font_size20"), m_pSpell_Name.c_str(), _float2((m_fFontX + m_fX) - m_fFontOffSet, m_fFontY + m_fY), XMVectorSet((215.f / 255.f) * m_fAlpha, (185.f / 255.f) * m_fAlpha, (95.f / 255.f) * m_fAlpha, m_fAlpha));
+ m_pGameInstance->Render_Text(TEXT("Font_size13"), m_fSpell_Type.c_str(), _float2(m_fType.x + m_fX, m_fType.y + m_fY), XMVectorSet(1.f * m_fAlpha, 1.f * m_fAlpha, 1.f * m_fAlpha, m_fAlpha));
+
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Header_Line.cpp b/Jusin154_Team3D/Editor/Private/Spell_Header_Line.cpp
index 6810ed202..a9e1fa2a9 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Header_Line.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Header_Line.cpp
@@ -22,7 +22,7 @@ HRESULT CSpell_Header_Line::Initialize(void* pArg)
CUIObject::UIOBJECT_DESC Desc{};
Desc.fX = 600.f;
- Desc.fY = -345.f;
+ Desc.fY = -340.f;
Desc.fSizeX = 487.f;
Desc.fSizeY = 18.f;
m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Preview.cpp b/Jusin154_Team3D/Editor/Private/Spell_Preview.cpp
index f42d4fc15..f48f0c060 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Preview.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Preview.cpp
@@ -43,12 +43,18 @@ HRESULT CSpell_Preview::Initialize(void* pArg)
m_fAlphaTime = 5.f;
m_vNine_Slice = _float4(50.f, 75.f, 30.f, 96.f);
m_fTopY = m_fY - m_vScale.y * 0.5f;
+ m_fPreviewOffSet = 0.f;
+ m_fOriginPerviewSize = 280.f;
SizeUpX(512.f);
- SizeUpY(270.f);
+ SizeUpY(m_fOriginPerviewSize);
m_iSpellType = ENUM_CLASS(SPELLTYPE::CONTROL);
m_fSortZ = 0.02f;
+ static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
+ m_fFontX = 740.f;
+ m_fFontY = 500.f;
+ m_iPerSpellIndex = -1;
return S_OK;
}
@@ -76,6 +82,7 @@ void CSpell_Preview::Update(_float fTimeDelta)
if (m_fAlpha >= 1.f)
{
m_bFadeIn = false;
+ m_bHover = true;
m_fAlpha = 1.f;
}
}
@@ -83,7 +90,10 @@ void CSpell_Preview::Update(_float fTimeDelta)
if (m_bFadeOut == true)
{
if (m_fAlpha >= 0.f)
- m_fAlpha -= fTimeDelta * m_fAlphaTime;;
+ {
+ m_fAlpha -= fTimeDelta * m_fAlphaTime;
+ m_bHover = false;
+ }
if (m_fAlpha <= 0.f)
{
@@ -92,6 +102,15 @@ void CSpell_Preview::Update(_float fTimeDelta)
}
}
m_fTime += fTimeDelta * m_fTimeMult;
+
+ if (m_iSpellType != -1 && m_iPerSpellIndex != m_iSpellType)
+ {
+ m_pSpell_Info = static_cast(m_pOwner)->Get_Info(m_iSpellType).pSpellInfo;
+ m_fPreviewOffSet = static_cast(m_pOwner)->Get_Info(m_iSpellType).fPreview;
+ SizeUpY(m_fOriginPerviewSize + m_fPreviewOffSet);
+ m_iPerSpellIndex = m_iSpellType;
+ }
+
__super::Update(fTimeDelta);
}
@@ -121,6 +140,8 @@ HRESULT CSpell_Preview::Render()
if (FAILED(m_pVIBufferCom->Render())) {
return E_FAIL;
}
+
+ m_pGameInstance->Render_Text(TEXT("Font_size14"), m_pSpell_Info.c_str(), _float2(m_fFontX + m_fX, (m_fFontY + m_fY) - m_fPreviewOffSet * 0.5f), XMVectorSet(1.f * m_fAlpha, 1.f * m_fAlpha, 1.f * m_fAlpha, m_fAlpha));
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp b/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
index 826bec3a4..770ba74f8 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
@@ -44,6 +44,7 @@ HRESULT CSpell_Vidio_Border::Initialize(void* pArg)
m_fLerpX = m_fX;
m_fLerpY = 45;
m_bStart = false;
+ m_fPreviewOffSet = 0;
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
@@ -96,6 +97,11 @@ void CSpell_Vidio_Border::Update(_float fTimeDelta)
if (m_fAlpha >= 0.3f)
m_bStart = true;
+ if (m_iSpellType != -1)
+ {
+ m_fY = m_fOrigin_Position.y + static_cast(m_pOwner)->Get_Info(m_iSpellType).fVidio;
+ }
+
__super::Update(fTimeDelta);
}
diff --git a/Jusin154_Team3D/Editor/Private/State_Hit.cpp b/Jusin154_Team3D/Editor/Private/State_Hit.cpp
new file mode 100644
index 000000000..fd450b69b
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/State_Hit.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Hit.h"
+#include "Unit.h"
+
+
+CState_Hit::CState_Hit()
+ :CState_Root()
+{
+}
+
+void CState_Hit::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Hit::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (FAILED(__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_Hit::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Hit::Initialize(STATE_HIT_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_Hit* CState_Hit::Create(STATE_HIT_DESC* pDesc)
+{
+ CState_Hit* pInstance = new CState_Hit;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Hit::Free()
+{
+ __super::Free();
+}
+
+void CState_Hit::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/State_IdleBreak.cpp b/Jusin154_Team3D/Editor/Private/State_IdleBreak.cpp
new file mode 100644
index 000000000..37935574c
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/State_IdleBreak.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_IdleBreak.h"
+#include "GameInstance.h"
+#include "Unit.h"
+
+CState_IdleBreak::CState_IdleBreak()
+ :CState_Root()
+{
+}
+
+void CState_IdleBreak::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_IdleBreak::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (E_FAIL == (__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_IdleBreak::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_IdleBreak::Initialize(STATE_IDLEBREAK_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_IdleBreak* CState_IdleBreak::Create(STATE_IDLEBREAK_DESC* pDesc)
+{
+ CState_IdleBreak* pInstance = new CState_IdleBreak;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_IdleBreak::Free()
+{
+ __super::Free();
+}
+
+void CState_IdleBreak::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/State_Slam.cpp b/Jusin154_Team3D/Editor/Private/State_Slam.cpp
new file mode 100644
index 000000000..76e36bbbf
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/State_Slam.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Slam.h"
+#include "Unit.h"
+
+
+CState_Slam::CState_Slam()
+ :CState_Root()
+{
+}
+
+void CState_Slam::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Slam::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (E_FAIL == (__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_Slam::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Slam::Initialize(STATE_SLAM_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_Slam* CState_Slam::Create(STATE_SLAM_DESC* pDesc)
+{
+ CState_Slam* pInstance = new CState_Slam;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Slam::Free()
+{
+ __super::Free();
+}
+
+void CState_Slam::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/State_Swing.cpp b/Jusin154_Team3D/Editor/Private/State_Swing.cpp
new file mode 100644
index 000000000..a3d45b12d
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/State_Swing.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Swing.h"
+#include "Unit.h"
+
+
+CState_Swing::CState_Swing()
+ :CState_Root()
+{
+}
+
+void CState_Swing::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Swing::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (E_FAIL == (__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_Swing::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Swing::Initialize(STATE_SWING_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_Swing* CState_Swing::Create(STATE_SWING_DESC* pDesc)
+{
+ CState_Swing* pInstance = new CState_Swing;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Swing::Free()
+{
+ __super::Free();
+}
+
+void CState_Swing::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/State_Throw.cpp b/Jusin154_Team3D/Editor/Private/State_Throw.cpp
new file mode 100644
index 000000000..91ea8a3cf
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/State_Throw.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Throw.h"
+#include "Unit.h"
+
+
+CState_Throw::CState_Throw()
+ :CState_Root()
+{
+}
+
+void CState_Throw::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Throw::Update(_float fTimeDelta)
+{
+ if (nullptr != m_funcPriorityUpdate) {
+ m_funcPriorityUpdate(fTimeDelta);
+ }
+ if (E_FAIL == (__super::Update(fTimeDelta))) {
+ return E_FAIL;
+ }
+ if (nullptr != m_funcLateUpdate) {
+ m_funcLateUpdate(fTimeDelta);
+ }
+ return S_OK;
+}
+
+void CState_Throw::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Throw::Initialize(STATE_THROW_DESC* pDesc)
+{
+ if (FAILED(__super::Initialize(pDesc))) {
+ return E_FAIL;
+ }
+ m_funcPriorityUpdate = pDesc->funcPriorityUpdate;
+ m_funcLateUpdate = pDesc->funcLateUpdate;
+ m_pModel = m_pOwner->Get_Component();
+ m_pFSM = m_pOwner->Get_Component();
+
+ return S_OK;
+}
+
+CState_Throw* CState_Throw::Create(STATE_THROW_DESC* pDesc)
+{
+ CState_Throw* pInstance = new CState_Throw;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Throw::Free()
+{
+ __super::Free();
+}
+
+void CState_Throw::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Editor/Private/Terrain.cpp b/Jusin154_Team3D/Editor/Private/Terrain.cpp
index b7ffb105d..eb413110b 100644
--- a/Jusin154_Team3D/Editor/Private/Terrain.cpp
+++ b/Jusin154_Team3D/Editor/Private/Terrain.cpp
@@ -51,22 +51,23 @@ HRESULT CTerrain::Initialize(void* pArg)
// Psx 적용할지 안할지
m_bUsePsx = true;
+#ifdef 진우
//if(!m_bUsePsx)
//{
// if (FAILED(m_pVIBufferCom->Load_HeightMap("Hogsmeade_HeightMap.bin")))
- // return E_FAIL;
//}
//else
- //{
- // CRigidBody_Static::RIGIDBODY_STATIC_DESC Desc{};
- // Desc.pMeshName = TEXT("Hogsmeade_HeightMap");
- // Desc.iSubKind = ENUM_CLASS(PXOBJECT::TERRAIN);
- // /* Com_RigidBody */
- // if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_RigidBody_Static_Terrain_Hogsmeade"),
- // reinterpret_cast(&m_pRigidBody), &Desc))) {
- // return E_FAIL;
- // }
- //}
+ {
+ CRigidBody_Static::RIGIDBODY_STATIC_DESC Desc{};
+ Desc.pMeshName = TEXT("Hogsmeade_HeightMap");
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::TERRAIN);
+ /* Com_RigidBody */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_RigidBody_Static_Terrain_Hogsmeade"),
+ reinterpret_cast(&m_pRigidBody), &Desc))) {
+ return E_FAIL;
+ }
+ }
+#endif
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/TrailObject.cpp b/Jusin154_Team3D/Editor/Private/TrailObject.cpp
index 12fbd1dcf..ece375502 100644
--- a/Jusin154_Team3D/Editor/Private/TrailObject.cpp
+++ b/Jusin154_Team3D/Editor/Private/TrailObject.cpp
@@ -484,7 +484,7 @@ void CTrailObject::Free()
void CTrailObject::Describe_Entity()
{
- const char* pRenderNames[] = { "PRIORITY" , "SHADOW", "NONBLEND", "DECAL", "BLUR" , "NONLIGHT" ,"EFFECT", "BLEND" ,"BLOOM" , "UI", "OCCLUSION" , "PRESHADOW" };
+ const char* pRenderNames[] = { "PRIORITY" , "SHADOW", "NONBLEND", "DECAL", "BLUR" , "NONLIGHT" ,"EFFECT", "BLEND" ,"BLOOM" , "UI", "OCCLUSION" , "PRESHADOW" , "UI_OVERLAY"};
const char* pEffectType[] = { "EFFECT" , "TRAIL" };
const char* pShaderPass[] = { "DEFAULT" , "SCISSOR" , "UI" , "UVMOVE" , "TRAIL" , "TRAIL_BLEND" , "TRAILWB_FOR_BLEND" , "TRAIL_BLUR", "TRAIL_BLOOM" };
const char* pBloomType[] = { "NONE" , "BASIC" , "MUILTY" };
diff --git a/Jusin154_Team3D/Editor/Private/Troll.cpp b/Jusin154_Team3D/Editor/Private/Troll.cpp
new file mode 100644
index 000000000..34ad753b6
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Private/Troll.cpp
@@ -0,0 +1,476 @@
+#include "pch.h"
+#include "Troll.h"
+
+#include "Troll_Weapon.h"
+#include "Troll_Rock.h"
+#include "GameInstance.h"
+#include "Effect_Container.h"
+#include "EditEffect.h"
+#include "EffectPool.h"
+#include "Layer.h"
+#include "TrailObject.h"
+
+#pragma region STATE
+#include "State_Idle.h"
+#include "State_Move.h"
+#include "State_Combat.h"
+#include "State_Hit.h"
+#include "Troll_State_Rush.h"
+#include "State_Throw.h"
+#pragma endregion
+
+CTroll::CTroll(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CMonster(pDevice, pContext)
+{
+}
+
+CTroll::CTroll(const CTroll& Prototype)
+ : CMonster(Prototype)
+{
+}
+
+HRESULT CTroll::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CTroll::Initialize(void* pArg)
+{
+ if (FAILED(__super::Initialize(pArg)))
+ return E_FAIL;
+
+ if (FAILED(Ready_Components()))
+ return E_FAIL;
+
+ if (FAILED(Ready_Parts()))
+ return E_FAIL;
+
+ Add_FSM();
+
+ Set_Anim();
+
+ {
+ CFSM::FSM_DESC FSMDesc{};
+ FSMDesc.pStates = &m_States;
+ FSMDesc.pStateMask = &m_iStateMask;
+
+ m_pFSM->Bind_States(FSMDesc);
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ }
+
+ m_pCallBack_Behavior->Initialize(m_pCharacter_Controller, m_pRigidBody);
+ m_pCallBack_HitReport->Initialize(m_pCharacter_Controller, m_pRigidBody);
+
+
+
+ m_pCharacter_Controller->Set_Position(XMVectorSet(3.f, 5.f, -20.f, 1.f));
+
+ m_pEffectPool = m_pGameInstance->Get_Layer(NEXT_LEVEL, TEXT("Layer_EffectPool"))->Get_Object();
+ SAFE_ADDREF(m_pEffectPool);
+
+ m_pLeftHand_BoneMat = m_pModelCom->Get_BoneMatrixPtr("LeftHand");
+ m_pRightHand_BoneMat = m_pModelCom->Get_BoneMatrixPtr("RightHand");
+
+ return S_OK;
+}
+
+void CTroll::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CTroll::Update(_float fTimeDelta)
+{
+ __super::Update(fTimeDelta);
+
+ m_pFSM->Update_State(fTimeDelta);
+
+ m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
+
+ Play_Event();
+
+ if (true == m_pCharacter_Controller->IsActive()) {
+ m_pCharacter_Controller->Move(fTimeDelta);
+ m_vStunTimer.x = 0.f;
+ }
+ else {
+ if (0.f == m_vStunTimer.x) {
+ PSX::PxExtendedVec3 pxControlllerPos = m_pCharacter_Controller->Get_Controller()->getPosition();
+ PSX::PxTransform pxTransform((_float)pxControlllerPos.x, (_float)pxControlllerPos.y + 100.f, (_float)pxControlllerPos.z);
+ m_pCharacter_Controller->Set_Position(XMLoadFloat3((_float3*)&pxTransform.p));
+ //m_pCharacter_Controller->Move(fTimeDelta);
+ }
+ m_vStunTimer.x += fTimeDelta;
+ m_pTransformCom->Set_WorldMatrix(m_pRigidBody->Get_Actor()->getGlobalPose());
+ if (m_vStunTimer.y < m_vStunTimer.x) {
+ m_pRigidBody->ConvertToCCT(*m_pCharacter_Controller);
+ }
+ }
+
+#ifdef _DEBUG
+ Describe_Entity();
+#endif // _DEBUG
+
+
+ for (_uint i = 0; i < ENUM_CLASS(TROLL_SKILL::END); i++)
+ m_fSkillCoolTime[i] = max(0.f, m_fSkillCoolTime[i] - fTimeDelta);
+
+
+#pragma region TRAIL_UPDATE
+
+ _matrix WorldMat = m_pTransformCom->Get_XMWorldMatrix();
+
+ _matrix LeftHandMatrix = {};
+ _matrix RightHandMatrix = {};
+
+ LeftHandMatrix = XMLoadFloat4x4(m_pLeftHand_BoneMat);
+ RightHandMatrix = XMLoadFloat4x4(m_pRightHand_BoneMat);
+
+ for (int i = 0; i < 3; ++i) {
+ LeftHandMatrix.r[i] = XMVector3Normalize(LeftHandMatrix.r[i]);
+ RightHandMatrix.r[i] = XMVector3Normalize(RightHandMatrix.r[i]);
+ }
+
+
+ m_pLeftTrail->Trail_Update(LeftHandMatrix * WorldMat, fTimeDelta);
+ m_pRightTrail->Trail_Update(RightHandMatrix * WorldMat, fTimeDelta);
+
+#pragma endregion
+
+}
+
+void CTroll::Late_Update(_float fTimeDelta)
+{
+ __super::Late_Update(fTimeDelta);
+ if (true == m_pCharacter_Controller->IsActive()) {
+ m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_FootPosition());
+ }
+ else {
+ m_pTransformCom->Set_WorldMatrix(m_pRigidBody->Get_Actor()->getGlobalPose());
+ }
+
+ if (m_bLookAt) {
+ m_pTransformCom->LookAt_Lerp(XMLoadFloat4(&m_vTargetPos),fTimeDelta, 3.f);
+ }
+
+
+ _vector vDir = XMLoadFloat4(&m_vTargetPos) - Get_WorldPostion();
+ vDir = XMVector4Normalize(vDir);
+ _vector vLook = XMVector3Normalize(
+ XMVectorSetY(m_pTransformCom->Get_State(STATE::LOOK), 0.f));
+ float dot = XMVectorGetX(XMVector3Dot(vLook, vDir));
+ dot = max(-1.f, min(1.f, dot));
+
+ float angle = acosf(dot);
+ m_fDegree = XMConvertToDegrees(angle);
+
+ m_fCross = XMVectorGetY(XMVector3Cross(vLook, vDir));
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CTroll::Render()
+{
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+ _uint iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::DEFAULT);
+ if (true == m_bDrawOutLine) {
+ iShaderPass = ENUM_CLASS(SHADER_PASS_ANIM::OUTLINE_WRITE);
+ }
+ 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))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(iShaderPass))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ if (m_bDrawOutLine) {
+ Render_OutLine();
+ }
+
+#ifdef _DEBUG
+ //if (true == m_pCharacter_Controller->IsActive()) {
+ // if (FAILED(m_pCharacter_Controller->Render())) {
+ // return E_FAIL;
+ // }
+ //}
+ //else {
+ // if (FAILED(m_pRigidBody->Render())) {
+ // return E_FAIL;
+ // }
+ //}
+#endif
+
+ return S_OK;
+}
+
+_vector CTroll::Get_LockOnPos()
+{
+ if (nullptr != m_pCharacter_Controller && true == m_pCharacter_Controller->IsActive()) {
+ return m_pCharacter_Controller->Get_Position();
+ }
+ else if (nullptr != m_pRigidBody) {
+ return m_pRigidBody->Get_Position();
+ }
+ return Get_WorldPostion();
+}
+
+void CTroll::OnCollision(CGameObject* pOther, void* pDesc)
+{
+ ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
+ _vector vWorldPos = {}; // 접촉지점
+ _vector vWorldNomal = {}; // 접촉노말
+ _vector vHitDir = {}; // 시도한 move 방향
+ _float fLength = {}; // 작용된 힘
+
+ _uint iSkillType = dynamic_cast(pOther)->Get_SkillType();
+ switch (iSkillType)
+ {
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ m_eHitSpell = STATEANIM::KNOCKDOWN_FWD;
+ break;
+ case ENUM_CLASS(SKILL_TYPE::FLIPENDO):
+ m_eHitSpell = STATEANIM::TUMBLE2;
+ break;
+ default:
+ m_eHitSpell = STATEANIM::KNOCKDOWN_FWD;
+ break;
+ }
+ m_pFSM->Change_State(FSMSTATE::HIT);
+}
+
+void CTroll::OnHit(CGameObject* pOther, CGameObject* pCaller)
+{
+}
+
+HRESULT CTroll::Ready_Components()
+{
+ CTransform::TRANSFORM_DESC Desc = {};
+
+ Desc.fSpeedPerSec = 10.f;
+ Desc.fRotationPerSec = XMConvertToRadians(180.0f);
+ Desc.fRadius = 10.f;
+
+ __super::Ready_Components(&Desc);
+
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Troll_Model");
+
+ /* Com_Model */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_strModelPrototypeTag,
+ reinterpret_cast(&m_pModelCom)))) {
+ return E_FAIL;
+ }
+
+ { // CCT
+ CCharacter_Controller::Character_Controller_DESC Desc{};
+
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::TROLL);
+ Desc.pTransform = m_pTransformCom;
+ Desc.eBodyType = ACTOR::CAPSULE;
+ Desc.fContactOffset = 0.3f;
+ Desc.fMaterial = { 1.2f, 1.0f, 0.0f };
+ Desc.bAutoStepping = { false };
+ Desc.fStepOffset = { 0.05f };
+ Desc.fRadius = 1.2f;
+ Desc.fHeight = 1.5f;
+ Desc.pCallback_HitReport = m_pCallBack_HitReport = CCallBack_Monster_HitReport::Create();
+ Desc.pCallback_Behavior = m_pCallBack_Behavior = CCallBack_Monster_Behavior::Create();
+ Desc.eClimbingMode = PSX::PxCapsuleClimbingMode::eEASY;
+ Desc.fWalkableSlope = 45.f;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_CCT_CAPSULE"), (CComponent**)&m_pCharacter_Controller, &Desc))) {
+ return E_FAIL;
+ }
+ }
+ m_pCharacter_Controller->Set_Position(m_pTransformCom->Get_State(STATE::POSITION));
+ { // DO
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::TROLL);
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_BOX"), (CComponent**)&m_pRigidBody, &Desc))) {
+ return E_FAIL;
+ }
+ m_pGameInstance->Detach_Actor(*m_pRigidBody->Get_Actor());
+ }
+
+ //if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("STAT_TROLL"), (CComponent**)&m_pStat))) {
+ // return E_FAIL;
+ //}
+
+ return S_OK;
+}
+
+HRESULT CTroll::Ready_Parts()
+{
+ CTroll_Weapon::TROLLWEAPON_DESC Troll_WeaponDesc{};
+
+ Troll_WeaponDesc.pParentTransform = m_pTransformCom;
+ Troll_WeaponDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_RightHand");
+
+ if (FAILED(Add_PartObject("Troll_Weapon", g_iStaticLevel, nullptr, &Troll_WeaponDesc)))
+ {
+ return E_FAIL;
+ }
+
+ CTroll_Rock::TROLLROCK_DESC Troll_RockDesc{};
+
+ Troll_RockDesc.pParentTransform = m_pTransformCom;
+ Troll_RockDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_LeftHand");
+
+ if (FAILED(Add_PartObject("Troll_Rock", g_iStaticLevel, nullptr, &Troll_RockDesc)))
+ {
+ return E_FAIL;
+ }
+
+ Get_PartObject()->Set_Visible(false);
+
+
+#pragma region EFFECT
+ /* EFFECT */
+
+ CPartObject::PARTOBJECT_DESC PartsDesc{};
+
+ PartsDesc.pParentTransform = m_pTransformCom;
+
+
+
+ if (FAILED(Add_PartObject("Troll_Particle", NEXT_LEVEL, &m_pTroll_Particle, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pTroll_Particle->Load("../Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle", static_cast(NEXT_LEVEL));
+ m_pTroll_Particle->FollowParants(m_pModelCom->Get_BoneMatrixPtr("HeadEnd"));
+
+
+
+ if (FAILED(Add_PartObject("Troll_Particle2", NEXT_LEVEL, &m_pTroll_Particle2, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pTroll_Particle2->Load("../Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Particle2", static_cast(NEXT_LEVEL));
+ m_pTroll_Particle2->FollowParants(m_pModelCom->Get_BoneMatrixPtr("HeadEnd"));
+
+
+ if (FAILED(Add_PartObject("Troll_Right_Smoke", NEXT_LEVEL, &m_pRight_Smoke, &PartsDesc)))
+ {
+ return E_FAIL;
+ }
+
+ m_pRight_Smoke->Load("../Bin/Resources/Data/Effect/Troll/TrollSide/Troll_Smoke", static_cast(NEXT_LEVEL));
+ m_pRight_Smoke->FollowParants(m_pModelCom->Get_BoneMatrixPtr("RightArm"));
+
+ if (FAILED(Add_PartObject