diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj b/Jusin154_Team3D/Client/Default/Client.vcxproj
index 99311a1b3..d8db8284f 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj
@@ -113,7 +113,7 @@
$(USERNAME);_DEBUG;_WINDOWS;%(PreprocessorDefinitions);%(PreprocessorDefinitions)
true
stdcpp17
- ../Public/;../../EngineSDK/Inc/;../../EngineSDK/Inc/DirectXTK/;../../EngineSDK/Inc/fMod/;../../EngineSDK/Inc/IMGUI/;../../EngineSDK/Inc/FX11/;%(AdditionalIncludeDirectories)
+ ../Public/;../../EngineSDK/Inc/;../../EngineSDK/Inc/DirectXTK/;../../EngineSDK/Inc/fMod/;../../EngineSDK/Inc/IMGUI/;../../EngineSDK/Inc/FX11/;../../EngineSDK/Inc/PhysX/;%(AdditionalIncludeDirectories)
true
true
Use
@@ -123,7 +123,7 @@
Windows
true
../../EngineSDK/Lib/$(ConfigurationName);%(AdditionalLibraryDirectories)
- Engine.lib;fmod_vc.lib;DirectXTKd.lib;%(AdditionalDependencies)
+ Engine.lib;fmod_vc.lib;PhysX_64.lib;PhysXCommon_64.lib;PhysXCooking_64.lib;PhysXExtensions_static_64.lib;PhysXFoundation_64.lib;DirectXTKd.lib;%(AdditionalDependencies);%(AdditionalDependencies)
cd /d "$(SolutionDir)"
@@ -140,7 +140,7 @@ call Update_Resources.bat
$(USERNAME);NDEBUG;_WINDOWS;%(PreprocessorDefinitions);%(PreprocessorDefinitions)
true
stdcpp17
- ../Public/;../../EngineSDK/Inc/;../../EngineSDK/Inc/DirectXTK/;../../EngineSDK/Inc/fMod/;../../EngineSDK/Inc/IMGUI/;../../EngineSDK/Inc/FX11/;%(AdditionalIncludeDirectories)
+ ../Public/;../../EngineSDK/Inc/;../../EngineSDK/Inc/DirectXTK/;../../EngineSDK/Inc/fMod/;../../EngineSDK/Inc/IMGUI/;../../EngineSDK/Inc/FX11/;../../EngineSDK/Inc/PhysX/;%(AdditionalIncludeDirectories)
true
true
Use
@@ -150,7 +150,7 @@ call Update_Resources.bat
Windows
true
../../EngineSDK/Lib/$(ConfigurationName);%(AdditionalLibraryDirectories)
- Engine.lib;fmod_vc.lib;%(AdditionalDependencies)
+ Engine.lib;fmod_vc.lib;PhysX_64.lib;PhysXCommon_64.lib;PhysXCooking_64.lib;PhysXExtensions_static_64.lib;PhysXFoundation_64.lib;%(AdditionalDependencies);%(AdditionalDependencies)
cd /d "$(SolutionDir)"
@@ -166,6 +166,10 @@ call Update_Resources.bat
+
+
+
+
@@ -175,8 +179,12 @@ call Update_Resources.bat
+
+
+
+
@@ -326,8 +334,6 @@ call Update_Resources.bat
-
-
@@ -410,6 +416,11 @@ call Update_Resources.bat
+
+
+
+
+
@@ -419,7 +430,10 @@ call Update_Resources.bat
+
+
+
@@ -571,8 +585,6 @@ call Update_Resources.bat
-
-
diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
index e9a5b824d..34cfb1e10 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
@@ -79,12 +79,6 @@
02.GameObjects\Item\Broom
-
- 02.GameObjects\PhysX
-
-
- 02.GameObjects\PhysX
-
04.Mechanic\State
@@ -338,7 +332,7 @@
04.Mechanic\State\State_Combat\State_Swing
- 04.Mechanic\State\State_Combat\State_Blink
+ 04.Mechanic\State\Movement\State_Blink
02.GameObjects\Item\Goblin_Dagger
@@ -410,9 +404,6 @@
02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector
-
- 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector
-
02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Warrior
@@ -751,6 +742,33 @@
02.GameObjects\Effect\MonsterEffect\Ranrok\Ranrok_Point
+
+
+ 02.GameObjects\Player
+
+
+ 02.GameObjects\Player\Robe
+
+
+ 02.GameObjects\Cameras\Camera_Model
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Assassin
+
+
+ 02.GameObjects\Item\Goblin_Sword
+
+
+ 04.Mechanic\State\State_Combat\State_Slash
+
+
+ 04.Mechanic\State\Movement\Dash
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector\Goblin_Warrior_Spector
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector\Goblin_Assassin_Spector
@@ -1140,9 +1158,6 @@
{f109c973-c532-4549-9680-d0d6495b0fa8}
-
- {27251db2-19f2-4492-a3a4-32c11526f413}
-
{b8c7e12b-da04-4d49-bc61-104649975d0b}
@@ -1562,6 +1577,33 @@
{a94e24d2-0f61-4263-b834-bfdf9f6c06ae}
+
+
+ {f3c7cf8d-2b83-49d3-85da-fe135e376a11}
+
+
+ {f8d55057-c0f8-4cac-8a6c-6f11345a83bb}
+
+
+ {af9f5cf6-151a-49bc-9af4-28ba0bde1d37}
+
+
+ {db12252c-8c0d-40bc-9466-e76ec60e2509}
+
+
+ {0736f27e-2722-483b-88b6-30471ad70835}
+
+
+ {27251db2-19f2-4492-a3a4-32c11526f413}
+
+
+ {6d1f0862-40a4-4c0b-9921-87fe6af2008b}
+
+
+ {0c62f4f7-a0e6-4ff2-a4dd-25e3dd79709e}
+
+
+ {bf7cf91b-742f-4913-8af2-39ed94d19e23}
@@ -1628,12 +1670,6 @@
02.GameObjects\Item\Broom
-
- 02.GameObjects\PhysX
-
-
- 02.GameObjects\PhysX
-
04.Mechanic\State
@@ -1884,7 +1920,7 @@
04.Mechanic\State\State_Combat\State_Swing
- 04.Mechanic\State\State_Combat\State_Blink
+ 04.Mechanic\State\Movement\State_Blink
02.GameObjects\Item\Goblin_Dagger
@@ -1967,9 +2003,6 @@
02.GameObjects\UI\GamePlay_Canvas\Enemy_Penel
-
- 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector
-
02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Warrior
@@ -2261,6 +2294,33 @@
02.GameObjects\Effect\MonsterEffect\Ranrok\Ranrok_Point
+
+
+ 02.GameObjects\Cameras\Camera_Model
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Assassin
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Assassin
+
+
+ 02.GameObjects\Item\Goblin_Sword
+
+
+ 04.Mechanic\State\State_Combat\State_Slash
+
+
+ 04.Mechanic\State\Movement\Dash
+
+
+ 02.GameObjects\Player\Robe
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector\Goblin_Warrior_Spector
+
+
+ 02.GameObjects\NPC\Hostile\Monster\Goblin\Goblin_Spector\Goblin_Assassin_Spector
diff --git a/Jusin154_Team3D/Client/Private/Avadakedavra.cpp b/Jusin154_Team3D/Client/Private/Avadakedavra.cpp
index 959c7d120..6296b3046 100644
--- a/Jusin154_Team3D/Client/Private/Avadakedavra.cpp
+++ b/Jusin154_Team3D/Client/Private/Avadakedavra.cpp
@@ -76,7 +76,9 @@ void CAvadakedavra::Late_Update(_float fTimeDelta)
__super::Late_Update(fTimeDelta);
- //XMStoreFloat4(&m_vEndPos, m_pStupefy_PJ_PT->Get_WorldPostion());
+ if (m_Info.pUnit) {
+ XMStoreFloat4(&m_vEndPos, m_Info.pUnit->Get_LockOnPos());
+ }
_vector vDir = XMLoadFloat4(&m_vEndPos) - XMLoadFloat4(&m_vStartPos);
@@ -84,7 +86,7 @@ void CAvadakedavra::Late_Update(_float fTimeDelta)
if (false == m_bHit) {
_vector vStartPos = XMLoadFloat4(&m_vStartPos);
_vector vEndPos = XMLoadFloat4(&m_vEndPos);
- ON_COLLISION_INFO CollisionInfo = SweepTarget(vStartPos, vEndPos, 0.002f);
+ ON_COLLISION_INFO CollisionInfo = SweepTarget(vStartPos, vEndPos, 0.2f);
OnCollision(this, &CollisionInfo);
}
diff --git a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp
index 08a5d9a48..258b6a796 100644
--- a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp
+++ b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp
@@ -251,38 +251,33 @@ void CBroomRaceManager::Check_RingPassed()
_vector prevPos = racer.prevPos;
- _float d0 = XMVectorGetX(
- XMVector3Dot(prevPos - ringPos, ringFwd));
- _float d1 = XMVectorGetX(
- XMVector3Dot(currPos - ringPos, ringFwd));
+ _float Prev = XMVectorGetX(XMVector3Dot(prevPos - ringPos, ringFwd));
+ _float Curr = XMVectorGetX(XMVector3Dot(currPos - ringPos, ringFwd));
#ifdef _DEBUG
GUI::Text("%s", racer.pAI ? "AI" : "Player");
GUI::SameLine();
GUI::Text("CurRing %d", racer.curRing);
- GUI::Text("PrevSide %.2f", d0);
- GUI::Text("CurrSide %.2f", d1);
+ GUI::Text("PrevSide %.2f", Prev);
+ GUI::Text("CurrSide %.2f", Curr);
#endif // _DEBUG
- if (d0 * d1 <= 0.f && fabs(d0 - d1) > 1e-4f)
+ if (Prev * Curr <= 0.f && fabs(Prev - Curr) > 1e-4f)
{
- _float t = d0 / (d0 - d1);
- t = std::clamp(t, 0.f, 1.f);
+ _float t = Prev / (Prev - Curr);
+ t = clamp(t, 0.f, 1.f);
- _vector hitPos =
- prevPos + (currPos - prevPos) * t;
+ _vector hitPos = prevPos + (currPos - prevPos) * t;
_vector v = hitPos - ringPos;
_float side = XMVectorGetX(XMVector3Dot(v, ringFwd));
_vector proj = hitPos - ringFwd * side;
- _float dist =
- XMVectorGetX(XMVector3Length(proj - ringPos));
+ _float dist = XMVectorGetX(XMVector3Length(proj - ringPos));
if (dist <= PASS_RADIUS)
{
if(racer.pRacer){
pRing->Set_Target(false);
}
-
racer.curRing = (racer.curRing + 1) % m_pRaceRings.size();
diff --git a/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp b/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp
index d2f1f3c84..68bcb4d7e 100644
--- a/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp
+++ b/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp
@@ -174,7 +174,7 @@ HRESULT CBroomRacerAI::Render()
}
if (m_pModelCom->Get_Type() == MODEL::PBR_ANIM)
{
- if (FAILED(m_pModelCom->Begin(i, m_pShaderCom, false))) {
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_Behavior.cpp b/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_Behavior.cpp
index 2e11f5720..d71b90b93 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_Behavior.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_Behavior.cpp
@@ -17,7 +17,7 @@ PSX::PxControllerBehaviorFlags CCallBack_EffectHitBox_Behavior::getBehaviorFlags
return PSX::PxControllerBehaviorFlags(0);
}
PSX::PxControllerBehaviorFlags eResults = PSX::PxControllerBehaviorFlags(0);
- PhsXUserData* pActorData = static_cast(actor.userData);
+ PHYSX_USERDATA* pActorData = static_cast(actor.userData);
switch (pActorData->eKind)
{
case PHYSX_KIND::BODY_STATIC:
diff --git a/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_HitReport.cpp
index 7c3a1370d..e7058f463 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_EffectHitBox_HitReport.cpp
@@ -34,8 +34,8 @@ void CCallBack_EffectHitBox_HitReport::onShapeHit(const PSX::PxControllerShapeHi
ON_COLLISION_INFO CollisionDesc = {};
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -119,8 +119,8 @@ void CCallBack_EffectHitBox_HitReport::onControllerHit(const PSX::PxControllersH
ON_COLLISION_INFO CollisionDesc = {};
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
assert(nullptr != pTargetActorData); // missing user data
switch (pTargetActorData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Monster_Behavior.cpp b/Jusin154_Team3D/Client/Private/CallBack_Monster_Behavior.cpp
index e4b961ca8..f27cdeb1b 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Monster_Behavior.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Monster_Behavior.cpp
@@ -17,7 +17,7 @@ PSX::PxControllerBehaviorFlags CCallBack_Monster_Behavior::getBehaviorFlags(cons
return PSX::PxControllerBehaviorFlags(0);
}
PSX::PxControllerBehaviorFlags eResults = PSX::PxControllerBehaviorFlags(0);
- PhsXUserData* pActorData = static_cast(actor.userData);
+ PHYSX_USERDATA* pActorData = static_cast(actor.userData);
switch (pActorData->eKind)
{
case PHYSX_KIND::BODY_STATIC:
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Monster_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_Monster_HitReport.cpp
index f01606d87..728bcf8e4 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Monster_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Monster_HitReport.cpp
@@ -33,8 +33,8 @@ void CCallBack_Monster_HitReport::onShapeHit(const PSX::PxControllerShapeHit& hi
PSX::PxRigidActor* pActor = hit.actor;
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -105,8 +105,8 @@ void CCallBack_Monster_HitReport::onControllerHit(const PSX::PxControllersHit& h
ON_COLLISION_INFO CollisionDesc = {};
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
assert(nullptr != pTargetActorData); // missing user data
switch (pTargetActorData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_Behavior.cpp b/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_Behavior.cpp
index 90dce5274..ba7105ea8 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_Behavior.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_Behavior.cpp
@@ -17,7 +17,7 @@ PSX::PxControllerBehaviorFlags CCallBack_NonPlayable_Behavior::getBehaviorFlags(
return PSX::PxControllerBehaviorFlags(0);
}
PSX::PxControllerBehaviorFlags eResults = PSX::PxControllerBehaviorFlags(0);
- PhsXUserData* pActorData = static_cast(actor.userData);
+ PHYSX_USERDATA* pActorData = static_cast(actor.userData);
switch (pActorData->eKind)
{
case PHYSX_KIND::BODY_STATIC:
diff --git a/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_HitReport.cpp
index fe36e9a90..1da0df324 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_NonPlayable_HitReport.cpp
@@ -31,8 +31,8 @@ void CCallBack_NonPlayable_HitReport::onShapeHit(const PSX::PxControllerShapeHit
PSX::PxRigidActor* pActor = hit.actor;
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -110,7 +110,7 @@ void CCallBack_NonPlayable_HitReport::onControllerHit(const PSX::PxControllersHi
PSX::PxController* pOtherController = hit.other; // 다른 컨트롤러
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pActorData = static_cast(pOtherController->getActor()->userData);
+ PHYSX_USERDATA* pActorData = static_cast(pOtherController->getActor()->userData);
assert(nullptr != pActorData); // missing user data
switch (pActorData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Playable_Behavior.cpp b/Jusin154_Team3D/Client/Private/CallBack_Playable_Behavior.cpp
index 28678a758..7b55633ab 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Playable_Behavior.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Playable_Behavior.cpp
@@ -17,7 +17,7 @@ PSX::PxControllerBehaviorFlags CCallBack_Playable_Behavior::getBehaviorFlags(con
return PSX::PxControllerBehaviorFlags(0);
}
PSX::PxControllerBehaviorFlags eResults = PSX::PxControllerBehaviorFlags(0);
- PhsXUserData* pActorData = static_cast(actor.userData);
+ PHYSX_USERDATA* pActorData = static_cast(actor.userData);
switch (pActorData->eKind)
{
case PHYSX_KIND::BODY_STATIC:
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Playable_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_Playable_HitReport.cpp
index 25d73a42d..a65b21501 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Playable_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Playable_HitReport.cpp
@@ -31,8 +31,8 @@ void CCallBack_Playable_HitReport::onShapeHit(const PSX::PxControllerShapeHit& h
PSX::PxRigidActor* pActor = hit.actor;
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -110,7 +110,7 @@ void CCallBack_Playable_HitReport::onControllerHit(const PSX::PxControllersHit&
PSX::PxController* pOtherController = hit.other; // 다른 컨트롤러
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pActorData = static_cast(pOtherController->getActor()->userData);
+ PHYSX_USERDATA* pActorData = static_cast(pOtherController->getActor()->userData);
assert(nullptr != pActorData); // missing user data
switch (pActorData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Ranrok_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_Ranrok_HitReport.cpp
index 1d2fa2d99..d89f0b92a 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Ranrok_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Ranrok_HitReport.cpp
@@ -34,8 +34,8 @@ void CCallBack_Ranrok_HitReport::onShapeHit(const PSX::PxControllerShapeHit& hit
PSX::PxRigidActor* pActor = hit.actor;
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -106,8 +106,8 @@ void CCallBack_Ranrok_HitReport::onControllerHit(const PSX::PxControllersHit& hi
ON_COLLISION_INFO CollisionDesc = {};
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
assert(nullptr != pTargetActorData); // missing user data
switch (pTargetActorData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/CallBack_Troll_HitReport.cpp b/Jusin154_Team3D/Client/Private/CallBack_Troll_HitReport.cpp
index b7d81f51a..b973b2653 100644
--- a/Jusin154_Team3D/Client/Private/CallBack_Troll_HitReport.cpp
+++ b/Jusin154_Team3D/Client/Private/CallBack_Troll_HitReport.cpp
@@ -34,8 +34,8 @@ void CCallBack_Troll_HitReport::onShapeHit(const PSX::PxControllerShapeHit& hit)
PSX::PxRigidActor* pActor = hit.actor;
if (nullptr != pController && nullptr != pActor) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
if (nullptr == pTargetActorData) { // missing user data
return;
}
@@ -117,8 +117,8 @@ void CCallBack_Troll_HitReport::onControllerHit(const PSX::PxControllersHit& hit
PSX::PxActor* pActor = pOtherController->getActor();
if (nullptr != pController && nullptr != pOtherController) {
- PhsXUserData* pTargetActorData = static_cast(pActor->userData);
- PhsXUserData* pOwnerActorData = static_cast(pController->getActor()->userData);
+ PHYSX_USERDATA* pTargetActorData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pOwnerActorData = static_cast(pController->getActor()->userData);
assert(nullptr != pTargetActorData); // missing user data
diff --git a/Jusin154_Team3D/Client/Private/CamPosition_Socket.cpp b/Jusin154_Team3D/Client/Private/CamPosition_Socket.cpp
index 14f9d07b9..afd31ccf9 100644
--- a/Jusin154_Team3D/Client/Private/CamPosition_Socket.cpp
+++ b/Jusin154_Team3D/Client/Private/CamPosition_Socket.cpp
@@ -16,7 +16,7 @@ void CCamPosition_Socket::Priority_Update(_float fTimeDelta)
{
/*_matrix socketMatrix = {};
- socketMatrix = XMLoadFloat4x4(m_pSocketMatrices);
+ socketMatrix = XMLoadFloat4x4(m_pSocketMatrix);
for (int i = 0; i < 3; ++i) {
socketMatrix.r[i] = XMVector3Normalize(socketMatrix.r[i]);
@@ -40,7 +40,7 @@ HRESULT CCamPosition_Socket::Initialize_Prototype()
HRESULT CCamPosition_Socket::Initialize(void* pArg)
{
CAMERAPOSITION_PLAYER_DESC* pDesc = static_cast (pArg);
- //m_pSocketMatrices = pDesc->pSocketMatrices;
+ //m_pSocketMatrix = pDesc->pSocketMatrix;
if (FAILED(__super::Initialize(pArg)))
{
return E_FAIL;
diff --git a/Jusin154_Team3D/Client/Private/Camera_Model.cpp b/Jusin154_Team3D/Client/Private/Camera_Model.cpp
new file mode 100644
index 000000000..2038d0675
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Camera_Model.cpp
@@ -0,0 +1,246 @@
+#include "pch.h"
+#include "Camera_Model.h"
+#include "Shader.h"
+#include "Layer.h"
+#include "Player.h"
+
+
+CCamera_Model::CCamera_Model(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CCamera(pDevice, pContext)
+{
+}
+
+CCamera_Model::CCamera_Model(const CCamera_Model& rhs)
+ : CCamera(rhs)
+{
+}
+
+void CCamera_Model::Priority_Update(_float fTimeDelta)
+{
+#ifdef _DEBUG
+ m_pGameInstance->Bind_Camera(NEXT_LEVEL, CAMERA_MODEL, false);
+#endif // _DEBUG
+
+ if (FAILED(m_pGameInstance->IsBinded_Camera(CAMERA_MODEL))) {
+ return;
+ }
+ //Transition(fTimeDelta);
+ _float3 vCamPos = {};
+ _float3 vSetPos = {};
+ XMStoreFloat3(&vCamPos, m_pTransformCom->Get_State(STATE::POSITION));
+#ifdef _DEBUG
+ GUI::Text("Cam Coord %.2f, %.2f, %.2f", vCamPos.x, vCamPos.y, vCamPos.z);
+#endif // _DEBUG
+
+ if (m_pGameInstance->Key_Up(DIK_GRAVE)) {
+ m_bMovable = !m_bMovable;
+ }
+ if (m_pGameInstance->Mouse_Down(DIM_MBUTTON)) {
+ m_pGameInstance->Toggle_MouseCenter();
+ }
+
+ __super::Bind_Matrices();
+}
+
+void CCamera_Model::Update(_float fTimeDelta)
+{
+ m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
+
+
+#ifdef _DEBUG
+ Describe_Entity();
+#endif // _DEBUG
+}
+
+void CCamera_Model::Late_Update(_float fTimeDelta)
+{
+ /*if (FAILED(m_pGameInstance->IsBinded_Camera(CAMERA_MODEL))) {
+ return;
+ }*/
+
+ auto M = m_pModelCom->Get_BoneMatrix("lookat_target");
+ GUI::Text("Bone T: %.3f %.3f %.3f", M.r[3].m128_f32[0], M.r[3].m128_f32[1], M.r[3].m128_f32[2]);
+
+
+ _vector vTargetPos = m_pModelCom->Get_BoneMatrix("lookat_target").r[3];
+
+ m_pTransformCom->LookAt(
+ XMVectorSetW(vTargetPos, 1.f)
+ );
+
+// m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CCamera_Model::Render()
+{
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+
+ for (_uint i = 0; i < iNumMeshes; i++)
+ {
+
+ if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_ANIM::DEFAULT)))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(31, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(32, 0);
+
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+HRESULT CCamera_Model::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CCamera_Model::Initialize(void* pArg)
+{
+ CAMERA_MODEL_DESC* pDesc = static_cast(pArg);
+
+ if (FAILED(__super::Initialize(pArg))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(Ready_Components(pArg))) {
+ return E_FAIL;
+ }
+ m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&pDesc->vEye), 1.f));
+ m_pTransformCom->LookAt(XMVectorSetW(XMLoadFloat3(&pDesc->vAt), 1.f));
+ m_matInitial = *m_pTransformCom->Get_WorldMatrixPtr();
+ m_bActive = true;
+
+
+ m_pModelCom->Set_Temp(true);
+ return S_OK;
+}
+
+HRESULT CCamera_Model::Ready_Components(void* pArg)
+{
+ if (FAILED(__super::Ready_Components(pArg))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_CCL_CameraRig.001_Model"),
+ reinterpret_cast(&m_pModelCom)))) {
+ return E_FAIL;
+ }
+
+
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_ANIMMESH,
+ reinterpret_cast(&m_pShaderCom)))) {
+ return E_FAIL;
+ }
+
+
+ return S_OK;
+}
+
+HRESULT CCamera_Model::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;
+ }
+#ifdef 기무리
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+#endif // 기무리
+
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float)))) {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+void CCamera_Model::Set_InitialPos()
+{
+ m_pTransformCom->Set_WorldMatrix(m_matInitial);
+}
+
+CCamera_Model* CCamera_Model::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CCamera_Model* pInstance = new CCamera_Model(pDevice, pContext);
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CCamera_Model");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CCamera_Model::Clone(void* pArg, CGameObject* pOwner)
+{
+ CCamera_Model* pInstance = new CCamera_Model(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CCamera_Model");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CCamera_Model::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pModelCom);
+ SAFE_RELEASE(m_pShaderCom);
+}
+#ifdef _DEBUG
+
+void CCamera_Model::Describe_Entity()
+{
+ _float3 vPosition = {};
+ GUI::Begin("CameraAnim List");
+ for (_int i = 0; i < m_pModelCom->Get_AnimSize(); i++)
+ {
+ if (GUI::Button(m_pModelCom->Get_AnimList(i)))
+ {
+ m_pModelCom->Set_AnimationIndex(i);
+ }
+ }
+
+
+ GUI::End();
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Dummy_PhysXPlayable.cpp b/Jusin154_Team3D/Client/Private/Dummy_PhysXPlayable.cpp
deleted file mode 100644
index 0e4bef5a7..000000000
--- a/Jusin154_Team3D/Client/Private/Dummy_PhysXPlayable.cpp
+++ /dev/null
@@ -1,232 +0,0 @@
-#include "pch.h"
-#include "Dummy_PhysXPlayable.h"
-#include "GameInstance.h"
-
-CDummy_PhysXPlayable::CDummy_PhysXPlayable(ID3D11Device* pDevice, ID3D11DeviceContext* pContext):
- CGameObject(pDevice, pContext)
-{
-}
-
-CDummy_PhysXPlayable::CDummy_PhysXPlayable(const CDummy_PhysXPlayable& rhs):
- CGameObject(rhs)
-{
-}
-
-void CDummy_PhysXPlayable::Priority_Update(_float fTimeDelta)
-{
- m_pTransformCom->RewindMomentum();
- m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_Position());
-}
-
-void CDummy_PhysXPlayable::Update(_float fTimeDelta)
-{
- if (m_pGameInstance->Key_Pressing(DIK_UPARROW)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(0.f, 0.f, 1.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Pressing(DIK_LEFT)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(-1.f, 0.f, 0.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Pressing(DIK_DOWN)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(0.f, 0.f, -1.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Pressing(DIK_RIGHT)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(1.f, 0.f, 0.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Pressing(DIK_LCONTROL)) {
- if (m_pGameInstance->Key_Pressing(DIK_SPACE)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(0.f, 10.f, 0.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Pressing(DIK_C)) {
- m_pTransformCom->AccumulateMomentum(XMVectorSet(0.f, -10.f, 0.f, 0.f) * m_pTransformCom->Get_Speed() * fTimeDelta);
- }
- if (m_pGameInstance->Key_Down(DIK_V)) {
- m_pGameInstance->Detach_Actor(*m_pCharacter_Controller->Get_Actor(), m_pGameInstance->Get_CurrentLevelID());
- }
- }
- else {
- if (m_pGameInstance->Key_Down(DIK_V)) {
- m_pGameInstance->Attach_Actor(*m_pCharacter_Controller->Get_Actor(), m_pGameInstance->Get_CurrentLevelID());
- }
- }
- m_pCharacter_Controller->Move(fTimeDelta);
-}
-
-void CDummy_PhysXPlayable::Late_Update(_float fTimeDelta)
-{
-#ifdef _DEBUG
- Describe_Entity();
-#endif // _DEBUG
-
- if (m_pGameInstance->IsIn_WorldFrustum(Get_WorldPostion(), m_pTransformCom->Get_Radius())) {
- m_pGameInstance->Add_RenderGroup(RENDER::BLEND, this);
- }
-}
-
-HRESULT CDummy_PhysXPlayable::Render()
-{
- //if (FAILED(Bind_ShaderResources())) {
- // return E_FAIL;
- //}
-
- //if (FAILED(m_pModelCom->Bind_Material(0, m_pShaderCom, "g_DiffuseTexture", aiTextureType_DIFFUSE, 0))) {
- // return E_FAIL;
- //}
- //if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_MESH::DEFAULT)))) {
- // return E_FAIL;
- //}
-
- //if (FAILED(m_pModelCom->Render(0))) {
- // return E_FAIL;
- //}
-#ifdef _DEBUG
- if (FAILED(m_pCharacter_Controller->Render())) {
- return E_FAIL;
- }
-#endif // _DEBUG
-
- return S_OK;
-}
-
-HRESULT CDummy_PhysXPlayable::Initialize_Prototype()
-{
- return S_OK;
-}
-
-HRESULT CDummy_PhysXPlayable::Initialize(void* pArg)
-{
- if (FAILED(__super::Initialize(pArg))) {
- return E_FAIL;
- }
-
- if (FAILED(Ready_Components(pArg))) {
- return E_FAIL;
- }
-
- m_pCallBack_Behavior->Initialize(m_pCharacter_Controller, m_pRigidBody);
- m_pCallBack_HitReport->Initialize(m_pCharacter_Controller, m_pRigidBody);
-
- return S_OK;
-}
-
-HRESULT CDummy_PhysXPlayable::Ready_Components(void* pArg)
-{
- CTransform::TRANSFORM_DESC TransformDesc{};
- TransformDesc.fRadius = 100.f;
- TransformDesc.fRotationPerSec = XMConvertToRadians(60.f);
- TransformDesc.fSpeedPerSec = 15.f;
- if (FAILED(__super::Ready_Components(&TransformDesc))) {
- 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);
- { // CCT
- CCharacter_Controller::Character_Controller_DESC Desc{};
-
- Desc.iSubKind = pDesc->iSubKind;
- Desc.pTransform = m_pTransformCom;
- Desc.eBodyType = ACTOR::CAPSULE;
- Desc.fContactOffset = 0.001f;
- Desc.fMaterial = { 0.5f, 0.5f, 0.6f };
- Desc.bAutoStepping = { false };
- Desc.fStepOffset = { 0.02f };
- Desc.fRadius = 0.5f;
- Desc.fHeight = 1.0f;
- Desc.pCallback_HitReport = m_pCallBack_HitReport = CCallBack_Playable_HitReport::Create();
- Desc.pCallback_Behavior = m_pCallBack_Behavior = CCallBack_Playable_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 = pDesc->iSubKind;
- 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(), NEXT_LEVEL);
- }
- /* Com_Shader */
- if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_MESH,
- reinterpret_cast(&m_pShaderCom)))){
- return E_FAIL;
- }
-
- if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_Box"), (CComponent**)&m_pModelCom))) {
- return E_FAIL;
- }
-
-
- return S_OK;
-}
-
-HRESULT CDummy_PhysXPlayable::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;
-}
-
-CDummy_PhysXPlayable* CDummy_PhysXPlayable::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
-{
- CDummy_PhysXPlayable* pInstance = new CDummy_PhysXPlayable(pDevice, pContext);
-
- if (FAILED(pInstance->Initialize_Prototype()))
- {
- MSG_BOX("Failed to Created : CDummy_PhysXPlayable");
- SAFE_RELEASE(pInstance);
- }
-
- return pInstance;
-}
-
-CGameObject* CDummy_PhysXPlayable::Clone(void* pArg, CGameObject* pOwner)
-{
- CDummy_PhysXPlayable* pInstance = new CDummy_PhysXPlayable(*this);
- pInstance->m_pOwner = pOwner;
- if (FAILED(pInstance->Initialize(pArg)))
- {
- MSG_BOX("Failed to Cloned : CDummy_PhysXPlayable");
- SAFE_RELEASE(pInstance);
- }
-
- return pInstance;
-}
-
-void CDummy_PhysXPlayable::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_Delete(m_pCallBack_Behavior);
- Safe_Delete(m_pCallBack_HitReport);
- SAFE_RELEASE(m_pShaderCom);
- SAFE_RELEASE(m_pModelCom);
-}
-#ifdef _DEBUG
-
-void CDummy_PhysXPlayable::Describe_Entity()
-{
- m_pCharacter_Controller->Describe_Entity();
-}
-
-#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Dummy_PhysXWall.cpp b/Jusin154_Team3D/Client/Private/Dummy_PhysXWall.cpp
deleted file mode 100644
index 9aa7c5bb8..000000000
--- a/Jusin154_Team3D/Client/Private/Dummy_PhysXWall.cpp
+++ /dev/null
@@ -1,170 +0,0 @@
-#include "pch.h"
-#include "Dummy_PhysXWall.h"
-
-#include "GameInstance.h"
-
-
-CDummy_PhysXWall::CDummy_PhysXWall(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
- : CGameObject{ pDevice, pContext }
-{
-}
-
-CDummy_PhysXWall::CDummy_PhysXWall(const CDummy_PhysXWall& rhs)
- : CGameObject(rhs)
-{
-}
-
-HRESULT CDummy_PhysXWall::Initialize_Prototype()
-{
- return S_OK;
-}
-
-HRESULT CDummy_PhysXWall::Initialize(void* pArg)
-{
- if (FAILED(__super::Initialize(pArg))) {
- return E_FAIL;
- }
-
- if (FAILED(Ready_Components(pArg))) {
- return E_FAIL;
- }
-
- return S_OK;
-}
-
-void CDummy_PhysXWall::Priority_Update(_float fTimeDelta)
-{
-
-}
-
-void CDummy_PhysXWall::Update(_float fTimeDelta)
-{
-}
-
-void CDummy_PhysXWall::Late_Update(_float fTimeDelta)
-{
- m_pGameInstance->Add_RenderGroup(RENDER::BLEND, this);
-}
-
-HRESULT CDummy_PhysXWall::Render()
-{
- //if (FAILED(Bind_ShaderResources())) {
- // return E_FAIL;
- //}
-
- //if (FAILED(m_pModelCom->Bind_Material(0, m_pShaderCom, "g_DiffuseTexture", aiTextureType_DIFFUSE, 0))) {
- // return E_FAIL;
- //}
- //if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_MESH::DEFAULT)))) {
- // return E_FAIL;
- //}
-
- //if (FAILED(m_pModelCom->Render(0))) {
- // return E_FAIL;
- //}
-#ifdef _DEBUG
- if (FAILED(m_pRigidBody->Render())) {
- return E_FAIL;
- }
-#endif // _DEBUG
-
-
- return S_OK;
-}
-
-HRESULT CDummy_PhysXWall::Ready_Components(void* pArg)
-{
- if (FAILED(__super::Ready_Components(pArg))) {
- return E_FAIL;
- }
- PHYSXDUMMY_DESC* pPhysXDummyDesc = static_cast(pArg);
-
- m_pTransformCom->Set_State(STATE::POSITION, XMVectorSetW(XMLoadFloat3(&pPhysXDummyDesc->vPos), 1.f));
- m_pTransformCom->Rotation(pPhysXDummyDesc->vRotRPY.x, pPhysXDummyDesc->vRotRPY.y, pPhysXDummyDesc->vRotRPY.z);
-
-
- { // RIGID_BODY
- CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
- Desc.iSubKind = pPhysXDummyDesc->iSubKind;
- if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_HEAVY_WALL"), (CComponent**)&m_pRigidBody, &Desc))) {
- return E_FAIL;
- }
- }
-
- /* Com_Shader */
- if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_MESH,
- reinterpret_cast(&m_pShaderCom)))) {
- return E_FAIL;
- }
-
- if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Component_Box"), (CComponent**)&m_pModelCom))) {
- return E_FAIL;
- }
-
-
- return S_OK;
-}
-
-HRESULT CDummy_PhysXWall::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;
-}
-
-CDummy_PhysXWall* CDummy_PhysXWall::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
-{
- CDummy_PhysXWall* pInstance = new CDummy_PhysXWall(pDevice, pContext);
-
- if (FAILED(pInstance->Initialize_Prototype()))
- {
- MSG_BOX("Failed to Created : CDummy_PhysXWall");
- SAFE_RELEASE(pInstance);
- }
-
- return pInstance;
-}
-
-CGameObject* CDummy_PhysXWall::Clone(void* pArg, CGameObject* pOwner)
-{
- CDummy_PhysXWall* pInstance = new CDummy_PhysXWall(*this);
- pInstance->m_pOwner = pOwner;
- if (FAILED(pInstance->Initialize(pArg)))
- {
- MSG_BOX("Failed to Cloned : CDummy_PhysXWall");
- SAFE_RELEASE(pInstance);
- }
-
- return pInstance;
-}
-
-void CDummy_PhysXWall::Free()
-{
- //if (nullptr != m_pRigidBody) {
- // m_pGameInstance->Release_Actor(*m_pRigidBody->Get_Actor(), m_pGameInstance->Get_CurrentLevelID());
- //}
-
- __super::Free();
-
- SAFE_RELEASE(m_pRigidBody);
- SAFE_RELEASE(m_pShaderCom);
- SAFE_RELEASE(m_pModelCom);
-}
-#ifdef _DEBUG
-
-void CDummy_PhysXWall::Describe_Entity()
-{
-}
-
-#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Effect_Container.cpp b/Jusin154_Team3D/Client/Private/Effect_Container.cpp
index cc936d3a9..e0588e643 100644
--- a/Jusin154_Team3D/Client/Private/Effect_Container.cpp
+++ b/Jusin154_Team3D/Client/Private/Effect_Container.cpp
@@ -652,7 +652,7 @@ _int CEffect_Container::CollisionCheck()
if (nullptr != pActor && nullptr != pActor->userData) {
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
if (pUserData->iSubKind >= UINT_MAX - 1) {
continue;
@@ -666,6 +666,7 @@ _int CEffect_Container::CollisionCheck()
case PXOBJECT::GOBLIN_WARRIOR:
case PXOBJECT::GOBLIN_MAGICIAN:
case PXOBJECT::TROLL:
+ case PXOBJECT::RANROK:
case PXOBJECT::WALL:
{
return i;
@@ -725,11 +726,22 @@ ON_COLLISION_INFO CEffect_Container::SweepTarget(_vector StartPos, _vector EndPo
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (pUserData->eKind)
{
+ case PHYSX_KIND::BODY_DYNAMIC:
+ switch (PXOBJECT(pUserData->iSubKind))
+ {
+ case PXOBJECT::GOBLIN_PROTEGO:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ }
+ break;
+ }
+ break;
case PHYSX_KIND::CCTActor:
{
switch (PXOBJECT(pUserData->iSubKind))
@@ -792,7 +804,7 @@ ON_COLLISION_INFO CEffect_Container::SweepTarget(_vector StartPos, _vector EndPo
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (PXOBJECT(pUserData->iSubKind))
@@ -844,11 +856,22 @@ ON_COLLISION_INFO CEffect_Container::MonsterSweepTarget(_vector StartPos, _vecto
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (pUserData->eKind)
{
+ case PHYSX_KIND::BODY_DYNAMIC:
+ switch (PXOBJECT(pUserData->iSubKind))
+ {
+ case PXOBJECT::SKILL_PROTEGO:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ }
+ break;
+ }
+ break;
case PHYSX_KIND::CCTActor:
{
switch (PXOBJECT(pUserData->iSubKind))
@@ -860,11 +883,7 @@ ON_COLLISION_INFO CEffect_Container::MonsterSweepTarget(_vector StartPos, _vecto
m_bHit = true;
}
break;
- case PXOBJECT::SKILL_PROTEGO:
- {
- pUserData->pOwner->OnCollision(this, &tagCollInfo);
- m_bHit = true;
- }
+
}
}
}
@@ -898,7 +917,7 @@ ON_COLLISION_INFO CEffect_Container::MonsterSweepTarget(_vector StartPos, _vecto
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (PXOBJECT(pUserData->iSubKind))
@@ -952,7 +971,7 @@ ON_COLLISION_INFO CEffect_Container::MonsterRayCast(_vector StartPos, _vector _v
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (pUserData->eKind)
diff --git a/Jusin154_Team3D/Client/Private/Goblin.cpp b/Jusin154_Team3D/Client/Private/Goblin.cpp
index 77e3a906f..bf67a4832 100644
--- a/Jusin154_Team3D/Client/Private/Goblin.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin.cpp
@@ -340,6 +340,12 @@ void CGoblin::OnCollision(CGameObject* pOther, void* pDesc)
case ENUM_CLASS(SKILL_TYPE::STUPEFY):
m_eHitSpell = ENUM_CLASS(SKILL_TYPE::STUPEFY);
break;
+ case ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
+ break;
}
}
else
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Assassin.cpp b/Jusin154_Team3D/Client/Private/Goblin_Assassin.cpp
new file mode 100644
index 000000000..f5fe540ec
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Assassin.cpp
@@ -0,0 +1,687 @@
+#include "pch.h"
+#include "Goblin_Assassin.h"
+
+#include "GameInstance.h"
+#include "InfoInstance.h"
+#include "Layer.h"
+#include "Player.h"
+#include "Goblin_Sword.h"
+#include "Goblin_Assassin_Spector.h"
+#include "Effect_Container.h"
+#include "EffectPool.h"
+#include "MapElement_Interactable.h"
+
+#include "EffectParts.h"
+
+
+CGoblin_Assassin::CGoblin_Assassin(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CMonster(pDevice, pContext)
+{
+}
+
+CGoblin_Assassin::CGoblin_Assassin(const CGoblin_Assassin& Prototype)
+ : CMonster(Prototype)
+{
+}
+
+HRESULT CGoblin_Assassin::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin::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(-52.f, 0.f, -14.f, 1.f));
+ m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(-52.f, 0.f, -14.f, 1.f));
+
+
+ m_pEffectPool = m_pGameInstance->Get_Layer(NEXT_LEVEL, TEXT("Layer_EffectPool"))->Get_Object();
+ SAFE_ADDREF(m_pEffectPool);
+
+ m_pModelCom->Set_Temp(true);
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CGoblin_Assassin::Update(_float fTimeDelta)
+{
+ if (m_bVisible == false)
+ return;
+
+ m_pFSM->Update_State(fTimeDelta);
+
+ m_pModelCom->Play_Animation(fTimeDelta * m_fEasing, m_pTransformCom);
+
+ __super::Update(fTimeDelta);
+
+ Play_Event();
+
+ if (true == m_pCharacter_Controller->IsActive()) {
+ { // 세트
+ m_pCallBack_HitReport->BeginFrame();
+ m_pCharacter_Controller->Move(fTimeDelta);
+ m_pCallBack_HitReport->Set_CurrentSlop();
+ }
+ 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_ASSASSIN_SKILL::END); i++)
+ m_fSkillCoolTime[i] = max(0.f, m_fSkillCoolTime[i] - fTimeDelta);
+
+
+ //m_pDetection->Set_Active(m_bDetection);
+
+
+ if (m_bDisolve) {
+ m_fDisolveTime += fTimeDelta*0.8f;
+ if (m_fDisolveTime >= 1.f)
+ {
+ m_fDisolveTime = 0.f;
+ m_bDisolve = false;
+ }
+ }
+}
+
+void CGoblin_Assassin::Late_Update(_float fTimeDelta)
+{
+ if (m_bVisible == false)
+ return;
+
+ __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_Lerp(XMLoadFloat4(&m_vTargetPos), fTimeDelta, 3.f);
+ }
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+
+ Set_Shadow(m_pGameInstance->IsIn_ShadowViewFrustum(m_pTransformCom->Get_State(STATE::POSITION), m_pTransformCom->Get_Radius()));
+}
+
+HRESULT CGoblin_Assassin::Render()
+{
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ if (FAILED(Render_DeadDisolve())) {
+ return E_FAIL;
+ }
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+ for (_uint i = 0; i < iNumMeshes; i++)
+ {
+ if (FAILED(m_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->Begin_OutLine_Write(2);
+ }
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->End_OutLine_Write();
+ }
+ }
+
+ if (true == 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
+
+ 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_Assassin::Render_OutLine()
+{
+ m_bDrawOutLine = false;
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ Compute_Depth();
+ _float fRatio = CMyTools::Saturate((m_fCamDepth / *m_pGameInstance->Get_CurrentCameraFar()));
+ m_fOutLineThickness = CMyTools::Lerp_f1D(0.01f, 0.1f, fRatio);
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_vOutLineColor", &m_vOutLineColor, sizeof(_float3)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineThickness", &m_fOutLineThickness, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineScale", &m_fOutLineScale, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLinePower", &m_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_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_NPC_PBR_ANIM::OUTLINE_READ)))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin::Render_Shadow(SHADOW eType)
+{
+ 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, eType))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_Shadow_Resource(m_pShaderCom, "g_ProjMatrix", D3DTS::PROJ, eType))) {
+ return E_FAIL;
+ }
+ _uint iNumMeshes = m_pModelCom->Get_NumMeshes();
+ for (_uint i = 0; i < iNumMeshes; i++)
+ {
+ if (FAILED(m_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+_vector CGoblin_Assassin::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 CGoblin_Assassin::OnCollision(CGameObject* pOther, void* pDesc)
+{
+ if (true == m_bDead) {
+ return;
+ }
+ if (m_pFSM->IsEnable(FSMSTATE::BLINK)) {
+ return;
+ }
+ m_DamageInfo.vTarget_Pos = m_pCharacter_Controller->Get_HeadPosition();
+
+// m_pGoblinSpector->Set_Visible(false);
+ ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
+
+ Check_HitAngle(XMLoadFloat4(&CollisionDesc->vHitDir));
+
+ m_fHitRadius = CMyTools::Get_Direction2D(m_pTransformCom->Get_State(STATE::LOOK), XMLoadFloat4(&CollisionDesc->vHitDir));
+
+ CEffect_Container* pEffect_Container = dynamic_cast(pOther);
+
+ pair<_float, _float> damagePair = {};
+
+ if (pEffect_Container != nullptr)
+ {
+ _uint iSkillType = pEffect_Container->Get_SkillType();
+ //damagePair = Get_Damage(m_pInfoInstance->Get_Spell_Damage(iSkillType));
+
+ switch (iSkillType)
+ {
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::DESCENDO);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::BOMBARDA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::BOMBARDA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::JAP):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::JAP);
+ m_fTumbleTimer = 0.f;
+ break;
+ case ENUM_CLASS(SKILL_TYPE::LEVIOSO):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::LEVIOSO);
+ m_eHitState = ENUM_CLASS(HIT_STATE::AIR_LEVIOSO);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ACCIO):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ACCIO);
+ m_eHitState = ENUM_CLASS(HIT_STATE::AIR_LEVIOSO);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::STUPEFY):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::STUPEFY);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
+ break;
+ }
+ }
+ else
+ {
+ damagePair = Get_Damage(m_pInfoInstance->Get_Spell_Damage(ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC_THROW)));
+ CMapElement_Interactable* pProps = dynamic_cast(pOther);
+ if (pProps != nullptr)
+ {
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC_THROW);
+ }
+ }
+
+
+ //m_DamageInfo.fDamage = damagePair.first;
+ //m_pInfoInstance->Event_CallBack(TEXT("Monster_Hit"), &m_DamageInfo);
+ //if (0 == damagePair.second) {
+ // m_pFSM->Change_State(FSMSTATE::DEAD);
+ // _int ID = m_pStat->Get_Stat().iObjectID;
+ // m_pInfoInstance->Event_CallBack(TEXT("MonsterDead"), &ID);
+ // return;
+ //}
+
+
+ m_pFSM->Change_State(FSMSTATE::HIT);
+
+
+}
+
+void CGoblin_Assassin::OnHit(CGameObject* pOther, CGameObject* pCaller)
+{
+}
+
+void CGoblin_Assassin::Set_Detection(_bool bDetection)
+{
+ m_bDetection = bDetection;
+}
+
+HRESULT CGoblin_Assassin::Ready_Components()
+{
+ CTransform::TRANSFORM_DESC Desc = {};
+
+ Desc.fSpeedPerSec = 10.f;
+ Desc.fRotationPerSec = XMConvertToRadians(180.0f);
+ Desc.fRadius = 10.f;
+
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pTransformCom, &Desc))) {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pFSM))) {
+ return E_FAIL;
+ }
+ /* Com_Shader */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, FX_NPC_PBR_ANIM,
+ reinterpret_cast(&m_pShaderCom)))) {
+ return E_FAIL;
+ }
+
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Goblin_Assassin_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_WARRIOR);
+ Desc.pTransform = m_pTransformCom;
+ Desc.eBodyType = ACTOR::CAPSULE;
+ Desc.fContactOffset = 0.001f;
+ Desc.fMaterial = { 1.2f, 1.0f, 0.0f };
+ Desc.bAutoStepping = { false };
+ Desc.fStepOffset = { 0.02f };
+ 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_WARRIOR);
+ 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(), NEXT_LEVEL);
+ }
+
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("STAT_GOBLIN"), (CComponent**)&m_pStat))) {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin::Ready_Parts()
+{
+ {
+ CGoblin_Sword::GOBLIN_SWORD_DESC Goblin_SwordDesc{};
+
+ Goblin_SwordDesc.pParentTransform = m_pTransformCom;
+ Goblin_SwordDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_LeftHand");
+ Goblin_SwordDesc.iIndex = 0;
+
+ if (FAILED(Add_PartObject("Goblin_Sword_L", g_iStaticLevel, nullptr, &Goblin_SwordDesc)))
+ {
+ return E_FAIL;
+ }
+ }
+
+ {
+ CGoblin_Sword::GOBLIN_SWORD_DESC Goblin_SwordDesc{};
+
+ Goblin_SwordDesc.pParentTransform = m_pTransformCom;
+ Goblin_SwordDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_RightHand");
+ Goblin_SwordDesc.iIndex = 1;
+
+ if (FAILED(Add_PartObject("Goblin_Sword_R", g_iStaticLevel, nullptr, &Goblin_SwordDesc)))
+ {
+ return E_FAIL;
+ }
+ }
+
+
+ CGoblin_Assassin_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, &m_pGoblinSpector))) {
+ 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(g_iStaticLevel));
+ m_pGoblin_Particle->FollowParents(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(g_iStaticLevel));
+ m_pGoblin_Particle2->FollowParents(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(g_iStaticLevel));
+ m_pSmoke->FollowParents(m_pModelCom->Get_BoneMatrixPtr("Spine2"));
+
+
+#pragma endregion
+
+
+ //if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER, &PartsDesc, this, &m_pDetection))) {
+ // return E_FAIL;
+ //}
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ 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_Assassin* CGoblin_Assassin::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Assassin* pInstance = new CGoblin_Assassin(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Assassin");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+CGameObject* CGoblin_Assassin::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Assassin* pInstance = new CGoblin_Assassin(*this);
+
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Assassin");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CGoblin_Assassin::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_pSmoke);
+ SAFE_RELEASE(m_pGoblin_Particle);
+ SAFE_RELEASE(m_pGoblin_Particle2);
+ SAFE_RELEASE(m_pEffectPool);
+ Safe_Delete(m_pCallBack_Behavior);
+ Safe_Delete(m_pCallBack_HitReport);
+}
+#ifdef _DEBUG
+
+void CGoblin_Assassin::Describe_Entity()
+{
+ GUI::Begin("UNIT", 0, IMGUI_GLOBAL_BEGIN_FLAG);
+ GUI::PushItemWidth(80);
+ if (GUI::CollapsingHeader("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_Assassin_Spector.cpp b/Jusin154_Team3D/Client/Private/Goblin_Assassin_Spector.cpp
new file mode 100644
index 000000000..d8ff2fc24
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Assassin_Spector.cpp
@@ -0,0 +1,367 @@
+#include "pch.h"
+#include "Goblin_Assassin_Spector.h"
+
+#include "GameInstance.h"
+#include "InfoInstance.h"
+#include "Goblin_Assassin.h"
+#include "Effect_Container.h"
+#include "Goblin_Sword.h"
+
+#include "EffectParts.h"
+#include "TrailObject.h"
+
+
+CGoblin_Assassin_Spector::CGoblin_Assassin_Spector(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CMonster(pDevice, pContext)
+{
+}
+
+CGoblin_Assassin_Spector::CGoblin_Assassin_Spector(const CGoblin_Assassin_Spector& Prototype)
+ : CMonster(Prototype)
+{
+}
+
+HRESULT CGoblin_Assassin_Spector::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin_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_pInfoInstance->Deregist_ActiveMonster(this);
+
+ m_pGoblin = dynamic_cast(m_pOwner);
+ SAFE_ADDREF(m_pGoblin);
+
+ m_vOriginScale = m_pTransformCom->Get_Scale();
+
+ m_pLeftHand_BoneMat = m_pModelCom->Get_BoneMatrixPtr("SKT_LeftHand");
+ m_pRightHand_BoneMat = m_pModelCom->Get_BoneMatrixPtr("SKT_RightHand");
+
+ m_pModelCom->Set_AnimationIndex(5);
+ m_pModelCom->Play_Animation(0, m_pTransformCom);
+
+
+ m_bVisible = false;
+
+ return S_OK;
+}
+
+void CGoblin_Assassin_Spector::Priority_Update(_float fTimeDelta)
+{
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CGoblin_Assassin_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_bVisible)
+ {
+ 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("Goblin_Sword_L")->Set_Visible(true);
+ Get_PartObject("Goblin_Sword_R")->Set_Visible(true);
+ m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
+ }
+ else {
+ Get_PartObject("Goblin_Sword_L")->Set_Visible(false);
+ Get_PartObject("Goblin_Sword_R")->Set_Visible(false);
+ m_vScale = { 1.f,1.f,1.f };
+ m_pTransformCom->Set_Scale(m_vOriginScale);
+ m_pModelCom->Set_AnimationIndex(5);
+ }
+
+ if (m_bDisolve) {
+ Get_PartObject("Goblin_Sword_L")->Set_Disolve(true);
+ Get_PartObject("Goblin_Sword_R")->Set_Disolve(true);
+ m_fDisolveTime += fTimeDelta;
+ if (m_fDisolveTime >= 1.f)
+ {
+ m_fDisolveTime = 0.f;
+ m_bDisolve = false;
+ m_bVisible = false;
+ }
+ }
+
+#ifdef _DEBUG
+ Describe_Entity();
+#endif // _DEBUG
+
+#pragma region TRAIL_UPDATE
+
+ _matrix WorldMat = m_pTransformCom->Get_XMWorldMatrix();
+
+ _matrix LeftHandMatrix = {};
+ _matrix RightHandMatrix = {};
+ _matrix WeaponMatrix = {};
+
+ 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]);
+ WeaponMatrix.r[i] = XMVector3Normalize(WeaponMatrix.r[i]);
+ }
+
+ _matrix WeaponSoket = WeaponMatrix * Get_Component()->Get_XMWorldMatrix();
+
+ m_pLeft_Trail->Trail_Update(LeftHandMatrix * WorldMat, fTimeDelta);
+ m_pRight_Trail->Trail_Update(RightHandMatrix * WorldMat, fTimeDelta);
+
+#pragma endregion
+
+}
+
+void CGoblin_Assassin_Spector::Late_Update(_float fTimeDelta)
+{
+ __super::Late_Update(fTimeDelta);
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CGoblin_Assassin_Spector::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::SPECTOR);
+
+ if (FAILED(Render_Disolve())) {
+ return E_FAIL;
+ }
+
+ for (_uint i = 0; i < iNumMeshes; i++)
+ {
+ if (FAILED(m_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(iShaderPass))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(31, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(32, 0);
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ {
+ _bool bDisolve = false;
+ _float zero = 0.f;
+ m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool));
+ m_pShaderCom->Bind_RawValue("g_fDisolveRatio", &zero, sizeof(_float));
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin_Spector::OnCollision(CGameObject* pOther, void* pDesc)
+{
+
+}
+
+void CGoblin_Assassin_Spector::OnHit(CGameObject* pOther, CGameObject* pCaller)
+{
+}
+
+HRESULT CGoblin_Assassin_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;
+ }
+
+
+
+
+ return S_OK;
+}
+
+void CGoblin_Assassin_Spector::Spector_Trail_Visible(_bool isTrailVisible)
+{
+ m_pLeft_Trail->Set_Visible(isTrailVisible);
+ m_pRight_Trail->Set_Visible(isTrailVisible);
+
+ m_pLeft_Trail->Get_Component()->Reset_Trail();
+ m_pRight_Trail->Get_Component()->Reset_Trail();
+}
+
+HRESULT CGoblin_Assassin_Spector::Ready_Parts()
+{
+
+ {
+ CGoblin_Sword::GOBLIN_SWORD_DESC Goblin_SwordDesc{};
+
+ Goblin_SwordDesc.pParentTransform = m_pTransformCom;
+ Goblin_SwordDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_LeftHand");
+ Goblin_SwordDesc.iIndex = 0;
+
+ if (FAILED(Add_PartObject("Goblin_Sword_L", g_iStaticLevel, nullptr, &Goblin_SwordDesc)))
+ {
+ return E_FAIL;
+ }
+ }
+
+ {
+ CGoblin_Sword::GOBLIN_SWORD_DESC Goblin_SwordDesc{};
+
+ Goblin_SwordDesc.pParentTransform = m_pTransformCom;
+ Goblin_SwordDesc.pSocketMatrices = m_pModelCom->Get_BoneMatrixPtr("SKT_RightHand");
+ Goblin_SwordDesc.iIndex = 1;
+
+ if (FAILED(Add_PartObject("Goblin_Sword_R", g_iStaticLevel, nullptr, &Goblin_SwordDesc)))
+ {
+ return E_FAIL;
+ }
+ }
+
+ CPartObject::PARTOBJECT_DESC PartsDesc{};
+
+ PartsDesc.pParentTransform = m_pTransformCom;
+
+ if (FAILED(Add_PartObject("Left_Trail", g_iStaticLevel, &m_pLeft_Trail, &PartsDesc))) {
+ return E_FAIL;
+ }
+
+ m_pLeft_Trail->Load_Trail("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Trail_R", static_cast(g_iStaticLevel));
+ m_pLeft_Trail->Set_Visible(false);
+
+ if (FAILED(Add_PartObject("Right_Trail", g_iStaticLevel, &m_pRight_Trail, &PartsDesc))) {
+ return E_FAIL;
+ }
+
+ m_pRight_Trail->Load_Trail("../Bin/Resources/Data/Effect/Goblin/GoblinSide/Goblin_Trail_R", static_cast(g_iStaticLevel));
+ m_pRight_Trail->Set_Visible(false);
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Assassin_Spector::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix"))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ 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_Assassin_Spector* CGoblin_Assassin_Spector::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Assassin_Spector* pInstance = new CGoblin_Assassin_Spector(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Assassin_Spector");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+CGameObject* CGoblin_Assassin_Spector::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Assassin_Spector* pInstance = new CGoblin_Assassin_Spector(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Assassin_Spector");
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CGoblin_Assassin_Spector::Free()
+{
+ __super::Free();
+
+
+ SAFE_RELEASE(m_pGoblin);
+ SAFE_RELEASE(m_pLeft_Trail);
+ SAFE_RELEASE(m_pRight_Trail);
+}
+#ifdef _DEBUG
+
+void CGoblin_Assassin_Spector::Describe_Entity()
+{
+ GUI::Begin("UNIT", 0, IMGUI_GLOBAL_BEGIN_FLAG);
+ GUI::PushItemWidth(80);
+ if (GUI::CollapsingHeader("GoblinSpector")) {
+ _float3 vScale = m_pTransformCom->Get_Scale();
+ GUI::DragFloat3("Scale", (_float*)&vScale);
+ }
+ GUI::End();
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Assassin_States.cpp b/Jusin154_Team3D/Client/Private/Goblin_Assassin_States.cpp
new file mode 100644
index 000000000..0326fe5e3
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Assassin_States.cpp
@@ -0,0 +1,1079 @@
+#include "pch.h"
+#include "Goblin_Assassin.h"
+#include "InfoInstance.h"
+#include "GameInstance.h"
+#include "Player.h"
+#include "Goblin_Assassin_Spector.h"
+#include "EffectParts.h"
+
+#include "EffectPool.h"
+#include "Goblin_Sword.h"
+
+#pragma region STATE
+#include "State_Idle.h"
+#include "State_IdleBreak.h"
+#include "State_Dodge.h"
+#include "State_Jump.h"
+#include "State_Land.h"
+#include "State_Move.h"
+#include "State_Combat.h"
+#include "State_Slash.h"
+#include "State_Dash.h"
+#include "State_Blink.h"
+#include "State_Hit.h"
+#include "State_Dead.h"
+#include "State_Shuffle.h"
+#pragma endregion
+
+
+void CGoblin_Assassin::Behavior_IdleEnter()
+{
+ m_pFSM->Enable_State(FSMSTATE::IDLE);
+
+}
+
+HRESULT CGoblin_Assassin::Behavior_IdleExitCheck()
+{
+ if (m_fTargetDistance <= 20.f && m_fTargetDistance > 10.f)
+ {
+ m_bLookAt = false;
+ m_bDetection = true;
+
+ pair<_uint, _bool> pairAnimInfo = m_Animation[STATEANIM::IDLE];
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ }
+ if ((m_fTargetDistance <= 10.f && m_fTargetDistance != 0.f) /*|| m_pDetection->Get_Step() == true*/)
+ {
+ m_vOriginPos = m_pTransformCom->Get_State(STATE::POSITION);
+ m_bLookAt = true;
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance >= 25.f)
+ {
+ m_bDetection = false;
+
+ m_pFSM->Change_State(FSMSTATE::IDLEBREAK);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_IdleExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::IDLE);
+}
+
+void CGoblin_Assassin::Behavior_IdleBreakEnter()
+{
+ m_pFSM->Enable_State(FSMSTATE::IDLEBREAK);
+ pair<_uint, _bool> pairAnimInfo;
+ m_bLookAt = false;
+ _int RandIndex = m_pGameInstance->Real_Random_Int(0, 6);
+ switch (RandIndex)
+ {
+ case 0:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK1];
+ break;
+ case 1:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK2];
+ break;
+ case 2:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK3];
+ break;
+ case 3:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK4];
+ break;
+ case 4:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK5];
+ break;
+ case 5:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK6];
+ break;
+ case 6:
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK7];
+ break;
+ }
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+}
+
+HRESULT CGoblin_Assassin::Behavior_IdleBreakExitCheck()
+{
+ if (m_pModelCom->IsFinishedAnim()) {
+ m_pFSM->Change_State(FSMSTATE::IDLE);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_IdleBreakExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::IDLEBREAK);
+}
+
+void CGoblin_Assassin::Behavior_MoveEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::MOVE);
+ m_bLookAt = true;
+ m_pFSM->Enable_State(FSMSTATE::JOG);
+
+ if (!m_pFSM->IsEnable_Previous(FSMSTATE::COMBAT))
+ {
+ m_bFirstMove = false;
+ }
+}
+
+HRESULT CGoblin_Assassin::Behavior_MoveExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+
+ 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.f)
+ {
+ m_bFirstMove = false;
+ m_fMoveTime = 0.f;
+ }
+ }
+
+
+ if (m_fTargetDistance <= 15.f && m_fTargetDistance >= 4.f && m_fTargetDistance != 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_MoveExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::MOVE | FSMSTATE::SPRINT | FSMSTATE::JOG | FSMSTATE::WALK);
+}
+
+void CGoblin_Assassin::Behavior_CombatEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::COMBAT);
+ m_bLookAt = true;
+}
+
+HRESULT CGoblin_Assassin::Behavior_CombatExitCheck(_float fTimeDelta)
+{
+ 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_ASSASSIN_SKILL::SLASH)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::SLASH);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance <= 10.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::DASH)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::DASH);
+ return E_FAIL;
+ }
+ else if (m_fTargetDistance <= 15.f && m_fSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::TP)] <= 0.f)
+ {
+ m_pFSM->Change_State(FSMSTATE::BLINK);
+ return E_FAIL;
+ }
+ else {
+ m_pFSM->Change_State(FSMSTATE::MOVE);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_CombatExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::COMBAT);
+}
+
+void CGoblin_Assassin::Behavior_SlashEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::SLASH);
+
+ pairAnimInfo = m_Animation[STATEANIM::SLASH];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second,1.5f);
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::SLASH)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::SLASH)];
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_pGoblinSpector->Set_Visible(true);
+ m_pGoblinSpector->Spector_Trail_Visible(true);
+
+ m_pEffectPool->Use_Skill(SKILL_TYPE::GOBLIN_ATTACK, m_pGoblinSpector->Get_PartObject(), (void*)&m_pGoblinSpector->Get_PartObject()->Get_SwordMatrix());
+ },
+ 0.05f);
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_pGoblinSpector->Set_Disolve(true); },
+ 0.28f);
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_bLookAt = false; },
+ 0.3f);
+
+ Set_Easing(pairAnimInfo.first, 0.01f, 0.15f, 0.8f);
+
+ Set_Easing(pairAnimInfo.first, 0.15f, 0.4f, 1.4f);
+}
+
+HRESULT CGoblin_Assassin::Behavior_SlashExitCheck(_float fTimeDelta)
+{
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_SlashExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::SLASH);
+ m_bLookAt = true;
+}
+
+void CGoblin_Assassin::Behavior_DashEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::DASH);
+
+ pairAnimInfo = m_Animation[STATEANIM::DASH];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::DASH)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::DASH)];
+}
+
+HRESULT CGoblin_Assassin::Behavior_DashExitCheck(_float fTimeDelta)
+{
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_pFSM->Change_State(FSMSTATE::SLASH);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_DashExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::DASH);
+}
+
+void CGoblin_Assassin::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);
+ m_bDisolve = true;
+
+ Add_Event(pairAnimInfo.first,
+ [this]() {
+ m_pEffectPool->Use_Skill(SKILL_TYPE::GOBILN_TELEPORT, this);
+ }, 0.1f);
+}
+
+HRESULT CGoblin_Assassin::Behavior_BlinkExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ if (!m_bDisolve && iCurrAnimIndex != m_Animation[STATEANIM::BLINK].first)
+ {
+ m_fSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::TP)] = m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_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);
+
+ _matrix rot = XMMatrixRotationY(randAngleRad);
+ _vector offsetDir = XMVector3TransformNormal(vPlayerLook, rot);
+
+ _float randDist = m_pGameInstance->Real_Random_Float(3.f, 3.5f);
+
+ _vector vFinalPos = vPlayerPos + offsetDir * randDist;
+ vFinalPos = XMVectorSetY(vFinalPos, XMVectorGetY(vPlayerPos) + 1.5f);
+
+ m_pCharacter_Controller->Set_Position(vFinalPos);
+
+ 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 S_OK;
+}
+
+void CGoblin_Assassin::Behavior_BlinkExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::BLINK);
+}
+
+void CGoblin_Assassin::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);
+}
+
+HRESULT CGoblin_Assassin::Behavior_ShuffleExitCheck(_float fTimeDelta)
+{
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+
+ if (fRatio >= 0.3f)
+ {
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_ShuffleExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::SHUFFLE);
+}
+
+void CGoblin_Assassin::Behavior_HitEnter()
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _int iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ m_pFSM->Enable_State(FSMSTATE::HIT);
+
+ m_bLookAt = false;
+
+ _float fAnimSpeed = 1.f;
+ switch (m_eHitSpell)
+ {
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD];
+ fAnimSpeed = 2.f;
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::TUMBLE_FWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, false, 0.5f);
+ m_pCharacter_Controller->SetGravity(false);
+ m_bAir = true;
+ },
+ 0.3f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [this]() {
+ CameraShake(10.f, 1.f, 2.f, 0.3f);
+ },
+ 0.27f);
+
+ Add_Event(m_Animation[STATEANIM::TUMBLE_FWD].first,
+ [this]() {m_pModelCom->Set_AnimSpeed(1.5f); },
+ 0.75f);
+
+ Add_Event(m_Animation[STATEANIM::TUMBLE_FWD].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_bAir = false;
+ m_pCharacter_Controller->SetGravity(true);
+ },
+ 0.96f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::GETUP_BWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f); },
+ 0.95f);
+
+ Add_Event(m_Animation[STATEANIM::GETUP_BWD].first,
+ [this]() {m_bLookAt = true; },
+ 0.7f);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::BOMBARDA):
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_L];
+ break;
+ case ENUM_CLASS(SKILL_TYPE::JAP):
+ {
+ if (m_fHitDegree >= 90.f)
+ {
+ _int iRandIndex = m_pGameInstance->Real_Random_Int(0, 3);
+ switch (iRandIndex)
+ {
+ case 0:
+ pairAnimInfo = m_Animation[STATEANIM::HIT_BWD];
+ break;
+ case 1:
+ pairAnimInfo = m_Animation[STATEANIM::HIT_BWD2];
+ break;
+ case 2:
+ pairAnimInfo = m_Animation[STATEANIM::HIT_BWD3];
+ break;
+ case 3:
+ pairAnimInfo = m_Animation[STATEANIM::HIT_BWD4];
+ break;
+ default:
+ break;
+ }
+ }
+ else if (m_fHitDegree >= 45.f) {
+
+ if (m_fHitCross > 0.f) {
+ pairAnimInfo = m_Animation[STATEANIM::HIT_L];
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::HIT_R];
+ }
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::HIT_FWD];
+ }
+ }
+ break;
+ case ENUM_CLASS(SKILL_TYPE::LEVIOSO):
+ pairAnimInfo = m_Animation[STATEANIM::HIT_LEVIOSO];
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ACCIO):
+ pairAnimInfo = m_Animation[STATEANIM::INCARCEROUS];
+ break;
+ default:
+ _int iRand = m_pGameInstance->Real_Random_Int(0, 1);
+ if (iRand == 0)
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_L];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_R];
+ break;
+ }
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, false, fAnimSpeed);
+
+}
+
+HRESULT CGoblin_Assassin::Behavior_HitExitCheck(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+ CTransform* pTransform = m_pTarget->Get_Component();
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::KNOCKDOWN_BWD].first)
+ {
+ if (fRatio >= 0.15f)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f,false,2.f);
+ }
+ }
+ if (m_bAir)
+ {
+ _vector vDir = m_pTransformCom->Get_State(STATE::UP);
+ vDir = XMVector4Normalize(vDir);
+ _vector vPos = m_pCharacter_Controller->Get_Position();
+ _vector Force = vDir * fTimeDelta*0.6f;
+ m_pCharacter_Controller->Set_Position(vPos + Force);
+ }
+
+ if (!m_bAir && iCurrAnimIndex == m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first)
+ {
+ m_fGravityAmount += fTimeDelta * fRatio* 20.f;
+ m_pCharacter_Controller->Set_GravityAmount(m_fGravityAmount);
+ }
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::TUMBLE_FWD].first)
+ {
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() {CameraShake(3.f, 0.8f, 1.f, 0.2f); },
+ 0.17f);
+ }
+
+ if (m_eHitSpell == ENUM_CLASS(SKILL_TYPE::ACCIO))
+ {
+ if (!m_bPos)
+ {
+ m_pCharacter_Controller->SetGravity(false);
+ _vector vPlayerPos = pTransform->Get_State(STATE::POSITION);
+ vPlayerPos = XMVectorSetY(vPlayerPos, XMVectorGetY(vPlayerPos) + 2.5f);
+ _vector vMonsterPos = m_pCharacter_Controller->Get_Position();
+
+ _vector vDir = XMVector3Normalize(vPlayerPos - vMonsterPos);
+ _float fLength = XMVectorGetX(XMVector3Length(vPlayerPos - vMonsterPos));
+
+ m_fSpeed += (m_fTargetSpeed - m_fSpeed) * fTimeDelta * m_fAccel;
+
+ if (fLength >= 4.f)
+ {
+ m_pCharacter_Controller->Set_Position(
+ vMonsterPos + vDir * m_fSpeed * fTimeDelta
+ );
+ }
+ else {
+ m_bPos = true;
+ pairAnimInfo = m_Animation[STATEANIM::HIT_LEVIOSO];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ }
+ }
+ }
+
+ if (m_eHitSpell == ENUM_CLASS(SKILL_TYPE::LEVIOSO))
+ {
+ 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);
+ }
+ }
+
+ HitState_Behavior(fTimeDelta);
+
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::TUMBLE].first)
+ {
+ m_fTumbleTimer += fTimeDelta;
+
+ if (m_fTumbleTimer >= 1.5f)
+ {
+ m_fTumbleTimer = 0.f;
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_pCharacter_Controller->SetGravity(true);
+
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() {CameraShake(3.f, 0.8f, 1.f, 0.2f); },
+ 0.21f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::GETUP_BWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ m_fAirTime = 0.f; },
+ 0.95f);
+ }
+ return S_OK;
+ }
+ if (m_vStunTimer.y < m_vStunTimer.x) {
+ pairAnimInfo = m_Animation[STATEANIM::GETUP_FWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ }
+
+ if (m_pModelCom->IsFinishedAnim())
+ {
+ m_pFSM->Change_State(FSMSTATE::COMBAT);
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_HitExit()
+{
+ m_pFSM->Disable_State(FSMSTATE::HIT);
+ m_bPos = false;
+ m_bLookAt = true;
+ m_eHitState = ENUM_CLASS(HIT_STATE::END);
+ m_pCharacter_Controller->Reset_GravityAmount();
+ m_fGravityAmount = 0.f;
+}
+
+void CGoblin_Assassin::Behavior_DeadEnter()
+{
+ m_bLookAt = false;
+ pair<_uint, _bool> pairAnimInfo = {};
+ m_pFSM->Enable_State(FSMSTATE::DEAD);
+ m_pCharacter_Controller->SetGravity(true);
+
+ _bool bStrongerKnockDown = { false };
+
+ _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_Assassin::Behavior_DeadExitCheck(_float fTimeDelta)
+{
+ if (FLT_EPSILON > m_pModelCom->Get_CurrentTrackProgressRatio()) {
+
+ return E_PENDING;
+ }
+ return S_OK;
+}
+
+void CGoblin_Assassin::Behavior_DeadExit()
+{
+ m_bDead = true;
+}
+
+void CGoblin_Assassin::HitState_Behavior(_float fTimeDelta)
+{
+ pair<_uint, _bool> pairAnimInfo = {};
+ CTransform* pTransform = m_pTarget->Get_Component();
+ _uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
+
+ if (m_eHitState == ENUM_CLASS(HIT_STATE::AIR_LEVIOSO))
+ {
+ switch (m_eHitSpell)
+ {
+ case ENUM_CLASS(SKILL_TYPE::DESCENDO):
+ {
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::END);
+ m_pCharacter_Controller->SetGravity(true);
+ m_pCharacter_Controller->Set_GravityAmount(1.5f);
+ m_fAirTime = 0.f;
+ pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, false, 2.f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::TUMBLE_FWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, false, 0.5f);
+ m_pCharacter_Controller->SetGravity(false);
+ m_bAir = true;
+ },
+ 0.3f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [this]() {
+ CameraShake(10.f, 1.f, 2.f, 0.3f);
+ },
+ 0.27f);
+
+ Add_Event(m_Animation[STATEANIM::TUMBLE_FWD].first,
+ [this]() {m_pModelCom->Set_AnimSpeed(1.5f); },
+ 0.75f);
+
+ Add_Event(m_Animation[STATEANIM::TUMBLE_FWD].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_bAir = false;
+ m_pCharacter_Controller->SetGravity(true);
+ },
+ 0.96f);
+
+ Add_Event(m_Animation[STATEANIM::KNOCKDOWN_BWD_SPLT].first,
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::GETUP_BWD];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f); },
+ 0.95f);
+
+ Add_Event(m_Animation[STATEANIM::GETUP_BWD].first,
+ [this]() {m_bLookAt = true; },
+ 0.7f);
+ }
+ break;
+ case ENUM_CLASS(SKILL_TYPE::BOMBARDA):
+ {
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::END);
+ m_pCharacter_Controller->ConvertToDO(*m_pRigidBody);
+ _vector vCameraLook = m_pGameInstance->Get_CameraLook();
+ vCameraLook = XMVector3Normalize(vCameraLook);
+ m_pRigidBody->Add_Force(vCameraLook * 60.f, PSX::PxForceMode::eIMPULSE);
+ m_fAirTime = 0.f;
+ }
+ break;
+ case ENUM_CLASS(SKILL_TYPE::JAP):
+ {
+ m_fHitTimer += fTimeDelta;
+ if (m_fHitTimer <= 0.4f)
+ {
+ _vector vPlayerLook = pTransform->Get_State(STATE::LOOK);
+ vPlayerLook = XMVector4Normalize(vPlayerLook);
+ _vector vPos = m_pCharacter_Controller->Get_Position();
+
+ _float t = clamp(m_fHitTimer, 0.f, 1.f);
+ _float ease = 1.f - (t * t);
+ _vector Force = vPlayerLook * fTimeDelta * 6.f * ease;
+
+ m_pCharacter_Controller->Set_Position(vPos + Force);
+ pairAnimInfo = m_Animation[STATEANIM::TUMBLE];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, false, 0.8f);
+ }
+ else {
+ m_fHitTimer = 0.f;
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::END);
+ }
+ }
+ break;
+ }
+ if (fRatio >= 0.31f && iCurrAnimIndex == m_Animation[STATEANIM::HIT_LEVIOSO].first)
+ {
+ m_fAirTime = 0.f;
+ m_pCharacter_Controller->SetGravity(true);
+ pairAnimInfo = m_Animation[STATEANIM::LAND];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f);
+ }
+ }
+
+}
+
+
+void CGoblin_Assassin::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_IdleBreak::STATE_IDLEBREAK_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_IdleBreakEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_IdleBreakExitCheck(); };
+ Desc.funcExitEvent = [this]() { Behavior_IdleBreakExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::IDLEBREAK, CState_IdleBreak::Create(&Desc));
+ }
+
+ {
+ CState_Move::STATE_MOVE_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_MoveEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_MoveExitCheck(fTimedelta); };
+ 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_Slash::STATE_SLASH_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_SlashEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_SlashExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_SlashExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::SLASH, CState_Slash::Create(&Desc));
+ }
+ {
+ CState_Dash::STATE_DASH_DESC Desc{};
+ Desc.pOwner = this;
+ Desc.funcEnterEvent = [this]() { Behavior_DashEnter(); };
+ Desc.funcExitCheck = [this](_float fTimedelta) { return Behavior_DashExitCheck(fTimedelta); };
+ Desc.funcExitEvent = [this]() { Behavior_DashExit(); };
+ Desc.funcPriorityUpdate = nullptr;
+ Desc.funcLateUpdate = nullptr;
+ m_States.emplace(FSMSTATE::DASH, CState_Dash::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));
+ }
+
+ {
+ 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
+ {
+ 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) {
+ 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);
+ 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_Assassin::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::IDLE_BREAK1] = { 137, false };
+ m_Animation[STATEANIM::IDLE_BREAK2] = { 138, false };
+ m_Animation[STATEANIM::IDLE_BREAK3] = { 139, false };
+ m_Animation[STATEANIM::IDLE_BREAK4] = { 37, false };
+ m_Animation[STATEANIM::IDLE_BREAK5] = { 38, false };
+ m_Animation[STATEANIM::IDLE_BREAK6] = { 39, false };
+ m_Animation[STATEANIM::IDLE_BREAK7] = { 41, 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::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::BLINK_START] = { 428,false }; // 텔레포트
+ m_Animation[STATEANIM::BLINK] = { 426,false }; // 텔레포트
+ m_Animation[STATEANIM::ATTACK_END] = { 76,false };
+ m_Animation[STATEANIM::SLASH] = { 72,false };
+ m_Animation[STATEANIM::DASH] = { 73,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::TUMBLE_FWD] = { 429, true };
+ m_Animation[STATEANIM::PETRIFICUSED_START] = { 383, false };
+
+ m_Animation[STATEANIM::LAND] = { 376, false };
+ m_Animation[STATEANIM::HIT_LEVIOSO] = { 381, false };
+ m_Animation[STATEANIM::INCARCEROUS] = { 382,false };
+
+ m_Animation[STATEANIM::STUMBLE_BWD_L] = { 394, false };
+ m_Animation[STATEANIM::STUMBLE_BWD_R] = { 395, false };
+ m_Animation[STATEANIM::STUMBLE_FWD] = { 396, 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 };
+
+ //Tp 426
+ // Tp Start 428
+ // 76 공격끝
+
+
+
+
+
+
+
+
+ // 걷기 시작 57
+ // 걷기 루프 50
+ // 뛰기 시작 157
+ // 뛰기 루프 45
+ // 나이프 던지기 85
+ // 도끼 공격 444
+ // 도끼 공격 후 76
+ // 도끼 찍기 439
+ //
+
+ // 텀블링 히트 380
+ // 디센도 찍기전 띄우기 371
+ // 디센도 찍기 372
+
+ // 레비오소 피격 381
+ // 착지 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
+
+
+ // L 394
+ // R 395
+ // fwd 396
+}
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Attack.cpp b/Jusin154_Team3D/Client/Private/Goblin_Attack.cpp
index a4e3e0eb7..b5ad316d3 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Attack.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Attack.cpp
@@ -66,12 +66,8 @@ void CGoblin_Attack::Update(_float fTimeDelta)
Update_Event(fTimeDelta);
- CGoblin_BattleAxe* pAxe = static_cast(m_pOwner);
-
- _float4x4 AxeMat = pAxe->Get_AxeMatrix();
-
- m_pPT1->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
- m_pPT2->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
+ m_pPT1->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&m_vMat));
+ m_pPT2->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&m_vMat));
}
@@ -90,13 +86,18 @@ HRESULT CGoblin_Attack::Pre_Setting(CGameObject* pObject, void* pArg)
{
if (FAILED(__super::Pre_Setting(pObject, nullptr)))
return E_FAIL;
-
- CGoblin_BattleAxe* pAxe = static_cast(m_pOwner);
-
- _float4x4 AxeMat = pAxe->Get_AxeMatrix();
+ //
+ //CGoblin_BattleAxe* pAxe = static_cast(m_pOwner);
+ //
+ //_float4x4 AxeMat = pAxe->Get_AxeMatrix();
- m_pPT1->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
- m_pPT2->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
+ m_vMat = *static_cast<_float4x4*>(pArg);
+
+ //m_pPT1->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
+ //m_pPT2->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&AxeMat));
+
+ m_pPT1->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&m_vMat));
+ m_pPT2->Get_Component()->Set_WorldMatrix(XMLoadFloat4x4(&m_vMat));
m_pPT1->Set_Visible(true);
m_pPT2->Set_Visible(true);
diff --git a/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp b/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp
index f46735c9f..db38f0cc6 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_BattleAxe.cpp
@@ -269,7 +269,7 @@ void CGoblin_BattleAxe::SwingHit(_bool& bPlayerHit)
for (_uint i = 0; i < pxHits.size(); ++i) {
PSX::PxActor* pxHitActor = pxHits[i].actor;
if (nullptr != pxHitActor && nullptr != pxHitActor->userData) {
- PhsXUserData* pUserData = (PhsXUserData*)pxHitActor->userData;
+ PHYSX_USERDATA* pUserData = (PHYSX_USERDATA*)pxHitActor->userData;
ON_COLLISION_INFO tagCollInfo = {};
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp b/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
index 9873105ac..fa04c9144 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Dagger.cpp
@@ -202,7 +202,7 @@ void CGoblin_Dagger::Dagger_Hit()
XMStoreFloat4(&tagCollInfo.vHitDir, vDir);
tagCollInfo.fLength = fLength;
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (PXOBJECT(pUserData->iSubKind))
{
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp b/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp
index 7c75e3eb8..91479b8ca 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Mage.cpp
@@ -82,9 +82,6 @@ void CGoblin_Mage::Priority_Update(_float fTimeDelta)
void CGoblin_Mage::Update(_float fTimeDelta)
{
- if (m_bVisible == false)
- return;
-
m_pFSM->Update_State(fTimeDelta);
m_pModelCom->Play_Animation(fTimeDelta, m_pTransformCom);
@@ -285,7 +282,6 @@ _vector CGoblin_Mage::Get_LockOnPos()
void CGoblin_Mage::OnCollision(CGameObject* pOther, void* pDesc)
{
-
if (true == m_bDead) {
return;
}
@@ -332,6 +328,12 @@ void CGoblin_Mage::OnCollision(CGameObject* pOther, void* pDesc)
case ENUM_CLASS(SKILL_TYPE::STUPEFY):
m_eHitSpell = ENUM_CLASS(SKILL_TYPE::STUPEFY);
break;
+ case ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
+ break;
}
}
else
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp b/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp
index 4cc70cbc5..98eb7e5ff 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Mage_States.cpp
@@ -466,7 +466,11 @@ void CGoblin_Mage::Behavior_HitEnter()
pairAnimInfo = m_Animation[STATEANIM::INCARCEROUS];
break;
default:
- pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_R];
+ _int iRand = m_pGameInstance->Real_Random_Int(0, 1);
+ if(iRand == 0)
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_L];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_R];
break;
}
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Protego.cpp b/Jusin154_Team3D/Client/Private/Goblin_Protego.cpp
index 95dfce590..c1fab98b3 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_Protego.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_Protego.cpp
@@ -73,6 +73,9 @@ void CGoblin_Protego::Update(_float fTimeDelta)
Update_Event(fTimeDelta);
+ if (m_bVisible == false) {
+ m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(0.f, 0.f, 0.f, 1.f));
+ }
/* 시작 사이즈 러프 */
@@ -92,10 +95,8 @@ void CGoblin_Protego::Late_Update(_float fTimeDelta)
{
if (m_bVisible == false)
return;
-
+ m_pTransformCom->Set_State(STATE::POSITION, m_pOwner->Get_Component()->Get_Position());
__super::Late_Update(fTimeDelta);
-
-
}
HRESULT CGoblin_Protego::Pre_Setting(CGameObject* pObject, void* pArg)
@@ -127,6 +128,15 @@ HRESULT CGoblin_Protego::Ready_Components(void* pArg)
return E_FAIL;
}
+ { // DO
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::GOBLIN_PROTEGO);
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_SHIELD"), (CComponent**)&m_pRigidBody, &Desc))) {
+ return E_FAIL;
+ }
+ m_pGameInstance->Attach_Actor(*m_pRigidBody->Get_Actor(), NEXT_LEVEL);
+ }
+
return S_OK;
}
@@ -164,6 +174,8 @@ CGameObject* CGoblin_Protego::Clone(void* pArg, CGameObject* pOwner)
void CGoblin_Protego::OnCollision(CGameObject* pOther, void* pDesc)
{
+ if (!m_bVisible)
+ return;
//CTransform* pOtherTransform = p
ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc);
@@ -180,6 +192,7 @@ void CGoblin_Protego::Free()
SAFE_RELEASE(m_pSphere);
SAFE_RELEASE(m_pBottom);
SAFE_RELEASE(m_pCircle);
+ SAFE_RELEASE(m_pRigidBody);
}
#ifdef _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Goblin_States.cpp b/Jusin154_Team3D/Client/Private/Goblin_States.cpp
index 1eac9fdf9..93d98f143 100644
--- a/Jusin154_Team3D/Client/Private/Goblin_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Goblin_States.cpp
@@ -30,9 +30,7 @@
void CGoblin::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::Behavior_IdleExitCheck()
@@ -41,6 +39,10 @@ HRESULT CGoblin::Behavior_IdleExitCheck()
{
m_bLookAt = false;
m_bDetection = true;
+
+ pair<_uint, _bool> pairAnimInfo = m_Animation[STATEANIM::IDLE];
+
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
if ((m_fTargetDistance <= 10.f && m_fTargetDistance != 0.f) /*|| m_pDetection->Get_Step() == true*/)
{
@@ -131,8 +133,6 @@ HRESULT CGoblin::Behavior_MoveExitCheck(_float fTimeDelta)
pair<_uint, _bool> pairAnimInfo = {};
_uint iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
-
-
if (m_fTargetDistance >= 6.f)
{
pairAnimInfo = m_Animation[STATEANIM::JOG_FWD];
@@ -207,8 +207,6 @@ void CGoblin::Behavior_CombatEnter()
HRESULT CGoblin::Behavior_CombatExitCheck(_float fTimeDelta)
{
- m_bLookAt = true;
-
if (m_fTargetDistance > 25.f && m_fTargetDistance != 0.f)
{
m_pFSM->Change_State(FSMSTATE::IDLE);
@@ -267,7 +265,7 @@ void CGoblin::Behavior_SwingEnter()
m_pGoblinSpector->Set_Visible(true);
m_pGoblinSpector->Spector_Trail_Visible(true);
- m_pEffectPool->Use_Skill(SKILL_TYPE::GOBLIN_ATTACK, m_pGoblinSpector->Get_PartObject());
+ m_pEffectPool->Use_Skill(SKILL_TYPE::GOBLIN_ATTACK, m_pGoblinSpector->Get_PartObject(), (void*)&m_pGoblinSpector->Get_PartObject()->Get_AxeMatrix());
},
0.05f);
@@ -286,7 +284,7 @@ void CGoblin::Behavior_SwingEnter()
Set_Easing(pairAnimInfo.first, 0.01f, 0.15f, 0.8f);
- Set_Easing(pairAnimInfo.first, 0.2f, 0.4f, 1.4f);
+ Set_Easing(pairAnimInfo.first, 0.15f, 0.4f, 1.4f);
}
HRESULT CGoblin::Behavior_SwingExitCheck(_float fTimeDelta)
@@ -549,7 +547,11 @@ void CGoblin::Behavior_HitEnter()
pairAnimInfo = m_Animation[STATEANIM::INCARCEROUS];
break;
default:
- pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_R];
+ _int iRand = m_pGameInstance->Real_Random_Int(0, 1);
+ if (iRand == 0)
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_L];
+ else
+ pairAnimInfo = m_Animation[STATEANIM::STUMBLE_BWD_R];
break;
}
@@ -798,7 +800,7 @@ void CGoblin::HitState_Behavior(_float fTimeDelta)
m_pCharacter_Controller->ConvertToDO(*m_pRigidBody);
_vector vCameraLook = m_pGameInstance->Get_CameraLook();
vCameraLook = XMVector3Normalize(vCameraLook);
- m_pRigidBody->Add_Force(vCameraLook * 30.f, PSX::PxForceMode::eIMPULSE);
+ m_pRigidBody->Add_Force(vCameraLook * 60.f, PSX::PxForceMode::eIMPULSE);
m_fAirTime = 0.f;
}
break;
diff --git a/Jusin154_Team3D/Client/Private/Goblin_Sword.cpp b/Jusin154_Team3D/Client/Private/Goblin_Sword.cpp
new file mode 100644
index 000000000..8ba90ac83
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Goblin_Sword.cpp
@@ -0,0 +1,328 @@
+#include "pch.h"
+#include "Goblin_Sword.h"
+
+#include "GameInstance.h"
+#include "Goblin.h"
+
+CGoblin_Sword::CGoblin_Sword(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CPartObject(pDevice, pContext)
+{
+}
+
+CGoblin_Sword::CGoblin_Sword(const CGoblin_Sword& Prototype)
+ : CPartObject(Prototype)
+{
+}
+
+HRESULT CGoblin_Sword::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CGoblin_Sword::Initialize(void* pArg)
+{
+ GOBLIN_SWORD_DESC* pDesc = static_cast (pArg);
+ m_pSocketMatrices = pDesc->pSocketMatrices;
+ m_iIndex = pDesc->iIndex;
+
+ if (FAILED(__super::Initialize(pArg))) {
+ return E_FAIL;
+ }
+
+
+ if (FAILED(Ready_Components())) {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CGoblin_Sword::Priority_Update(_float fTimeDelta)
+{
+
+
+
+#ifdef _DEBUG
+ Describe_Entity();
+
+#endif // _DEBUG
+}
+
+void CGoblin_Sword::Update(_float fTimeDelta)
+{
+ if (m_bDisolve) {
+ m_fDisolveTime += fTimeDelta;
+ if (m_fDisolveTime >= 1.f)
+ {
+ m_fDisolveTime = 0.f;
+ m_bDisolve = false;
+ m_bVisible = false;
+ }
+ }
+}
+
+void CGoblin_Sword::Late_Update(_float fTimeDelta)
+{
+ XMStoreFloat4(&m_vStartPos, m_pTransformCom->Get_State(STATE::POSITION));
+
+ _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_vSwordMat, XMLoadFloat4x4(m_pModelCom->Get_BoneMatrixPtr("Bone")) * m_pTransformCom->Get_XMWorldMatrix());
+ if (m_bCanTakeDamage)
+ {
+ Sword_Hit();
+ }
+ else {
+ m_bHit = false;
+ }
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+}
+
+HRESULT CGoblin_Sword::Render()
+{
+ if (!m_pModelCom)
+ return S_OK;
+
+ if (!m_bVisible)
+ return S_OK;
+
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ if (FAILED(Render_Disolve())) {
+ 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::SPECTOR_WEAPON)))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+
+ {
+ _bool bDisolve = false;
+ _float zero = 0.f;
+ m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool));
+ m_pShaderCom->Bind_RawValue("g_fDisolveRatio", &zero, sizeof(_float));
+ }
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Sword::Render_Disolve()
+{
+ if (FLT_EPSILON3 * 10 < m_fDisolveTime)
+ {
+ _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_fDisolveTime, 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_DisolveTexture"))) {
+ return E_FAIL;
+ }
+ }
+
+ return S_OK;
+}
+
+HRESULT CGoblin_Sword::Ready_Components()
+{
+
+ CTransform::TRANSFORM_DESC Desc = {};
+
+ Desc.fSpeedPerSec = 10.f;
+ Desc.fRotationPerSec = XMConvertToRadians(180.0f);
+ Desc.fRadius = 10.f;
+
+ __super::Ready_Components(&Desc);
+
+
+ if (m_iIndex == 0)
+ {
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Goblin_Sword_L_Model");
+ }
+ else {
+ m_strModelPrototypeTag = TEXT("Prototype_Component_Goblin_Sword_R_Model");
+ }
+
+ /* Com_Model */
+ if (FAILED(__super::Add_Asset_Component(g_iStaticLevel, m_strModelPrototypeTag,
+ 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_Sword::Bind_ShaderResources()
+{
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_WorldMatrix", m_pTransformCom->Get_WorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ 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;
+}
+
+void CGoblin_Sword::Sword_Hit()
+{
+ _vector vStartPos = XMLoadFloat4(&m_vStartPos);
+ _vector vEndPos = m_pTransformCom->Get_State(STATE::POSITION);
+ _vector vDir = vEndPos - vStartPos;
+ _float fLength = XMVectorGetX(XMVector4Length(vDir));
+ vDir = XMVector4Normalize(vDir);
+ m_SweepBuffer = {};
+ _bool bHit = m_pGameInstance->SphereCast(0.5f, vStartPos, vDir, fLength, PSX::PxHitFlag::eDEFAULT, PSX::PxQueryFlag::eDYNAMIC, m_SweepBuffer);
+ if (true == bHit) {
+ vector Hits;
+ _uint iHitCount = m_SweepBuffer.nbTouches;
+ if (true == m_SweepBuffer.hasBlock) {
+ iHitCount += 1;
+ Hits.reserve(iHitCount);
+ Hits.emplace_back(&m_SweepBuffer.block);
+ }
+ else {
+ Hits.reserve(iHitCount);
+ }
+ for (_uint i = 0; i < m_SweepBuffer.nbTouches; ++i) {
+ Hits.emplace_back(&m_SweepBuffer.touches[i]);
+ }
+
+ for (_uint i = 0; i < Hits.size(); ++i) {
+ PSX::PxSweepHit* pHit = Hits[i];
+ PSX::PxActor* pActor = pHit->actor;
+ if (nullptr != pActor && nullptr != pActor->userData) {
+ const PSX::PxSweepHit& hit = m_SweepBuffer.block;
+ PSX::PxShape* pShape = hit.shape;
+ ON_COLLISION_INFO tagCollInfo = {};
+
+ tagCollInfo.vWorldPos.w = 1.f;
+
+ 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 = fLength;
+ tagCollInfo.fDamage = 10.f;
+ tagCollInfo.eHitType = ENUM_CLASS(HIT_TYPE::HIT_MEDIUM);
+
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
+ tagCollInfo.pObject = pUserData->pOwner;
+ switch (PXOBJECT(pUserData->iSubKind))
+ {
+ case Engine::PXOBJECT::PLAYER:
+ {
+ pUserData->pOwner->OnCollision(this, &tagCollInfo);
+ m_bHit = true;
+ m_bCanTakeDamage = false;
+ }
+ break;
+ case Engine::PXOBJECT::ALLY_HITBOX:
+ break;
+ default:
+ break;
+ }
+
+
+ }
+ }
+ }
+}
+
+
+CGoblin_Sword* CGoblin_Sword::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CGoblin_Sword* pInstance = new CGoblin_Sword(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CGoblin_Sword");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CGoblin_Sword::Clone(void* pArg, CGameObject* pOwner)
+{
+ CGoblin_Sword* pInstance = new CGoblin_Sword(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CGoblin_Sword");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CGoblin_Sword::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pModelCom);
+
+}
+#ifdef _DEBUG
+
+void CGoblin_Sword::Describe_Entity()
+{
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Level_Field.cpp b/Jusin154_Team3D/Client/Private/Level_Field.cpp
index 9c23705d7..70e9b924c 100644
--- a/Jusin154_Team3D/Client/Private/Level_Field.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_Field.cpp
@@ -130,7 +130,22 @@ HRESULT CLevel_Field::Ready_Lights()
{
CLight_Main* pLight = { nullptr };
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT,nullptr, nullptr, &pLight))) {
+ LIGHT_DESC Desc = {};
+ if (m_isDay)
+ {
+ Desc.vDiffuse = _float4(0.6529f, 0.6157f, 0.7843f, 1.0f);
+ Desc.vAmbient = _float4(0.6275f, 0.6275f, 0.6275f, 0.0314f);
+ Desc.vSpecular = _float4(0.05f, 0.05f, 0.05f, 0.05f);
+ }
+ else
+ {
+ Desc.vDiffuse = _float4(0.0471f, 0.0745f, 0.1294f, 0.2549f);
+ Desc.vAmbient = _float4(0.1686f, 0.1765f, 0.1373f, 0.0f);
+ Desc.vSpecular = _float4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT, &Desc, nullptr, &pLight))) {
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
index 2cca88c8f..84ebb9e3b 100644
--- a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
@@ -4,13 +4,12 @@
#include "Level_Loading.h"
#include "Light_Main.h"
#include "Camera_Debug.h"
+#include "Camera_Model.h"
#include "InfoInstance.h"
#include "UI_Manager.h"
#include "Layer.h"
#include "SkyBox.h"
#include "Broom.h"
-#include "Dummy_PhysXWall.h"
-#include "Dummy_PhysXPlayable.h"
#include "Terrain.h"
#include "EffectPool.h"
#include "InstancedProp.h"
@@ -25,6 +24,7 @@
#include "Troll.h"
#include "Goblin.h"
#include "Goblin_Mage.h"
+#include "Goblin_Assassin.h"
#include "Goblin_Spector.h"
#include "NPC_Ollivander.h"
#include "NPC_EleazarFig.h"
@@ -42,10 +42,31 @@ CLevel_GamePlay::CLevel_GamePlay(ID3D11Device* pDevice, ID3D11DeviceContext* pCo
HRESULT CLevel_GamePlay::Initialize(void* pArg)
{
+ // 낮, 밤 설정
+#ifdef gimch
+ m_isDay = false;
+#endif // gimch
+#ifdef Bin
+ m_isDay = true;
+#endif //
+#ifdef 진우
+ m_isDay = true;
+#endif //
+#ifdef 기무리
+ m_isDay = true;
+#endif //
+#ifdef 인혁
+ m_isDay = true;
+#endif //
+
if (FAILED(Ready_Lights())) {
return E_FAIL;
}
+ if (FAILED(Ready_Volumetric())) {
+ return E_FAIL;
+ }
+
//플레이어 , 맵 보다 먼저 생성해야함 !
if (FAILED(Reday_Layer_EffectPool())) {
return E_FAIL;
@@ -164,13 +185,54 @@ HRESULT CLevel_GamePlay::Render()
HRESULT CLevel_GamePlay::Ready_Lights()
{
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT))) {
+
+ LIGHT_DESC Desc = {};
+ if (m_isDay)
+ {
+ Desc.vDiffuse = _float4(0.6529f, 0.6157f, 0.7843f, 1.0f);
+ Desc.vAmbient = _float4(0.6275f, 0.6275f, 0.6275f, 0.0314f);
+ Desc.vSpecular = _float4(0.05f, 0.05f, 0.05f, 0.05f);
+ }
+ else
+ {
+ Desc.vDiffuse = _float4(0.0471f, 0.0745f, 0.1294f, 0.2549f);
+ Desc.vAmbient = _float4(0.1686f, 0.1765f, 0.1373f, 0.0f);
+ Desc.vSpecular = _float4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(ENUM_CLASS(LEVEL::STATIC), NEXT_LEVEL, LAYER_LIGHT, &Desc))) {
return E_FAIL;
}
return S_OK;
}
+HRESULT CLevel_GamePlay::Ready_Volumetric()
+{
+ // Volumetric 설정
+ if(m_isDay)
+ {
+ m_pGameInstance->Setting_Volumetirc(
+ 1.251f, // 밀도
+ 0.0253f, // 빛 강도
+ 0.9f, // 산란 계수
+ 1.78f // 깊이 분포 계수
+ );
+ }
+ else
+ {
+ m_pGameInstance->Setting_Volumetirc(
+ 0.626f, // 밀도
+ 0.01f, // 빛 강도
+ 0.11f, // 산란 계수
+ 1.0f // 깊이 분포 계수
+ );
+ }
+
+ return S_OK;
+}
+
HRESULT CLevel_GamePlay::Ready_Background()
{
CTerrain::TERRAIN_DESC Terrain_Desc = {};
@@ -267,8 +329,8 @@ HRESULT CLevel_GamePlay::Ready_Background()
#endif //
#ifdef 기무리
isReady_Background = true;
- isReady_Hogsmeade = true;
- isReady_Hogwart = true;
+ isReady_Hogsmeade = false;
+ isReady_Hogwart = false;
#endif //
#ifdef 인혁
isReady_Background = false;
@@ -582,33 +644,57 @@ HRESULT CLevel_GamePlay::Ready_Layer_Player(const _wstring& strLayerTag)
return E_FAIL;
}
- {
- CNPC_Ollivander::NPCDESC NPCDesc{};
- NPCDesc.vPos = _float4(40.f, 4.f, 68.9f, 1.f);
- NPCDesc.vRotQ = _float4(0.f, 0.f, 0.f, 1.f);
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, &NPCDesc))) {
- return E_FAIL;
- }
- }
- {
- CNPC_EleazarFig::NPCDESC NPCDesc{};
- NPCDesc.vPos = _float4(101.f, 14.f, 100.f, 1.f);
- NPCDesc.vRotQ = _float4(0.f, 0.f, 0.f, 1.f);
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, &NPCDesc))) {
- return E_FAIL;
- }
- }
+ _bool isLoad_NPC = { true };
+#ifdef _DEBUG
+#ifdef gimch
+
+#endif // gimch
+#ifdef 진우
+
+#endif //
+#ifdef 기무리
+ isLoad_NPC = true;
+#endif //
+#ifdef 인혁
+
+#endif //
+#ifdef Bin
+
+#endif // Bin
+#endif // _DEBUG
+
+ if(true == isLoad_NPC)
+ {
+ {
+ CNPC_Ollivander::NPCDESC NPCDesc{};
+ NPCDesc.vPos = _float4(40.f, 4.f, 68.9f, 1.f);
+ NPCDesc.vRotQ = _float4(0.f, 0.f, 0.f, 1.f);
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, &NPCDesc))) {
+ return E_FAIL;
+ }
+ }
+ {
+ CNPC_EleazarFig::NPCDESC NPCDesc{};
+ NPCDesc.vPos = _float4(101.f, 14.f, 100.f, 1.f);
+ NPCDesc.vRotQ = _float4(0.f, 0.f, 0.f, 1.f);
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, &NPCDesc))) {
+ return E_FAIL;
+ }
+ }
+ }
return S_OK;
}
HRESULT CLevel_GamePlay::Ready_Layer_BroomRacerAI(const _wstring& strLayerTag)
{
- for (_uint i = 0; i < 10; ++i) {
+#ifdef Bin
+ for (_uint i = 0; i < 0; ++i) {
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, m_pBroomRaceManager))) {
return E_FAIL;
}
}
+#endif // Bin
return S_OK;
}
@@ -619,15 +705,16 @@ HRESULT CLevel_GamePlay::Ready_Layer_Item(const _wstring& strLayerTag)
HRESULT CLevel_GamePlay::Ready_Layer_RaceRing(const _wstring& strLayerTag)
{
- for (_uint i = 0; i < 10; ++i) {
+ for (_uint i = 0; i < 1; ++i) {
- CRaceRing::RACERING_DESC RaceRingDesc {};
+ CRaceRing::RACERING_DESC RaceRingDesc{};
RaceRingDesc.pBroomRaceManager = m_pBroomRaceManager;
RaceRingDesc.iIndex = i;
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, &RaceRingDesc))) {
return E_FAIL;
}
}
+
return S_OK;
}
@@ -637,49 +724,65 @@ HRESULT CLevel_GamePlay::Ready_Layer_SkyBox(const _wstring& strLayerTag)
return E_FAIL;
}
- CDummy_PhysXWall::PHYSXDUMMY_DESC Desc{};
- Desc.vPos = { 0.f, 0.f, 0.f };
- Desc.vRotRPY = { 0.f, m_pGameInstance->Random_Float(0.f, XM_2PI), 0.f };
- Desc.iSubKind = ENUM_CLASS(PXOBJECT::WALL);
-
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_CUBE, &Desc))) {
- return E_FAIL;
- }
-
return S_OK;
}
HRESULT CLevel_GamePlay::Ready_Layer_Monster()
{
- for (_uint i = 0; i <1; ++i)
- {
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
+ _bool isLoad_Monster = { true };
+#ifdef _DEBUG
+#ifdef gimch
+
+#endif // gimch
+#ifdef 진우
+
+#endif //
+#ifdef 기무리
+ isLoad_Monster = true;
+#endif //
+#ifdef 인혁
+
+#endif //
+#ifdef Bin
+
+#endif // Bin
+#endif // _DEBUG
+ if (true == isLoad_Monster) {
+ for (_uint i = 0; i < 1; ++i)
+ {
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
+ return E_FAIL;
+ }
+ }
+
+ for (_uint i = 0; i < 1; ++i)
+ {
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
+ return E_FAIL;
+ }
+ }
+
+ for (_uint i = 0; i < 1; ++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;
}
- }
- for (_uint i = 0; i <1; ++i)
- {
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER))) {
+ 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;
- }
-
#if 진우
#else
#endif
-
-
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Light_Main.cpp b/Jusin154_Team3D/Client/Private/Light_Main.cpp
index 07378ca26..4a6a16f7a 100644
--- a/Jusin154_Team3D/Client/Private/Light_Main.cpp
+++ b/Jusin154_Team3D/Client/Private/Light_Main.cpp
@@ -23,10 +23,12 @@ HRESULT CLight_Main::Initialize(void* pArg)
if (FAILED(__super::Initialize(pArg))){
return E_FAIL;
}
- if (FAILED(Ready_Components())){
+ if (FAILED(Ready_Components(pArg))){
return E_FAIL;
}
+ m_pTransformCom->Set_State(STATE::LOOK, XMVectorSet(-1.716f, 0.121f, 0.211f, 0.f));
+
return S_OK;
}
@@ -88,23 +90,23 @@ HRESULT CLight_Main::Capture_PreShadow()
_float4x4 ProjMatrix = {}; XMStoreFloat4x4(&ProjMatrix, Get_OffCenterProjMatrix(xmViewMatrix, vNeededPos));
m_pGameInstance->Render_PreShadow(ViewMatrix, ProjMatrix);
+
+ m_pGameInstance->Update_Volumetric();
return S_OK;
}
-HRESULT CLight_Main::Ready_Components()
+HRESULT CLight_Main::Ready_Components(void* pArg)
{
__super::Ready_Components(nullptr);
- m_pTransformCom->LookAt(XMVectorSet(1.f, -4.f, 1.f, 1.f));
+ LIGHT_DESC* pLightDescArg = static_cast(pArg);
+
LIGHT_DESC LightDesc{};
LightDesc.eType = LIGHT::DIRECTIONAL;
- //LightDesc.vDiffuse = _float4(0.8f, 0.8f, 0.8f, 0.f);
- //LightDesc.vAmbient = _float4(0.6f, 0.6f, 0.6f, 0.f);
- //LightDesc.vSpecular = _float4(0.f, 0.f, 0.f, 0.f);
- LightDesc.vDiffuse = _float4(0.3f, 0.3f, 0.1f, 0.f);
- LightDesc.vAmbient = _float4(0.12f, 0.12f, 0.24f, 0.f);
- LightDesc.vSpecular = _float4(0.f, 0.f, 0.f, 0.f);
+ LightDesc.vDiffuse = pLightDescArg->vDiffuse;
+ LightDesc.vAmbient = pLightDescArg->vAmbient;
+ LightDesc.vSpecular = pLightDescArg->vSpecular;
LightDesc.pDirection = m_pTransformCom->Get_StatePtr(STATE::LOOK);
LightDesc.iLevel = NEXT_LEVEL;
diff --git a/Jusin154_Team3D/Client/Private/Lightning.cpp b/Jusin154_Team3D/Client/Private/Lightning.cpp
index 975c21975..04c8df5ab 100644
--- a/Jusin154_Team3D/Client/Private/Lightning.cpp
+++ b/Jusin154_Team3D/Client/Private/Lightning.cpp
@@ -39,7 +39,7 @@ HRESULT CLightning::Initialize(void* pArg)
if (FAILED(Create_Effect()))
return E_FAIL;
- m_iSkillType = ENUM_CLASS(SKILL_TYPE::LIGHTNING);
+ m_iSkillType = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
m_wstrEffectName = L"Lightning";
@@ -82,14 +82,15 @@ void CLightning::Late_Update(_float fTimeDelta)
__super::Late_Update(fTimeDelta);
- //if (false == m_bHit) {
- // _vector vStartPos = XMLoadFloat4(&m_vStartPos);
- // _vector vEndPos = XMLoadFloat4(&m_vEndPos);
- // ON_COLLISION_INFO CollisionInfo = SweepTarget(vStartPos, vEndPos, 0.002f , true);
+ if (false == m_bHit) {
+ _vector vTop = XMLoadFloat4(&m_vTargetPos) + XMVectorSet(0.f, 5.f, 0.f, 0.f);
- // OnCollision(this, &CollisionInfo);
- //}
+ _vector vBottom = XMLoadFloat4(&m_vTargetPos) - XMVectorSet(0.f, 5.f, 0.f, 0.f);
+ ON_COLLISION_INFO CollisionInfo = SweepTarget(vTop, vBottom, 0.02f, true);
+
+ OnCollision(this, &CollisionInfo);
+ }
}
HRESULT CLightning::Pre_Setting(CGameObject* pObject, void* pArg)
@@ -215,7 +216,7 @@ void CLightning::OnCollision(CGameObject* pOther, void* pDesc)
pPair.second->Get_Component()->Set_State(STATE::POSITION, vPos);
}
- CWand* pWand = static_cast(m_pOwner)->Get_PartObject();
+ CWand* pWand = static_cast(m_pOwner);
if (pWand == nullptr)
return;
diff --git a/Jusin154_Team3D/Client/Private/Loader.cpp b/Jusin154_Team3D/Client/Private/Loader.cpp
index b76bba824..1da230075 100644
--- a/Jusin154_Team3D/Client/Private/Loader.cpp
+++ b/Jusin154_Team3D/Client/Private/Loader.cpp
@@ -14,6 +14,7 @@
#include "CamPosition_Socket.h"
#include "CamPosition_Target.h"
#include "CamPosition_AI.h"
+#include "Camera_Model.h"
#include "SkyBox.h"
#include "Troll_Weapon.h"
#include "Troll_Rock.h"
@@ -21,15 +22,19 @@
#include "Wand.h"
#include "Item_Potion.h"
#include "RaceRing.h"
+#include "Goblin_Sword.h"
#include "Goblin_BattleAxe.h"
#include "BroomRaceManager.h"
#pragma region ACTOR
#include "Player.h"
+#include "PlayerRobe.h"
#include "Goblin.h"
#include "Goblin_Mage.h"
+#include "Goblin_Assassin.h"
#include "Goblin_Spector.h"
+#include "Goblin_Assassin_Spector.h"
#include "Troll.h"
#include "NPC_Ollivander.h"
#include "NPC_EleazarFig.h"
@@ -135,9 +140,6 @@
#pragma endregion
#pragma region PHYSX
-
-#include "Dummy_PhysXWall.h"
-#include "Dummy_PhysXPlayable.h"
#include "PhysXEffectHitBox.h"
#pragma endregion
@@ -355,27 +357,39 @@ HRESULT CLoader::Loading_For_GamePlay()
_bool isLoad_Background = { true };
_bool isLoad_Hogwart = { false };
+ _bool isLoad_UI_SEQUANTIAL = { true };
+ _bool isLoad_NPC = { true };
+ _bool isLoad_Monster = { true };
+#ifdef _DEBUG
#ifdef gimch
isLoad_Background = true;
isLoad_Hogwart = false;
+ isLoad_UI_SEQUANTIAL = false;
#endif // gimch
-#ifdef Bin
- isLoad_Background = false;
- isLoad_Hogwart = false;
-#endif //
#ifdef 진우
isLoad_Background = false;
isLoad_Hogwart = false;
+ isLoad_UI_SEQUANTIAL = false;
#endif //
#ifdef 기무리
isLoad_Background = true;
- isLoad_Hogwart = true;
+ isLoad_Hogwart = false;
+ isLoad_UI_SEQUANTIAL = false;
+ isLoad_NPC = true;
+ isLoad_Monster = true;
#endif //
#ifdef 인혁
isLoad_Background = false;
isLoad_Hogwart = false;
+ isLoad_UI_SEQUANTIAL = false;
#endif //
+#ifdef Bin
+ isLoad_Background = false;
+ isLoad_Hogwart = false;
+ isLoad_UI_SEQUANTIAL = false;
+#endif // Bin
+#endif // _DEBUG
#pragma region MAP_MODELS
vector*>> jobMapModels;
@@ -945,8 +959,6 @@ HRESULT CLoader::Loading_For_GamePlay()
}
#pragma endregion
-
-
#pragma region UI
Asset_FileLoad("../Bin/Resources/Textures/Keyboard", L"Prototype_Texture_", [&](_wstring wstrFileName, const _char* pFilePath)
@@ -1225,106 +1237,103 @@ HRESULT CLoader::Loading_For_GamePlay()
{
return E_FAIL;
}
+#pragma region UI_ANI
+ if (true == isLoad_UI_SEQUANTIAL) {
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Ancient_Magic"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Ancient_Magic\\Ancient_Magic%d.png"), 152))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Ancient_Magic_Throw"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Ancient_Magic_Throw\\Ancient_Magic_Throw%d.png"), 89))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Arresto_Momentum"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Arresto_Momentum\\Arresto_Momentum%d.png"), 120))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Avada_Kedavra"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Avada_Kedavra\\Avada_Kedavra%d.png"), 208))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Basic_Cast"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Basic_Cast\\Basic_Cast%d.png"), 308))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Bombarda"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Bombarda\\Bombarda%d.png"), 262))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Descendo"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Descendo\\Descendo%d.png"), 155))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Levioso"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Levioso\\Levioso%d.png"), 180))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Lumos"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Lumos\\Lumos%d.png"), 365))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Petrificus_Totalus"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Petrificus_Totalus\\Petrificus_Totalus%d.png"), 275))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Protego"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Protego\\Protego%d.png"), 285))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Revelio"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Revelio\\Revelio%d.png"), 227))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Stupefy"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Stupefy\\Stupefy%d.png"), 222))))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Transformation"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Transformation\\Transformation%d.png"), 146))))
+ {
+ return E_FAIL;
+ }
+
+ }
+#pragma endregion
+
+#pragma endregion
#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
-#if 진우
-#elif 기무리
-#elif 인혁
-#elif Bin
-#elif gimch
-#else
-#pragma region UI_ANI
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Ancient_Magic"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Ancient_Magic\\Ancient_Magic%d.png"), 152))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Ancient_Magic_Throw"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Ancient_Magic_Throw\\Ancient_Magic_Throw%d.png"), 89))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Arresto_Momentum"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Arresto_Momentum\\Arresto_Momentum%d.png"), 120))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Avada_Kedavra"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Avada_Kedavra\\Avada_Kedavra%d.png"), 208))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Basic_Cast"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Basic_Cast\\Basic_Cast%d.png"), 308))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Bombarda"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Bombarda\\Bombarda%d.png"), 262))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Descendo"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Descendo\\Descendo%d.png"), 155))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Levioso"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Levioso\\Levioso%d.png"), 180))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Lumos"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Lumos\\Lumos%d.png"), 365))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Petrificus_Totalus"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Petrificus_Totalus\\Petrificus_Totalus%d.png"), 275))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Protego"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Protego\\Protego%d.png"), 285))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Revelio"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Revelio\\Revelio%d.png"), 227))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Stupefy"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Stupefy\\Stupefy%d.png"), 222))))
- {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Transformation"),
- CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Transformation\\Transformation%d.png"), 146))))
- {
- return E_FAIL;
- }
-
-#pragma endregion
-#endif
-
#pragma region TERRAIN_TEXTURE
/* Terrain_Diffuse */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Terrain_Diffuse"),
@@ -1373,7 +1382,6 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
}
#pragma endregion
-
#pragma region LAKE_TEXTURE
/* For.Prototype_Component_Water_Noise_D */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("T_Noises_D"),
@@ -1510,6 +1518,7 @@ HRESULT CLoader::Loading_For_GamePlay()
#pragma endregion
+#pragma region SHADER
m_strMessage = TEXT("셰이더를(을) 로딩 중 입니다.");
@@ -1531,7 +1540,7 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, FX_INSTANCE_PROP_MODEL,
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, FX_INSTANCE_PROP_MODEL,
CShader::Create(m_pDevice, m_pContext, TEXT("../Bin/Resources/ShaderFiles/Shader_VtxWorldModelInstance.hlsl"),
VTX_MODEL_INSTANCE_MODEL::Elements, VTX_MODEL_INSTANCE_MODEL::iNumElements)))) {
return E_FAIL;
@@ -1572,6 +1581,7 @@ HRESULT CLoader::Loading_For_GamePlay()
return E_FAIL;
}
+#pragma endregion
m_strMessage = TEXT("모델를(을) 로딩 중 입니다.");
CVIBuffer_UI_Instance::UI_INSTANCE_DESC SpellSlotUIDesc{};
@@ -1663,7 +1673,68 @@ HRESULT CLoader::Loading_For_GamePlay()
CVIBuffer_UI_Instance::Create(m_pDevice, m_pContext, &Quest_Slot_Desc)))) {
return E_FAIL;
}
-
+ {
+ CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
+ Desc.eType = ACTOR::SPHERE;
+ Desc.ePxRigidBodyFlags = { /*PSX::PxRigidBodyFlag::eKINEMATIC*/ };
+ Desc.ePxShapeFlags = { PSX::PxShapeFlag::eVISUALIZATION | PSX::PxShapeFlag::eSCENE_QUERY_SHAPE | PSX::PxShapeFlag::eSIMULATION_SHAPE };
+ Desc.ePxMaterialTypes = { PXMATERIAL::DEFAULT };
+ Desc.vMatInfo = { 0.5f, 0.5f, 0.001f };
+ Desc.fContactOffset = { 0.005f };
+ Desc.vhalfGeometryInfo = { 0.025f, 0.025f, 0.025f };
+ Desc.fDensity = 0.01f;
+ Desc.pxMassCenter = PSX::PxTransform(PSX::PxIDENTITY());
+ Desc.eLockFlag = {};
+ Desc.vAutoDamping = { 12.f, 12.f };
+ Desc.vLocalRotQ = { 0.f, 0.f, 0.f, 1.f };
+ Desc.vLocalTranslation = { 0.f, 0.f, 0.f };
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_JOINT_ANCHOR"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
+ return E_FAIL;
+ }
+ }
+ {
+ CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
+ Desc.eType = ACTOR::CAPSULE;
+ Desc.ePxRigidBodyFlags = { /*PSX::PxRigidBodyFlag::eKINEMATIC*/ };
+ Desc.ePxShapeFlags = { PSX::PxShapeFlag::eVISUALIZATION | PSX::PxShapeFlag::eSCENE_QUERY_SHAPE | PSX::PxShapeFlag::eSIMULATION_SHAPE };
+ Desc.ePxMaterialTypes = { PXMATERIAL::DEFAULT };
+ Desc.vMatInfo = { 0.5f, 0.5f, 0.001f };
+ Desc.fContactOffset = { 0.005f };
+ Desc.vhalfGeometryInfo = { 0.025f, 0.085f, 0.f };
+ Desc.fDensity = 0.01f;
+ Desc.pxMassCenter = PSX::PxTransform(PSX::PxIDENTITY());
+ Desc.eLockFlag = {};
+ Desc.vAutoDamping = { 12.f, 12.f };
+ Desc.vLocalRotQ = { 0.f, 0.f, 0.f, 1.f };
+ Desc.vLocalTranslation = { 0.f, 0.f, 0.f };
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_JOINT_ROUTE"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
+ return E_FAIL;
+ }
+ }
+ {
+ CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
+ Desc.eType = ACTOR::CAPSULE;
+ Desc.ePxRigidBodyFlags = { PSX::PxRigidBodyFlag::eKINEMATIC };
+ Desc.ePxShapeFlags = { PSX::PxShapeFlag::eVISUALIZATION | PSX::PxShapeFlag::eSCENE_QUERY_SHAPE | PSX::PxShapeFlag::eSIMULATION_SHAPE };
+ Desc.ePxMaterialTypes = { PXMATERIAL::DEFAULT };
+ Desc.vMatInfo = { 0.5f, 0.5f, 0.01f };
+ Desc.fContactOffset = { 0.01f };
+ Desc.vhalfGeometryInfo = { 0.12f, 0.25f, 0.f };
+ Desc.fDensity = 122.f;
+ Desc.pxMassCenter = PSX::PxTransform(PSX::PxIDENTITY());
+ Desc.eLockFlag = {};
+ Desc.vAutoDamping = { 1.f, 1.f };
+ Desc.vLocalRotQ = { 0.f, 0.f, 0.f, 1.f };
+ Desc.vLocalTranslation = { 0.f, 0.f, 0.f };
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_Player_Leg"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
+ return E_FAIL;
+ }
+ }
+ {
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_DynamicJoint"), CDynamic_D6Joint::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ }
{ // LIGHT PHYSX DYNAMIC
CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
{
@@ -1690,7 +1761,7 @@ HRESULT CLoader::Loading_For_GamePlay()
Desc1.ePxMaterialTypes = { PXMATERIAL::DEFAULT };
Desc1.vMatInfo = { 0.5f, 0.5f, 0.6f };
Desc1.fContactOffset = { 0.05f };
- Desc1.vhalfGeometryInfo = { 1.f, 1.f, 1.f };
+ Desc1.vhalfGeometryInfo = { 2.f, 2.f, 2.f };
Desc1.fDensity = 1.f;
Desc1.pxMassCenter = PSX::PxTransform(PSX::PxIDENTITY());
Desc1.eLockFlag = {};
@@ -1702,22 +1773,21 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_HEAVY_WALL"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
return E_FAIL;
}
-
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_BOX"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
return E_FAIL;
}
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_SHIELD"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc1)))) {
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_CCT_CAPSULE"), CCharacter_Controller::Create(m_pDevice, m_pContext)))) {
- return E_FAIL;
- }
Desc.ePxRigidBodyFlags = { PSX::PxRigidBodyFlag::eKINEMATIC };
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_BOX_KIN"), CRigidBody_Dynamic::Create(m_pDevice, m_pContext, Desc)))) {
return E_FAIL;
}
- }
+ }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("PHYSX_CCT_CAPSULE"), CCharacter_Controller::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
{ // DOOR PHYSX
CRigidBody_Dynamic::RIGIDBODY_PROTOTYPE_DYNAMIC_DESC Desc{};
{
@@ -1760,55 +1830,69 @@ HRESULT CLoader::Loading_For_GamePlay()
CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/PlayableCharacter/Playable.bin", XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
return E_FAIL;
}
+ if (true == isLoad_NPC) {
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Npc_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Human/Npc/Npc.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GerboldOlivander_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/GerboldOllivander/GerboldOlivander.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Npc_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Human/Npc/Npc.bin",XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
- return E_FAIL;
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Professor_EleazarFig_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_VictorRookWood_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/VictorRookWood/VictorRookWood.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
}
+ if (true == isLoad_Monster) {
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin/Goblin.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
- return E_FAIL;
- }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin/Goblin.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ 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_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_Goblin_Assassin_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master.bin", XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GerboldOlivander_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/GerboldOllivander/GerboldOlivander.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/GerboldOllivander/GerboldOlivander.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
return E_FAIL;
}
if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Professor_EleazarFig_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))){
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_VictorRookWood_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/VictorRookWood/VictorRookWood.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
- return E_FAIL;
- }
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Ghost_Peeves_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/Ghost_Peeves/Ghost_Peeves.bin", XMMatrixScaling(0.1f, 0.1f, 0.1f) * XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
- return E_FAIL;
- }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Ghost_Peeves_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Human/Npc/Ghost_Peeves/Ghost_Peeves.bin", XMMatrixScaling(0.1f, 0.1f, 0.1f) * 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.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.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
- if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Ranrok_Model"),
- CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
- return E_FAIL;
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Ranrok_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::PBR_ANIM, "../Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.bin", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) {
+ return E_FAIL;
+ }
}
-
#pragma endregion
#pragma region ITEM
@@ -1841,13 +1925,27 @@ HRESULT CLoader::Loading_For_GamePlay()
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_Sword_L_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Goblin_Sword/SK_WPN_GOB_SmallSword_L.bin", XMMatrixIdentity()))))
+ return E_FAIL;
+
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_Goblin_Sword_R_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Goblin_Sword/SK_WPN_GOB_SmallSword_R.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", XMMatrixScaling(0.01f, 0.01f, 0.01f) * XMMatrixRotationX(XMConvertToRadians(-90.f)) * XMMatrixIdentity()))))
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Goblin_BattleAxe/SK_WPN_GOB_BattleAxe01.bin", XMMatrixRotationX(XMConvertToRadians(-90.f)) * XMMatrixIdentity()))))
return E_FAIL;
#pragma endregion
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CPlayerRobe::Create(m_pDevice, m_pContext)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_CCL_CameraRig.001_Model"),
+ CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Object/Camera/CCL_CameraRig.001.bin", XMMatrixScaling(0.0001f, 0.0001f, 0.0001f) * XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity()))))
+ return E_FAIL;
/* For.Prototype_Component_SkyboxModel */
if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_SkyboxModel"),
@@ -2721,10 +2819,18 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Mage::Create(m_pDevice, m_pContext))))
return E_FAIL;
+ /* For.Prototype_GameObject_Goblin_Assassin */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Assassin::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_Goblin_Assassin_Spector */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Assassin_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;
@@ -2775,6 +2881,10 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CCamPosition_Arm::Create(m_pDevice, m_pContext))))
return E_FAIL;
+ /* For.Prototype_GameObject_Camera_Model */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CCamera_Model::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))))
return E_FAIL;
@@ -2799,6 +2909,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_Sword */
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CGoblin_Sword::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;
@@ -2811,15 +2925,6 @@ HRESULT CLoader::Loading_For_GamePlay()
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CBroomRaceManager::Create(m_pDevice, m_pContext))))
return E_FAIL;
-
- if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CDummy_PhysXWall::Create(m_pDevice, m_pContext)))) {
- return E_FAIL;
- }
-
- if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CDummy_PhysXPlayable::Create(m_pDevice, m_pContext)))) {
- return E_FAIL;
- }
-
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CPhysXEffectHitBox::Create(m_pDevice, m_pContext)))) {
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/MapElement_Chest.cpp b/Jusin154_Team3D/Client/Private/MapElement_Chest.cpp
index e88df1c57..c0a2d1748 100644
--- a/Jusin154_Team3D/Client/Private/MapElement_Chest.cpp
+++ b/Jusin154_Team3D/Client/Private/MapElement_Chest.cpp
@@ -56,7 +56,7 @@ HRESULT CMapElement_Chest::Initialize(void* pArg)
m_pActor = static_cast(m_pRigidBody->Get_Actor());
static_cast(m_pRigidBody)->Set_HalfGeometryInfo(pDesc->vBoxSize);
- static_cast(m_pRigidBody)->Move_LocalPos(_float4(0.f, 0.f, 0.f, 0.f), pDesc->vBoxLocalPosition);
+ static_cast(m_pRigidBody)->Move_LocalPos(XMVectorSet(0.f, 0.f, 0.f, 1.f), XMLoadFloat3(&pDesc->vBoxLocalPosition));
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/MapElement_Door.cpp b/Jusin154_Team3D/Client/Private/MapElement_Door.cpp
index 3252956d8..5cfaea21f 100644
--- a/Jusin154_Team3D/Client/Private/MapElement_Door.cpp
+++ b/Jusin154_Team3D/Client/Private/MapElement_Door.cpp
@@ -117,7 +117,7 @@ void CMapElement_Door::Late_Update(_float fTimeDelta)
* (ScaleMatrix * RotationMatrix * TranslationWorld); // 그 후 SRT 적용
m_pTransformCom->Set_WorldMatrix(world);
- m_pActor->setGlobalPose(XMWorldToPx_NoScale(world));
+ m_pActor->setGlobalPose(XMWorldToPx_NoScaleNoFlip(world));
m_pActor->setAngularVelocity(PSX::PxVec3(0));
m_pActor->setLinearVelocity(PSX::PxVec3(0));
diff --git a/Jusin154_Team3D/Client/Private/MapElement_Interactable.cpp b/Jusin154_Team3D/Client/Private/MapElement_Interactable.cpp
index 025f96a04..b81314591 100644
--- a/Jusin154_Team3D/Client/Private/MapElement_Interactable.cpp
+++ b/Jusin154_Team3D/Client/Private/MapElement_Interactable.cpp
@@ -58,7 +58,7 @@ HRESULT CMapElement_Interactable::Initialize(void* pArg)
m_pActor = static_cast(m_pRigidBody->Get_Actor());
static_cast(m_pRigidBody)->Set_HalfGeometryInfo(pDesc->vBoxSize);
- static_cast(m_pRigidBody)->Move_LocalPos(_float4(0.f, 0.f, 0.f, 0.f), pDesc->vBoxLocalPosition);
+ static_cast(m_pRigidBody)->Move_LocalPos(XMVectorSet(0.f, 0.f, 0.f, 1.f), XMLoadFloat3(&pDesc->vBoxLocalPosition));
//static_cast(m_pRigidBody)->Set_Kinematic(false);
if (false == m_isPooled)
@@ -338,7 +338,7 @@ void CMapElement_Interactable::ActivateAt(_fvector vPos)
m_pTransformCom->Set_State(STATE::POSITION, vPos);
m_pInfoInstance->Regist_ActiveInteractive(this);
m_pRigidBody->Set_Kinematic(false);
- m_pRigidBody->Set_Position(vPos);
+ m_pRigidBody->Set_Position(vPos, true);
}
ON_COLLISION_INFO CMapElement_Interactable::CollisionCheck(_fvector StartPos, _fvector EndPos, _float fRadius)
@@ -372,7 +372,7 @@ ON_COLLISION_INFO CMapElement_Interactable::CollisionCheck(_fvector StartPos, _f
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (pUserData->eKind)
@@ -432,7 +432,7 @@ ON_COLLISION_INFO CMapElement_Interactable::CollisionCheck(_fvector StartPos, _f
if (nullptr != pActor && nullptr != pActor->userData)
{
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
switch (PXOBJECT(pUserData->iSubKind))
diff --git a/Jusin154_Team3D/Client/Private/Monster.cpp b/Jusin154_Team3D/Client/Private/Monster.cpp
index c7efd8cb7..953e311b3 100644
--- a/Jusin154_Team3D/Client/Private/Monster.cpp
+++ b/Jusin154_Team3D/Client/Private/Monster.cpp
@@ -28,7 +28,7 @@ HRESULT CMonster::Initialize(void* pArg)
}
m_pInfoInstance->Regist_ActiveMonster(this);
-
+
return S_OK;
}
@@ -115,14 +115,8 @@ HRESULT CMonster::Render_OutLine()
return E_FAIL;
}
Compute_Depth();
- _float fRatio = (m_fCamDepth / *m_pGameInstance->Get_CurrentCameraFar());
+ _float fRatio = CMyTools::Saturate((m_fCamDepth / *m_pGameInstance->Get_CurrentCameraFar()));
m_fOutLineThickness = CMyTools::Lerp_f1D(2.f, 6.f, fRatio);
- if (m_fOutLineThickness > 6.f) {
- m_fOutLineThickness = 6.f;
- }
- else if (m_fOutLineThickness < 2.f) {
- m_fOutLineThickness = 2.f;
- }
if (FAILED(m_pShaderCom->Bind_RawValue("g_vOutLineColor", &m_vOutLineColor, sizeof(_float3)))) {
return E_FAIL;
}
@@ -227,10 +221,10 @@ HRESULT CMonster::Render_Disolve()
if (FLT_EPSILON3 * 10 < m_fDisolveTime)
{
m_bDrawOutLine = false;
- _bool bDisolve = true;
+ _int bDisolve = 1;
_float fDisolveAmount = 0.1f;
_float fDisolveEdgeWidth = 0.1f;
- if (FAILED(m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_bool)))) {
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_bDisolve", &bDisolve, sizeof(_int)))) {
return E_FAIL;
}
if (FAILED(m_pShaderCom->Bind_RawValue("g_fDisolveRatio", &m_fDisolveTime, sizeof(_float)))) {
diff --git a/Jusin154_Team3D/Client/Private/NPC_Ollivander.cpp b/Jusin154_Team3D/Client/Private/NPC_Ollivander.cpp
index 8a9aff9a6..91c8304cd 100644
--- a/Jusin154_Team3D/Client/Private/NPC_Ollivander.cpp
+++ b/Jusin154_Team3D/Client/Private/NPC_Ollivander.cpp
@@ -311,7 +311,7 @@ HRESULT CNPC_Ollivander::Ready_Components(void* pArg)
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_MONSTER, nullptr, this, &m_pNPCInteraction))) {
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, &m_pNPCInteraction))) {
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/NomalJap.cpp b/Jusin154_Team3D/Client/Private/NomalJap.cpp
index 2f62d531b..c4f08c21d 100644
--- a/Jusin154_Team3D/Client/Private/NomalJap.cpp
+++ b/Jusin154_Team3D/Client/Private/NomalJap.cpp
@@ -6,6 +6,7 @@
#include "GameInstance.h"
#include "EffectParts.h"
#include "TrailObject.h"
+#include "Player.h"
CNomalJap::CNomalJap(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
@@ -112,7 +113,7 @@ void CNomalJap::Update(_float fTimeDelta)
_vector vDir = XMLoadFloat4(&m_vEndPos) - XMLoadFloat4(&m_vStartPos);
- if (true == m_pGameInstance->SphereCast(0.25, XMLoadFloat4(&m_vStartPos), XMVector3Normalize(vDir), XMVectorGetX(XMVector3Length(vDir))
+ if (true == m_pGameInstance->SphereCast(0.25f, XMLoadFloat4(&m_vStartPos), XMVector3Normalize(vDir), XMVectorGetX(XMVector3Length(vDir))
, PSX::PxHitFlag::ePOSITION | PSX::PxHitFlag::eNORMAL, PSX::PxQueryFlag::eDYNAMIC | PSX::PxQueryFlag::eSTATIC, m_Hitbuffer))
{
OnCollision(this);
@@ -302,7 +303,7 @@ void CNomalJap::OnCollision(CGameObject* pOther, void* pDesc)
Get_PartObject()->Set_Visible(false);
Get_PartObject()->Get_Component()->Set_State(STATE::POSITION, XMVectorSet(0.f, 0.f, 0.f, 1.f));
-
+ dynamic_cast(m_pOwner->Get_Owner())->Start_CameraShake(0.2f, 1.f);
}
void CNomalJap::Free()
diff --git a/Jusin154_Team3D/Client/Private/Player.cpp b/Jusin154_Team3D/Client/Private/Player.cpp
index c0ca9a43f..9a2eaae22 100644
--- a/Jusin154_Team3D/Client/Private/Player.cpp
+++ b/Jusin154_Team3D/Client/Private/Player.cpp
@@ -17,6 +17,7 @@
#include "MapElement_Interactable.h"
#include "BroomRaceManager.h"
#include "RaceRing.h"
+#include "PlayerRobe.h"
#pragma region STATE
#include "State_Idle.h"
@@ -177,6 +178,7 @@ __super::Update(fTimeDelta);
m_pCharacter_Controller->Move(fTimeDelta);
m_pCallBack_HitReport->Set_CurrentSlop();
}
+
if (m_pGameInstance->Mouse_Down(DIM_RBUTTON)){
m_pInfoInstance->Mouse_Input(ENUM_CLASS(KEYINPUT::DIM_RBUTTON_DOWN));
}
@@ -187,6 +189,116 @@ __super::Update(fTimeDelta);
}
}
+void CPlayer::Late_Update(_float fTimeDelta)
+{
+ m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_FootPosition());
+
+ m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
+#ifdef _DEBUG
+ m_pGameInstance->Add_RenderGroup(RENDER::NONLIGHT, this);
+#endif // _DEBUG
+
+ Set_Shadow(m_pGameInstance->IsIn_ShadowViewFrustum(m_pTransformCom->Get_State(STATE::POSITION), m_pTransformCom->Get_Radius()));
+
+ __super::Late_Update(fTimeDelta);
+
+ if (nullptr != m_LockOnInfo.pUnit) {
+ if (false == m_LockOnInfo.pUnit->isDead()) {
+ static_cast(m_LockOnInfo.pUnit)->Set_DrawOutLine();
+ }
+ else {
+ m_LockOnInfo.pUnit = nullptr;
+ }
+ }
+ if (nullptr != m_LockOnInfo.pInteractive) {
+ static_cast(m_LockOnInfo.pInteractive)->Set_DrawOutLine();
+ }
+
+ if (m_bLookAt && m_LockOnInfo.pUnit)
+ {
+ m_pTransformCom->LookAt_Horizontal_Lerp(m_LockOnInfo.pUnit->Get_WorldPostion(), fTimeDelta, 5.f);
+ }
+ ////////////////////////////////////////////////////////////////////////////
+ _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);
+ ////////////////////////////////////////////////////////////////////////////
+
+//#ifdef 기무리
+// if (nullptr == m_pRobePart) {
+// {
+// CPlayerRobe::PlayerRobe_DESC Desc{};
+// Desc.pModel = m_pModelCom;
+// Desc.pParentTransform = m_pTransformCom;
+// Desc.pSocketMatrix = m_pModelCom->Get_BoneMatrixPtr("Hips_Cloth");
+// if (FAILED(Add_PartObject("RobePart", g_iStaticLevel, &m_pRobePart, &Desc))) {
+// assert(false);
+// }
+// }
+// }
+//#endif // 기무리
+}
+
+
+HRESULT CPlayer::Render()
+{
+ if (!m_bVisible){
+ return S_OK;
+ }
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+ RENDER eType = m_pGameInstance->Get_CurrentRenderPass();
+ if (RENDER::NONBLEND == eType) {
+ _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->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+
+ m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+ if (FAILED(Bind_ShaderParameters(i))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+ }
+ Render_CameraCoordinateSystem();
+ //m_pCharacter_Controller->Render();
+ }
+#ifdef _DEBUG
+ if (RENDER::NONLIGHT == eType) {
+ //m_pRigidBody->Render();
+ }
+#endif
+
+ return S_OK;
+}
void CPlayer::UpdateGrapInteractive(_float fTimeDelta)
{
if (nullptr != m_pGrapInteractive) {
@@ -217,98 +329,6 @@ void CPlayer::Update_CameraShake(_float fTimeDelta)
}
}
}
-
-void CPlayer::Late_Update(_float fTimeDelta)
-{
- m_pTransformCom->Set_State(STATE::POSITION, m_pCharacter_Controller->Get_FootPosition());
-
- m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
-
- Set_Shadow(m_pGameInstance->IsIn_ShadowViewFrustum(m_pTransformCom->Get_State(STATE::POSITION), m_pTransformCom->Get_Radius()));
-
- __super::Late_Update(fTimeDelta);
-
- if (nullptr != m_LockOnInfo.pUnit) {
- if (false == m_LockOnInfo.pUnit->isDead()) {
- static_cast(m_LockOnInfo.pUnit)->Set_DrawOutLine();
- }
- else {
- m_LockOnInfo.pUnit = nullptr;
- }
- }
- if (nullptr != m_LockOnInfo.pInteractive) {
- static_cast(m_LockOnInfo.pInteractive)->Set_DrawOutLine();
- }
-
- if (m_bLookAt && m_LockOnInfo.pUnit)
- {
- m_pTransformCom->LookAt_Horizontal_Lerp(m_LockOnInfo.pUnit->Get_WorldPostion(), fTimeDelta, 10.f);
- }
- ////////////////////////////////////////////////////////////////////////////
- _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()
-{
- 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->Bind_Matrices(
- "g_OffsetMatrix",
- m_pModelCom->Get_OffsetMatrix(i).data(),
- (_int)m_pModelCom->Get_OffsetMatrix(i).size()
- )))
- {
- return E_FAIL;
- }
- if (FAILED(m_pModelCom->Begin(i, m_pShaderCom, false))) {
- return E_FAIL;
- }
-
-
- m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
- m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
- if (FAILED(Bind_ShaderParameters(i))) {
- return E_FAIL;
- }
-
- if (FAILED(m_pModelCom->Render(i))) {
- return E_FAIL;
- }
- }
-
-#ifdef _DEBUG
- m_pCharacter_Controller->Render();
- //m_pRigidBody->Render();
- Render_CameraCoordinateSystem();
-#endif
-
- return S_OK;
-}
HRESULT CPlayer::Render_Shadow(SHADOW eType)
{
if (FAILED(m_pShaderCom->Bind_Matrix("g_WorldMatrix", m_pTransformCom->Get_WorldMatrixPtr()))) {
@@ -349,12 +369,11 @@ HRESULT CPlayer::Render_Shadow(SHADOW eType)
}
void CPlayer::OnCollision(CGameObject* pOther, void* pDesc)
{
-
- if (m_pFSM->IsEnable(FSMSTATE::SHIELD))
- {
- m_bShield = true;
- }
- if (m_pFSM->IsEnable(FSMSTATE::DODGE | FSMSTATE::BLINK) && m_bShield)
+ _int iCurrAnim = m_pModelCom->Get_AnimIndex();
+ if (m_pFSM->IsEnable(FSMSTATE::DODGE | FSMSTATE::BLINK) ||
+ m_bShield ||
+ iCurrAnim == m_Animation[STATEANIM::AVADA_KEDAVRA].first||
+ iCurrAnim == m_Animation[STATEANIM::ANCIENT_LIGHTNING].first)
return;
#ifdef _DEBUG
@@ -372,7 +391,8 @@ void CPlayer::OnCollision(CGameObject* pOther, void* pDesc)
m_fHitDegree = -1.f;
}
- m_pFSM->Change_State(FSMSTATE::HIT);
+ if(m_eHitType !=ENUM_CLASS(HIT_TYPE::HIT_NONE))
+ m_pFSM->Change_State(FSMSTATE::HIT);
}
void CPlayer::OnHit(CGameObject* pOther, CGameObject* pCaller)
{
@@ -385,7 +405,6 @@ void CPlayer::Start_CameraShake(_float fTime, _float fIntense)
m_fCameraShakeIntense = fIntense;
m_bCameraShake = true;
}
-#ifdef _DEBUG
void CPlayer::Render_CameraCoordinateSystem()
{
@@ -437,8 +456,6 @@ void CPlayer::Render_CameraCoordinateSystem()
);
m_Batch->End();
}
-#endif // _DEBUG
-
HRESULT CPlayer::Ready_Components()
{
CTransform::TRANSFORM_DESC Desc = {};
@@ -550,8 +567,6 @@ HRESULT CPlayer::Ready_Parts()
return E_FAIL;
}
-
-
return S_OK;
}
@@ -719,7 +734,7 @@ void CPlayer::Free()
{
__super::Free();
-
+ SAFE_RELEASE(m_pRobePart);
SAFE_RELEASE(m_pGrapInteractive);
if (nullptr != m_pInfoInstance) {
CInfoInstance* pInfo = m_pInfoInstance;
diff --git a/Jusin154_Team3D/Client/Private/PlayerRobe.cpp b/Jusin154_Team3D/Client/Private/PlayerRobe.cpp
new file mode 100644
index 000000000..45f614a02
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/PlayerRobe.cpp
@@ -0,0 +1,638 @@
+#include "pch.h"
+#include "PlayerRobe.h"
+#include "GameInstance.h"
+
+CPlayerRobe::CPlayerRobe(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ : CPartObject(pDevice, pContext)
+{
+}
+
+CPlayerRobe::CPlayerRobe(const CPlayerRobe& Prototype)
+ : CPartObject(Prototype)
+{
+}
+void CPlayerRobe::Priority_Update(_float fTimeDelta)
+{
+}
+
+void CPlayerRobe::Update(_float fTimeDelta)
+{
+ _matrix SocketMatrixFixed = (XMMatrixRotationZ(XM_PI) * XMLoadFloat4x4(m_pSocketMatrix)) *
+ XMLoadFloat4x4(m_pParentTransformCom->Get_WorldMatrixPtr());
+ m_pRobeMainAnchor->Move_Kinematic(SocketMatrixFixed, false);
+ m_pRobeMainAnchor->Get_Actor()->wakeUp();
+ Update_LegsPosition();
+}
+
+void CPlayerRobe::Late_Update(_float fTimeDelta)
+{
+ Update_RobeSocketPosition();
+#ifdef _DEBUG
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_ORDER::END); ++i) {
+ PSX::PxConstraintFlags pxConstraintFlags = m_pDynamicJoints[i]->getConstraintFlags();
+ const bool bBroken = (pxConstraintFlags.isSet(PSX::PxConstraintFlag::eBROKEN));
+ if (true == bBroken) {
+ assert(false);
+ }
+ }
+ m_pGameInstance->Add_RenderGroup(RENDER::NONLIGHT, this);
+#endif // _DEBUG
+}
+
+HRESULT CPlayerRobe::Render()
+{
+ Render_BonePhysX();
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Update_RobeSocketPosition()
+{
+ {
+ PSX::PxTransform pxTransform = {};
+ _matrix WorldMatrix = {};
+ _matrix OwnerInvWorldMatrix = m_pParentTransformCom->Get_WorldMatrixInv();
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i) {
+ pxTransform = m_pRobeJointAnchor[i]->Get_GlobalPosition();
+ WorldMatrix = XMMatrixAffineTransformation(XMVectorSet(1.f, 1.f, 1.f, 0.f), XMVectorZero(), XMLoadFloat4((_float4*)&pxTransform.q), XMVectorSetW(XMLoadFloat3((_float3*)&pxTransform.p), 1.f));
+ XMStoreFloat4x4(&m_ReconstructedJointAnchorMatirces[i], WorldMatrix * OwnerInvWorldMatrix);
+ }
+ }
+ {
+ D3D11_MAPPED_SUBRESOURCE SubResource{};
+ if (FAILED(m_pContext->Map(m_pBoneCombinedMatrixBuffer, 0, D3D11_MAP_WRITE_DISCARD, 0, &SubResource))) {
+ return E_FAIL;
+ }
+ memcpy_s(SubResource.pData, sizeof(_float4x4) * ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END), m_ReconstructedJointAnchorMatirces, sizeof(_float4x4) * ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END));
+ m_pContext->Unmap(m_pBoneCombinedMatrixBuffer, 0);
+ }
+ m_pModelCom->ComputeInsertionBoneBuffer(m_BoneInsertionDesc, m_pBoneCombinedMatrixSRV);
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Helper_RouteJointGenerater(CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC& Desc_Body, ROUTE_DESC& Desc_Route, _matrix* xmAnchorMatricesWorld)
+{
+
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ROUTE"), (CComponent**)&m_pRobeJointRoute[Desc_Route.iTargetRouteIndex], &Desc_Body))) {
+ return E_FAIL;
+ }
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_CenterTransform(xmAnchorMatricesWorld[Desc_Route.iStartBoneIndex].r[3], xmAnchorMatricesWorld[Desc_Route.iEndBoneIndex].r[3], true);
+
+
+ PSX::PxRigidDynamic* startAnchorRigidActor = m_pRobeJointAnchor[Desc_Route.iStartBoneIndex]->Get_Actor();
+ PSX::PxRigidDynamic* routeRigidActor = m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_Actor();
+ PSX::PxRigidDynamic* endAnchorRigidActor = m_pRobeJointAnchor[Desc_Route.iEndBoneIndex]->Get_Actor();
+
+ PSX::PxTransform startJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), false); // start y--
+ PSX::PxTransform endJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), true); // end y++
+
+ m_pDynamicJoints[Desc_Route.iStartJointIndex] = m_pGameInstance->Create_PxD6Joint(startAnchorRigidActor, routeRigidActor, startJointWorldPose);
+
+ m_pDynamicJoints[Desc_Route.iEndJointIndex] = m_pGameInstance->Create_PxD6Joint(routeRigidActor, endAnchorRigidActor, endJointWorldPose);
+
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Create_BoneCombinedMatrixSRV()
+{
+ D3D11_BUFFER_DESC desc{};
+ desc.Usage = D3D11_USAGE_DYNAMIC;
+ desc.ByteWidth = sizeof(_float4x4) * ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END);
+ desc.BindFlags = D3D11_BIND_SHADER_RESOURCE;
+ desc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ desc.StructureByteStride = sizeof(_float4x4);
+ desc.MiscFlags = D3D11_RESOURCE_MISC_BUFFER_STRUCTURED;
+
+ if (FAILED(m_pDevice->CreateBuffer(&desc, nullptr, &m_pBoneCombinedMatrixBuffer))) {
+ return E_FAIL;
+ }
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc = {};
+ srvDesc.ViewDimension = D3D11_SRV_DIMENSION_BUFFER;
+ srvDesc.Format = DXGI_FORMAT_UNKNOWN;
+ srvDesc.Buffer.FirstElement = 0;
+ srvDesc.Buffer.NumElements = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END);
+
+
+ if (FAILED(m_pDevice->CreateShaderResourceView(m_pBoneCombinedMatrixBuffer, &srvDesc, &m_pBoneCombinedMatrixSRV))){
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+
+HRESULT CPlayerRobe::Update_LegsPosition()
+{
+ _matrix WorldMatrix = m_pParentTransformCom->Get_XMWorldMatrix();
+ {
+
+ _vector vFootPos = XMVector4Transform(XMLoadFloat4((_float4*)&m_pLeftFootLocalMatrix->m[3][0]), WorldMatrix);
+ _vector vLegPos = XMVector4Transform(XMLoadFloat4((_float4*)&m_pLeftLegLocalMatrix->m[3][0]), WorldMatrix);
+ m_pLeftLeg->Set_CenterTransform(vFootPos, vLegPos, false);
+
+#ifdef _DEBUG
+ {
+ _vector vCenterWorldPos = (vFootPos + vLegPos ) * 0.5f;
+ _vector vRotQ = XMQuaternionIdentity();
+ _vector vDir = XMVectorSetW(vLegPos - vFootPos, 0.f);
+ _float vLength = XMVectorGetX(XMVector3Length(vDir));
+ if (vLength > FLT_EPSILON5) {
+ vDir = XMVector3Normalize(vDir);
+ vRotQ = CMyTools::MakeQuaternionFromTo(XMVectorSet(0.f, 1.f, 0.f, 0.f), vDir);
+ }
+ XMStoreFloat4x4(&m_LeftLegMatrix, XMMatrixRotationQuaternion(vRotQ) * XMMatrixTranslationFromVector(vCenterWorldPos));
+ }
+#endif // _DEBUG
+
+ vFootPos = XMVector4Transform(XMLoadFloat4((_float4*)&m_pRightFootLocalMatrix->m[3][0]), WorldMatrix);
+ vLegPos = XMVector4Transform(XMLoadFloat4((_float4*)&m_pRightLegLocalMatrix->m[3][0]), WorldMatrix);
+ m_pRightLeg->Set_CenterTransform(vFootPos, vLegPos, false);
+
+#ifdef _DEBUG
+ {
+ _vector vCenterWorldPos = (vFootPos + vLegPos) * 0.5f;
+ _vector vRotQ = XMQuaternionIdentity();
+ _vector vDir = XMVectorSetW(vLegPos - vFootPos, 0.f);
+ _float vLength = XMVectorGetX(XMVector3Length(vDir));
+ if (vLength > FLT_EPSILON5) {
+ vDir = XMVector3Normalize(vDir);
+ vRotQ = CMyTools::MakeQuaternionFromTo(XMVectorSet(0.f, 1.f, 0.f, 0.f), vDir);
+ }
+ XMStoreFloat4x4(&m_RightLegMatrix, XMMatrixRotationQuaternion(vRotQ) * XMMatrixTranslationFromVector(vCenterWorldPos));
+ }
+#endif // _DEBUG
+ }
+
+ return S_OK;
+}
+
+#ifdef _DEBUG
+HRESULT CPlayerRobe::Render_Legs()
+{
+ _float fHeight = 0.25f;
+
+ _matrix WorldMatrix = XMLoadFloat4x4(&m_LeftLegMatrix);
+ _matrix ViewMatrix = m_pGameInstance->Get_Transform_Matrix(D3DTS::VIEW);
+ _matrix ProjMatrix = m_pGameInstance->Get_Transform_Matrix(D3DTS::PROJ);
+ _vector vColor = CMyTools::ColorRGB_A_HEXtoVECTOR(0xff0000, 1.f);
+
+ m_pMainShape->Draw(WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ _matrix WorldUp = XMMatrixTranslationFromVector(WorldMatrix.r[1] * fHeight);
+ _matrix WorldDown = XMMatrixTranslationFromVector(WorldMatrix.r[1] * -fHeight);
+ m_pSubShape->Draw(WorldUp * WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ m_pSubShape->Draw(WorldDown * WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+
+ WorldMatrix = XMLoadFloat4x4(&m_RightLegMatrix);
+
+ m_pMainShape->Draw(WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ WorldUp = XMMatrixTranslationFromVector(WorldMatrix.r[1] * fHeight);
+ WorldDown = XMMatrixTranslationFromVector(WorldMatrix.r[1] * -fHeight);
+ m_pSubShape->Draw(WorldUp * WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ m_pSubShape->Draw(WorldDown * WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Render_BonePhysX()
+{
+ _vector vColor = CMyTools::ColorRGB_A_HEXtoVECTOR(0x00ff00, 1.f);
+ _fmatrix OwnerMatrix = m_pParentTransformCom->Get_XMWorldMatrix();
+ _cmatrix ViewMatrix = m_pGameInstance->Get_Transform_Matrix(D3DTS::VIEW);
+ _matrix ProjMatrix = m_pGameInstance->Get_Transform_Matrix(D3DTS::PROJ);
+ ID3D11DepthStencilState* pPrevDSS = nullptr;
+ UINT iPrevStencilRef = 0;
+ m_pContext->OMGetDepthStencilState(&pPrevDSS, &iPrevStencilRef);
+
+ for (_uint iBoneIndex = 0; iBoneIndex < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++iBoneIndex)
+ {
+ _matrix WorldMatrix = XMLoadFloat4x4(m_pModelCom->Get_BoneMatrixPtr(PLAYER_JOINT_BONE_NAMES[iBoneIndex])) * OwnerMatrix;
+
+ m_pSubShape->Draw(WorldMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ }
+ _matrix MainAnchorMatrix = /*XMMatrixRotationZ(XM_PIDIV2) * */XMLoadFloat4x4(m_pSocketMatrix) * OwnerMatrix;
+ m_pSubShape->Draw(MainAnchorMatrix, ViewMatrix, ProjMatrix, vColor, nullptr, true,
+ [this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ m_pRobeMainAnchor->Render([this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ Render_Legs();
+ _vector vRouteColor = CMyTools::ColorRGB_A_HEXtoVECTOR(0x0000ff, 1.f);
+ //for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::END); ++i) {
+ // if (nullptr != m_pRobeJointRoute[i]) {
+ // m_pRobeJointRoute[i]->Render([this]() {
+ // m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ // });
+ // }
+ //}
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i) {
+ m_pRobeJointAnchor[i]->Render([this]() {
+ m_pContext->OMSetDepthStencilState(m_pDepthStencilStateNone, 0);
+ });
+ }
+ m_pContext->OMSetDepthStencilState(pPrevDSS, iPrevStencilRef);
+ if (pPrevDSS != nullptr) {
+ pPrevDSS->Release();
+ }
+ return S_OK;
+}
+#endif // _DEBUG
+
+HRESULT CPlayerRobe::Ready_Components()
+{
+ __super::Ready_Components(nullptr);
+
+ _matrix socketWorld = /*XMMatrixRotationZ(XM_PIDIV2) * */XMLoadFloat4x4(m_pSocketMatrix) * m_pParentTransformCom->Get_XMWorldMatrix();
+ _matrix xmAnchorMatricesWorld[ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END)] = { };
+ for (_uint iBoneIndex = 0; iBoneIndex < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++iBoneIndex) {
+ xmAnchorMatricesWorld[iBoneIndex] = XMLoadFloat4x4(&m_ReconstructedJointAnchorMatirces[iBoneIndex]) * socketWorld;
+ }
+
+ { //
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::LEG);
+ Desc.bAutoOwnerTranslation = false;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_Player_Leg"), (CComponent**)&m_pLeftLeg, &Desc))) {
+ return E_FAIL;
+ }
+ }
+ { //
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::LEG);
+ Desc.bAutoOwnerTranslation = false;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_Player_Leg"), (CComponent**)&m_pRightLeg, &Desc))) {
+ return E_FAIL;
+ }
+ }
+ { // RobeSocket
+ { // Fixed_MainAnchor
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::JOINT_ANCHOR);
+ Desc.bAutoOwnerTranslation = false;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ANCHOR"), (CComponent**)&m_pRobeMainAnchor, &Desc))) {
+ return E_FAIL;
+ }
+ m_pRobeMainAnchor->Set_Kinematic(true);
+ m_pRobeMainAnchor->Set_Transform(socketWorld, true);
+#ifdef _DEBUG
+ m_pRobeMainAnchor->Set_Name("MainAnchor");
+#endif // _DEBUG
+ }
+ // SubAnchors
+ for (_int i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i) {
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::JOINT_ANCHOR);
+ Desc.bAutoOwnerTranslation = false;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ANCHOR"), (CComponent**)&m_pRobeJointAnchor[i], &Desc))) {
+ return E_FAIL;
+ }
+
+ m_pRobeJointAnchor[i]->Set_Transform(xmAnchorMatricesWorld[i], true);
+#ifdef _DEBUG
+ m_pRobeJointAnchor[i]->Set_Name(PLAYER_JOINT_BONE_NAMES[i]);
+#endif // _DEBUG
+ }
+ }
+ { // RobeRoute
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc_Body = {};
+ ROUTE_DESC Desc_Route = {};
+ Desc_Body.bAutoOwnerTranslation = false;
+ Desc_Body.iSubKind = ENUM_CLASS(PXOBJECT::JOINT_ROUTE);
+ /*Origin_Linked_Routes*/
+ {
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::ORIGIN_TO_RUP);
+ Desc_Route.iStartBoneIndex = -1;
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTUP);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::ORIGIN_TO_RUP_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ROUTE"), (CComponent**)&m_pRobeJointRoute[Desc_Route.iTargetRouteIndex], &Desc_Body))) {
+ return E_FAIL;
+ }
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_CenterTransform(socketWorld.r[3], xmAnchorMatricesWorld[Desc_Route.iEndBoneIndex].r[3], true);
+#ifdef _DEBUG
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_Name("Origin_Linked_Routes");
+#endif // _DEBUG
+ { // Joint
+ PSX::PxRigidDynamic* startAnchorRigidActor = m_pRobeMainAnchor->Get_Actor();
+ PSX::PxRigidDynamic* routeRigidActor = m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_Actor();
+ PSX::PxRigidDynamic* endAnchorRigidActor = m_pRobeJointAnchor[Desc_Route.iEndBoneIndex]->Get_Actor();
+
+ PSX::PxTransform startJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), false); // start y--
+ PSX::PxTransform endJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), true); // end y++
+
+ m_pDynamicJoints[Desc_Route.iStartJointIndex] = m_pGameInstance->Create_PxD6Joint(startAnchorRigidActor, routeRigidActor, startJointWorldPose);
+ m_pDynamicJoints[Desc_Route.iEndJointIndex] = m_pGameInstance->Create_PxD6Joint(routeRigidActor, endAnchorRigidActor, endJointWorldPose);
+ }
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::ORIGIN_TO_TUP);
+ Desc_Route.iStartBoneIndex = -1;
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAILUP);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::ORIGIN_TO_TUP_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ROUTE"), (CComponent**)&m_pRobeJointRoute[Desc_Route.iTargetRouteIndex], &Desc_Body))) {
+ return E_FAIL;
+ }
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_CenterTransform(socketWorld.r[3], xmAnchorMatricesWorld[Desc_Route.iEndBoneIndex].r[3], true);
+#ifdef _DEBUG
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_Name("Origin_Linked_Routes");
+#endif // _DEBUG
+ { // Joint
+ PSX::PxRigidDynamic* startAnchorRigidActor = m_pRobeMainAnchor->Get_Actor();
+ PSX::PxRigidDynamic* routeRigidActor = m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_Actor();
+ PSX::PxRigidDynamic* endAnchorRigidActor = m_pRobeJointAnchor[Desc_Route.iEndBoneIndex]->Get_Actor();
+
+ PSX::PxTransform startJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), false); // start y--
+ PSX::PxTransform endJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), true); // end y++
+
+ m_pDynamicJoints[Desc_Route.iStartJointIndex] = m_pGameInstance->Create_PxD6Joint(startAnchorRigidActor, routeRigidActor, startJointWorldPose);
+ m_pDynamicJoints[Desc_Route.iEndJointIndex] = m_pGameInstance->Create_PxD6Joint(routeRigidActor, endAnchorRigidActor, endJointWorldPose);
+ }
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::ORIGIN_TO_LUP);
+ Desc_Route.iStartBoneIndex = -1;
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFTUP);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::ORIGIN_TO_LUP_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_JOINT_ROUTE"), (CComponent**)&m_pRobeJointRoute[Desc_Route.iTargetRouteIndex], &Desc_Body))) {
+ return E_FAIL;
+ }
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_CenterTransform(socketWorld.r[3], xmAnchorMatricesWorld[Desc_Route.iEndBoneIndex].r[3], true);
+#ifdef _DEBUG
+ m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Set_Name("Origin_Linked_Routes");
+#endif // _DEBUG
+ { // Joint
+ PSX::PxRigidDynamic* startAnchorRigidActor = m_pRobeMainAnchor->Get_Actor();
+ PSX::PxRigidDynamic* routeRigidActor = m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_Actor();
+ PSX::PxRigidDynamic* endAnchorRigidActor = m_pRobeJointAnchor[Desc_Route.iEndBoneIndex]->Get_Actor();
+
+ PSX::PxTransform startJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), false); // start y--
+ PSX::PxTransform endJointWorldPose = CMyTools::MakeJointWorldPoseFromRouteEnd(routeRigidActor, m_pRobeJointRoute[Desc_Route.iTargetRouteIndex]->Get_HalfGeometryInfo(), true); // end y++
+
+ m_pDynamicJoints[Desc_Route.iStartJointIndex] = m_pGameInstance->Create_PxD6Joint(startAnchorRigidActor, routeRigidActor, startJointWorldPose);
+ m_pDynamicJoints[Desc_Route.iEndJointIndex] = m_pGameInstance->Create_PxD6Joint(routeRigidActor, endAnchorRigidActor, endJointWorldPose);
+ }
+ }
+ }
+ /*UP_TO_MIDDLE*/
+ {
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::RUP_TO_RMIDDLE);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTUP);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHT);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::RUP_TO_RMIDDLE_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::TUP_TO_TMIDDLE);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAILUP);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAIL);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::TUP_TO_TMIDDLE_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::LUP_TO_LMIDDLE);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFTUP);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFT);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::LUP_TO_LMIDDLE_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ }
+ /*MIDDLE_TO_DOWN*/
+ {
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::RMIDDLE_TO_RR);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHT);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTDOWNRIGHT);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::RMIDDLE_TO_RR_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::RMIDDLE_TO_R);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHT);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTDOWN);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::RMIDDLE_TO_R_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::TMIDDLE_TO_TR);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAIL);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAILRIGHTDOWN);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::TMIDDLE_TO_TR_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::TMIDDLE_TO_TL);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAIL);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAILLEFTDOWN);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::TMIDDLE_TO_TL_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::LMIDDLE_TO_L);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFT);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFTDOWN);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::LMIDDLE_TO_L_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ {
+ Desc_Route.iTargetRouteIndex = ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::LMIDDLE_TO_LL);
+ Desc_Route.iStartBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFT);
+ Desc_Route.iEndBoneIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFTDOWNLEFT);
+ Desc_Route.iStartJointIndex = ENUM_CLASS(PLAYER_JOINT_ORDER::LMIDDLE_TO_LL_START);
+ Desc_Route.iEndJointIndex = Desc_Route.iStartJointIndex + 1;
+ Helper_RouteJointGenerater(Desc_Body, Desc_Route, xmAnchorMatricesWorld);
+ }
+ }
+ }
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CPlayerRobe::Initialize(void* pArg)
+{
+ PlayerRobe_DESC* pDesc = static_cast (pArg);
+ m_pSocketMatrix = pDesc->pSocketMatrix;
+ m_pModelCom = pDesc->pModel;
+
+ m_pLeftFootLocalMatrix = m_pModelCom->Get_BoneMatrixPtr("LeftFoot");
+ m_pLeftLegLocalMatrix = m_pModelCom->Get_BoneMatrixPtr("LeftLeg");
+ m_pRightFootLocalMatrix = m_pModelCom->Get_BoneMatrixPtr("RightFoot");
+ m_pRightLegLocalMatrix = m_pModelCom->Get_BoneMatrixPtr("RightLeg");
+
+ {
+ ZeroMemory(&m_BoneInsertionDesc, sizeof(m_BoneInsertionDesc));
+ m_BoneInsertionDesc.iMatrixCount = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END);
+ m_BoneInsertionDesc.iStartOffset = m_pModelCom->Get_BoneIndex(PLAYER_JOINT_BONE_NAMES[ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTUP)]);
+ }
+ Create_BoneCombinedMatrixSRV();
+
+ XMStoreFloat4x4(&m_PreTransformMatrix, XMLoadFloat4x4(m_pModelCom->Get_PreTransformMatrixPtr()));
+
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i) {
+ m_RobeJointAnchorMatrices[i] = m_pModelCom->Get_BoneLocalMatrixPtr(PLAYER_JOINT_BONE_NAMES[i]);
+ }
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i)
+ {
+ _uint iParentIndex = UINT_MAX;
+ _bool bCopyPreTransform = false;
+
+ switch ((PLAYER_JOINT_BONE_ORDER)i)
+ {
+ case PLAYER_JOINT_BONE_ORDER::RIGHTUP:
+ case PLAYER_JOINT_BONE_ORDER::TAILUP:
+ case PLAYER_JOINT_BONE_ORDER::LEFTUP:
+ bCopyPreTransform = true;
+ break;
+
+ case PLAYER_JOINT_BONE_ORDER::RIGHT:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHTUP);
+ break;
+ case PLAYER_JOINT_BONE_ORDER::TAIL:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAILUP);
+ break;
+ case PLAYER_JOINT_BONE_ORDER::LEFT:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFTUP);
+ break;
+ case PLAYER_JOINT_BONE_ORDER::RIGHTDOWNRIGHT:
+ case PLAYER_JOINT_BONE_ORDER::RIGHTDOWN:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::RIGHT);
+ break;
+ case PLAYER_JOINT_BONE_ORDER::TAILRIGHTDOWN:
+ case PLAYER_JOINT_BONE_ORDER::TAILLEFTDOWN:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::TAIL);
+ break;
+ case PLAYER_JOINT_BONE_ORDER::LEFTDOWN:
+ case PLAYER_JOINT_BONE_ORDER::LEFTDOWNLEFT:
+ iParentIndex = ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::LEFT);
+ break;
+ default:
+ assert(false);
+ break;
+ }
+
+ if (true == bCopyPreTransform)
+ {
+ _matrix constructedMatrix = XMLoadFloat4x4(m_RobeJointAnchorMatrices[i]) * XMLoadFloat4x4(&m_PreTransformMatrix);
+
+ XMStoreFloat4x4(&m_ReconstructedJointAnchorMatirces[i], constructedMatrix);
+ continue;
+ }
+
+ _matrix constructedMatrix = XMLoadFloat4x4(m_RobeJointAnchorMatrices[i])
+ * XMLoadFloat4x4(&m_ReconstructedJointAnchorMatirces[iParentIndex]);
+
+ XMStoreFloat4x4(&m_ReconstructedJointAnchorMatirces[i], constructedMatrix);
+ }
+
+ if (FAILED(__super::Initialize(pArg))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(Ready_Components())) {
+ return E_FAIL;
+ }
+#ifdef _DEBUG
+ m_pSubShape = (GeometricPrimitive::CreateSphere(m_pContext, 0.05f, 22, false, false));
+ m_pMainShape = (GeometricPrimitive::CreateCylinder(m_pContext, 0.3f, 0.075f, 22, false));
+ D3D11_DEPTH_STENCIL_DESC depthStencilDesc = {};
+ depthStencilDesc.DepthEnable = FALSE;
+ depthStencilDesc.DepthWriteMask = D3D11_DEPTH_WRITE_MASK_ZERO;
+ depthStencilDesc.DepthFunc = D3D11_COMPARISON_ALWAYS;
+ depthStencilDesc.StencilEnable = FALSE;
+
+ HRESULT result = m_pDevice->CreateDepthStencilState(&depthStencilDesc, &m_pDepthStencilStateNone);
+ if (FAILED(result)){
+ return E_FAIL;
+ }
+#endif // _DEBUG
+ return S_OK;
+}
+
+CPlayerRobe* CPlayerRobe::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CPlayerRobe* pInstance = new CPlayerRobe(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CPlayerRobe");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CPlayerRobe::Clone(void* pArg, CGameObject* pOwner)
+{
+ CPlayerRobe* pInstance = new CPlayerRobe(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CPlayerRobe");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CPlayerRobe::Free()
+{
+ __super::Free();
+#ifdef _DEBUG
+ SAFE_RELEASE(m_pDepthStencilStateNone);
+#endif // _DEBUG
+ SAFE_RELEASE(m_pBoneCombinedMatrixSRV);
+ SAFE_RELEASE(m_pBoneCombinedMatrixBuffer);
+ SAFE_RELEASE(m_pRightLeg);
+ SAFE_RELEASE(m_pLeftLeg);
+ SAFE_RELEASE(m_pRobeMainAnchor);
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::END); ++i) {
+ SAFE_RELEASE(m_pRobeJointRoute[i]);
+ }
+ for (_uint i = 0; i < ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END); ++i) {
+ SAFE_RELEASE(m_pRobeJointAnchor[i]);
+ }
+}
+#ifdef _DEBUG
+
+void CPlayerRobe::Describe_Entity()
+{
+}
+
+#endif // _DEBUG
diff --git a/Jusin154_Team3D/Client/Private/Player_States.cpp b/Jusin154_Team3D/Client/Private/Player_States.cpp
index e2bc1b266..85b936d59 100644
--- a/Jusin154_Team3D/Client/Private/Player_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Player_States.cpp
@@ -186,24 +186,6 @@ HRESULT CPlayer::InputBroom()
void CPlayer::Behavior_IdleEnter() {
m_pFSM->Enable_State(FSMSTATE::IDLE);
- pair<_uint, _bool> pairAnimInfo;
-
- if (SUCCEEDED(InputAim()))
- {
- if (m_pGameInstance->Mouse_Pressing(DIM_LBUTTON)) {
- pairAnimInfo = m_Animation[STATEANIM::IDLE_AIM];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
- }
- else
- pairAnimInfo = m_Animation[STATEANIM::IDLE];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true,1.f,false);
- }
- else
- {
- pairAnimInfo = m_Animation[STATEANIM::IDLE];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
- }
-
m_bSprintToggle = false;
m_bWalkToggle = false;
@@ -258,6 +240,23 @@ HRESULT CPlayer::Behavior_IdleExitCheck(_float fTimeDelta)
}
return E_FAIL;
}
+ else {
+ if (SUCCEEDED(InputAim()))
+ {
+ if (m_pGameInstance->Mouse_Pressing(DIM_LBUTTON)) {
+ pairAnimInfo = m_Animation[STATEANIM::IDLE_AIM];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true);
+ }
+ else
+ pairAnimInfo = m_Animation[STATEANIM::IDLE];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
+ }
+ else
+ {
+ pairAnimInfo = m_Animation[STATEANIM::IDLE];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
+ }
+ }
if (SUCCEEDED(InputMove()))
{
@@ -1126,6 +1125,7 @@ void CPlayer::Behavior_CombatEnter()
HRESULT CPlayer::Behavior_CombatExitCheck()
{
pair<_uint, _bool> pairAnimInfo;
+ _int iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
_float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio();
if (SUCCEEDED(InputAction()) || SUCCEEDED(InputSpell())) {
@@ -1183,7 +1183,8 @@ HRESULT CPlayer::Behavior_CombatExitCheck()
}
else
{
- if (SUCCEEDED(InputMove()) && fRatio >= 0.3f) {
+ if (SUCCEEDED(InputMove()) && fRatio >= 0.3f &&
+ iCurrAnimIndex != m_Animation[STATEANIM::ANCIENT_LIGHTNING].first) {
m_pFSM->Change_State(FSMSTATE::MOVE);
m_bLookAt = false;
return E_FAIL;
@@ -1426,7 +1427,7 @@ void CPlayer::Behavior_SpellEnter()
pairAnimInfo = m_Animation[STATEANIM::SPELL];
fRatio = 0.2f;
}
- else if (Degree <= 135.f)
+ else if (Degree <= 85.f)
{
if (Cross < 0.f)
{
@@ -1577,7 +1578,8 @@ HRESULT CPlayer::Behavior_SpellExitCheck()
Play_SpellHitAnim();
- if (SUCCEEDED(InputMove()) && iIndex != m_Animation[STATEANIM::AVADA_KEDAVRA].first) {
+ if (SUCCEEDED(InputMove()) &&
+ iIndex != m_Animation[STATEANIM::AVADA_KEDAVRA].first) {
if (fRatio >= 0.4f) {
m_pFSM->Change_State(FSMSTATE::MOVE);
return E_FAIL;
@@ -1704,10 +1706,15 @@ HRESULT CPlayer::Behavior_ShieldExitCheck()
_vector vCross = XMVector3Cross(vLook, vCameraLook);
_float Cross = XMVectorGetY(vCross);
- if (Degree <= 60.f)
+ if (Degree <= 30.f)
{
pairAnimInfo = m_Animation[STATEANIM::PARRY4];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
+ }
+ else if (Degree <= 60.f)
+ {
+ pairAnimInfo = m_Animation[STATEANIM::PARRY4];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
Add_Event(pairAnimInfo.first,
[this]() {m_bLookAt = true;
},
@@ -1718,22 +1725,26 @@ HRESULT CPlayer::Behavior_ShieldExitCheck()
if (Cross < 0.f)
{
pairAnimInfo = m_Animation[STATEANIM::PARRY2];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second,1.f,true,1.f,false);
}
else {
pairAnimInfo = m_Animation[STATEANIM::PARRY3];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
}
Add_Event(pairAnimInfo.first,
[this]() {m_bLookAt = true;
},
- 0.8f);
+ 0.11f);
}
else {
pairAnimInfo = m_Animation[STATEANIM::PARRY_180];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
+ }
+ else {
+ pairAnimInfo = m_Animation[STATEANIM::PARRY4];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, 1.f, false);
}
Add_Event(pairAnimInfo.first,
diff --git a/Jusin154_Team3D/Client/Private/Protego.cpp b/Jusin154_Team3D/Client/Private/Protego.cpp
index f71361785..ab48ec95b 100644
--- a/Jusin154_Team3D/Client/Private/Protego.cpp
+++ b/Jusin154_Team3D/Client/Private/Protego.cpp
@@ -97,7 +97,6 @@ void CProtego::Late_Update(_float fTimeDelta)
m_pTransformCom->Set_State(STATE::POSITION, m_pOwner->Get_Component()->Get_Position());
__super::Late_Update(fTimeDelta);
-
}
HRESULT CProtego::Pre_Setting(CGameObject* pObject, void* pArg)
@@ -129,14 +128,14 @@ HRESULT CProtego::Ready_Components(void* pArg)
}
- //{ // DO
- // CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
- // Desc.iSubKind = ENUM_CLASS(PXOBJECT::SKILL_PROTEGO);
- // if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_SHIELD"), (CComponent**)&m_pRigidBody, &Desc))) {
- // return E_FAIL;
- // }
- // m_pGameInstance->Attach_Actor(*m_pRigidBody->Get_Actor());
- //}
+ { // DO
+ CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC Desc{};
+ Desc.iSubKind = ENUM_CLASS(PXOBJECT::SKILL_PROTEGO);
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("PHYSX_DYNAMIC_SHIELD"), (CComponent**)&m_pRigidBody, &Desc))) {
+ return E_FAIL;
+ }
+ m_pGameInstance->Attach_Actor(*m_pRigidBody->Get_Actor(), NEXT_LEVEL);
+ }
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Ranrok.cpp b/Jusin154_Team3D/Client/Private/Ranrok.cpp
index 02a268856..9999d1883 100644
--- a/Jusin154_Team3D/Client/Private/Ranrok.cpp
+++ b/Jusin154_Team3D/Client/Private/Ranrok.cpp
@@ -72,8 +72,8 @@ HRESULT CRanrok::Initialize(void* pArg)
}
else {
- m_pCharacter_Controller->Set_Position(XMVectorSet(-44.704f, -2.860f, 16.071f, 1.f));
- m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(-44.704f, -2.860f, 16.071f, 1.f));
+ m_pCharacter_Controller->Set_Position(XMVectorSet(-44.704f, 6.860f, 16.071f, 1.f));
+ m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(-44.704f, 6.860f, 16.071f, 1.f));
}
Load_RanrokPos("../Bin/Resources/Data/RanrokPos/RanrokPos.xml");
@@ -162,7 +162,9 @@ void CRanrok::Late_Update(_float fTimeDelta)
{
if (true == m_bLookAt) {
m_pTransformCom->LookAt_Horizontal_Lerp(XMLoadFloat4(&m_vTargetPos), fTimeDelta, 3.f);
+
}
+ m_pModelCom->Set_TargetPos((XMLoadFloat4(&m_vTargetPos)));
}
m_pGameInstance->Add_RenderGroup(RENDER::NONBLEND, this);
@@ -279,6 +281,12 @@ void CRanrok::OnCollision(CGameObject* pOther, void* pDesc)
case ENUM_CLASS(SKILL_TYPE::STUPEFY):
m_eHitSpell = ENUM_CLASS(SKILL_TYPE::STUPEFY);
break;
+ case ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
+ break;
}
}
else
@@ -428,16 +436,23 @@ HRESULT CRanrok::Render_Nonblend()
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
return E_FAIL;
}
- if (FAILED(m_pModelCom->Begin(i, m_pShaderCom, m_bDrawOutLine))) {
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
return E_FAIL;
}
m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->Begin_OutLine_Write(2);
+ }
if (FAILED(m_pModelCom->Render(i))) {
return E_FAIL;
}
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->End_OutLine_Write();
+ }
}
if (m_bDrawOutLine) {
@@ -490,7 +505,82 @@ HRESULT CRanrok::Render_Blend()
if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
return E_FAIL;
}
- if (FAILED(m_pModelCom->Begin(i, m_pShaderCom, m_bDrawOutLine))) {
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
+ m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->Begin_OutLine_Write(2);
+ }
+ if (FAILED(m_pModelCom->Render(i))) {
+ return E_FAIL;
+ }
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->End_OutLine_Write();
+ }
+ }
+
+ if (true == m_bDrawOutLine) {
+ Render_OutLine();
+ }
+ return S_OK;
+}
+HRESULT CRanrok::Render_OutLine()
+{
+ m_bDrawOutLine = false;
+ if (FAILED(Bind_ShaderResources())) {
+ return E_FAIL;
+ }
+
+ Compute_Depth();
+ _float fRatio = CMyTools::Saturate((m_fCamDepth / *m_pGameInstance->Get_CurrentCameraFar()));
+ m_fOutLineThickness = CMyTools::Lerp_f1D(2.f, 6.f, fRatio);
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_vOutLineColor", &m_vOutLineColor, sizeof(_float3)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineThickness", &m_fOutLineThickness, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLineScale", &m_fOutLineScale, sizeof(_float)))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOutLinePower", &m_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_pShaderCom->Bind_Matrices(
+ "g_OffsetMatrix",
+ m_pModelCom->Get_OffsetMatrix(i).data(),
+ (_int)m_pModelCom->Get_OffsetMatrix(i).size()
+ )))
+ {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pModelCom->Bind_Material(i, m_pShaderCom))) {
+ return E_FAIL;
+ }
+
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_NPC_PBR_ANIM::OUTLINE_READ)))) {
return E_FAIL;
}
@@ -501,7 +591,6 @@ HRESULT CRanrok::Render_Blend()
return E_FAIL;
}
}
-
return S_OK;
}
@@ -523,7 +612,6 @@ void CRanrok::MoveTo(_float fTimeDelta)
_vector vLook = XMVector3Normalize(m_pTransformCom->Get_State(STATE::LOOK));
-
_vector toTarget = Target - CurPos;
_float fDist = XMVectorGetX(XMVector3Length(toTarget));
diff --git a/Jusin154_Team3D/Client/Private/Ranrok_FireBall.cpp b/Jusin154_Team3D/Client/Private/Ranrok_FireBall.cpp
index 4eec50dab..f9a7976fb 100644
--- a/Jusin154_Team3D/Client/Private/Ranrok_FireBall.cpp
+++ b/Jusin154_Team3D/Client/Private/Ranrok_FireBall.cpp
@@ -85,7 +85,6 @@ void CRanrok_FireBall::Update(_float fTimeDelta)
_vector vStartPos = XMLoadFloat4(&m_vStartPos);
_vector vEndPos = m_pFireBall->Get_WorldPostion();
ON_COLLISION_INFO CollisionInfo = MonsterSweepTarget(vStartPos, vEndPos, 0.2f, true);
-
OnCollision(this, &CollisionInfo);
}
@@ -134,7 +133,7 @@ HRESULT CRanrok_FireBall::Pre_Setting(CGameObject* pObject, void* pArg)
XMStoreFloat4(&m_vStartPos, vStartPos);
/* 플레이어 위치 받기 */
- CUnit* pPlayer = m_pInfoInstance->Get_NearestPlayerAlly(m_pOwner->Get_WorldPostion()).first;
+ CUnit* pPlayer = m_pInfoInstance->Get_NearestPlayerAlly(m_pOwner->Get_WorldPostion()).first;
if (pPlayer == nullptr)
return E_FAIL;
diff --git a/Jusin154_Team3D/Client/Private/Ranrok_States.cpp b/Jusin154_Team3D/Client/Private/Ranrok_States.cpp
index 0147b33b2..fe01b71b4 100644
--- a/Jusin154_Team3D/Client/Private/Ranrok_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Ranrok_States.cpp
@@ -32,7 +32,7 @@ void CRanrok::Behavior_IdleEnter()
{
m_pFSM->Enable_State(FSMSTATE::IDLE);
pair<_uint, _bool> pairAnimInfo = m_Animation[STATEANIM::HOVER_LOOP];
-
+ m_bLookAt = true;
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
@@ -49,12 +49,14 @@ HRESULT CRanrok::Behavior_IdleExitCheck()
void CRanrok::Behavior_IdleExit()
{
m_pFSM->Disable_State(FSMSTATE::IDLE);
+ m_bLookAt = false;
}
void CRanrok::Behavior_IdleBreakEnter()
{
m_pFSM->Enable_State(FSMSTATE::IDLEBREAK);
pair<_uint, _bool> pairAnimInfo;
+ m_bLookAt = true;
pairAnimInfo = m_Animation[STATEANIM::IDLE_BREAK2];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
}
@@ -71,6 +73,7 @@ HRESULT CRanrok::Behavior_IdleBreakExitCheck()
void CRanrok::Behavior_IdleBreakExit()
{
m_pFSM->Disable_State(FSMSTATE::IDLEBREAK);
+ m_bLookAt = false;
}
void CRanrok::Behavior_MoveEnter()
@@ -283,31 +286,29 @@ void CRanrok::Behavior_FlyExit()
void CRanrok::Behavior_FireBreathEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
+ m_bLookAt = true;
m_pFSM->Enable_State(FSMSTATE::FIREBREATH);
if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_AIR))
{
pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_WINDUP_A];
Add_Event(pairAnimInfo.first,
- [&]() {
- pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_A];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)];
- m_bLookAt = false;
- }, 0.95f);
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_A];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
+ m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)];
+ m_pModelCom->Play_HeadBone(true);
+ m_bLookAt = false; },
+ 0.95f);
Add_Event(m_Animation[STATEANIM::FIREBREATH_A].first,
- [&]() {
- pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_COOLDOWN_A];
- m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- m_bLookAt = true;
- }, 0.95f);
+ [&]() { pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_COOLDOWN_A];
+ m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); },
+ 0.95f);
Add_Event(m_Animation[STATEANIM::FIREBREATH_A].first,
[this]() {
m_pEffectPool->Use_Skill(SKILL_TYPE::RANROK_BREATH, this);
}, 0.1f);
-
}
else if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_GROUND))
{
@@ -321,9 +322,25 @@ HRESULT CRanrok::Behavior_FireBreathExitCheck(_float fTimeDelta)
{
pair<_uint, _bool> pairAnimInfo = {};
_int iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ if (m_pModelCom->Get_PlayHeadBone())
+ {
+ m_fHeadAimWeight += fTimeDelta;
+ if (m_fHeadAimWeight >= 1.f)
+ {
+ m_fHeadAimWeight = 1.f;
+ }
+ m_pModelCom->Set_HeadAimWeight(m_fHeadAimWeight);
+ }
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::FIREBREATH_COOLDOWN_A].first)
+ {
+ m_fHeadAimWeight -= fTimeDelta * 2.f;
+ m_pModelCom->Set_HeadAimWeight(m_fHeadAimWeight);
+ }
if (m_pModelCom->IsFinishedAnim())
{
+ m_pModelCom->Play_HeadBone(false);
if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_AIR))
{
m_pFSM->Change_State(FSMSTATE::IDLEBREAK);
@@ -341,11 +358,13 @@ HRESULT CRanrok::Behavior_FireBreathExitCheck(_float fTimeDelta)
void CRanrok::Behavior_FireBreathExit()
{
m_pFSM->Disable_State(FSMSTATE::FIREBREATH);
+ m_fHeadAimWeight = 0.f;
}
void CRanrok::Behavior_FireSweepEnter()
{
pair<_uint, _bool> pairAnimInfo = {};
+ m_bLookAt = true;
m_pFSM->Enable_State(FSMSTATE::FIRESWEEP);
if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_AIR))
{
@@ -355,15 +374,15 @@ void CRanrok::Behavior_FireSweepEnter()
[&]() { pairAnimInfo = m_Animation[STATEANIM::FIRESWEEP_A];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIRESWEEP)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIRESWEEP)];
- m_bLookAt = false;
- }, 0.95f);
+ m_pModelCom->Play_HeadBone(true);
+ m_bLookAt = false; },
+ 0.95f);
Add_Event(m_Animation[STATEANIM::FIRESWEEP_A].first,
[&]() { pairAnimInfo = m_Animation[STATEANIM::FIRESWEEP_COOLDOWN_A];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- m_bLookAt = true;
},
- 0.94f);
+ 0.95f);
Add_Event(m_Animation[STATEANIM::FIRESWEEP_A].first,
@@ -389,8 +408,25 @@ HRESULT CRanrok::Behavior_FireSweepExitCheck(_float fTimeDelta)
pair<_uint, _bool> pairAnimInfo = {};
_int iCurrAnimIndex = m_pModelCom->Get_AnimIndex();
+ if (m_pModelCom->Get_PlayHeadBone())
+ {
+ m_fHeadAimWeight += fTimeDelta;
+ if (m_fHeadAimWeight >= 1.f)
+ {
+ m_fHeadAimWeight = 1.f;
+ }
+ m_pModelCom->Set_HeadAimWeight(m_fHeadAimWeight);
+ }
+
+ if (iCurrAnimIndex == m_Animation[STATEANIM::FIRESWEEP_COOLDOWN_A].first)
+ {
+ m_fHeadAimWeight -= fTimeDelta * 2.f;
+ m_pModelCom->Set_HeadAimWeight(m_fHeadAimWeight);
+ }
+
if (m_pModelCom->IsFinishedAnim())
{
+ m_pModelCom->Play_HeadBone(false);
if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_AIR))
{
m_pFSM->Change_State(FSMSTATE::IDLEBREAK);
@@ -408,6 +444,7 @@ HRESULT CRanrok::Behavior_FireSweepExitCheck(_float fTimeDelta)
void CRanrok::Behavior_FireSweepExit()
{
m_pFSM->Disable_State(FSMSTATE::FIRESWEEP);
+ m_fHeadAimWeight = 0.f;
}
void CRanrok::Behavior_FireBallEnter()
@@ -465,9 +502,6 @@ void CRanrok::Behavior_FireBallEnter()
}, 0.45f);
break;
}
-
-
-
}
m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBALL)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBALL)];
@@ -620,9 +654,9 @@ void CRanrok::Behavior_PulseEnter()
m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::PULSE)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::PULSE)];
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
- /*Add_Event(pairAnimInfo.first,
+ Add_Event(pairAnimInfo.first,
[this]() { CameraShake(10.f, 2.f, 5.f, 1.2f); },
- 0.39f);*/
+ 0.39f);
}
HRESULT CRanrok::Behavior_PulseExitCheck(_float fTimeDelta)
diff --git a/Jusin154_Team3D/Client/Private/Skill_Data.cpp b/Jusin154_Team3D/Client/Private/Skill_Data.cpp
index 87a66ea56..d42db2959 100644
--- a/Jusin154_Team3D/Client/Private/Skill_Data.cpp
+++ b/Jusin154_Team3D/Client/Private/Skill_Data.cpp
@@ -57,7 +57,7 @@ void CSkill_Data::Update_Damage(_float Damage)
{
for (_int i = 0; i < m_iSpell_Count; ++i)
{
- m_fSpell_Damage[i] = SpellInfo->fSpell_Damage + Damage;
+ m_fSpell_Damage[i] = SpellInfo[i].fSpell_Damage + Damage;
}
}
diff --git a/Jusin154_Team3D/Client/Private/State_Dash.cpp b/Jusin154_Team3D/Client/Private/State_Dash.cpp
new file mode 100644
index 000000000..4ab7f691e
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/State_Dash.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Dash.h"
+#include "Unit.h"
+
+
+CState_Dash::CState_Dash()
+ :CState_Root()
+{
+}
+
+void CState_Dash::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Dash::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_Dash::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Dash::Initialize(STATE_DASH_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_Dash* CState_Dash::Create(STATE_DASH_DESC* pDesc)
+{
+ CState_Dash* pInstance = new CState_Dash;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Dash::Free()
+{
+ __super::Free();
+}
+
+void CState_Dash::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Client/Private/State_Slash.cpp b/Jusin154_Team3D/Client/Private/State_Slash.cpp
new file mode 100644
index 000000000..d0c51f682
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/State_Slash.cpp
@@ -0,0 +1,64 @@
+#include "pch.h"
+#include "State_Slash.h"
+#include "Unit.h"
+
+
+CState_Slash::CState_Slash()
+ :CState_Root()
+{
+}
+
+void CState_Slash::Enter()
+{
+ __super::Enter();
+}
+
+HRESULT CState_Slash::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_Slash::Exit()
+{
+ __super::Exit();
+}
+
+HRESULT CState_Slash::Initialize(STATE_SLASH_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_Slash* CState_Slash::Create(STATE_SLASH_DESC* pDesc)
+{
+ CState_Slash* pInstance = new CState_Slash;
+ if (FAILED(pInstance->Initialize(pDesc))) {
+ SAFE_RELEASE(pInstance);
+ }
+ return pInstance;
+}
+
+void CState_Slash::Free()
+{
+ __super::Free();
+}
+
+void CState_Slash::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Client/Private/Transformation.cpp b/Jusin154_Team3D/Client/Private/Transformation.cpp
index d2d0fd2c8..e36f77300 100644
--- a/Jusin154_Team3D/Client/Private/Transformation.cpp
+++ b/Jusin154_Team3D/Client/Private/Transformation.cpp
@@ -216,7 +216,7 @@ void CTransformation::OnCollision(CGameObject* pOther, void* pDesc)
//m_pCharacter_Controller->Move(fTimeDelta);
- PhsXUserData* pUserData = static_cast(pCCT->Get_Actor()->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pCCT->Get_Actor()->userData);
switch (pUserData->eKind)
{
case PHYSX_KIND::CCTActor:
diff --git a/Jusin154_Team3D/Client/Private/Troll.cpp b/Jusin154_Team3D/Client/Private/Troll.cpp
index 3befbaa81..2b2a8d415 100644
--- a/Jusin154_Team3D/Client/Private/Troll.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll.cpp
@@ -197,16 +197,24 @@ HRESULT CTroll::Render()
return E_FAIL;
}
- if (FAILED(m_pModelCom->Begin(i, m_pShaderCom, m_bDrawOutLine))) {
+ if (FAILED(m_pModelCom->Begin(i, m_pShaderCom))) {
return E_FAIL;
}
m_pModelCom->Bind_OutPut_SRV_VS(26, 0);
m_pModelCom->Bind_OutPut_SRV_VS_Prev(27, 0);
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->Begin_OutLine_Write(2);
+ }
if (FAILED(m_pModelCom->Render(i))) {
return E_FAIL;
}
+
+ if (true == m_bDrawOutLine) {
+ m_pGameInstance->End_OutLine_Write();
+ }
}
if (true == m_bDrawOutLine) {
@@ -252,6 +260,15 @@ HRESULT CTroll::Render_OutLine()
else if (m_fOutLineThickness < 2.f) {
m_fOutLineThickness = 2.f;
}
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_PrevWorldMatrix", m_pTransformCom->Get_PrevWorldMatrixPtr()))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevViewMatrix", D3DTS::VIEW))) {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Bind_PrevMatrix(m_pShaderCom, "g_PrevProjMatrix", D3DTS::PROJ))) {
+ return E_FAIL;
+ }
if (FAILED(m_pShaderCom->Bind_RawValue("g_vOutLineColor", &m_vOutLineColor, sizeof(_float3)))) {
return E_FAIL;
}
@@ -388,6 +405,12 @@ void CTroll::OnCollision(CGameObject* pOther, void* pDesc)
case ENUM_CLASS(SKILL_TYPE::STUPEFY):
m_eHitSpell = ENUM_CLASS(SKILL_TYPE::STUPEFY);
break;
+ case ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::AVADAKEDAVRA);
+ break;
+ case ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC):
+ m_eHitSpell = ENUM_CLASS(SKILL_TYPE::ANCIENT_MAGIC);
+ break;
}
}
else
diff --git a/Jusin154_Team3D/Client/Private/Troll_Rock.cpp b/Jusin154_Team3D/Client/Private/Troll_Rock.cpp
index 982105e77..8d47fc8a6 100644
--- a/Jusin154_Team3D/Client/Private/Troll_Rock.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll_Rock.cpp
@@ -122,7 +122,7 @@ void CTroll_Rock::RockHit()
memcpy_s(&tagCollInfo.vWorldNomal, sizeof(tagCollInfo.vWorldNomal), &hit.normal, sizeof(hit.normal));
XMStoreFloat4(&tagCollInfo.vHitDir, vDir);
tagCollInfo.fLength = fLength;
- PhsXUserData* pUserData = static_cast(pActor->userData);
+ PHYSX_USERDATA* pUserData = static_cast(pActor->userData);
tagCollInfo.pObject = pUserData->pOwner;
tagCollInfo.eHitType = ENUM_CLASS(HIT_TYPE::HIT_HEAVY);
tagCollInfo.fDamage = 10.f;
diff --git a/Jusin154_Team3D/Client/Private/Troll_States.cpp b/Jusin154_Team3D/Client/Private/Troll_States.cpp
index 4a25fa58b..663388a19 100644
--- a/Jusin154_Team3D/Client/Private/Troll_States.cpp
+++ b/Jusin154_Team3D/Client/Private/Troll_States.cpp
@@ -883,7 +883,7 @@ void CTroll::SwingHit(_bool& bPlayerHit)
for (_uint i = 0; i < pxHits.size(); ++i) {
PSX::PxActor* pxHitActor = pxHits[i].actor;
if (nullptr != pxHitActor && nullptr != pxHitActor->userData) {
- PhsXUserData* pUserData = (PhsXUserData*)pxHitActor->userData;
+ PHYSX_USERDATA* pUserData = (PHYSX_USERDATA*)pxHitActor->userData;
ON_COLLISION_INFO tagCollInfo = {};
tagCollInfo.vWorldPos.w = 1.f;
@@ -934,7 +934,7 @@ void CTroll::SlamHit(_bool& bPlayerHit)
for (_uint i = 0; i < pxHits.size(); ++i) {
PSX::PxActor* pxHitActor = pxHits[i].actor;
if (nullptr != pxHitActor && nullptr != pxHitActor->userData) {
- PhsXUserData* pUserData = (PhsXUserData*)pxHitActor->userData;
+ PHYSX_USERDATA* pUserData = (PHYSX_USERDATA*)pxHitActor->userData;
ON_COLLISION_INFO tagCollInfo = {};
diff --git a/Jusin154_Team3D/Client/Public/Camera_Model.h b/Jusin154_Team3D/Client/Public/Camera_Model.h
new file mode 100644
index 000000000..eee7bdcfc
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Camera_Model.h
@@ -0,0 +1,50 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "Camera.h"
+
+NS_BEGIN(Client)
+
+class CCamera_Model final : public CCamera
+{
+public:
+ typedef struct tagCamera_Model : public CCamera::CAMERA_DESC
+ {
+ _float3 vEye{}, vAt{};
+ _float fMouseSensor{};
+ }CAMERA_MODEL_DESC;
+private:
+ CCamera_Model(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CCamera_Model(const CCamera_Model& rhs);
+ virtual ~CCamera_Model() = 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;
+
+private:
+ class CModel* m_pModelCom = { nullptr };
+ class CShader* m_pShaderCom = { nullptr };
+ _bool m_bMovable = true;
+ _float4x4 m_matInitial = {};
+
+private:
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+ virtual HRESULT Ready_Components(void* pArg) override;
+ HRESULT Bind_ShaderResources() override;
+ void Set_InitialPos();
+
+public:
+ static CCamera_Model* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, CGameObject* pOwner) override;
+ virtual void Free() override;
+#ifdef _DEBUG
+ void Describe_Entity() override;
+#endif // _DEBUG
+
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Client_Enum.h b/Jusin154_Team3D/Client/Public/Client_Enum.h
index 032b07f62..0b55e9391 100644
--- a/Jusin154_Team3D/Client/Public/Client_Enum.h
+++ b/Jusin154_Team3D/Client/Public/Client_Enum.h
@@ -25,7 +25,7 @@ namespace Client
enum class SHADER_PASS_NPC_PBR_ANIM {
EYELASH_DAOTHV_ToSRO, TEETH_SRXO_ToSRO, EYE_DN_ToSRO, EYE_OCC, FACIAL_HAIR_DAOTHV_ToSRO, HEAD_HAIR_DAOTHV_ToSRO, HEADwtHAND_DSRXON_ToSRO, LOWER_DSRON_ToSRO, UPPER_DMRON_ToMRO, GLASSES_DMRON_ToMRO, EmissiveMetalness_DENMRO_ToMRO, MI_ClothSim_DSEN_ToSRO, MI_Troll_Club_DAENMROSRXO_To
- , OUTLINE_READ, TEETH_SRXO_ToSRO__OUTLINE_WRITE, EYE_DN_ToSRO__OUTLINE_WRITE, HEADwtHAND_DSRXON_ToSRO__OUTLINE_WRITE, UPPER_DMRON_ToMRO__OUTLINE_WRITE, EmissiveMetalness_DENMRO_ToMRO__OUTLINE_WRITE, MI_ClothSim_DSEN_ToSRO__OUTLINE_WRITE
+ , OUTLINE_READ
, END
};
enum class UI_STATE { GAMEPLAYER, SPELL, QUEST, INVENTORY, SPELLLNEARN, END };
diff --git a/Jusin154_Team3D/Client/Public/Client_Macro.h b/Jusin154_Team3D/Client/Public/Client_Macro.h
index a1a9fddb0..9e18c3844 100644
--- a/Jusin154_Team3D/Client/Public/Client_Macro.h
+++ b/Jusin154_Team3D/Client/Public/Client_Macro.h
@@ -34,6 +34,7 @@ namespace Client {
#define CAMERA_DEBUG TEXT("CAMERA_DEBUG")
#define CAMERA_SHOULDER TEXT("CAMERA_SHOULDER")
#define CAMERA_AI TEXT("CAMERA_AI")
+#define CAMERA_MODEL TEXT("CAMERA_MODEL")
#pragma endregion
#pragma region COMPONENT
diff --git a/Jusin154_Team3D/Client/Public/Dummy_PhysXPlayable.h b/Jusin154_Team3D/Client/Public/Dummy_PhysXPlayable.h
deleted file mode 100644
index 6c2583d33..000000000
--- a/Jusin154_Team3D/Client/Public/Dummy_PhysXPlayable.h
+++ /dev/null
@@ -1,54 +0,0 @@
-#pragma once
-
-#include "Client_Define.h"
-#include "GameObject.h"
-#include "CallBack_Playable_Behavior.h"
-#include "CallBack_Playable_HitReport.h"
-
-NS_BEGIN(Client)
-
-class CDummy_PhysXPlayable final : public CGameObject
-{
-public:
- typedef struct tagPhysXDummyDesc
- {
- _float3 vPos = { };
- _float3 vRotRPY = { };
- _uint iSubKind = { };
- }PHYSXDUMMY_DESC;
-private:
- CDummy_PhysXPlayable(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
- CDummy_PhysXPlayable(const CDummy_PhysXPlayable& rhs);
- virtual ~CDummy_PhysXPlayable() = 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;
-
-private:
- CCharacter_Controller* m_pCharacter_Controller = { nullptr };
- CRigidBody_Dynamic* m_pRigidBody = { nullptr };
- CModel* m_pModelCom = { nullptr };
- CShader* m_pShaderCom = { nullptr };
-
- CCallBack_Playable_Behavior* m_pCallBack_Behavior = { nullptr };
- CCallBack_Playable_HitReport* m_pCallBack_HitReport = { nullptr };
-
-private:
- virtual HRESULT Initialize_Prototype() override;
- virtual HRESULT Initialize(void* pArg) override;
- virtual HRESULT Ready_Components(void* pArg) override;
- virtual HRESULT Bind_ShaderResources() override;
-
-public:
- static CDummy_PhysXPlayable* 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/Dummy_PhysXWall.h b/Jusin154_Team3D/Client/Public/Dummy_PhysXWall.h
deleted file mode 100644
index a51fb0305..000000000
--- a/Jusin154_Team3D/Client/Public/Dummy_PhysXWall.h
+++ /dev/null
@@ -1,51 +0,0 @@
-#pragma once
-
-#include "Client_Define.h"
-#include "GameObject.h"
-
-NS_BEGIN(Client)
-
-class CDummy_PhysXWall final : public CGameObject
-{
-public:
- typedef struct tagPhysXDummyDesc
- {
- _float3 vPos = { };
- _float3 vRotRPY = { };
- _uint iSubKind = { };
- }PHYSXDUMMY_DESC;
-private:
- CDummy_PhysXWall(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
- CDummy_PhysXWall(const CDummy_PhysXWall& rhs);
- virtual ~CDummy_PhysXWall() = 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;
-
-private:
- CRigidBody* m_pRigidBody = { nullptr };
- const PSX::PxRigidDynamic* m_pActor = { nullptr };
- CModel* m_pModelCom = { nullptr };
- CShader* m_pShaderCom = { nullptr };
-
-
-private:
- virtual HRESULT Initialize_Prototype() override;
- virtual HRESULT Initialize(void* pArg) override;
- virtual HRESULT Ready_Components(void* pArg) override;
- virtual HRESULT Bind_ShaderResources() override;
-
-public:
- static CDummy_PhysXWall* 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/Goblin_Assassin.h b/Jusin154_Team3D/Client/Public/Goblin_Assassin.h
new file mode 100644
index 000000000..3dfaa013c
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_Assassin.h
@@ -0,0 +1,138 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "Monster.h"
+#include "CallBack_Monster_Behavior.h"
+#include "CallBack_Monster_HitReport.h"
+#include "Enemy_Detection.h"
+
+NS_BEGIN(Client)
+
+class CGoblin_Assassin final : public CMonster
+{
+ enum class GOBLIN_ASSASSIN_SKILL
+ {
+ SLASH,
+ DASH,
+ TP,
+ END
+ };
+private:
+ CGoblin_Assassin(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_Assassin(const CGoblin_Assassin& Prototype);
+ virtual ~CGoblin_Assassin() = 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_OutLine();
+ virtual HRESULT Render_Shadow(SHADOW eType) 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;
+
+ void Set_Detection(_bool bDetection);
+private:
+ CCallBack_Monster_Behavior* m_pCallBack_Behavior = { nullptr };
+ CCallBack_Monster_HitReport* m_pCallBack_HitReport = { nullptr };
+ CEnemy_Detection* m_pDetection = { nullptr };
+
+ CCharacter_Controller* m_pCharacter_Controller = { nullptr };
+ CRigidBody_Dynamic* m_pRigidBody = { nullptr };
+ _float2 m_vStunTimer = { 0.f, 4.f };
+ _uint iIndex;
+private:
+ class CEffectPool* m_pEffectPool = nullptr;
+ DAMAGE_INFO m_DamageInfo;
+
+ _bool m_bDetection = { false };
+
+
+ class CEffectParts* m_pSmoke = { nullptr };
+ class CEffectParts* m_pGoblin_Particle = { nullptr };
+ class CEffectParts* m_pGoblin_Particle2 = { nullptr };
+ class CGoblin_Assassin_Spector* m_pGoblinSpector = { nullptr };
+private:
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+ HRESULT Ready_Components();
+ HRESULT Ready_Parts();
+ HRESULT Bind_ShaderResources();
+ void HitState_Behavior(_float fTimeDelta);
+
+public:
+ static CGoblin_Assassin* 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_ASSASSIN_SKILL::END)] = {};
+ _float m_fMaxSkillCoolTime[ENUM_CLASS(GOBLIN_ASSASSIN_SKILL::END)] = { 5.f,2.f,15.f };
+
+ _bool m_bStep = { true };
+ _float m_fTpTime = {};
+ _float m_fAirTime = {};
+ _vector m_vOriginPos = {};
+ _float m_fLength = {};
+ _float m_fMoveTime = {};
+ _bool m_bFirstMove = {};
+ _bool m_bPos = {};
+ _float m_fAccel = { 3.f};
+ _float m_fTargetSpeed = {60.f};
+ _float m_fSpeed = {};
+ _bool m_bAir = {};
+ _float m_fGravityAmount = {};
+ _float m_fHitTimer = {};
+ _float m_fTumbleTimer = {};
+
+ void Behavior_IdleEnter();
+ HRESULT Behavior_IdleExitCheck();
+ void Behavior_IdleExit();
+
+ void Behavior_IdleBreakEnter();
+ HRESULT Behavior_IdleBreakExitCheck();
+ void Behavior_IdleBreakExit();
+
+ void Behavior_MoveEnter();
+ HRESULT Behavior_MoveExitCheck(_float fTimeDelta);
+ void Behavior_MoveExit();
+
+ void Behavior_CombatEnter();
+ HRESULT Behavior_CombatExitCheck(_float fTimeDelta);
+ void Behavior_CombatExit();
+
+ void Behavior_SlashEnter();
+ HRESULT Behavior_SlashExitCheck(_float fTimeDelta);
+ void Behavior_SlashExit();
+
+ void Behavior_DashEnter();
+ HRESULT Behavior_DashExitCheck(_float fTimeDelta);
+ void Behavior_DashExit();
+
+ void Behavior_BlinkEnter();
+ 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();
+
+ void Behavior_DeadEnter();
+ HRESULT Behavior_DeadExitCheck(_float fTimeDelta);
+ void Behavior_DeadExit();
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Goblin_Assassin_Spector.h b/Jusin154_Team3D/Client/Public/Goblin_Assassin_Spector.h
new file mode 100644
index 000000000..079a9de14
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_Assassin_Spector.h
@@ -0,0 +1,79 @@
+#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_Assassin_Spector final : public CMonster
+{
+public:
+ typedef struct tagSpector
+ {
+ CTransform* pParentTransform = { nullptr };
+ }GOBLIN_SPECTOR_DESC;
+private:
+ CGoblin_Assassin_Spector(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_Assassin_Spector(const CGoblin_Assassin_Spector& Prototype);
+ virtual ~CGoblin_Assassin_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;
+
+public:
+ void Spector_Trail_Visible(_bool isTrailVisible);
+ void Set_Disolve(_bool bDisolve) { m_bDisolve = bDisolve; }
+
+
+private:
+ class CGoblin_Assassin* 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 CTrailObject* m_pLeft_Trail = { nullptr };
+ class CTrailObject* m_pRight_Trail = { nullptr };
+
+ const _float4x4* m_pLeftHand_BoneMat = { nullptr };
+ const _float4x4* m_pRightHand_BoneMat = { 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_Assassin_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/Goblin_Attack.h b/Jusin154_Team3D/Client/Public/Goblin_Attack.h
index ad6aee3bf..aa9a247c7 100644
--- a/Jusin154_Team3D/Client/Public/Goblin_Attack.h
+++ b/Jusin154_Team3D/Client/Public/Goblin_Attack.h
@@ -34,6 +34,7 @@ class CGoblin_Attack final : public CEffect_Container
_wstring m_wstrEffectName = {};
class CEffectParts* m_pPT1 = { nullptr };
class CEffectParts* m_pPT2 = { nullptr };
+ _float4x4 m_vMat = {};
public:
static CGoblin_Attack* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual void Free() override;
diff --git a/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h b/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h
index 97263633d..37064e7e1 100644
--- a/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h
+++ b/Jusin154_Team3D/Client/Public/Goblin_BattleAxe.h
@@ -24,7 +24,7 @@ class CGoblin_BattleAxe final : public CPartObject
virtual HRESULT Render() override;
HRESULT Render_Disolve();
void Set_Disolve(_bool bDisolve) { m_bDisolve = bDisolve; }
- const _float4x4 Get_AxeMatrix() { return m_vAxeMat; };
+ const _float4x4& Get_AxeMatrix() { return m_vAxeMat; };
private:
const _float4x4* m_pSocketMatrices = { };
diff --git a/Jusin154_Team3D/Client/Public/Goblin_Protego.h b/Jusin154_Team3D/Client/Public/Goblin_Protego.h
index 284adbc40..9de274855 100644
--- a/Jusin154_Team3D/Client/Public/Goblin_Protego.h
+++ b/Jusin154_Team3D/Client/Public/Goblin_Protego.h
@@ -32,7 +32,7 @@ class CGoblin_Protego final : public CEffect_Container
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr) override;
private:
_wstring m_wstrEffectName = {};
-
+ CRigidBody_Dynamic* m_pRigidBody = { nullptr };
class CEffectParts* m_pSphere = { nullptr };
class CEffectParts* m_pBottom = { nullptr };
class CEffectParts* m_pCircle = { nullptr };
diff --git a/Jusin154_Team3D/Client/Public/Goblin_Sword.h b/Jusin154_Team3D/Client/Public/Goblin_Sword.h
new file mode 100644
index 000000000..7fd12ca13
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Goblin_Sword.h
@@ -0,0 +1,64 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "PartObject.h"
+
+NS_BEGIN(Client)
+
+class CGoblin_Sword final : public CPartObject
+{
+public:
+ typedef struct tagSword : public CPartObject::PARTOBJECT_DESC
+ {
+ const _float4x4* pSocketMatrices = { };
+ _int iIndex = {};
+ }GOBLIN_SWORD_DESC;
+private:
+ CGoblin_Sword(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CGoblin_Sword(const CGoblin_Sword& Prototype);
+ virtual ~CGoblin_Sword() = 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;
+ HRESULT Render_Disolve();
+ void Set_Disolve(_bool bDisolve) { m_bDisolve = bDisolve; }
+ void Set_CanTakeDamage(_bool bCanTake) { m_bCanTakeDamage = bCanTake; }
+ const _float4x4& Get_SwordMatrix() { return m_vSwordMat; };
+public:
+
+private:
+ const _float4x4* m_pSocketMatrices = { };
+ CShader* m_pShaderCom = { nullptr };
+ CModel* m_pModelCom = { nullptr };
+ _int m_iIndex = {};
+ _wstring m_strModelPrototypeTag;
+ _bool m_bCanTakeDamage = { false };
+ _bool m_bHit = { false };
+ _bool m_bDisolve = { false };
+ _float m_fDisolveTime = { 0.f };
+ _float4x4 m_vSwordMat = {};
+
+ _float4 m_vStartPos = {};
+ PSX::PxSweepBufferN<12> m_SweepBuffer = {};
+
+private:
+ HRESULT Ready_Components();
+ HRESULT Bind_ShaderResources();
+ void Sword_Hit();
+
+public:
+ static CGoblin_Sword* 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/Level_Field.h b/Jusin154_Team3D/Client/Public/Level_Field.h
index 880a29d7d..4c875dd93 100644
--- a/Jusin154_Team3D/Client/Public/Level_Field.h
+++ b/Jusin154_Team3D/Client/Public/Level_Field.h
@@ -15,6 +15,7 @@ class CLevel_Field final : public CLevel
virtual void Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ _bool m_isDay = { true };
private:
class CInfoInstance* m_pInfoInstance = { nullptr };
diff --git a/Jusin154_Team3D/Client/Public/Level_GamePlay.h b/Jusin154_Team3D/Client/Public/Level_GamePlay.h
index 42385a209..c5bd6bcd8 100644
--- a/Jusin154_Team3D/Client/Public/Level_GamePlay.h
+++ b/Jusin154_Team3D/Client/Public/Level_GamePlay.h
@@ -19,10 +19,13 @@ class CLevel_GamePlay final : public CLevel
private:
class CInfoInstance* m_pInfoInstance = { nullptr };
class CBroomRaceManager* m_pBroomRaceManager = { nullptr };
+
+ _bool m_isDay = { true };
private:
virtual HRESULT Initialize() override;
HRESULT Initialize(void* pArg);
HRESULT Ready_Lights();
+ HRESULT Ready_Volumetric();
HRESULT Ready_Background();
HRESULT Ready_Layer_Hogsmeade();
HRESULT Ready_Layer_Hogwart();
diff --git a/Jusin154_Team3D/Client/Public/Light_Main.h b/Jusin154_Team3D/Client/Public/Light_Main.h
index a56ac9081..e030c53cd 100644
--- a/Jusin154_Team3D/Client/Public/Light_Main.h
+++ b/Jusin154_Team3D/Client/Public/Light_Main.h
@@ -20,13 +20,13 @@ class CLight_Main final : public CGameObject
virtual HRESULT Capture_PreShadow();
private:
- CLight* m_pLightCom = { nullptr };
+ CLight* m_pLightCom = { nullptr };
private:
virtual HRESULT Initialize_Prototype() override;
virtual HRESULT Initialize(void* pArg) override;
- HRESULT Ready_Components();
+ HRESULT Ready_Components(void* pArg);
HRESULT Bind_ShaderResources();
_matrix Get_OffCenterProjMatrix(_fmatrix ViewMatrix, vector<_float3>& WorldPositions);
diff --git a/Jusin154_Team3D/Client/Public/Player.h b/Jusin154_Team3D/Client/Public/Player.h
index 51da992ec..874aaf0aa 100644
--- a/Jusin154_Team3D/Client/Public/Player.h
+++ b/Jusin154_Team3D/Client/Public/Player.h
@@ -2,30 +2,12 @@
#include "Client_Define.h"
#include "Unit.h"
+#include "Player_ENUM.h"
NS_BEGIN(Client)
class CPlayer final : public CUnit
{
- enum class PLAYER_MESH_ORDER {
- HEAD_EYE_OCC,
- HEAD_FACE,
- HEAD_TEETH,
- HEAD_EYELASH,
- HEAD_EYES,
- BODY_ARMS,
- HAIR_MAIN,
- HAIR_MAIN_CLOTH,
- LOWER,
- SHOES,
- UPPER,
- HAIR_SUB,
- HAIR_SUB_CLOTH,
- ROBE_SKIRT,
- ROBE_FUR,
- ROBE_CLOTH,
- END
- };
public:
typedef struct tagPlayerInitDesc {
_float4 vPos;
@@ -92,6 +74,8 @@ class CPlayer final : public CUnit
class CTransform* m_pBroomTransform = { nullptr };
class CBroom* m_pBroom = { nullptr };
CStat* m_pStat = { nullptr };
+ class CPlayerRobe* m_pRobePart = { nullptr };
+
class CBroomRaceManager* m_pBroomRaceManager = { nullptr };
class CRaceRing* m_pRaceRing = { nullptr };
diff --git a/Jusin154_Team3D/Client/Public/PlayerRobe.h b/Jusin154_Team3D/Client/Public/PlayerRobe.h
new file mode 100644
index 000000000..b5ab2c13a
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/PlayerRobe.h
@@ -0,0 +1,88 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "PartObject.h"
+#include "Player_ENUM.h"
+
+NS_BEGIN(Client)
+
+class CPlayerRobe final : public CPartObject
+{
+ typedef struct tagRouteCreater {
+ _uint iTargetRouteIndex = UINT_MAX; // 만들려는 루트
+ _uint iStartBoneIndex = UINT_MAX; // 시작 앵커
+ _uint iEndBoneIndex = UINT_MAX; // 끝 앵커
+ _uint iStartJointIndex = UINT_MAX; // 시작 앵커가 할당받을 인덱스
+ _uint iEndJointIndex = UINT_MAX; // 끝 앵커가 할당받을 인덱스
+ }ROUTE_DESC;
+
+public:
+ typedef struct tagPlayerRobe : public CPartObject::PARTOBJECT_DESC
+ {
+ const _float4x4* pSocketMatrix = { };
+ CModel* pModel = { nullptr };
+ }PlayerRobe_DESC;
+private:
+ CPlayerRobe(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CPlayerRobe(const CPlayerRobe& Prototype);
+ virtual ~CPlayerRobe() = 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;
+private:
+ _float4x4 m_PreTransformMatrix = { };
+ const _float4x4* m_pSocketMatrix = { nullptr };
+ const _float4x4* m_pLeftFootLocalMatrix = { nullptr };
+ const _float4x4* m_pLeftLegLocalMatrix = { nullptr };
+ const _float4x4* m_pRightFootLocalMatrix = { nullptr };
+ const _float4x4* m_pRightLegLocalMatrix = { nullptr };
+ const _float4x4* m_RobeJointAnchorMatrices[ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END)] = { nullptr };
+ _float4x4 m_ReconstructedJointAnchorMatirces[ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END)] = { };
+
+ CModel* m_pModelCom = { nullptr };
+ CRigidBody_Dynamic* m_pRightLeg = { nullptr };
+ CRigidBody_Dynamic* m_pLeftLeg = { nullptr };
+ CRigidBody_Dynamic* m_pRobeMainAnchor = { nullptr };
+ CRigidBody_Dynamic* m_pRobeJointRoute[ENUM_CLASS(PLAYER_JOINT_ROUTE_ORDER::END)] = { nullptr };
+ CRigidBody_Dynamic* m_pRobeJointAnchor[ENUM_CLASS(PLAYER_JOINT_BONE_ORDER::END)] = { nullptr };
+ PSX::PxD6Joint* m_pDynamicJoints[ENUM_CLASS(PLAYER_JOINT_ORDER::END)] = { nullptr };
+
+ ID3D11Buffer* m_pBoneCombinedMatrixBuffer = { nullptr };
+ ID3D11ShaderResourceView* m_pBoneCombinedMatrixSRV = { nullptr };
+
+ CModel::BONEINSERTION_DESC m_BoneInsertionDesc = {};
+#ifdef _DEBUG
+ unique_ptr m_pMainShape = { nullptr };
+ unique_ptr m_pSubShape = { nullptr };
+ ID3D11DepthStencilState* m_pDepthStencilStateNone = { nullptr };
+ _float4x4 m_LeftLegMatrix = {};
+ _float4x4 m_RightLegMatrix = {};
+#endif // _DEBUG
+private:
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+ HRESULT Ready_Components();
+ HRESULT Bind_ShaderResources() { return S_OK; }
+
+ HRESULT Update_LegsPosition();
+ HRESULT Update_RobeSocketPosition();
+ HRESULT Helper_RouteJointGenerater(CRigidBody_Dynamic::RIGIDBODY_DYNAMIC_DESC& Desc_Body, ROUTE_DESC& Desc_Route, _matrix* xmAnchorMatricesWorld);
+ HRESULT Create_BoneCombinedMatrixSRV();
+#ifdef _DEBUG
+ HRESULT Render_BonePhysX();
+ HRESULT Render_Legs();
+#endif // _DEBUG
+public:
+ static CPlayerRobe* 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/Player_ENUM.h b/Jusin154_Team3D/Client/Public/Player_ENUM.h
new file mode 100644
index 000000000..41b9bfd7f
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Player_ENUM.h
@@ -0,0 +1,125 @@
+#pragma once
+#include "Client_Define.h"
+
+NS_BEGIN(Client)
+
+enum class PLAYER_MESH_ORDER {
+ HEAD_EYE_OCC,
+ HEAD_FACE,
+ HEAD_TEETH,
+ HEAD_EYELASH,
+ HEAD_EYES,
+ BODY_ARMS,
+ HAIR_MAIN,
+ HAIR_MAIN_CLOTH,
+ LOWER,
+ SHOES,
+ UPPER,
+ HAIR_SUB,
+ HAIR_SUB_CLOTH,
+ ROBE_SKIRT,
+ ROBE_FUR,
+ ROBE_CLOTH,
+ END
+};
+
+static const _char* PLAYER_JOINT_BONE_NAMES[12] = {
+ "RightUpLeg_Cloth"
+ , "TailUp_Cloth"
+ , "LeftUpLeg_Cloth"
+
+ , "RightLeg_Cloth"
+ , "Tail_Cloth"
+ , "LeftLeg_Cloth"
+
+ , "RightDownLeg_Cloth"
+ , "RightDownRightLeg_Cloth"
+ , "TailRightDown_Cloth"
+
+ , "TailLeftDown_Cloth"
+ , "LeftDownLeftLeg_Cloth"
+ , "LeftDownLeg_Cloth"
+};
+
+enum class PLAYER_JOINT_BONE_ORDER {
+ RIGHTUP
+ , RIGHT
+ , RIGHTDOWN
+ , RIGHTDOWNRIGHT
+
+ , LEFTUP
+ , LEFT
+ , LEFTDOWN
+ , LEFTDOWNLEFT
+
+ , TAILUP
+ , TAIL
+ , TAILLEFTDOWN
+ , TAILRIGHTDOWN
+
+ , END
+};
+
+enum class PLAYER_JOINT_ORDER {
+ ORIGIN_TO_RUP_START
+ , ORIGIN_TO_RUP_END
+
+ , ORIGIN_TO_TUP_START
+ , ORIGIN_TO_TUP_END
+
+ , ORIGIN_TO_LUP_START
+ , ORIGIN_TO_LUP_END
+
+
+ , RUP_TO_RMIDDLE_START
+ , RUP_TO_RMIDDLE_END
+
+ , TUP_TO_TMIDDLE_START
+ , TUP_TO_TMIDDLE_END
+
+ , LUP_TO_LMIDDLE_START
+ , LUP_TO_LMIDDLE_END
+
+
+ , RMIDDLE_TO_RR_START
+ , RMIDDLE_TO_RR_END
+
+ , RMIDDLE_TO_R_START
+ , RMIDDLE_TO_R_END
+
+ , TMIDDLE_TO_TR_START
+ , TMIDDLE_TO_TR_END
+
+ , TMIDDLE_TO_TL_START
+ , TMIDDLE_TO_TL_END
+
+ , LMIDDLE_TO_L_START
+ , LMIDDLE_TO_L_END
+
+ , LMIDDLE_TO_LL_START
+ , LMIDDLE_TO_LL_END
+
+
+ , END
+};
+
+enum class PLAYER_JOINT_ROUTE_ORDER {
+ ORIGIN_TO_RUP
+ , ORIGIN_TO_TUP
+ , ORIGIN_TO_LUP
+
+ , RUP_TO_RMIDDLE
+ , TUP_TO_TMIDDLE
+ , LUP_TO_LMIDDLE
+
+ , RMIDDLE_TO_RR
+ , RMIDDLE_TO_R
+ , TMIDDLE_TO_TR
+ , TMIDDLE_TO_TL
+ , LMIDDLE_TO_L
+ , LMIDDLE_TO_LL
+ , END
+};
+
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Ranrok.h b/Jusin154_Team3D/Client/Public/Ranrok.h
index 2f3c723e9..1edc6ef52 100644
--- a/Jusin154_Team3D/Client/Public/Ranrok.h
+++ b/Jusin154_Team3D/Client/Public/Ranrok.h
@@ -48,6 +48,7 @@ class CRanrok final : public CMonster
virtual void Update(_float fTimeDelta) override;
virtual void Late_Update(_float fTimeDelta) override;
virtual HRESULT Render() override;
+ virtual HRESULT Render_OutLine() override;
virtual HRESULT Render_Shadow(SHADOW eType) override;
virtual _vector Get_LockOnPos() override;
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr)override;
@@ -93,7 +94,7 @@ class CRanrok final : public CMonster
_int m_ePhase = ENUM_CLASS(RANROK_PHASE::PHASE_AIR);
_float m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::END)] = {};
- _float m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::END)] = { 40.f,40.f ,15.f,40.f,40.f,40.f};
+ _float m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::END)] = { 40.f,40.f ,8.f,40.f,40.f,40.f};
_float m_fTuckedTime = {};
_bool m_bFireBurst = { false };
@@ -112,6 +113,7 @@ class CRanrok final : public CMonster
_float m_fAroundRadius = 40.f;
_float m_fAroundTime = {};
_float m_fRushTime = {};
+ _float m_fHeadAimWeight = {};
class CEffect_Container* m_pRanrok_Point = { nullptr };
_float m_fTuckedSpeed = { 75.f };
diff --git a/Jusin154_Team3D/Client/Public/State_Dash.h b/Jusin154_Team3D/Client/Public/State_Dash.h
new file mode 100644
index 000000000..61387d619
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/State_Dash.h
@@ -0,0 +1,36 @@
+#pragma once
+#include "Client_Define.h"
+#include "State_Root.h"
+
+NS_BEGIN(Client)
+
+class CState_Dash final : public CState_Root
+{
+public:
+ typedef struct tagDash : public CState_Root::STATE_ROOT_DESC {
+ function funcPriorityUpdate = { nullptr };
+ function funcLateUpdate = { nullptr };
+ }STATE_DASH_DESC;
+private:
+ CState_Dash();
+ virtual ~CState_Dash() = 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_DASH_DESC* pDesc);
+
+public:
+ static CState_Dash* Create(STATE_DASH_DESC* pDesc);
+ virtual void Free() override;
+ virtual void Describe_Entity();
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/State_Slash.h b/Jusin154_Team3D/Client/Public/State_Slash.h
new file mode 100644
index 000000000..cbfc28c0f
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/State_Slash.h
@@ -0,0 +1,36 @@
+#pragma once
+#include "Client_Define.h"
+#include "State_Root.h"
+
+NS_BEGIN(Client)
+
+class CState_Slash final : public CState_Root
+{
+public:
+ typedef struct tagSlash : public CState_Root::STATE_ROOT_DESC {
+ function funcPriorityUpdate = { nullptr };
+ function funcLateUpdate = { nullptr };
+ }STATE_SLASH_DESC;
+private:
+ CState_Slash();
+ virtual ~CState_Slash() = 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_SLASH_DESC* pDesc);
+
+public:
+ static CState_Slash* Create(STATE_SLASH_DESC* pDesc);
+ virtual void Free() override;
+ virtual void Describe_Entity();
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/Stat/Stat.xml
index a18e49aa2..a9bf5fcb8 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/Spell/SpellInfo.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
index a5487a058..2f4d236b3 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/UI/Spell/SpellInfo.xml
@@ -109,7 +109,7 @@
반환됩니다." Spell_Lock="0"
Equip_Spell="0" Use_Skill="1" Preview="0" Vidio="0" />
-
+
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig_Anim.xml b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig_Anim.xml
index 63a17c1c2..ca2a1c2a6 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig_Anim.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/Npc/EleazarFig/Professor_EleazarFig_Anim.xml
@@ -173,7 +173,7 @@
-
+
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.bin
index 403e0054c..401c670b0 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:e6ecd489ba85df6cb5c61fba767fdff0bc202c8b36b0459b5195c1bd8322a43f
-size 10290646
+oid sha256:19fe722384b732f55bddc9ac5d09f0d50c2a81c76bd7b8c580378f6fa077ca92
+size 10364804
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.fbx
index 6442fd9fb..bb404edba 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:aa133b47cdbc06afb3c3ad6a86f1983d7bc977a9d87dc4381316776bbcd1ae6f
-size 5616188
+oid sha256:32213c93d4cc6a61dd1bfcdb4193bfa76ddb1df6446e1ab1dfeab4d5ff522efd
+size 5730924
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.xml b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.xml
index 837220a11..9bf7fcb9c 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable.xml
@@ -86,7 +86,7 @@
-
+
@@ -115,7 +115,7 @@
-
+
@@ -173,7 +173,7 @@
-
+
@@ -231,7 +231,7 @@
-
+
@@ -260,7 +260,7 @@
-
+
@@ -289,7 +289,7 @@
-
+
@@ -318,7 +318,7 @@
-
+
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.bin
new file mode 100644
index 000000000..84a67412b
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.bin
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5de12debaa365a050c382275f3f5ea6f0d1837fb91455f97ec7ed6664ca0a125
+size 10647812
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.fbx
new file mode 100644
index 000000000..421a1ac9e
--- /dev/null
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavra.fbx
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:78fb82fcf96c82e6150fcbb64add88abc6bc7c622c4b3eee282fe75c3aaf438e
+size 6313116
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.bin
deleted file mode 100644
index 6d491ba80..000000000
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.bin
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:552a7e673dd5b90f308bc17e429ce5871b8b69c407800fba7c01deee8a4d0fd1
-size 10570937
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.fbx
deleted file mode 100644
index ac69afac8..000000000
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_AvadaKedavran.fbx
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:3e2e58a126c01b12f8a6e7f16fd1bff734f2cfac8a2a781c27616db44d07e6be
-size 6158620
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.bin
index 82d20f449..87e386e1e 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:45d37a80efc01abf16883a6386324f9180775c227c6ac3be54351330d43c56d1
-size 170896473
+oid sha256:d6603be4f8c20ac9d35068a179b14d328d2e3ed8606cbbe4ff485ee20860c0e8
+size 171707390
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.fbx
index b89f32cd1..a9917c355 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Bm.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:8f471396193ee00ab3f6e5cfb05671521ce2ec5f2f7658ad01034d075fcbf25d
-size 457150268
+oid sha256:a4b060e3740116655157dcef4e1c24be46ef19e135bee51f1f226c8e67f92553
+size 483257372
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.bin
index dcf9cec67..d0c17e284 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:65bd1b7aba444dad6e52c4189b668a5b3ac388f2c92d8dbacde6f79552581f90
-size 22917444
+oid sha256:1d7c2c35f74162db556b2ffc41430330758f2663ff74789a9df08228ed384de7
+size 23075473
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.fbx
index 6ba2d37e2..16f03d476 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Broom.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:d68ebc089dc66df34e3258a490420e26257a78ea22c4938eb77460e390c2560c
-size 53888796
+oid sha256:0ad3ae0879799efcc14fb85e27aadb253deb42262d583646d59e96e0e4971891
+size 56931356
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.bin
index 1e4b15edd..4cfeee79b 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:99855947403e10ea088248ca45a3dab3933b22678cc20ca09d1352c6a4bd0df4
-size 68983780
+oid sha256:d11392338e9b08f59daf4a89c6314c909324db9b8cd12eed44b9d54f0f38024a
+size 69331867
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.fbx
index a918a2c86..a6552e63f 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Cmbt.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:efe0d8710e5d25ebe687b5d0d5f341757da9ec7e2fc2b3202c6316bbeee1b367
-size 172856076
+oid sha256:3852584ae91ce78b9c3299e91ea1639afa69ce3fddb78fa301aec277ecdfd796
+size 182598812
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.bin
index e076bc073..04d63a307 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:ce6c582a267476b868bdb2d2ab121ee8fc66de14c193d61816b9fd7e026f6fc0
-size 10730733
+oid sha256:5530b986c6bd101b5e3eda8eb5631594b07a071886f7708b69494730193fd8de
+size 10807972
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.fbx
index b7d866ccc..f087a226a 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Lightning.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:00bf25ba5abdcce10d0ab1afd50f62b5667300a499850c133499e8563e4b3d91
-size 6247020
+oid sha256:8a95ec0fd1c0b1991083fd21c0fb2a87d6126400acde22ef97a6df438b1c5d3c
+size 6401564
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.bin
index a5f036d71..d005baddb 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:0596ec615a1f3ab2dc03e0875e7b6a2840c8df3e75326893afaf220b73eb1d00
-size 11478642
+oid sha256:cf4c2fc354b8fe220a85cf2a4766aca198966d2afe06b99ea15b60520b3d600d
+size 11563567
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.fbx
index 7c1a1471b..17ee917fe 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Protego.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:e14fce3cf9cdcdc0fab741dc5417ce453057cf19594d4ad56fc5461ba825164b
-size 10536764
+oid sha256:9344cd73993ca5a9979005e4a2d6602afd495ce1a665b6693807ffc8288891bb
+size 10960124
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.bin
index 1b3fa3e3a..d3c6afa9c 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:0c69e1ec83a75f80f797e8a2970c912ed8c54b7c7e484afe7d6bbcb97c44010c
-size 60341885
+oid sha256:fed83d790ce5ec13ed5cf7acd245ac38b3a86658e52c72d7c8d3424d86d500f7
+size 60651350
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.fbx
index eff18e350..e8fc6d273 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Rct.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:e7bf8861475ec0eff44cdf88ae9795e5b13b7dc6c341e057e80feceb3ea384e1
-size 149327452
+oid sha256:c15071ebf86e8c4688d6f252de7b50487cb1454bc5e7ca5231334ac0d5546d64
+size 157682572
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.bin
index 400887a4c..3f55b79df 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:cef8d8458de71ab0bd5cd4344879ab5402d36074bab926262cd496a7939f9304
-size 19356151
+oid sha256:1d369879ae3846d1bb1779818b025a714b9412cb4a7faaa238c6b862f7bdd0ec
+size 19489076
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.fbx
index 211971f2d..8e0194c1e 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Sneak.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:c041565fa7b147ce6fdfb89cd3d34e410f5bb971e2f569b91ebdd2972bfea380
-size 38994124
+oid sha256:068105d25b85bbd235d0be09005cfa7d4a2938571965019ad3459dcaa3133360
+size 41111868
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.bin
index a96583e9c..8173f74c8 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:13f56a745a91c3c7054387613b0aed0fe7299e157b8570ba3ae9b0844923b3a0
-size 15410052
+oid sha256:97a3468fa1372811a36391ffece957b786dcf633ec84b6bb1ded222e89bca6d9
+size 15496127
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.fbx
index 316f5b897..4f53e5320 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spawn.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:1b4a14778bc770f934c888c6dae7377228f1032d584ca318795577557d6a0e66
-size 12808700
+oid sha256:7c57f4192cd1cc660c7975d3d0c2e73680f55257a48c3d6ef6965e3290b19c0e
+size 13271484
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.bin
index d2949a371..f3654b2ae 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.bin
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.bin
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:ab8b4150a5940dccab76789aa47f07401e0e0ae4f93d0fc3447faa421d5e563f
-size 12127590
+oid sha256:e6cdba1d2a122702abe7704d60fe38a1fed7d33020713ad0478ca5374681651d
+size 12209325
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.fbx
index be2dc4bac..a2146657d 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.fbx
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Human/PlayableCharacter/Playable_Spell_Learning.fbx
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:27f8e609b42eb9ad7c32c8d59d67d538f64eac901bc1852b15893ffcf9e37ad9
-size 9075324
+oid sha256:dfdb7b6f61c64274ea30443d94497b20db204a7c9e82154980154b16af194e6d
+size 9383916
diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.xml b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.xml
index b82a6a608..52cde6bca 100644
--- a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.xml
+++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/ConjuredDragon/ConjuredDragon.xml
@@ -1,5 +1,5 @@
-
+
@@ -28,7 +28,7 @@
-
+
@@ -57,7 +57,7 @@
-
+
@@ -86,7 +86,7 @@
-
+
@@ -115,7 +115,7 @@
-
+
@@ -144,7 +144,7 @@
-
+
@@ -173,7 +173,7 @@
-
+