commit
This commit is contained in:
@@ -157,6 +157,7 @@
|
||||
</PreBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\Public\Protego.h" />
|
||||
<ClInclude Include="..\Public\Bombard.h" />
|
||||
<ClInclude Include="..\Public\Broom.h" />
|
||||
<ClInclude Include="..\public\BuildingContainer.h" />
|
||||
@@ -223,6 +224,7 @@
|
||||
<ClInclude Include="targetver.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\Private\Protego.cpp" />
|
||||
<ClCompile Include="..\Private\Bombard.cpp" />
|
||||
<ClCompile Include="..\Private\Broom.cpp" />
|
||||
<ClCompile Include="..\private\BuildingContainer.cpp" />
|
||||
|
||||
@@ -193,6 +193,9 @@
|
||||
<ClInclude Include="..\public\InstancedProp.h">
|
||||
<Filter>02.GameObjects\Environment\02.InstancedProp</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\Protego.h">
|
||||
<Filter>02.GameObjects\Effect\Effects\Protego</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Image Include="Client.ico">
|
||||
@@ -451,10 +454,13 @@
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Effect\EffectPool">
|
||||
<UniqueIdentifier>{bdd4863e-8ab9-4ce8-a88d-9a0c558a67fb}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Environment\02.InstancedProp">
|
||||
<UniqueIdentifier>{4ef15d06-4520-4d55-ab49-1ae7179f145b}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Effect\Effects\Protego">
|
||||
<UniqueIdentifier>{37b6e4b9-42fb-4fda-9112-e62ab434bee0}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Client.cpp">
|
||||
@@ -637,6 +643,9 @@
|
||||
<ClCompile Include="..\private\InstancedProp.cpp">
|
||||
<Filter>02.GameObjects\Environment\02.InstancedProp</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\Protego.cpp">
|
||||
<Filter>02.GameObjects\Effect\Effects\Protego</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="Client.rc">
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "Bombard.h"
|
||||
#include "NomalJap.h"
|
||||
#include "Decendo.h"
|
||||
|
||||
#include "Protego.h"
|
||||
|
||||
CEffectPool::CEffectPool(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CGameObject(pDevice, pContext)
|
||||
@@ -130,7 +130,7 @@ HRESULT CEffectPool::Ready_Effect()
|
||||
return pEffect;}
|
||||
))) return E_FAIL;
|
||||
|
||||
if (FAILED(Create_Effect(SKILL_TYPE::DECENDO, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel)-> CEffect_Container* {
|
||||
if (FAILED(Create_Effect(SKILL_TYPE::DESCENDO, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel)-> CEffect_Container* {
|
||||
|
||||
CDecendo* pEffect = nullptr;
|
||||
|
||||
@@ -139,6 +139,16 @@ HRESULT CEffectPool::Ready_Effect()
|
||||
return pEffect;}
|
||||
))) return E_FAIL;
|
||||
|
||||
if (FAILED(Create_Effect(SKILL_TYPE::PROTEGO, 5, NEXT_LEVEL, NEXT_LEVEL, [&](_uint iPrototypeLevel, _uint iCloneLevel)-> CEffect_Container* {
|
||||
|
||||
CProtego* pEffect = nullptr;
|
||||
|
||||
pEffect = m_pGameInstance->Clone_Prototype<CProtego>(iPrototypeLevel, nullptr);
|
||||
|
||||
return pEffect; }
|
||||
))) return E_FAIL;
|
||||
|
||||
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include "Bombard.h"
|
||||
#include "Decendo.h"
|
||||
#include "NomalJap.h"
|
||||
#include "Protego.h"
|
||||
|
||||
#include "TrailObject.h"
|
||||
#include "Instance_Model.h"
|
||||
@@ -378,6 +379,10 @@ HRESULT CLoader::Loading_For_GamePlay()
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CProtego>(NEXT_LEVEL, CProtego::Create(m_pDevice, m_pContext)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
if (FAILED(m_pGameInstance->Add_Prototype<CEffectPool>(g_iStaticLevel, CEffectPool::Create(m_pDevice, m_pContext)))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
@@ -598,12 +598,18 @@ void CPlayer::Behavior_CombatEnter()
|
||||
else if (m_pGameInstance->Key_Down(DIK_Q)) {
|
||||
m_pFSM->Enable_State(FSMSTATE::SKILL2);
|
||||
pairAnimInfo = m_Animation[STATEANIM::SKILL2];
|
||||
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::PROTEGO, this);
|
||||
}
|
||||
else if (m_pGameInstance->Mouse_Up(DIM_LBUTTON)) {
|
||||
m_pFSM->Enable_State(FSMSTATE::LIGHT_ATTACK);
|
||||
pairAnimInfo = m_Animation[STATEANIM::LIGHT_ATTACK];
|
||||
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::JAP, this);
|
||||
m_pModelCom->Anim_Event(0.1f, m_Animation[STATEANIM::LIGHT_ATTACK].first, [this]() {
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::JAP, this);
|
||||
|
||||
return E_FAIL;
|
||||
});
|
||||
}
|
||||
else if (SUCCEEDED(InputSpell())) {
|
||||
m_pFSM->Enable_State(FSMSTATE::SPELL);
|
||||
@@ -712,23 +718,37 @@ HRESULT CPlayer::Behavior_CombatExitCheck()
|
||||
case STATEANIM::ACCIO:
|
||||
{
|
||||
pairAnimInfo = m_Animation[STATEANIM::ACCIO];
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::BOMBARD, this);
|
||||
|
||||
|
||||
}
|
||||
break;
|
||||
case STATEANIM::DESCENDO:
|
||||
pairAnimInfo = m_Animation[STATEANIM::DESCENDO];
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::DECENDO, this);
|
||||
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second);
|
||||
|
||||
|
||||
|
||||
m_pModelCom->Anim_Event(0.1f, m_Animation[STATEANIM::ACCIO].first, [this]() {
|
||||
Spawn_Effect<CBombard>();
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::BOMBARD, this);
|
||||
|
||||
m_eSpell = STATEANIM::END;
|
||||
return E_FAIL;
|
||||
});
|
||||
|
||||
m_pModelCom->Anim_Event(0.1f, m_Animation[STATEANIM::DESCENDO].first, [this]() {
|
||||
m_pEffectPool->Use_Skill(SKILL_TYPE::DESCENDO, this);
|
||||
|
||||
m_eSpell = STATEANIM::END;
|
||||
return E_FAIL;
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,178 @@
|
||||
#include "pch.h"
|
||||
#include "Protego.h"
|
||||
|
||||
#include "GameInstance.h"
|
||||
#include "EffectParts.h"
|
||||
#include "PhysXEffectHitBox.h"
|
||||
|
||||
|
||||
CProtego::CProtego(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
: CEffect_Container{ pDevice, pContext }
|
||||
{
|
||||
}
|
||||
|
||||
CProtego::CProtego(const CProtego& rhs)
|
||||
: CEffect_Container(rhs)
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CProtego::Initialize_Prototype()
|
||||
{
|
||||
|
||||
return S_OK;
|
||||
|
||||
}
|
||||
|
||||
HRESULT CProtego::Initialize(void* pArg)
|
||||
{
|
||||
if (FAILED(__super::Initialize(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
if (FAILED(Ready_Components(pArg)))
|
||||
return E_FAIL;
|
||||
|
||||
|
||||
if (FAILED(Load_Package("../Bin/Resources/Data/Effect/Package/Protego")))
|
||||
return E_FAIL;
|
||||
|
||||
m_pSphere = Get_PartObject<CEffectParts>("ProtegoSphere");
|
||||
m_pBottom = Get_PartObject<CEffectParts>("ProtegoBottom");
|
||||
m_pCircle = Get_PartObject<CEffectParts>("ProtegoCircle");
|
||||
|
||||
SAFE_ADDREF(m_pSphere);
|
||||
SAFE_ADDREF(m_pBottom);
|
||||
SAFE_ADDREF(m_pCircle);
|
||||
|
||||
m_wstrEffectName = L"Protego";
|
||||
|
||||
|
||||
m_fDuration = 2.5f;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void CProtego::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
__super::Priority_Update(fTimeDelta);
|
||||
|
||||
}
|
||||
|
||||
void CProtego::Update(_float fTimeDelta)
|
||||
{
|
||||
if (m_bVisible == false)
|
||||
return;
|
||||
|
||||
m_pSphere->Get_Component<CTransform>()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
|
||||
m_pBottom->Get_Component<CTransform>()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
|
||||
m_pCircle-> Get_Component<CTransform>()->Set_State(STATE::POSITION, m_pOwner->Get_WorldPostion());
|
||||
|
||||
__super::Update(fTimeDelta);
|
||||
|
||||
Update_Event(fTimeDelta);
|
||||
}
|
||||
|
||||
void CProtego::Late_Update(_float fTimeDelta)
|
||||
{
|
||||
if (m_bVisible == false)
|
||||
return;
|
||||
|
||||
__super::Late_Update(fTimeDelta);
|
||||
|
||||
|
||||
}
|
||||
|
||||
HRESULT CProtego::Pre_Setting(CGameObject* pObject)
|
||||
{
|
||||
if (pObject == nullptr)
|
||||
return E_FAIL;
|
||||
|
||||
m_pOwner = pObject;
|
||||
|
||||
Reset_EffectParts();
|
||||
|
||||
m_fAccTime = 0.f;
|
||||
__super::m_fAccTime = 0.f;
|
||||
m_fPreAccTime = 0.f;
|
||||
|
||||
m_pSphere->Set_Visible(true);
|
||||
m_pCircle->Set_Visible(true);
|
||||
m_pBottom->Set_Visible(true);
|
||||
|
||||
m_bVisible = true;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CProtego::Ready_Components(void* pArg)
|
||||
{
|
||||
if (FAILED(__super::Ready_Components(pArg))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT CProtego::Ready_Child()
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
CProtego* CProtego::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
{
|
||||
CProtego* pInstance = new CProtego(pDevice, pContext);
|
||||
|
||||
if (FAILED(pInstance->Initialize_Prototype()))
|
||||
{
|
||||
MSG_BOX("Failed to Created : CProtego");
|
||||
SAFE_RELEASE(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
|
||||
CGameObject* CProtego::Clone(void* pArg, CGameObject* pOwner)
|
||||
{
|
||||
CProtego* pInstance = new CProtego(*this);
|
||||
pInstance->m_pOwner = pOwner;
|
||||
if (FAILED(pInstance->Initialize(pArg)))
|
||||
{
|
||||
MSG_BOX("Failed to Cloned : CProtego");
|
||||
SAFE_RELEASE(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
void CProtego::OnCollision(CGameObject* pOther, void* pDesc)
|
||||
{
|
||||
//CTransform* pOtherTransform = p
|
||||
ON_COLLISION_INFO* CollisionDesc = static_cast<ON_COLLISION_INFO*>(pDesc);
|
||||
|
||||
}
|
||||
|
||||
void CProtego::Free()
|
||||
{
|
||||
__super::Free();
|
||||
|
||||
//if(m_pPhysHitBox != nullptr)
|
||||
// if (m_pPhysHitBox->Get_Depth() == false)
|
||||
// SAFE_RELEASE(m_pPhysHitBox);
|
||||
|
||||
SAFE_RELEASE(m_pSphere);
|
||||
SAFE_RELEASE(m_pBottom);
|
||||
SAFE_RELEASE(m_pCircle);
|
||||
|
||||
}
|
||||
|
||||
void CProtego::Describe_Entity()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
HRESULT CProtego::Bind_ShaderResources()
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -17,5 +17,5 @@ namespace Client
|
||||
enum class SHADER_PASS_UIEDITOR { DEFAULT, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, END };
|
||||
|
||||
enum class EFFECT_TYPE { EFFECT, TRAIL, END };
|
||||
enum class SKILL_TYPE { JAP, BOMBARD, DECENDO, PROTEGO, END };
|
||||
enum class SKILL_TYPE { JAP, BOMBARD, DESCENDO, PROTEGO, END };
|
||||
}
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
#pragma once
|
||||
|
||||
#include "Client_Define.h"
|
||||
#include "Effect_Container.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
NS_END
|
||||
|
||||
NS_BEGIN(Client)
|
||||
|
||||
class CProtego final : public CEffect_Container
|
||||
{
|
||||
private:
|
||||
CProtego(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
CProtego(const CProtego& rhs);
|
||||
virtual ~CProtego() = default;
|
||||
|
||||
public:
|
||||
virtual void Priority_Update(_float fTimeDelta) override;
|
||||
virtual void Update(_float fTimeDelta) override;
|
||||
virtual void Late_Update(_float fTimeDelta) override;
|
||||
|
||||
public:
|
||||
virtual HRESULT Pre_Setting(CGameObject* pObject) override;
|
||||
|
||||
private:
|
||||
virtual HRESULT Initialize_Prototype() override;
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
virtual HRESULT Ready_Components(void* pArg) override;
|
||||
HRESULT Ready_Child();
|
||||
HRESULT Bind_ShaderResources() override;
|
||||
virtual void OnCollision(CGameObject* pOther = nullptr, void* pDesc = nullptr) override;
|
||||
private:
|
||||
_wstring m_wstrEffectName = {};
|
||||
|
||||
CPartObject* m_pSphere = { nullptr };
|
||||
CPartObject* m_pBottom = { nullptr };
|
||||
CPartObject* m_pCircle = { nullptr };
|
||||
public:
|
||||
static CProtego* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
virtual void Free() override;
|
||||
CGameObject* Clone(void* pArg, CGameObject* pOwner) override;
|
||||
#ifdef _DEBUG
|
||||
void Describe_Entity() override;
|
||||
#endif // _DEBUG
|
||||
};
|
||||
|
||||
NS_END
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user