diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj b/Jusin154_Team3D/Client/Default/Client.vcxproj
index 352d08506..938f7212f 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj
@@ -242,6 +242,7 @@ call Update_Resources.bat
+
@@ -365,6 +366,7 @@ call Update_Resources.bat
+
diff --git a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
index b673d2dcc..6a7c02799 100644
--- a/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
+++ b/Jusin154_Team3D/Client/Default/Client.vcxproj.filters
@@ -356,6 +356,9 @@
02.GameObjects\Item\Troll_Rock
+
+ 02.GameObjects\UI\Spell_Canvas\Spell_Panel\Spell_Drag
+
@@ -1116,6 +1119,9 @@
02.GameObjects\Item\Troll_Rock
+
+ 02.GameObjects\UI\Spell_Canvas\Spell_Panel\Spell_Drag
+
diff --git a/Jusin154_Team3D/Client/Private/Action_Panel.cpp b/Jusin154_Team3D/Client/Private/Action_Panel.cpp
index ccc5aea7d..adc0bf6e4 100644
--- a/Jusin154_Team3D/Client/Private/Action_Panel.cpp
+++ b/Jusin154_Team3D/Client/Private/Action_Panel.cpp
@@ -54,7 +54,8 @@ HRESULT CAction_Panel::Initialize(void* pArg)
Magic_Meter_UV();
Magic_Meter_Visible(1, true);
Magic_Meter_Visible(5, true);
- m_bActive = true;
+ Visible(true);
+ ElementAllVisible(true);
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Current_Slot_Number.cpp b/Jusin154_Team3D/Client/Private/Current_Slot_Number.cpp
index e084a8135..64db13a77 100644
--- a/Jusin154_Team3D/Client/Private/Current_Slot_Number.cpp
+++ b/Jusin154_Team3D/Client/Private/Current_Slot_Number.cpp
@@ -47,7 +47,6 @@ HRESULT CCurrent_Slot_Number::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(-805.f, 380.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_pVIBufferCom->Set_ImageUV(pUVDesc);
- m_bActive = true;
return S_OK;
}
@@ -113,7 +112,7 @@ HRESULT CCurrent_Slot_Number::Render()
{
return E_FAIL;
}
- if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ALPHABLEND))))
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIINTANCE::UVALPHABLEND))))
{
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/Current_Spell_Slot.cpp b/Jusin154_Team3D/Client/Private/Current_Spell_Slot.cpp
index ed1b5f8a7..d351bebdd 100644
--- a/Jusin154_Team3D/Client/Private/Current_Spell_Slot.cpp
+++ b/Jusin154_Team3D/Client/Private/Current_Spell_Slot.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "Current_Spell_Slot.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
CCurrent_Spell_Slot::CCurrent_Spell_Slot(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
@@ -8,7 +9,8 @@ CCurrent_Spell_Slot::CCurrent_Spell_Slot(ID3D11Device* pDevice, ID3D11DeviceCont
}
CCurrent_Spell_Slot::CCurrent_Spell_Slot(const CCurrent_Spell_Slot& rhs)
- :CElementObject(rhs)
+ :CElementObject(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
@@ -47,7 +49,11 @@ HRESULT CCurrent_Spell_Slot::Initialize(void* pArg)
m_pVIBufferCom->Set_Cloned(true);
m_pVIBufferCom->Set_Pos(-780.f, 340.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
- m_bActive = true;
+ m_bChangeSlot = false;
+ m_iSpellType = -1;
+ m_iSkill_Index = -1;
+ Clear(-1);
+ static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
return S_OK;
}
@@ -91,6 +97,43 @@ void CCurrent_Spell_Slot::Update(_float fTimeDelta)
}
}
m_fTime += fTimeDelta * m_fTimeMult;
+ Hover();
+
+
+ if (m_bHover == true)
+ {
+ if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_bClick == false)
+ {
+ m_bClick = true;
+ m_iSkill_Index = Chack_Slot(m_iSlot_Index);
+ static_cast(m_pOwner)->Function_Callback(TEXT("Current_Hover"), &m_iSkill_Index);
+ }
+ }
+
+ if (m_pGameInstance->Mouse_Up(DIM_LBUTTON))
+ {
+ if (m_bHover == true)
+ {
+ if (m_iSpellType != -1)
+ {
+ Get_Skill(m_iSpellType, m_iSlot_Index);
+ }
+
+ if (m_iSkill_Index != -1)
+ {
+ Get_Skill(m_iSkill_Index, m_iSlot_Index);
+ m_iSkill_Index = -1;
+ }
+ m_bHover = false;
+ m_bClick = false;
+ m_iSkill_Index = -1;
+ }
+ else
+ {
+ m_iSkill_Index = -1;
+ static_cast(m_pOwner)->Function_Callback(TEXT("Current_Hover"), &m_iSkill_Index);
+ }
+ }
__super::Update(fTimeDelta);
}
@@ -113,7 +156,7 @@ HRESULT CCurrent_Spell_Slot::Render()
{
return E_FAIL;
}
- if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIINTANCE::DEFAULT))))
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIINTANCE::SPELL_SLOT))))
{
return E_FAIL;
}
@@ -153,6 +196,109 @@ void CCurrent_Spell_Slot::SizeUpdate(_float fSizeX, _float fSizeY)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
}
+void CCurrent_Spell_Slot::Hover()
+{
+ POINT ptMouse{};
+ GetCursorPos(&ptMouse);
+ ScreenToClient(g_hWnd, &ptMouse);
+ _float2 fMouse;
+ fMouse.x = ptMouse.x - (g_iWinSizeX * 0.5f);
+ fMouse.y = -(ptMouse.y - (g_iWinSizeY * 0.5f));
+
+ // 엘리먼트의 월드 위치를 더해주면 엘리먼트 좌표계 기준이 됨
+ fMouse.x -= m_pOwner->Get_WorldPostion().m128_f32[0];
+ fMouse.y -= m_pOwner->Get_WorldPostion().m128_f32[1];
+
+ m_iSlot_Index = m_pVIBufferCom->Set_Mouse_Hover(fMouse);
+ if (m_iSlot_Index != -1)
+ {
+ m_bHover = true;
+ }
+ else
+ {
+ m_bHover = false;
+ m_bClick = false;
+ }
+}
+
+void CCurrent_Spell_Slot::Click_Slot(_bool bClick)
+{
+ if (bClick == true)
+ {
+ m_bClick = true;
+ }
+ else
+ {
+ m_bClick = false;
+ }
+}
+
+void CCurrent_Spell_Slot::Get_Skill(_int SpellIndex, _int SlotIndex)
+{
+ if (SlotIndex == -1)
+ return;
+
+ if (SpellIndex == -1)
+ return;
+
+ _int iSlotx = 4;
+
+ _int x = SlotIndex % iSlotx;
+ _int y = SlotIndex / iSlotx;
+
+ m_iSpell[y][x] = SpellIndex;
+ m_pVIBufferCom->Set_Equip_Index(SlotIndex);
+ m_vUV.fUV = UV(SpellIndex);
+ m_pVIBufferCom->Set_Index_Color(SlotIndex, static_cast<_float>(m_pInfoInstance->Get_Spell_Info(SpellIndex).iSpell_Type));
+ m_pVIBufferCom->Set_Index_ImageUV(SlotIndex, m_vUV);
+}
+
+_int CCurrent_Spell_Slot::Chack_Slot(_int Index) const
+{
+ _int iSlotx = 4;
+
+ _int x = Index % iSlotx;
+ _int y = Index / iSlotx;
+
+ return m_iSpell[y][x];
+}
+
+void CCurrent_Spell_Slot::Clear(_int iValue)
+{
+ for (_int i = 0; i < 4; ++i)
+ {
+ for (_int j = 0; j < 4; ++j)
+ {
+ m_iSpell[i][j] = iValue;
+ }
+ }
+}
+
+_float4 CCurrent_Spell_Slot::UV(_int SpellID)
+{
+ _float2 fImage_Size = { 1024.f, 1792.f };
+
+ _uint iCountX = 4;
+ _uint iCountY = 7;
+
+ _float iImageX = 256.f;
+ _float iImageY = 256.f;
+
+ _uint iframeX = SpellID % iCountX;
+ _uint iframeY = SpellID / iCountX;
+
+ _float2 UVStart;
+ UVStart.x = iframeX * iImageX / fImage_Size.x;
+ UVStart.y = iframeY * iImageY / fImage_Size.y;
+
+ _float2 UVEnd;
+ UVEnd.x = UVStart.x + (iImageX / fImage_Size.x);
+ UVEnd.y = UVStart.y + (iImageY / fImage_Size.y);
+
+ _float4 UV = _float4{ UVStart.x, UVStart.y, UVEnd.x, UVEnd.y };
+ return UV;
+}
+
HRESULT CCurrent_Spell_Slot::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
@@ -171,6 +317,14 @@ HRESULT CCurrent_Spell_Slot::Bind_ShaderResources()
{
return E_FAIL;
}
+ if (FAILED(m_pDiffuse_TextureCom1->Bind_ShaderResource(m_pShaderCom, "g_Texture1", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom2->Bind_ShaderResource(m_pShaderCom, "g_Texture2", 0)))
+ {
+ return E_FAIL;
+ }
if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float))))
{
return E_FAIL;
@@ -201,7 +355,15 @@ HRESULT CCurrent_Spell_Slot::Ready_Components(void* pArg)
{
return E_FAIL;
}
- if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_ActionItemGoldleaf_4K"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_SpellType_Generic"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_Atlas_Spell"), reinterpret_cast(&m_pDiffuse_TextureCom1), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_ActionItemGoldleaf_4K"), reinterpret_cast(&m_pDiffuse_TextureCom2), nullptr)))
{
return E_FAIL;
}
@@ -244,6 +406,8 @@ void CCurrent_Spell_Slot::Free()
__super::Free();
SAFE_RELEASE(m_pDiffuse_TextureCom);
+ SAFE_RELEASE(m_pDiffuse_TextureCom1);
+ SAFE_RELEASE(m_pDiffuse_TextureCom2);
SAFE_RELEASE(m_pShaderCom);
SAFE_RELEASE(m_pVIBufferCom);
}
diff --git a/Jusin154_Team3D/Client/Private/Eessential_Spell.cpp b/Jusin154_Team3D/Client/Private/Eessential_Spell.cpp
index c07574d2f..97b5f2e73 100644
--- a/Jusin154_Team3D/Client/Private/Eessential_Spell.cpp
+++ b/Jusin154_Team3D/Client/Private/Eessential_Spell.cpp
@@ -49,7 +49,6 @@ HRESULT CEessential_Spell::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(-731.f, -300.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_pVIBufferCom->Set_ImageUV(pUVDesc);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Eessential_Spell_Slot.cpp b/Jusin154_Team3D/Client/Private/Eessential_Spell_Slot.cpp
index 97ed2abec..05e63d6d7 100644
--- a/Jusin154_Team3D/Client/Private/Eessential_Spell_Slot.cpp
+++ b/Jusin154_Team3D/Client/Private/Eessential_Spell_Slot.cpp
@@ -48,7 +48,6 @@ HRESULT CEessential_Spell_Slot::Initialize(void* pArg)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_fDelayTime = 0.5f;
m_iPerSpell_Slot = -1;
- m_bActive = true;
return S_OK;
}
@@ -92,7 +91,7 @@ void CEessential_Spell_Slot::Update(_float fTimeDelta)
}
}
- Hover(fTimeDelta);
+ Hover();
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
@@ -157,7 +156,7 @@ void CEessential_Spell_Slot::SizeUpdate(_float fSizeX, _float fSizeY)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
}
-void CEessential_Spell_Slot::Hover(_float fTimeDelta)
+void CEessential_Spell_Slot::Hover()
{
POINT ptMouse{};
GetCursorPos(&ptMouse);
@@ -186,7 +185,7 @@ void CEessential_Spell_Slot::Hover(_float fTimeDelta)
Info.iHover_Index = m_iSpellType + ENUM_CLASS(SKILL_TYPE::JAP);
static_cast(m_pOwner)->Function_Callback(TEXT("Hover"), &Info);
- }
+ }
}
diff --git a/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp b/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
index 2ba2436c6..26378f14d 100644
--- a/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
+++ b/Jusin154_Team3D/Client/Private/GamePlay_Canvas.cpp
@@ -44,8 +44,7 @@ HRESULT CGamePlay_Canvas::Initialize(void* pArg)
{
return E_FAIL;
}
- m_bVisible = true;
- m_bActive = true;
+ Visible(true);
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/HpBarBG.cpp b/Jusin154_Team3D/Client/Private/HpBarBG.cpp
index b0ba7def3..81c4232a8 100644
--- a/Jusin154_Team3D/Client/Private/HpBarBG.cpp
+++ b/Jusin154_Team3D/Client/Private/HpBarBG.cpp
@@ -48,7 +48,6 @@ HRESULT CHpBarBG::Initialize(void* pArg)
m_fHpBGPos = _float2(0.f, 13.f);
m_fHpBG = _float2(0, m_fSizeX);
SizeUpX(240.f);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
index ae55df7fb..5d136ae4a 100644
--- a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
+++ b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp
@@ -161,29 +161,29 @@ HRESULT CLevel_GamePlay::Ready_Background()
/* Map Containters */
/* 테스트용 맵 */
- //CInfoInstance::GetInstance()->Load_MapObjects("ClientTest");
- ///* 전체 맵 */
- //CInfoInstance::GetInstance()->Load_MapObjects("Map1129");
+ CInfoInstance::GetInstance()->Load_MapObjects("ClientTest");
+ /* 전체 맵 */
+ CInfoInstance::GetInstance()->Load_MapObjects("Map1129");
- ///* 조명 오브젝트 */
- //CInfoInstance::GetInstance()->Load_LightElements("LightElement");
+ /* 조명 오브젝트 */
+ CInfoInstance::GetInstance()->Load_LightElements("LightElement");
- //
- //CInstancedProp::INSTANCE_PROP_DESC Desc = {};
+
+ CInstancedProp::INSTANCE_PROP_DESC Desc = {};
- ///* InstanceProp Oak_Tree*/
- //Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_OakTree_MedA";
- //Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/OakTree_MedA.bin";
- //if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc))){
- // return E_FAIL;
- //}
+ /* InstanceProp Oak_Tree*/
+ Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_OakTree_MedA";
+ Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/OakTree_MedA.bin";
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc))){
+ return E_FAIL;
+ }
- ///* BearBerry */
- //Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_BearBerry_A";
- //Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/BearBerry_A.bin";
- //if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc))){
- // return E_FAIL;
- //}
+ /* BearBerry */
+ Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_BearBerry_A";
+ Desc.strInstanceDataPath = "../Bin/Resources/Data/Map/Instance/BearBerry_A.bin";
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_BACKGROUND, &Desc))){
+ return E_FAIL;
+ }
/* SM_HM_OwlPost_Window_A */
Desc.strPrototypeTag = L"Prototype_Component_VIBuffer_Model_Instancel_SM_HM_OwlPost_Window_A";
diff --git a/Jusin154_Team3D/Client/Private/Loader.cpp b/Jusin154_Team3D/Client/Private/Loader.cpp
index 51344ee0d..3c3660708 100644
--- a/Jusin154_Team3D/Client/Private/Loader.cpp
+++ b/Jusin154_Team3D/Client/Private/Loader.cpp
@@ -30,10 +30,20 @@
#pragma region UI
#include "Skill_Data.h"
-
#include "UI_Manager.h"
#include "GamePlay_Canvas.h"
+
+#include "Mission_Panel.h"
+//#include "MissionBanner_Border.h"
+//#include "MissionBanner_Key.h"
+//#include "Mission_Icon.h"
+//#include "Mouse_Cursor.h"
+#include "MiniMap_TrimBorder.h"
+
+#include "MiniMap_Panel.h"
+#include "NoMountIcon.h"
+
#include "Loading_Panel.h"
#include "LoadingWidget.h"
#include "LoadingWidget_Flame.h"
@@ -49,12 +59,6 @@
#include "Spell_UI.h"
#include "Magic_Item.h"
-#include "MiniMap_Panel.h"
-#include "MiniMap_TrimBorder.h"
-#include "NoMountIcon.h"
-
-#include "Mission_Panel.h"
-
#include "Spell_Canvas.h"
#include "Spell_Panel.h"
#include "Current_Spell_Slot.h"
@@ -71,6 +75,8 @@
#include "Spell_Vidio_Border.h"
#include "Spell_Anim.h"
#include "Current_Slot_Number.h"
+#include "Spell_Drag.h"
+
#pragma endregion
@@ -240,48 +246,48 @@ HRESULT CLoader::Loading_For_GamePlay()
));
}
- //{ /* Ollivanders*/
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Ollivanders/Meshes",
- // ".bin", false
- // ));
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Ollivanders/Collision",
- // ".bin", false
- // ));
- //}
+ { /* Ollivanders*/
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Ollivanders/Meshes",
+ ".bin", false
+ ));
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Ollivanders/Collision",
+ ".bin", false
+ ));
+ }
- //{ /* Gatehouse*/
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Gatehouse/Meshes",
- // ".bin", false
- // ));
- //}
+ { /* Gatehouse*/
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Gatehouse/Meshes",
+ ".bin", false
+ ));
+ }
- //{ /* TScrolls */
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_TScrolls/Meshes",
- // ".bin", false
- // ));
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_TScrolls/Collisions",
- // ".bin", false
- // ));
- //}
- //{ /* 3BroomStick*/
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Meshes",
- // ".bin", false
- // ));
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Collision",
- // ".bin", false
- // ));
- // jobMapModels.emplace_back(Deferred_FolderLoad(
- // "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Meshes/3Broom_Kit",
- // ".bin", false
- // ));
- //}
+ { /* TScrolls */
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_TScrolls/Meshes",
+ ".bin", false
+ ));
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_TScrolls/Collisions",
+ ".bin", false
+ ));
+ }
+ { /* 3BroomStick*/
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Meshes",
+ ".bin", false
+ ));
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Collision",
+ ".bin", false
+ ));
+ jobMapModels.emplace_back(Deferred_FolderLoad(
+ "../Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_ThreeBroomsticks/Meshes/3Broom_Kit",
+ ".bin", false
+ ));
+ }
{ /* BLDG_QuidditchShop */
@@ -1808,6 +1814,10 @@ HRESULT CLoader::Loading_For_GamePlay()
{
return E_FAIL;
}
+ if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CSpell_Drag::Create(m_pDevice, m_pContext))))
+ {
+ return E_FAIL;
+ }
/* For.Prototype_GameObject_SkyBox */
if (FAILED(m_pGameInstance->Add_Prototype(g_iStaticLevel, CSkyBox::Create(m_pDevice, m_pContext))))
diff --git a/Jusin154_Team3D/Client/Private/LoadingWidget.cpp b/Jusin154_Team3D/Client/Private/LoadingWidget.cpp
index 7f16a0561..3fdd94bb7 100644
--- a/Jusin154_Team3D/Client/Private/LoadingWidget.cpp
+++ b/Jusin154_Team3D/Client/Private/LoadingWidget.cpp
@@ -47,7 +47,7 @@ HRESULT CLoadingWidget::Initialize(void* pArg)
m_iImageFrameX = 6; // 이미지의 x 갯수
m_iImageFrameY = 6; // 이미지의 y 갯수
- //m_bActive = true;
+ m_bActive = false;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/LoadingWidget_Flame.cpp b/Jusin154_Team3D/Client/Private/LoadingWidget_Flame.cpp
index 93623a688..f45001382 100644
--- a/Jusin154_Team3D/Client/Private/LoadingWidget_Flame.cpp
+++ b/Jusin154_Team3D/Client/Private/LoadingWidget_Flame.cpp
@@ -49,7 +49,6 @@ HRESULT CLoadingWidget_Flame::Initialize(void* pArg)
m_iImageFrameX = 3; // 이미지의 x 갯수
m_iImageFrameY = 3; // 이미지의 y 갯수
- m_bActive = true;
// 이 친구는 FadeIn을 해주면 알아서 한번 깜빡이고 들어감
// 조절을 할꺼면 나중에 제대로 확인을 한 다음에 할 예정
Set_FadeIn();
diff --git a/Jusin154_Team3D/Client/Private/Loading_Panel.cpp b/Jusin154_Team3D/Client/Private/Loading_Panel.cpp
index a39128f96..b4c71ab91 100644
--- a/Jusin154_Team3D/Client/Private/Loading_Panel.cpp
+++ b/Jusin154_Team3D/Client/Private/Loading_Panel.cpp
@@ -41,7 +41,6 @@ HRESULT CLoading_Panel::Initialize(void* pArg)
{
return E_FAIL;
}
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Magic_Icon.cpp b/Jusin154_Team3D/Client/Private/Magic_Icon.cpp
index b06a7c3d6..6c17c2683 100644
--- a/Jusin154_Team3D/Client/Private/Magic_Icon.cpp
+++ b/Jusin154_Team3D/Client/Private/Magic_Icon.cpp
@@ -40,7 +40,6 @@ HRESULT CMagic_Icon::Initialize(void* pArg)
m_fTimeMult = 3.f;
m_fAlpha = 1.f;
m_fAlphaTime = 3.f;
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Magic_Item.cpp b/Jusin154_Team3D/Client/Private/Magic_Item.cpp
index 8102488dd..4b081f9ae 100644
--- a/Jusin154_Team3D/Client/Private/Magic_Item.cpp
+++ b/Jusin154_Team3D/Client/Private/Magic_Item.cpp
@@ -47,7 +47,6 @@ HRESULT CMagic_Item::Initialize(void* pArg)
m_iArratCount = 2;
Compute_UV(0);
Compute_Image();
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Magic_Meter.cpp b/Jusin154_Team3D/Client/Private/Magic_Meter.cpp
index 5ee0715f5..f706a140e 100644
--- a/Jusin154_Team3D/Client/Private/Magic_Meter.cpp
+++ b/Jusin154_Team3D/Client/Private/Magic_Meter.cpp
@@ -43,8 +43,6 @@ HRESULT CMagic_Meter::Initialize(void* pArg)
m_fAlphaTime = 1.f;
m_fMaxGauge = 20.f;
m_fCurrentGauge = 10.f;
- Visible(false);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/MiniMap_Panel.cpp b/Jusin154_Team3D/Client/Private/MiniMap_Panel.cpp
index 82ac9609d..f47084c13 100644
--- a/Jusin154_Team3D/Client/Private/MiniMap_Panel.cpp
+++ b/Jusin154_Team3D/Client/Private/MiniMap_Panel.cpp
@@ -40,8 +40,8 @@ HRESULT CMiniMap_Panel::Initialize(void* pArg)
{
return E_FAIL;
}
-
- m_bActive = true;
+ Visible(true);
+ ElementAllVisible(true);
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp b/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
index a02ef979b..1216c67d9 100644
--- a/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
+++ b/Jusin154_Team3D/Client/Private/MiniMap_TrimBorder.cpp
@@ -40,8 +40,6 @@ HRESULT CMiniMap_TrimBorder::Initialize(void* pArg)
m_fTimeMult = 3.f;
m_fAlpha = 1.f;
m_fAlphaTime = 3.f;
-
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/NoMountIcon.cpp b/Jusin154_Team3D/Client/Private/NoMountIcon.cpp
index ccb7ce9fd..9c015b9f8 100644
--- a/Jusin154_Team3D/Client/Private/NoMountIcon.cpp
+++ b/Jusin154_Team3D/Client/Private/NoMountIcon.cpp
@@ -40,8 +40,6 @@ HRESULT CNoMountIcon::Initialize(void* pArg)
m_fTimeMult = 3.f;
m_fAlpha = 0.7f;
m_fAlphaTime = 3.f;
-
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Slot_Number.cpp b/Jusin154_Team3D/Client/Private/Slot_Number.cpp
index 0e7a0d043..1cfe3c454 100644
--- a/Jusin154_Team3D/Client/Private/Slot_Number.cpp
+++ b/Jusin154_Team3D/Client/Private/Slot_Number.cpp
@@ -47,7 +47,6 @@ HRESULT CSlot_Number::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(350.f, 10.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_pVIBufferCom->Set_ImageUV(pUVDesc);
- m_bActive = true;
return S_OK;
}
@@ -102,7 +101,7 @@ void CSlot_Number::Late_Update(_float fTimeDelta)
}
if (m_bVisible)
{
- m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
}
__super::Late_Update(fTimeDelta);
}
@@ -113,7 +112,7 @@ HRESULT CSlot_Number::Render()
{
return E_FAIL;
}
- if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::ALPHABLEND))))
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIINTANCE::UVALPHABLEND))))
{
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Anim.cpp b/Jusin154_Team3D/Client/Private/Spell_Anim.cpp
index ae831bcc0..5ce3998bf 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Anim.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Anim.cpp
@@ -51,7 +51,6 @@ HRESULT CSpell_Anim::Initialize(void* pArg)
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
- m_bActive = true;
return S_OK;
}
@@ -183,6 +182,8 @@ void CSpell_Anim::Set_SkillType(_int eType)
m_iCurrentFrame = 0;
Change_Image(eType);
}
+ else if (eType == -1)
+ m_iPerSpell = eType;
}
HRESULT CSpell_Anim::Bind_ShaderResources()
@@ -228,7 +229,7 @@ HRESULT CSpell_Anim::Ready_Components(void* pArg)
{
return E_FAIL;
}
- if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Arresto_Momentum"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Accio"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
{
return E_FAIL;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Canvas.cpp b/Jusin154_Team3D/Client/Private/Spell_Canvas.cpp
index c44c70c76..756b5f9af 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Canvas.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Canvas.cpp
@@ -39,6 +39,7 @@ HRESULT CSpell_Canvas::Initialize(void* pArg)
{
return E_FAIL;
}
+ Visible(false);
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Drag.cpp b/Jusin154_Team3D/Client/Private/Spell_Drag.cpp
new file mode 100644
index 000000000..a010e7c99
--- /dev/null
+++ b/Jusin154_Team3D/Client/Private/Spell_Drag.cpp
@@ -0,0 +1,413 @@
+#include "pch.h"
+#include "Spell_Drag.h"
+#include "GameInstance.h"
+#include "InfoInstance.h"
+
+CSpell_Drag::CSpell_Drag(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+ :CElementObject(pDevice, pContext)
+{
+}
+
+CSpell_Drag::CSpell_Drag(const CSpell_Drag& rhs)
+ :CElementObject(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
+
+{
+}
+
+HRESULT CSpell_Drag::Initialize_Prototype()
+{
+ return S_OK;
+}
+
+HRESULT CSpell_Drag::Initialize(void* pArg)
+{
+ CUIObject::UIOBJECT_DESC Desc{};
+
+ Desc.fX = 0.f;
+ Desc.fY = 0.f;
+ Desc.fSizeX = 105.f;
+ Desc.fSizeY = 105.f;
+
+ m_pRect = { long(Desc.fX - Desc.fSizeX * 0.5f), long(Desc.fY - Desc.fSizeY * 0.5f), long(Desc.fX + Desc.fSizeX * 0.5f), long(Desc.fY + Desc.fSizeY * 0.5f) };
+
+ if (FAILED(__super::Initialize(&Desc)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Ready_Components(pArg)))
+ {
+ return E_FAIL;
+ }
+
+ m_fTimeMult = 3.f;
+ m_fAlpha = 1.f;
+ m_fAlphaTime = 1.f;
+ m_fDelayTime = 0.2f;
+ m_fSortZ = 0.f;
+ m_iSkillType = ENUM_CLASS(SKILL_TYPE::ARRESTO_MOMENTUM);
+ Compute_UI(m_iSkillType);
+ m_bMove = false;
+ m_bClick = false;
+ m_iSpellType = -1;
+ m_iCurrent_Slot_Index = -1;
+ static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SpellType(*reinterpret_cast<_int*>(p)); });
+ static_cast(m_pOwner)->Add_Function(TEXT("Current_Hover"), [this](void* p) {this->Set_Current_Slot(*reinterpret_cast<_int*>(p)); });
+ return S_OK;
+}
+
+void CSpell_Drag::Priority_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ __super::Priority_Update(fTimeDelta);
+}
+
+void CSpell_Drag::Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+
+ if (m_bFadeIn == true)
+ {
+ if (m_fAlpha <= 1.f)
+ m_fAlpha += fTimeDelta * m_fAlphaTime;
+
+ if (m_fAlpha >= 1.f)
+ {
+ m_bFadeIn = false;
+ m_fAlpha = 1.f;
+ }
+ }
+
+ if (m_bFadeOut == true)
+ {
+ if (m_fAlpha >= 0.f)
+ m_fAlpha -= fTimeDelta;
+
+ if (m_fAlpha <= 0.f)
+ {
+ m_bFadeOut = false;
+ m_fAlpha = 0.f;
+ }
+ }
+ m_fTime += fTimeDelta * m_fTimeMult;
+
+ if (m_pGameInstance->Mouse_Down(DIM_LBUTTON))
+ {
+ if (m_iSpellType == -1 && m_iCurrent_Slot_Index == -1)
+ {
+ m_bFalse = true;
+ return;
+ }
+
+ m_vStart_MousePos = XMVectorSet(0.f, 0.f, 0.f, 0.f);
+
+ POINT m_pPt{};
+ GetCursorPos(&m_pPt);
+ ScreenToClient(g_hWnd, &m_pPt);
+ _float2 fMouse{};
+ fMouse.x = m_pPt.x - (g_iWinSizeX * 0.5f);
+ fMouse.y = m_pPt.y - (g_iWinSizeY * 0.5f);
+
+ m_vStart_MousePos = XMVectorSet(fMouse.x, fMouse.y, 0.f, 1.f);
+ m_bFalse = false;
+ }
+
+ if (m_bFalse == false && (m_bHover == true || m_bCurrent_Hover == true))
+ {
+ if (m_pGameInstance->Mouse_Pressing(DIM_LBUTTON))
+ {
+ POINT pt{};
+ GetCursorPos(&pt);
+ ScreenToClient(g_hWnd, &pt);
+
+ float moveX = pt.x - (g_iWinSizeX * 0.5f);
+ float moveY = pt.y - (g_iWinSizeY * 0.5f);
+
+ m_vMove_MousePos = XMVectorSet(moveX, moveY, 0.f, 1.f);
+
+ _vector Dir = m_vMove_MousePos - m_vStart_MousePos;
+ _float fLength2 = XMVectorGetX(XMVector2Dot(Dir, Dir));
+
+ if (fLength2 >= 50.f)
+ {
+ m_bMove = true;
+ }
+ m_bClick = true;
+
+ }
+ }
+ else
+ {
+ m_iSpellType = -1;
+ }
+
+ if (m_bMove == true)
+ {
+ MoveX(Get_MousePos().x);
+ MoveY(Get_MousePos().y);
+ }
+
+
+ if (m_pGameInstance->Mouse_Up(DIM_LBUTTON) && m_bClick == true)
+ {
+ m_bHover = false;
+ m_bClick = false;
+ m_bCurrent_Hover = false;
+ m_bMove = false;
+ m_iSpellType = -1;
+ }
+
+ static_cast(m_pOwner)->Function_Callback(TEXT("Click"), &m_bClick);
+
+ __super::Update(fTimeDelta);
+
+}
+
+void CSpell_Drag::Late_Update(_float fTimeDelta)
+{
+ if (!__super::Chack_Visible())
+ {
+ return;
+ }
+ if (m_bVisible) {
+ if (m_bMove == true)
+ {
+ m_pGameInstance->Add_RenderGroup(RENDER::UI, this);
+ }
+ }
+ __super::Late_Update(fTimeDelta);
+}
+
+HRESULT CSpell_Drag::Render()
+{
+ if (FAILED(Bind_ShaderResources()))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Begin(ENUM_CLASS(SHADER_PASS_UIEDITOR::SPELL_DRAG))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Bind_Resources()))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pVIBufferCom->Render()))
+ {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+_vector CSpell_Drag::Get_WorldPostion()
+{
+ return m_pTransformCom->Get_State(STATE::POSITION);
+}
+
+HRESULT CSpell_Drag::Bind_ShaderResources()
+{
+ if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ViewMatrix", &m_ViewMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_Matrix("g_ProjMatrix", &m_ProjMatrix)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom->Bind_ShaderResource(m_pShaderCom, "g_Texture", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom1->Bind_ShaderResource(m_pShaderCom, "g_Texture1", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom2->Bind_ShaderResource(m_pShaderCom, "g_Texture2", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pDiffuse_TextureCom3->Bind_ShaderResource(m_pShaderCom, "g_Texture3", 0)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fFar", m_pGameInstance->Get_CurrentCameraFar(), sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fTime", &m_fTime, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAngle", &m_fAngle, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fAlpha", &m_fAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fOwnerAlpha", &m_fOwnerAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCanvasAlpha", &m_fCanvasAlpha, sizeof(_float))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fImageUV", &m_vUV, sizeof(_float4))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pShaderCom->Bind_RawValue("g_fCurrent_Size", &m_vScale, sizeof(_float2))))
+ {
+ return E_FAIL;
+ }
+ return S_OK;
+}
+
+HRESULT CSpell_Drag::Ready_Components(void* pArg)
+{
+ if (FAILED(Add_Component(g_iStaticLevel, &m_pVIBufferCom)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_SpellType_Generic"), reinterpret_cast(&m_pDiffuse_TextureCom), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_SelectedPresetBorder"), reinterpret_cast(&m_pDiffuse_TextureCom1), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_UI_T_GoldLeaf"), reinterpret_cast(&m_pDiffuse_TextureCom2), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("Prototype_Texture_Atlas_Widget_Spell"), reinterpret_cast(&m_pDiffuse_TextureCom3), nullptr)))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(Add_Asset_Component(g_iStaticLevel, FX_UIEDITOR, (CComponent**)&m_pShaderCom, nullptr)))
+ {
+ return E_FAIL;
+ }
+
+ return S_OK;
+}
+
+void CSpell_Drag::Compute_UI(_uint SpellID)
+{
+ _float2 fImage_Size = { 1024.f, 1792.f };
+
+ _uint iCountX = 4;
+ _uint iCountY = 7;
+
+ _float iImageX = 256.f;
+ _float iImageY = 256.f;
+
+ _uint iframeX = SpellID % iCountX;
+ _uint iframeY = SpellID / iCountX;
+
+ _float2 UVStart;
+ UVStart.x = iframeX * iImageX / fImage_Size.x;
+ UVStart.y = iframeY * iImageY / fImage_Size.y;
+
+ _float2 UVEnd;
+ UVEnd.x = UVStart.x + (iImageX / fImage_Size.x);
+ UVEnd.y = UVStart.y + (iImageY / fImage_Size.y);
+
+ _float4 UV = _float4{ UVStart.x, UVStart.y, UVEnd.x, UVEnd.y };
+ m_vUV = UV;
+}
+
+void CSpell_Drag::Set_SpellType(_int SpellID)
+{
+ if (SpellID == -1 || SpellID >= 26)
+ {
+ m_iSkillType = -1;
+ m_bHover = false;
+ return;
+ }
+ m_iSpellType = SpellID;
+ m_bHover = true;
+ Compute_UI(m_pInfoInstance->Get_Spell_Info(m_iSpellType).iSkill_Type);
+}
+
+_float2 CSpell_Drag::Get_MousePos()
+{
+ POINT m_pPt{};
+ GetCursorPos(&m_pPt);
+ ScreenToClient(g_hWnd, &m_pPt);
+ _float2 fMouse{};
+ fMouse.x = m_pPt.x - (g_iWinSizeX * 0.5f);
+ fMouse.y = m_pPt.y - (g_iWinSizeY * 0.5f);
+
+ m_vMove_MousePos = XMVectorSet(fMouse.x, fMouse.y, 0.f, 1.f);
+ return fMouse;
+}
+
+void CSpell_Drag::Set_Current_Slot(_uint Index)
+{
+ if (Index == -1)
+ {
+ m_iCurrent_Slot_Index = -1;
+ m_bCurrent_Hover = false;
+ return;
+ }
+ m_iCurrent_Slot_Index = Index;
+ m_bCurrent_Hover = true;
+ Compute_UI(m_pInfoInstance->Get_Spell_Info(m_iCurrent_Slot_Index).iSkill_Type);
+}
+
+CSpell_Drag* CSpell_Drag::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
+{
+ CSpell_Drag* pInstance = new CSpell_Drag(pDevice, pContext);
+
+ if (FAILED(pInstance->Initialize_Prototype()))
+ {
+ MSG_BOX("Failed to Created : CSpell_Drag");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+CGameObject* CSpell_Drag::Clone(void* pArg, CGameObject* pOwner)
+{
+ CSpell_Drag* pInstance = new CSpell_Drag(*this);
+ pInstance->m_pOwner = pOwner;
+ if (FAILED(pInstance->Initialize(pArg)))
+ {
+ MSG_BOX("Failed to Cloned : CSpell_Drag");
+ SAFE_RELEASE(pInstance);
+ }
+
+ return pInstance;
+}
+
+void CSpell_Drag::Free()
+{
+ __super::Free();
+
+ SAFE_RELEASE(m_pDiffuse_TextureCom);
+ SAFE_RELEASE(m_pDiffuse_TextureCom1);
+ SAFE_RELEASE(m_pDiffuse_TextureCom2);
+ SAFE_RELEASE(m_pDiffuse_TextureCom3);
+ SAFE_RELEASE(m_pShaderCom);
+ SAFE_RELEASE(m_pVIBufferCom);
+}
+
+void CSpell_Drag::Describe_Entity()
+{
+}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Header.cpp b/Jusin154_Team3D/Client/Private/Spell_Header.cpp
index 5625e7645..a7f4526f9 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Header.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Header.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "Spell_Header.h"
#include "GameInstance.h"
+#include "InfoInstance.h"
CSpell_Header::CSpell_Header(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
@@ -8,7 +9,8 @@ CSpell_Header::CSpell_Header(ID3D11Device* pDevice, ID3D11DeviceContext* pContex
}
CSpell_Header::CSpell_Header(const CSpell_Header& rhs)
- :CElementObject(rhs)
+ :CElementObject(rhs),
+ m_pInfoInstance(CInfoInstance::GetInstance())
{
}
@@ -46,7 +48,6 @@ HRESULT CSpell_Header::Initialize(void* pArg)
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
- m_bActive = true;
return S_OK;
}
@@ -93,7 +94,7 @@ void CSpell_Header::Update(_float fTimeDelta)
if (m_iSpellType != -1)
{
- m_iSkillType = static_cast(m_pOwner)->Get_Info(m_iSpellType).iSpell_Type;
+ m_iSkillType = m_pInfoInstance->Get_Spell_Info(m_iSpellType).iSpell_Type;
}
m_fTime += fTimeDelta * m_fTimeMult;
diff --git a/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp b/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
index fc5d96073..1bd1c8aa5 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Header_Line.cpp
@@ -41,7 +41,6 @@ HRESULT CSpell_Header_Line::Initialize(void* pArg)
m_fAlphaTime = 5.f;
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Hover.cpp b/Jusin154_Team3D/Client/Private/Spell_Hover.cpp
index 3e018dd98..7c18a81e2 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Hover.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Hover.cpp
@@ -47,7 +47,6 @@ HRESULT CSpell_Hover::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(-185.f, 375.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
- m_bActive = true;
return S_OK;
}
@@ -91,7 +90,10 @@ void CSpell_Hover::Update(_float fTimeDelta)
}
}
- m_pVIBufferCom->Set_Hover_Index(m_iSpellType);
+ if (m_bClick == false)
+ {
+ m_pVIBufferCom->Set_Hover_Index(m_iSpellType);
+ }
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
@@ -156,6 +158,18 @@ void CSpell_Hover::SizeUpdate(_float fSizeX, _float fSizeY)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
}
+void CSpell_Hover::Click_Slot(_bool bClick)
+{
+ if (bClick == true)
+ {
+ m_bClick = true;
+ }
+ else
+ {
+ m_bClick = false;
+ }
+}
+
HRESULT CSpell_Hover::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
diff --git a/Jusin154_Team3D/Client/Private/Spell_Hover_Effect.cpp b/Jusin154_Team3D/Client/Private/Spell_Hover_Effect.cpp
index ab130ff64..0f99b618a 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Hover_Effect.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Hover_Effect.cpp
@@ -48,7 +48,6 @@ HRESULT CSpell_Hover_Effect::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(-185.f, 375.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
- m_bActive = true;
return S_OK;
}
@@ -91,7 +90,10 @@ void CSpell_Hover_Effect::Update(_float fTimeDelta)
m_fAlpha = 0.f;
}
}
- m_pVIBufferCom->Set_Hover_Index(m_iSpellType);
+ if (m_bClick == false)
+ {
+ m_pVIBufferCom->Set_Hover_Index(m_iSpellType);
+ }
m_fTime += fTimeDelta * m_fTimeMult;
__super::Update(fTimeDelta);
}
@@ -155,6 +157,18 @@ void CSpell_Hover_Effect::SizeUpdate(_float fSizeX, _float fSizeY)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
}
+void CSpell_Hover_Effect::Click_Slot(_bool bClick)
+{
+ if (bClick == true)
+ {
+ m_bClick = true;
+ }
+ else
+ {
+ m_bClick = false;
+ }
+}
+
HRESULT CSpell_Hover_Effect::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
diff --git a/Jusin154_Team3D/Client/Private/Spell_List.cpp b/Jusin154_Team3D/Client/Private/Spell_List.cpp
index 671305474..24eaf5441 100644
--- a/Jusin154_Team3D/Client/Private/Spell_List.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_List.cpp
@@ -48,9 +48,11 @@ HRESULT CSpell_List::Initialize(void* pArg)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_fDelayTime = 0.5f;
m_iPerSpell_Slot = -1;
+ m_bClick = false;
Color();
- m_bActive = true;
+ static_cast(m_pOwner)->Add_Function(TEXT("Click"), [this](void* p) {this->Click_Slot(*reinterpret_cast<_bool*>(p)); });
return S_OK;
+
}
void CSpell_List::Priority_Update(_float fTimeDelta)
@@ -93,7 +95,10 @@ void CSpell_List::Update(_float fTimeDelta)
}
}
m_fTime += fTimeDelta * m_fTimeMult;
- Hover(fTimeDelta);
+ if (m_bClick == false)
+ {
+ Hover();
+ }
__super::Update(fTimeDelta);
}
@@ -168,7 +173,7 @@ void CSpell_List::Color()
m_pVIBufferCom->Set_Index_Renge_Color(23, 25, 3.f);
}
-void CSpell_List::Hover(_float fTimeDelta)
+void CSpell_List::Hover()
{
POINT ptMouse{};
GetCursorPos(&ptMouse);
@@ -199,6 +204,18 @@ void CSpell_List::Hover(_float fTimeDelta)
}
+void CSpell_List::Click_Slot(_bool bClick)
+{
+ if (bClick == true)
+ {
+ m_bClick = true;
+ }
+ else
+ {
+ m_bClick = false;
+ }
+}
+
HRESULT CSpell_List::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
diff --git a/Jusin154_Team3D/Client/Private/Spell_List_Image.cpp b/Jusin154_Team3D/Client/Private/Spell_List_Image.cpp
index 26d8fa5a0..2d03173e0 100644
--- a/Jusin154_Team3D/Client/Private/Spell_List_Image.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_List_Image.cpp
@@ -48,7 +48,6 @@ HRESULT CSpell_List_Image::Initialize(void* pArg)
m_pVIBufferCom->Set_Pos(-185.f, 375.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
m_pVIBufferCom->Set_ImageUV(pUVDesc);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp b/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp
index ba8bd55c1..d92d40a23 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp
@@ -50,7 +50,6 @@ HRESULT CSpell_Overlay::Initialize(void* pArg)
m_fSortZ = 0.01f;
m_iSpellType = ENUM_CLASS(SPELLTYPE::CONTROL);
Compute_UI(5);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Panel.cpp b/Jusin154_Team3D/Client/Private/Spell_Panel.cpp
index 242fe64c9..c631ef00b 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Panel.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Panel.cpp
@@ -15,6 +15,7 @@
#include "Spell_Header.h"
#include "Spell_Header_Line.h"
#include "Spell_Anim.h"
+#include "Spell_Drag.h"
#include "InfoInstance.h"
CSpell_Panel::CSpell_Panel(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
@@ -60,9 +61,11 @@ HRESULT CSpell_Panel::Initialize(void* pArg)
m_iPendingSpell = -1;
m_fDelayTime = 1.f;
m_bActive = true;
-
Add_Function(TEXT("Hover"), [this](void* p) {this->Slot_Chack(p); });
-
+ Add_Function(TEXT("Click"), [this](void* p) {this->Click_Slot(*reinterpret_cast<_bool*>(p)); });
+ Add_Function(TEXT("Current_Slot_Click"), [this](void* p) {this->Current_Slot_Chack(*reinterpret_cast<_int*>(p)); });
+ Visible(true);
+ ElementAllVisible(true);
return S_OK;
}
@@ -84,7 +87,7 @@ void CSpell_Panel::Update(_float fTimeDelta)
if (m_iSpellType != -1)
{
- m_fHoverTimer += fTimeDelta;
+ m_fHoverTimer += fTimeDelta;
}
else
{
@@ -92,9 +95,9 @@ void CSpell_Panel::Update(_float fTimeDelta)
Function_Callback(TEXT("FadeOut"));
}
- if (m_fHoverTimer >= m_fDelayTime && m_iPendingSpell != m_iSpellType)
+ if (m_fHoverTimer >= m_fDelayTime)
{
- m_iPendingSpell = m_iSpellType;
+
Function_Callback(TEXT("FadeIn"));
}
@@ -163,6 +166,23 @@ void CSpell_Panel::Slot_Chack(void* pArg)
Function_Callback(TEXT("Slot_Hover"), &m_iSpellType);
}
+void CSpell_Panel::Click_Slot(_bool bClick)
+{
+ if (bClick == true)
+ {
+ m_bHover = true;
+ }
+ else
+ {
+ m_bHover = false;
+ }
+}
+
+void CSpell_Panel::Current_Slot_Chack(_int Index)
+{
+ m_iCurrent_Slot_Index = Index;
+}
+
HRESULT CSpell_Panel::Bind_ShaderResources()
{
if (FAILED(m_pTransformCom->Bind_ShaderResource(m_pShaderCom, "g_WorldMatrix")))
@@ -304,6 +324,12 @@ HRESULT CSpell_Panel::Ready_Element(void* pArg)
}
Add_Element(TEXT("Spell_Anim"), m_pSpell_Anim);
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, nullptr, this, reinterpret_cast(&m_pSpell_Drag))))
+ {
+ return E_FAIL;
+ }
+ Add_Element(TEXT("Spell_Drag"), m_pSpell_Drag);
+
//if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_UI, m_Info, nullptr, reinterpret_cast(&m_pSpell_Data))))
//{
// return E_FAIL;
diff --git a/Jusin154_Team3D/Client/Private/Spell_Preview.cpp b/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
index 4ab5944e2..662d64f78 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Preview.cpp
@@ -49,7 +49,6 @@ HRESULT CSpell_Preview::Initialize(void* pArg)
m_fSortZ = 0.02f;
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Slot.cpp b/Jusin154_Team3D/Client/Private/Spell_Slot.cpp
index 154832ff0..f020de280 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Slot.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Slot.cpp
@@ -47,7 +47,6 @@ HRESULT CSpell_Slot::Initialize(void* pArg)
m_pVIBufferCom->Set_Cloned(true);
m_pVIBufferCom->Set_Pos(380.f, -30.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_State.cpp b/Jusin154_Team3D/Client/Private/Spell_State.cpp
index 60391a3ed..bcfce9906 100644
--- a/Jusin154_Team3D/Client/Private/Spell_State.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_State.cpp
@@ -46,8 +46,7 @@ HRESULT CSpell_State::Initialize(void* pArg)
m_pVIBufferCom->Set_Cloned(true);
m_pVIBufferCom->Set_Pos(-185.f, 375.f, m_fOffSetX, m_fOffSetY, m_iCols);
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
- m_bActive = true;
-
+ static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
return S_OK;
}
@@ -90,8 +89,13 @@ void CSpell_State::Update(_float fTimeDelta)
m_fAlpha = 0.f;
}
}
+
m_fTime += fTimeDelta * m_fTimeMult;
- Hover();
+ if (m_bClick == false)
+ {
+ m_pVIBufferCom->Set_Hover_Index(m_iSpellType);
+ }
+
__super::Update(fTimeDelta);
}
@@ -154,21 +158,16 @@ void CSpell_State::SizeUpdate(_float fSizeX, _float fSizeY)
m_pVIBufferCom->Set_Size(m_fSizeX, m_fSizeY);
}
-void CSpell_State::Hover()
+void CSpell_State::Click_Slot(_bool bClick)
{
- POINT ptMouse{};
- GetCursorPos(&ptMouse);
- ScreenToClient(g_hWnd, &ptMouse);
- _float2 fMouse;
- fMouse.x = ptMouse.x - (g_iWinSizeX * 0.5f);
- fMouse.y = -(ptMouse.y - (g_iWinSizeY * 0.5f));
-
- // 엘리먼트의 월드 위치를 더해주면 엘리먼트 좌표계 기준이 됨
- fMouse.x -= m_pOwner->Get_WorldPostion().m128_f32[0];
- fMouse.y -= m_pOwner->Get_WorldPostion().m128_f32[1];
-
- m_pVIBufferCom->Set_Mouse_Hover(fMouse);
-
+ if (bClick == true)
+ {
+ m_bClick = true;
+ }
+ else
+ {
+ m_bClick = false;
+ }
}
HRESULT CSpell_State::Bind_ShaderResources()
diff --git a/Jusin154_Team3D/Client/Private/Spell_UI.cpp b/Jusin154_Team3D/Client/Private/Spell_UI.cpp
index 43c6c45ce..fecb52a8c 100644
--- a/Jusin154_Team3D/Client/Private/Spell_UI.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_UI.cpp
@@ -45,7 +45,6 @@ HRESULT CSpell_UI::Initialize(void* pArg)
//m_vImageUV[2] = Image_UV(1);
//m_vImageUV[3] = Alphabet_UV('T');
Set_ImagePos();
- m_bActive = true;
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp b/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
index 0f2cd9760..be702f1fb 100644
--- a/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
+++ b/Jusin154_Team3D/Client/Private/Spell_Vidio_Border.cpp
@@ -1,7 +1,6 @@
#include "pch.h"
#include "Spell_Vidio_Border.h"
#include "GameInstance.h"
-#include "Spell_Anim.h"
CSpell_Vidio_Border::CSpell_Vidio_Border(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
@@ -48,8 +47,6 @@ HRESULT CSpell_Vidio_Border::Initialize(void* pArg)
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeIn"), [this](void* p) {this->Set_FadeIn(); });
static_cast(m_pOwner)->Add_Function(TEXT("FadeOut"), [this](void* p) {this->Set_FadeOut(); });
- m_bActive = true;
-
return S_OK;
}
diff --git a/Jusin154_Team3D/Client/Public/Client_Enum.h b/Jusin154_Team3D/Client/Public/Client_Enum.h
index e44d69abe..3d75f6690 100644
--- a/Jusin154_Team3D/Client/Public/Client_Enum.h
+++ b/Jusin154_Team3D/Client/Public/Client_Enum.h
@@ -12,22 +12,25 @@ namespace Client
enum class SHADER_PASS_PARTICLE { EXPLOSION, END };
enum class SHADER_PASS_POSTEX { DEFAULT, SCISSOR, UI, UVMOVE, TRAIL, TRAIL_BLEND, TRAILWB_FOR_BLEND, TRAIL_BLUR, TRAIL_BLOOM, END };
enum class SHADER_PASS_INSTANCE_MODEL { DEFAULT, NON_NOMALMAP, BLUR, WEIGHTBLEND, NON_WORLD, NON_WORLD_BLUR, BLEND, BLEND_NOWORLD, BLOOM, BLOOM_NOWORLD, BLUR_NO_EMMISVE, BLUR_NO_WORLD_NO_EMISSIVE, WEIGHTBLEND_FOR_BLEND, END };
- enum class SHADER_PASS_UIEDITOR { DEFAULT, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, END };
- enum class SHADER_PASS_UIINTANCE { DEFAULT, ALPHABLEND, MAGIC_METER, SPELL_LIST, EESSENTIAL_SPELL_SOLT, EESSENTIAL_SPELL, COLOR, SPELL_HOVER, SPELL_SLOT_EFFECT, END };
+ enum class SHADER_PASS_UIEDITOR { DEFAULT, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, SPELL_DRAG, END };
+ enum class SHADER_PASS_UIINTANCE { DEFAULT, ALPHABLEND, UVALPHABLEND, MAGIC_METER, SPELL_LIST, EESSENTIAL_SPELL_SOLT, EESSENTIAL_SPELL, COLOR, SPELL_HOVER, SPELL_SLOT_EFFECT, SPELL_SLOT, END };
enum class EFFECT_TYPE { EFFECT, TRAIL, END };
- enum class SKILL_TYPE {
- ARESTO_MOMENTUM, GLACIUS, LEVIOSO, TRANSFORM, ASSIO,
- DEPULSO, DESCENDO, FLIPENDO, CONFRINGO, DIFFINDO, EXPELLIARMUS,
- BOMBARDA, INCENDIO, DISILLUSIONMENT, LUMOS, REPARO, WINGARDIUM_LEVIOSA,
- CONJURING_SPELL, ALTERING_SPELL, EVANESCO, AVADA_KEDAVRA, CRUCIO, IMPERIO,
- BEAST_PETTING_BRUSH, BEAST_FEED, NAB_SACK, JAP, REVELIO, PROTEGO, STUPEFY,
+ enum class SKILL_TYPE {
+ ARRESTO_MOMENTUM, GLACIUS, LEVIOSO, TRANSFORM, // 노란색
+ ACCIO, DEPULSO, DESCENDO, FLIPENDO, // 보라색
+ CONFRINGO, DIFFINDO, EXPELLIARMUS, BOMBARDA, INCENDIO, // 빨간색
+ DISILLUSIONMENT, LUMOS, REPARO, WINGARDIUM_LEVIOSA, // 하늘색
+ CONJURING_SPELL, ALTERING_SPELL, EVANESCO, // 연녹색
+ AVADA_KEDAVRA, CRUCIO, IMPERIO, // 진녹색
+ BEAST_PETTING_BRUSH, BEAST_FEED, NAB_SACK, // 하늘색
+ JAP, REVELIO, PROTEGO, STUPEFY, // 검은색
ANCIENT_MAGIC_THROW, ANCIENT_MAGIC, ALOHOMORA, PETRIFICUS_TOTALUS,
- JAP_SIDE, BOMBARDA_SIDE , DESCENDO_SIDE , LEVIOSO_SIDE
- ,END
+ JAP_SIDE, BOMBARDA_SIDE, DESCENDO_SIDE, LEVIOSO_SIDE, END
};
+
enum class BLOOM_TYPE { NONE, BASIC, MULTIPLY, END };
enum class KEYINPUT
diff --git a/Jusin154_Team3D/Client/Public/Current_Spell_Slot.h b/Jusin154_Team3D/Client/Public/Current_Spell_Slot.h
index 91305afe5..ed2184fd1 100644
--- a/Jusin154_Team3D/Client/Public/Current_Spell_Slot.h
+++ b/Jusin154_Team3D/Client/Public/Current_Spell_Slot.h
@@ -29,6 +29,14 @@ class CCurrent_Spell_Slot final : public CElementObject
virtual void SizeUpY(_float fSizeY) override;
virtual void SizeUpdate(_float fSizeX, _float fSizeY) override;
+private:
+ void Hover();
+ void Click_Slot(_bool bClick);
+ void Get_Skill(_int SpellIndex, _int SlotIndex);
+ _int Chack_Slot(_int Index) const;
+ void Clear(_int iValue);
+
+ _float4 UV(_int SpellID);
private:
virtual HRESULT Bind_ShaderResources() override;
@@ -37,13 +45,26 @@ class CCurrent_Spell_Slot final : public CElementObject
virtual HRESULT Initialize(void* pArg) override;
private:
+ CInfoInstance* m_pInfoInstance = { nullptr };
+
CTexture* m_pDiffuse_TextureCom = { nullptr };
+ CTexture* m_pDiffuse_TextureCom1 = { nullptr };
+ CTexture* m_pDiffuse_TextureCom2 = { nullptr };
CShader* m_pShaderCom = { nullptr };
CVIBuffer_UI_Instance* m_pVIBufferCom = { nullptr };
- _float m_fOffSetX{};
- _float m_fOffSetY{};
- _uint m_iCols{};
+ class CUI_Manager* m_pManager = { nullptr };
+
+ _float m_fOffSetX{};
+ _float m_fOffSetY{};
+ _uint m_iCols{};
+
+ _bool m_bChangeSlot = { false };
+
+ _int m_iSlot_Index{};
+ _int m_iSkill_Index{};
+ _int m_iSpell[4][4]{};
+ CVIBuffer_UI_Instance::UI_ATLAS_DESC m_vUV{};
public:
static CCurrent_Spell_Slot* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
diff --git a/Jusin154_Team3D/Client/Public/Eessential_Spell_Slot.h b/Jusin154_Team3D/Client/Public/Eessential_Spell_Slot.h
index 1cc98a0fc..c2f8e83c2 100644
--- a/Jusin154_Team3D/Client/Public/Eessential_Spell_Slot.h
+++ b/Jusin154_Team3D/Client/Public/Eessential_Spell_Slot.h
@@ -31,7 +31,7 @@ class CEessential_Spell_Slot final : public CElementObject
private:
- void Hover(_float fTimeDelta);
+ void Hover();
private:
virtual HRESULT Bind_ShaderResources() override;
diff --git a/Jusin154_Team3D/Client/Public/MiniMap_Panel.h b/Jusin154_Team3D/Client/Public/MiniMap_Panel.h
index 79381c49c..ee3cc6a2b 100644
--- a/Jusin154_Team3D/Client/Public/MiniMap_Panel.h
+++ b/Jusin154_Team3D/Client/Public/MiniMap_Panel.h
@@ -31,8 +31,6 @@ class CMiniMap_Panel final : public CPanelObject
virtual HRESULT Initialize(void* pArg) override;
private:
- CTexture* m_pDiffuse_TextureCom = { nullptr };
- CShader* m_pShaderCom = { nullptr };
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
CGameObject* m_pMiniMap_TrimBorder = { nullptr };
CGameObject* m_pNoMountIcon = { nullptr };
diff --git a/Jusin154_Team3D/Client/Public/Spell_Drag.h b/Jusin154_Team3D/Client/Public/Spell_Drag.h
new file mode 100644
index 000000000..4b0858b9c
--- /dev/null
+++ b/Jusin154_Team3D/Client/Public/Spell_Drag.h
@@ -0,0 +1,68 @@
+#pragma once
+
+#include "Client_Define.h"
+#include "ElementObject.h"
+
+NS_BEGIN(Engine)
+class CTexture;
+class CShader;
+class CVIBuffer_Rect;
+NS_END
+
+NS_BEGIN(Client)
+
+class CSpell_Drag final : public CElementObject
+{
+private:
+ CSpell_Drag(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ CSpell_Drag(const CSpell_Drag& rhs);
+ virtual ~CSpell_Drag() = default;
+
+public:
+ virtual void Priority_Update(_float fTimeDelta);
+ virtual void Update(_float fTimeDelta);
+ virtual void Late_Update(_float fTimeDelta);
+ virtual HRESULT Render() override;
+ virtual _vector Get_WorldPostion() override;
+
+
+private:
+ virtual HRESULT Bind_ShaderResources() override;
+ virtual HRESULT Ready_Components(void* pArg) override;
+ virtual HRESULT Initialize_Prototype() override;
+ virtual HRESULT Initialize(void* pArg) override;
+
+private:
+ void Compute_UI(_uint SpellID);
+ virtual void Set_SpellType(_int SpellID) override;
+ _float2 Get_MousePos();
+ void Set_Current_Slot(_uint Index);
+
+private:
+ CInfoInstance* m_pInfoInstance = { nullptr };
+
+ CTexture* m_pDiffuse_TextureCom = { nullptr };
+ CTexture* m_pDiffuse_TextureCom1 = { nullptr };
+ CTexture* m_pDiffuse_TextureCom2 = { nullptr };
+ CTexture* m_pDiffuse_TextureCom3 = { nullptr };
+ CShader* m_pShaderCom = { nullptr };
+ CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
+
+ _vector m_vStart_MousePos{};
+ _vector m_vMove_MousePos{};
+ _float4 m_vUV{};
+
+ _int m_iCurrent_Slot_Index{};
+
+ _bool m_bCurrent_Hover = { false };
+ _bool m_bMove = { false };
+ _bool m_bClick = { false };
+ _bool m_bFalse = { false };
+public:
+ static CSpell_Drag* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
+ virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
+ virtual void Free() override;
+ void Describe_Entity() override;
+};
+
+NS_END
diff --git a/Jusin154_Team3D/Client/Public/Spell_Header.h b/Jusin154_Team3D/Client/Public/Spell_Header.h
index cb7f1956d..d65b41934 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Header.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Header.h
@@ -32,6 +32,8 @@ class CSpell_Header final : public CElementObject
virtual HRESULT Initialize(void* pArg) override;
private:
+ CInfoInstance* m_pInfoInstance = { nullptr };
+
CTexture* m_pDiffuse_TextureCom = { nullptr };
CShader* m_pShaderCom = { nullptr };
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
diff --git a/Jusin154_Team3D/Client/Public/Spell_Hover.h b/Jusin154_Team3D/Client/Public/Spell_Hover.h
index bd223cb21..316b57221 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Hover.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Hover.h
@@ -30,7 +30,7 @@ class CSpell_Hover final : public CElementObject
virtual void SizeUpdate(_float fSizeX, _float fSizeY) override;
private:
- void Hover();
+ void Click_Slot(_bool bClick);
private:
virtual HRESULT Bind_ShaderResources() override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_Hover_Effect.h b/Jusin154_Team3D/Client/Public/Spell_Hover_Effect.h
index c416c180a..5911f58c6 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Hover_Effect.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Hover_Effect.h
@@ -29,6 +29,9 @@ class CSpell_Hover_Effect final : public CElementObject
virtual void SizeUpY(_float fSizeY) override;
virtual void SizeUpdate(_float fSizeX, _float fSizeY) override;
+private:
+ void Click_Slot(_bool bClick);
+
private:
virtual HRESULT Bind_ShaderResources() override;
virtual HRESULT Ready_Components(void* pArg) override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_List.h b/Jusin154_Team3D/Client/Public/Spell_List.h
index 2be2758cf..b1733544d 100644
--- a/Jusin154_Team3D/Client/Public/Spell_List.h
+++ b/Jusin154_Team3D/Client/Public/Spell_List.h
@@ -31,7 +31,8 @@ class CSpell_List final : public CElementObject
private:
void Color();
- void Hover(_float fTimeDelta);
+ void Hover();
+ void Click_Slot(_bool bClick);
private:
virtual HRESULT Bind_ShaderResources() override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_Panel.h b/Jusin154_Team3D/Client/Public/Spell_Panel.h
index daab8a2ca..f4769dd97 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Panel.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Panel.h
@@ -31,6 +31,8 @@ class CSpell_Panel final : public CPanelObject
private:
void Slot_Chack(void* pArg);
+ void Click_Slot(_bool Click);
+ void Current_Slot_Chack(_int Index);
private:
@@ -62,13 +64,19 @@ class CSpell_Panel final : public CPanelObject
CGameObject* m_pSpell_Header = { nullptr };
CGameObject* m_pSpell_Header_Line = { nullptr };
CGameObject* m_pSpell_Anim = { nullptr };
+ CGameObject* m_pSpell_Drag = { nullptr };
_int m_iHoverSlot[2] = { -1,-1 };
+ SPELLINFO m_Info[34] = {};
CUIObject::HOVER_INFO m_Hover;
- _int m_iPendingSpell = -1;
- _float m_fHoverTimer = 0.f;
+ _int m_iPendingSpell = -1;
+ _float m_fHoverTimer = 0.f;
+
+ _int m_iCurrent_Slot_Index{};
+ _bool m_bCurrentSlot_Hover = { false };
+
public:
static CSpell_Panel* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_State.h b/Jusin154_Team3D/Client/Public/Spell_State.h
index 9e958722e..c16df540f 100644
--- a/Jusin154_Team3D/Client/Public/Spell_State.h
+++ b/Jusin154_Team3D/Client/Public/Spell_State.h
@@ -30,7 +30,7 @@ class CSpell_State final : public CElementObject
virtual void SizeUpdate(_float fSizeX, _float fSizeY) override;
private:
- void Hover();
+ void Click_Slot(_bool bClick);
private:
virtual HRESULT Bind_ShaderResources() override;
diff --git a/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h b/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
index eb4c32fd6..de678b1f4 100644
--- a/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
+++ b/Jusin154_Team3D/Client/Public/Spell_Vidio_Border.h
@@ -25,12 +25,6 @@ class CSpell_Vidio_Border final : public CElementObject
virtual HRESULT Render() override;
virtual _vector Get_WorldPostion() override;
-//public:
-// virtual const SPELLINFO Get_Info(_int Index) override;
-//
-//public:
-// virtual void Set_SkillType(_int eType);
-
private:
virtual HRESULT Bind_ShaderResources() override;
virtual HRESULT Ready_Components(void* pArg) override;
diff --git a/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters b/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
index 9809eb3e0..f9e14d913 100644
--- a/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
+++ b/Jusin154_Team3D/Editor/Default/Editor.vcxproj.filters
@@ -930,7 +930,9 @@
04.InfoInstance\02.MapInfo
-
+
+ 50.UI\UI_Manager
+
@@ -1382,7 +1384,9 @@
04.InfoInstance\02.MapInfo
-
+
+ 50.UI\UI_Manager
+
diff --git a/Jusin154_Team3D/Editor/Private/Current_Spell_Slot.cpp b/Jusin154_Team3D/Editor/Private/Current_Spell_Slot.cpp
index c4f19938c..06c62b6b0 100644
--- a/Jusin154_Team3D/Editor/Private/Current_Spell_Slot.cpp
+++ b/Jusin154_Team3D/Editor/Private/Current_Spell_Slot.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "Current_Spell_Slot.h"
#include "GameInstance.h"
+#include "UI_Manager.h"
CCurrent_Spell_Slot::CCurrent_Spell_Slot(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
@@ -99,28 +100,39 @@ void CCurrent_Spell_Slot::Update(_float fTimeDelta)
Hover();
- if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_bClick == false)
+ if (m_bHover == true)
{
- m_bClick = true;
- m_iSkill_Index = Chack_Slot(m_iSlot_Index);
- static_cast(m_pOwner)->Function_Callback(TEXT("Current_Hover"), &m_iSkill_Index);
+ if (m_pGameInstance->Mouse_Down(DIM_LBUTTON) && m_bClick == false)
+ {
+ m_bClick = true;
+ m_iSkill_Index = Chack_Slot(m_iSlot_Index);
+ static_cast(m_pOwner)->Function_Callback(TEXT("Current_Hover"), &m_iSkill_Index);
+ }
}
- if (m_pGameInstance->Mouse_Up(DIM_LBUTTON) && m_bHover == true)
+ if (m_pGameInstance->Mouse_Up(DIM_LBUTTON))
{
- if (m_iSpellType != -1)
+ if (m_bHover == true)
{
- Get_Skill(m_iSpellType, m_iSlot_Index);
- }
+ if (m_iSpellType != -1)
+ {
+ Get_Skill(m_iSpellType, m_iSlot_Index);
+ }
- if (m_iSkill_Index != -1)
- {
- Get_Skill(m_iSkill_Index, m_iSlot_Index);
+ if (m_iSkill_Index != -1)
+ {
+ Get_Skill(m_iSkill_Index, m_iSlot_Index);
+ m_iSkill_Index = -1;
+ }
+ m_bHover = false;
+ m_bClick = false;
m_iSkill_Index = -1;
}
- m_bHover = false;
- m_bClick = false;
- m_iSkill_Index = -1;
+ else
+ {
+ m_iSkill_Index = -1;
+ static_cast(m_pOwner)->Function_Callback(TEXT("Current_Hover"), &m_iSkill_Index);
+ }
}
__super::Update(fTimeDelta);
@@ -240,6 +252,7 @@ void CCurrent_Spell_Slot::Get_Skill(_int SpellIndex, _int SlotIndex)
m_vUV.fUV = UV(SpellIndex);
m_pVIBufferCom->Set_Index_Color(SlotIndex, static_cast<_float>(static_cast(m_pOwner)->Get_Info(SpellIndex).iSpell_Type));
m_pVIBufferCom->Set_Index_ImageUV(SlotIndex, m_vUV);
+ m_pManager->Event_Callback(TEXT("Skill_Change"));
}
_int CCurrent_Spell_Slot::Chack_Slot(_int Index) const
@@ -360,7 +373,6 @@ HRESULT CCurrent_Spell_Slot::Ready_Components(void* pArg)
{
return E_FAIL;
}
-
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp b/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
index 12885eba3..077702144 100644
--- a/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
+++ b/Jusin154_Team3D/Editor/Private/GamePlay_Canvas.cpp
@@ -1,6 +1,7 @@
#include "pch.h"
#include "GamePlay_Canvas.h"
#include "GameInstance.h"
+#include "UI_Manager.h"
#include "Mission_Panel.h"
#include "MiniMap_Panel.h"
#include "Loading_Panel.h"
@@ -50,6 +51,7 @@ HRESULT CGamePlay_Canvas::Initialize(void* pArg)
void CGamePlay_Canvas::Priority_Update(_float fTimeDelta)
{
+
__super::Priority_Update(fTimeDelta);
}
diff --git a/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp b/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
index 4ed045698..c5ddcdc85 100644
--- a/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
+++ b/Jusin154_Team3D/Editor/Private/IMGUIUI.cpp
@@ -32,6 +32,38 @@ HRESULT CIMGUIUI::Initialize(void* pArg)
return S_OK;
}
+void CIMGUIUI::CanvaswstringTostring(vector& panelNames)
+{
+ m_iCanvasNamestring.clear();
+ m_iCanvaslName.clear();
+ m_iCanvasNamewstring.clear();
+
+ m_iCanvasNamewstring = panelNames;
+
+ for (auto& wname : panelNames)
+ {
+ // wstring -> UTF-8 string 변환
+ int size = WideCharToMultiByte(CP_UTF8, 0,
+ wname.c_str(), (int)wname.size(),
+ nullptr, 0, nullptr, nullptr);
+
+ std::string result(size, 0);
+
+ WideCharToMultiByte(CP_UTF8, 0,
+ wname.c_str(), (int)wname.size(),
+ &result[0], size, nullptr, nullptr);
+
+ // 변환된 string 저장
+ m_iCanvasNamestring.push_back(std::move(result));
+ }
+
+ // vector 업데이트
+ for (auto& str : m_iCanvasNamestring)
+ m_iCanvaslName.push_back(str.c_str());
+
+ m_iCanvasCount = 999;
+}
+
void CIMGUIUI::PanelwstringTostring(vector& panelNames)
{
m_iPanelNamestring.clear();
@@ -104,7 +136,6 @@ void CIMGUIUI::Update(_float fTimeDelta)
{
static const char* SpellTypeNames[] = { "CONTROL","POWER", "DAMAGE","UTILITY", "TRANSFORM", "CURSE", "ESSENTIAL" };
int itemCount = sizeof(SpellTypeNames) / sizeof(const char*);
- static const char* CanvasNames[] = { "GamePlay Canvas", "Spell Canvas" };
static int iCanvasIndex = 0;
if (m_pCurrent_Canvas != nullptr)
{
@@ -160,12 +191,14 @@ void CIMGUIUI::Update(_float fTimeDelta)
GUI::Begin("Current_CanvasObject_Info");
if (m_pUI_Manager != nullptr)
{
- if (GUI::Combo("Canvas", &iCanvasIndex, CanvasNames, 2))
+ auto CanvasName = static_cast(m_pUI_Manager)->Canvas_Name();
+ if (CanvasName != m_iCanvasNamewstring)
{
- //if (iCanvasIndex == 0)
- // m_pCurrent_Canvas = m_pGamePlay_Canvas;
- //else
- // m_pCurrent_Canvas = m_pSpell_Canvas;
+ CanvaswstringTostring(CanvasName);
+ }
+ if (GUI::Combo("Canvas", &m_iCanvasCount, m_iCanvaslName.data(), static_cast<_int>(m_iCanvaslName.size())))
+ {
+ m_pCurrent_Canvas = static_cast(m_pUI_Manager)->Get_Canvas(m_iCanvasNamewstring[m_iCanvasCount]);
}
}
if (m_pCurrent_Canvas != nullptr)
diff --git a/Jusin154_Team3D/Editor/Private/Loader.cpp b/Jusin154_Team3D/Editor/Private/Loader.cpp
index b869e62d6..67da6813b 100644
--- a/Jusin154_Team3D/Editor/Private/Loader.cpp
+++ b/Jusin154_Team3D/Editor/Private/Loader.cpp
@@ -526,208 +526,208 @@ HRESULT CLoader::Loading_For_UI()
return E_FAIL;
}
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Altering_Spell"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Altering_Spell\\Altering_Spell%d.png"), 349))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Altering_Spell"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Altering_Spell\\Altering_Spell%d.png"), 349))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Alohomora"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Alohomora\\Alohomora%d.png"), 394))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Alohomora"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Alohomora\\Alohomora%d.png"), 394))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Beast_Feed"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Beast_Feed\\Beast_Feed%d.png"), 378))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Beast_Feed"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Beast_Feed\\Beast_Feed%d.png"), 378))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Beast_Petting_Brush"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Beast_Petting_Brush\\Beast_Petting_Brush%d.png"), 327))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Beast_Petting_Brush"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Beast_Petting_Brush\\Beast_Petting_Brush%d.png"), 327))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Confringo"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Confringo\\Confringo%d.png"), 157))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Confringo"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Confringo\\Confringo%d.png"), 157))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Conjuring_Spell"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Conjuring_Spell\\Conjuring_Spell%d.png"), 115))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Conjuring_Spell"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Conjuring_Spell\\Conjuring_Spell%d.png"), 115))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Depulso"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Depulso\\Depulso%d.png"), 152))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Depulso"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Depulso\\Depulso%d.png"), 152))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Diffindo"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Diffindo\\Diffindo%d.png"), 150))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Diffindo"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Diffindo\\Diffindo%d.png"), 150))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Disillusionment"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Disillusionment\\Disillusionment%d.png"), 260))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Disillusionment"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Disillusionment\\Disillusionment%d.png"), 260))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Evanesco"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Evanesco\\Evanesco%d.png"), 136))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Evanesco"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Evanesco\\Evanesco%d.png"), 136))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Expelliarmus"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Expelliarmus\\Expelliarmus%d.png"), 146))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Expelliarmus"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Expelliarmus\\Expelliarmus%d.png"), 146))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Flipendo"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Flipendo\\Flipendo%d.png"), 188))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Flipendo"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Flipendo\\Flipendo%d.png"), 188))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Glacius"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Glacius\\Glacius%d.png"), 156))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Glacius"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Glacius\\Glacius%d.png"), 156))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Imperio"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Imperio\\Imperio%d.png"), 462))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Imperio"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Imperio\\Imperio%d.png"), 462))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Incendio"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Incendio\\Incendio%d.png"), 213))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Incendio"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Incendio\\Incendio%d.png"), 213))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Nab_Sack"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Nab_Sack\\Nab_Sack%d.png"), 235))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Nab_Sack"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Nab_Sack\\Nab_Sack%d.png"), 235))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Reparo"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Reparo\\Reparo%d.png"), 385))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Reparo"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Reparo\\Reparo%d.png"), 385))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), 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(ENUM_CLASS(LEVEL::UI), TEXT("Transformation"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Transformation\\Transformation%d.png"), 146))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Transformation"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Transformation\\Transformation%d.png"), 146))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Wingardium_Leviosa"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Wingardium_Leviosa\\Wingardium_Leviosa%d.png"), 273))))
- //{
- // return E_FAIL;
- //}
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Wingardium_Leviosa"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Wingardium_Leviosa\\Wingardium_Leviosa%d.png"), 273))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Wingardium_Leviosa"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Wingardium_Leviosa\\Wingardium_Leviosa%d.png"), 273))))
+ {
+ return E_FAIL;
+ }
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Wingardium_Leviosa"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Wingardium_Leviosa\\Wingardium_Leviosa%d.png"), 273))))
+ {
+ return E_FAIL;
+ }
- //if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Crucio"),
- // CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Crucio\\Crucio%d.png"), 216))))
- //{
- // return E_FAIL;
- //}
+ if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::UI), TEXT("Crucio"),
+ CTexture::Create(m_pDevice, m_pContext, TEXTURE_LOAD_TYPE::INCREMENTAL, TEXT("C:\\MeshTable\\SpellAnim\\Crucio\\Crucio%d.png"), 216))))
+ {
+ return E_FAIL;
+ }
m_strMessage = TEXT("Model Loading..");
diff --git a/Jusin154_Team3D/Editor/Private/Magic_Meter.cpp b/Jusin154_Team3D/Editor/Private/Magic_Meter.cpp
index bb03f3089..e3d6a650d 100644
--- a/Jusin154_Team3D/Editor/Private/Magic_Meter.cpp
+++ b/Jusin154_Team3D/Editor/Private/Magic_Meter.cpp
@@ -43,7 +43,6 @@ HRESULT CMagic_Meter::Initialize(void* pArg)
m_fAlphaTime = 1.f;
m_fMaxGauge = 20.f;
m_fCurrentGauge = 10.f;
- Visible(false);
return S_OK;
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Canvas.cpp b/Jusin154_Team3D/Editor/Private/Spell_Canvas.cpp
index f9fb027a5..b15c58a94 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Canvas.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Canvas.cpp
@@ -1,4 +1,5 @@
#include "pch.h"
+#include "UI_Manager.h"
#include "Spell_Canvas.h"
#include "GameInstance.h"
#include "Spell_Panel.h"
@@ -50,6 +51,7 @@ void CSpell_Canvas::Priority_Update(_float fTimeDelta)
void CSpell_Canvas::Update(_float fTimeDelta)
{
+
__super::Update(fTimeDelta);
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Drag.cpp b/Jusin154_Team3D/Editor/Private/Spell_Drag.cpp
index 47e8bd535..5884d5967 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Drag.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Drag.cpp
@@ -47,6 +47,7 @@ HRESULT CSpell_Drag::Initialize(void* pArg)
m_bMove = false;
m_bClick = false;
m_iSpellType = -1;
+ m_iCurrent_Slot_Index = -1;
static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SpellType(*reinterpret_cast<_int*>(p)); });
static_cast(m_pOwner)->Add_Function(TEXT("Current_Hover"), [this](void* p) {this->Set_Current_Slot(*reinterpret_cast<_int*>(p)); });
return S_OK;
@@ -93,25 +94,29 @@ void CSpell_Drag::Update(_float fTimeDelta)
}
m_fTime += fTimeDelta * m_fTimeMult;
- Get_MousePos();
-
-
- if (m_bHover == true || m_bCurrent_Hover == true)
+ if (m_pGameInstance->Mouse_Down(DIM_LBUTTON))
{
- if (m_pGameInstance->Mouse_Down(DIM_LBUTTON))
+ if (m_iSpellType == -1 && m_iCurrent_Slot_Index == -1)
{
- m_vStart_MousePos = XMVectorSet(0.f, 0.f, 0.f, 0.f);
-
- POINT m_pPt{};
- GetCursorPos(&m_pPt);
- ScreenToClient(g_hWnd, &m_pPt);
- _float2 fMouse{};
- fMouse.x = m_pPt.x - (g_iWinSizeX * 0.5f);
- fMouse.y = m_pPt.y - (g_iWinSizeY * 0.5f);
-
- m_vStart_MousePos = XMVectorSet(fMouse.x, fMouse.y, 0.f, 1.f);
+ m_bFalse = true;
+ return;
}
+ m_vStart_MousePos = XMVectorSet(0.f, 0.f, 0.f, 0.f);
+
+ POINT m_pPt{};
+ GetCursorPos(&m_pPt);
+ ScreenToClient(g_hWnd, &m_pPt);
+ _float2 fMouse{};
+ fMouse.x = m_pPt.x - (g_iWinSizeX * 0.5f);
+ fMouse.y = m_pPt.y - (g_iWinSizeY * 0.5f);
+
+ m_vStart_MousePos = XMVectorSet(fMouse.x, fMouse.y, 0.f, 1.f);
+ m_bFalse = false;
+ }
+
+ if (m_bFalse == false && (m_bHover == true || m_bCurrent_Hover == true))
+ {
if (m_pGameInstance->Mouse_Pressing(DIM_LBUTTON))
{
POINT pt{};
@@ -327,6 +332,7 @@ void CSpell_Drag::Set_SpellType(_int SpellID)
{
if (SpellID == -1 || SpellID >= 26)
{
+ m_iSkillType = -1;
m_bHover = false;
return;
}
@@ -352,6 +358,7 @@ void CSpell_Drag::Set_Current_Slot(_uint Index)
{
if (Index == -1)
{
+ m_iCurrent_Slot_Index = -1;
m_bCurrent_Hover = false;
return;
}
diff --git a/Jusin154_Team3D/Editor/Private/Spell_State.cpp b/Jusin154_Team3D/Editor/Private/Spell_State.cpp
index cf8f5df3c..a41babab4 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_State.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_State.cpp
@@ -89,6 +89,7 @@ void CSpell_State::Update(_float fTimeDelta)
m_fAlpha = 0.f;
}
}
+
m_fTime += fTimeDelta * m_fTimeMult;
if (m_bClick == false)
{
diff --git a/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp b/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
index 1324ee4b8..826bec3a4 100644
--- a/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
+++ b/Jusin154_Team3D/Editor/Private/Spell_Vidio_Border.cpp
@@ -1,7 +1,6 @@
#include "pch.h"
#include "Spell_Vidio_Border.h"
#include "GameInstance.h"
-#include "Spell_Anim.h"
CSpell_Vidio_Border::CSpell_Vidio_Border(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
:CElementObject(pDevice, pContext)
diff --git a/Jusin154_Team3D/Editor/Private/UI_Manager.cpp b/Jusin154_Team3D/Editor/Private/UI_Manager.cpp
index f396869e9..888e842d2 100644
--- a/Jusin154_Team3D/Editor/Private/UI_Manager.cpp
+++ b/Jusin154_Team3D/Editor/Private/UI_Manager.cpp
@@ -26,9 +26,64 @@ HRESULT CUI_Manager::Initialize(void* pArg)
return E_FAIL;
}
m_bCanvas_Change = false;
+ m_eType = Canvases::GAMEPLAYER_CANVAS;
return S_OK;
}
+void CUI_Manager::Canvas_Change(Canvases eType)
+{
+ m_eType = eType;
+
+ switch (eType)
+ {
+ case Canvases::GAMEPLAYER_CANVAS:
+ static_cast(m_pGamePlay_Canves)->Visible(true);
+ static_cast(m_pSpell_Canvas)->Visible(false);
+
+ break;
+ case Canvases::SPELL_CANVAS:
+ static_cast(m_pSpell_Canvas)->Visible(true);
+ static_cast(m_pGamePlay_Canves)->Visible(false);
+
+ break;
+ default:
+ return;
+ }
+}
+
+void CUI_Manager::Clear_Canvas()
+{
+}
+
+CGameObject* CUI_Manager::Get_Canvas(const wstring& Name)
+{
+ return Find_Canvas(Name);
+}
+
+_int CUI_Manager::Canvas_Count()
+{
+ return m_iCanvas_Count;
+}
+
+const vector CUI_Manager::Canvas_Name()
+{
+ return m_CanvasNames;
+}
+
+void CUI_Manager::Add_Manager_Event(_wstring Name, function Event)
+{
+ m_Event_map.emplace(Name, Event);
+}
+
+void CUI_Manager::Event_Callback(_wstring Name, void* pArg)
+{
+ auto range = m_Event_map.equal_range(Name);
+ for (auto it = range.first; it != range.second; ++it)
+ {
+ it->second(pArg);
+ }
+}
+
void CUI_Manager::Priority_Update(_float fTimeDelta)
{
}
@@ -37,19 +92,12 @@ void CUI_Manager::Update(_float fTimeDelta)
{
if (m_pGameInstance->Key_Down(DIK_T))
{
- m_bCanvas_Change = !m_bCanvas_Change;
+ if (m_eType == Canvases::GAMEPLAYER_CANVAS)
+ Canvas_Change(Canvases::SPELL_CANVAS);
+ else
+ Canvas_Change(Canvases::GAMEPLAYER_CANVAS);
}
- if (m_bCanvas_Change == false)
- {
- static_cast(m_pGamePlay_Canves)->Visible(true);
- static_cast(m_pSpell_Panel)->Visible(false);
- }
- else
- {
- static_cast(m_pSpell_Panel)->Visible(true);
- static_cast(m_pGamePlay_Canves)->Visible(false);
- }
}
void CUI_Manager::Late_Update(_float fTimeDelta)
@@ -80,15 +128,41 @@ HRESULT CUI_Manager::Ready_Components(void* pArg)
if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, g_iStaticLevel, LAYER_UI, nullptr, this, reinterpret_cast(&m_pGamePlay_Canves)))) {
return E_FAIL;
}
- if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, g_iStaticLevel, LAYER_UI, nullptr, this, reinterpret_cast(&m_pSpell_Panel)))) {
+ Add_Canvas(TEXT("GamePlay_Canvas"), m_pGamePlay_Canves);
+
+ if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, g_iStaticLevel, LAYER_UI, nullptr, this, reinterpret_cast(&m_pSpell_Canvas)))) {
return E_FAIL;
}
+ Add_Canvas(TEXT("Spell_Canvas"), m_pSpell_Canvas);
return S_OK;
}
-void CUI_Manager::Clear_Penel()
+void CUI_Manager::Add_Canvas(_wstring Name, CGameObject* pCanvas)
{
+ if (pCanvas == nullptr)
+ {
+ return;
+ }
+
+ if (Find_Canvas(Name) != nullptr)
+ {
+ return;
+ }
+ m_Canvases.push_back(pCanvas);
+ m_CanvasNames.push_back(Name);
+ m_Canvas_map.emplace(Name, pCanvas);
+ m_iCanvas_Count++;
+}
+
+CGameObject* CUI_Manager::Find_Canvas(const _wstring& Name)
+{
+ auto iter = m_Canvas_map.find(Name);
+
+ if (iter == m_Canvas_map.end())
+ return nullptr;
+
+ return iter->second;
}
CUI_Manager* CUI_Manager::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
diff --git a/Jusin154_Team3D/Editor/Public/Current_Spell_Slot.h b/Jusin154_Team3D/Editor/Public/Current_Spell_Slot.h
index 6f21aee4b..4472b06b8 100644
--- a/Jusin154_Team3D/Editor/Public/Current_Spell_Slot.h
+++ b/Jusin154_Team3D/Editor/Public/Current_Spell_Slot.h
@@ -45,6 +45,8 @@ class CCurrent_Spell_Slot final : public CElementObject
CShader* m_pShaderCom = { nullptr };
CVIBuffer_UI_Instance* m_pVIBufferCom = { nullptr };
+ class CUI_Manager* m_pManager = { nullptr };
+
_float m_fOffSetX{};
_float m_fOffSetY{};
_uint m_iCols{};
diff --git a/Jusin154_Team3D/Editor/Public/Editor_Define.h b/Jusin154_Team3D/Editor/Public/Editor_Define.h
index 70c60eb5e..6e637b091 100644
--- a/Jusin154_Team3D/Editor/Public/Editor_Define.h
+++ b/Jusin154_Team3D/Editor/Public/Editor_Define.h
@@ -26,7 +26,7 @@ namespace Editor
enum class SHADER_PASS_POSTEX { DEFAULT, SCISSOR, UI, UVMOVE, TRAIL, TRAIL_BLEND , TRAILWB_FOR_BLEND , TRAIL_BLUR , TRAIL_BLOOM, END };
enum class SHADER_PASS_INSTANCE_MODEL { DEFAULT, NON_NOMALMAP, BLUR, WEIGHTBLEND, NON_WORLD, NON_WORLD_BLUR, BLEND, BLEND_NOWORLD, BLOOM, BLOOM_NOWORLD, BLUR_NO_EMMISVE, BLUR_NO_WORLD_NO_EMISSIVE, WEIGHTBLEND_FOR_BLEND,END };
- enum class SHADER_PASS_UIEDITOR { DEFAULT, ALPHABLEND,CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, SPELL_DRAG, END };
+ enum class SHADER_PASS_UIEDITOR { DEFAULT, ALPHABLEND, CLAMP, CURSOR, LODING, HOLD_ROTATION, MISSION, QUESTYPE, UVMULT, NINECLICE, ROTATION, SLOT, TYPE, HPBAR, MAGIC_METER, MAGIC_ICON, REMOVEUV, REVELIO, POTION, MAGIC_ITEM, SPELL_PREVIEW, SPELL_HEADER, SPELL_HEADER_LINE, SPELL_DRAG, END };
enum class SHADER_PASS_UIINTANCE { DEFAULT, ALPHABLEND, UVALPHABLEND, MAGIC_METER, SPELL_LIST, EESSENTIAL_SPELL_SOLT, EESSENTIAL_SPELL, COLOR, SPELL_HOVER, SPELL_SLOT_EFFECT, SPELL_SLOT, END };
@@ -40,12 +40,8 @@ namespace Editor
AVADA_KEDAVRA, CRUCIO, IMPERIO, // 진녹색
BEAST_PETTING_BRUSH, BEAST_FEED, NAB_SACK, // 하늘색
JAP , REVELIO, PROTEGO, STUPEFY, // 검은색
-
-
ANCIENT_MAGIC_THROW, ANCIENT_MAGIC, ALOHOMORA, PETRIFICUS_TOTALUS,
- JAP_SIDE, BOMBARDA_SIDE, DESCENDO_SIDE, LEVIOSO_SIDE,
-
- END
+ JAP_SIDE, BOMBARDA_SIDE, DESCENDO_SIDE, LEVIOSO_SIDE,END
};
enum class BLOOM_TYPE { NONE , BASIC , MULTIPLY , END};
diff --git a/Jusin154_Team3D/Editor/Public/IMGUIUI.h b/Jusin154_Team3D/Editor/Public/IMGUIUI.h
index 3e3e43339..de548593b 100644
--- a/Jusin154_Team3D/Editor/Public/IMGUIUI.h
+++ b/Jusin154_Team3D/Editor/Public/IMGUIUI.h
@@ -30,6 +30,7 @@ class CIMGUIUI final : public CGameObject
virtual HRESULT Initialize(void* pArg) override;
private:
+ void CanvaswstringTostring(vector& panelNames);
void PanelwstringTostring(vector& panelNames);
void ElementwstringTostring(vector& panelNames);
@@ -86,6 +87,11 @@ class CIMGUIUI final : public CGameObject
vector m_iPanelNamestring;
vector m_iPanelName;
+ _int m_iCanvasCount{};
+ vector m_iCanvasNamewstring;
+ vector m_iCanvasNamestring;
+ vector m_iCanvaslName;
+
_bool m_bCanvasVisible = { false };
_bool m_bPanelVisible = { false };
_bool m_bElementAllVisible = { false };
diff --git a/Jusin154_Team3D/Editor/Public/Spell_Drag.h b/Jusin154_Team3D/Editor/Public/Spell_Drag.h
index 90bf98782..6918f1ab2 100644
--- a/Jusin154_Team3D/Editor/Public/Spell_Drag.h
+++ b/Jusin154_Team3D/Editor/Public/Spell_Drag.h
@@ -49,6 +49,7 @@ class CSpell_Drag final : public CElementObject
_bool m_bCurrent_Hover = { false };
_bool m_bMove = { false };
_bool m_bClick = { false };
+ _bool m_bFalse = { false };
public:
static CSpell_Drag* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Editor/Public/Spell_Vidio_Border.h b/Jusin154_Team3D/Editor/Public/Spell_Vidio_Border.h
index bb306b7bb..515064bc2 100644
--- a/Jusin154_Team3D/Editor/Public/Spell_Vidio_Border.h
+++ b/Jusin154_Team3D/Editor/Public/Spell_Vidio_Border.h
@@ -19,12 +19,6 @@ class CSpell_Vidio_Border final : public CElementObject
virtual HRESULT Render() override;
virtual _vector Get_WorldPostion() override;
-//public:
-// virtual const SPELLINFO Get_Info(_int Index) override;
-//
-//public:
-// virtual void Set_SkillType(_int eType);
-
private:
virtual HRESULT Bind_ShaderResources() override;
virtual HRESULT Ready_Components(void* pArg) override;
diff --git a/Jusin154_Team3D/Editor/Public/UI_Manager.h b/Jusin154_Team3D/Editor/Public/UI_Manager.h
index 192b1d08a..b42b75c79 100644
--- a/Jusin154_Team3D/Editor/Public/UI_Manager.h
+++ b/Jusin154_Team3D/Editor/Public/UI_Manager.h
@@ -11,6 +11,9 @@ NS_BEGIN(Editor)
class CUI_Manager final : public CUIObject
{
+public:
+ enum class Canvases {GAMEPLAYER_CANVAS, SPELL_CANVAS};
+
private:
CUI_Manager(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
CUI_Manager(const CUI_Manager& rhs);
@@ -31,15 +34,35 @@ class CUI_Manager final : public CUIObject
virtual HRESULT Initialize(void* pArg) override;
public:
- void Clear_Penel();
+ void Canvas_Change(Canvases m_eType);
+ void Clear_Canvas();
+ virtual class CGameObject* Get_Canvas(const wstring& Name);
+ virtual _int Canvas_Count();
+ virtual const vector Canvas_Name();
+
+ void Add_Manager_Event(_wstring Name, function Event);
+ void Event_Callback(_wstring Name, void* pArg = nullptr);
+private:
+ void Add_Canvas(_wstring Name, class CGameObject* pCanvas);
+ CGameObject* Find_Canvas(const _wstring& Name);
private:
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
CGameObject* m_pGamePlay_Canves = { nullptr };
- CGameObject* m_pSpell_Panel = { nullptr };
+ CGameObject* m_pSpell_Canvas = { nullptr };
_bool m_bCanvas_Change = { false };
+ Canvases m_eType{};
+
+ vector m_Canvases; // 캔버스가 패널들을 관리 하기 위해서 필요함
+ vector m_CanvasNames; // 패널들의 이름을 전해주기 위해서
+ map m_Canvas_map; // 캔버스에서 내가 원하는 패널을 찾기 위해서
+ _int m_iCanvas_Count{}; // 전체 패널의 갯수
+
+ multimap> m_Event_map;
+
+
public:
static CUI_Manager* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
diff --git a/Jusin154_Team3D/Engine/Private/UIObject.cpp b/Jusin154_Team3D/Engine/Private/UIObject.cpp
index 4f2f687fa..2d578317d 100644
--- a/Jusin154_Team3D/Engine/Private/UIObject.cpp
+++ b/Jusin154_Team3D/Engine/Private/UIObject.cpp
@@ -100,11 +100,6 @@ void CUIObject::Update(_float fTimeDelta)
//m_fCurrent_Position = XMVectorSet(m_fX, m_fY, m_fSortZ, 1.f);
- if (m_pGameInstance->Key_Down(DIK_T))
- {
- m_bVisible = !m_bVisible;
- }
-
}
void CUIObject::Late_Update(_float fTimeDelta)