@@ -89,10 +89,12 @@ void CDialogue_Font::Update(_float fTimeDelta)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case ENUM_CLASS(NPCTEXTTYPE::BROOM):
|
case ENUM_CLASS(NPCTEXTTYPE::BROOM):
|
||||||
|
m_pInfoInstance->Event_CallBack(TEXT("RACEREADY"), &m_bChoiceText);
|
||||||
MapMove();
|
MapMove();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ENUM_CLASS(NPCTEXTTYPE::BATTLE):
|
case ENUM_CLASS(NPCTEXTTYPE::BATTLE):
|
||||||
|
m_pInfoInstance->Event_CallBack(TEXT("BATTLE"), &m_bChoiceText);
|
||||||
MapMove();
|
MapMove();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@@ -109,7 +111,7 @@ void CDialogue_Font::Update(_float fTimeDelta)
|
|||||||
switch (m_iType)
|
switch (m_iType)
|
||||||
{
|
{
|
||||||
case ENUM_CLASS(NPCTEXTTYPE::ENDTEXT):
|
case ENUM_CLASS(NPCTEXTTYPE::ENDTEXT):
|
||||||
m_fTime = 0.5f;
|
m_fTime = 0.f;
|
||||||
ENDText();
|
ENDText();
|
||||||
break;
|
break;
|
||||||
case ENUM_CLASS(NPCTEXTTYPE::NEXTTEXT):
|
case ENUM_CLASS(NPCTEXTTYPE::NEXTTEXT):
|
||||||
@@ -129,22 +131,7 @@ void CDialogue_Font::Update(_float fTimeDelta)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!m_pCurrentDialogue.empty())
|
|
||||||
{
|
|
||||||
for (auto it = m_pCurrentDialogue.begin(); it != m_pCurrentDialogue.end();)
|
|
||||||
{
|
|
||||||
if ((*it)->Get_Hover() == false)
|
|
||||||
{
|
|
||||||
(*it)->Visible(false);
|
|
||||||
m_DialoguInfo.push_back((*it));
|
|
||||||
it = m_pCurrentDialogue.erase(it);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
it++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (m_fTime >= 0.f)
|
if (m_fTime >= 0.f)
|
||||||
{
|
{
|
||||||
@@ -158,6 +145,25 @@ void CDialogue_Font::Update(_float fTimeDelta)
|
|||||||
|
|
||||||
void CDialogue_Font::Late_Update(_float fTimeDelta)
|
void CDialogue_Font::Late_Update(_float fTimeDelta)
|
||||||
{
|
{
|
||||||
|
if (!m_pCurrentDialogue.empty())
|
||||||
|
{
|
||||||
|
if (!m_pCurrentDialogue.empty())
|
||||||
|
{
|
||||||
|
for (auto it = m_pCurrentDialogue.begin(); it != m_pCurrentDialogue.end();)
|
||||||
|
{
|
||||||
|
if ((*it)->Get_Hover() == false)
|
||||||
|
{
|
||||||
|
(*it)->Visible(false);
|
||||||
|
m_DialoguInfo.push_back((*it));
|
||||||
|
it = m_pCurrentDialogue.erase(it);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if (!m_pCurrentDialogue.empty())
|
if (!m_pCurrentDialogue.empty())
|
||||||
{
|
{
|
||||||
m_pGameInstance->Add_RenderGroup(RENDER::UI_OVERLAY, this);
|
m_pGameInstance->Add_RenderGroup(RENDER::UI_OVERLAY, this);
|
||||||
@@ -166,12 +172,9 @@ void CDialogue_Font::Late_Update(_float fTimeDelta)
|
|||||||
|
|
||||||
HRESULT CDialogue_Font::Render()
|
HRESULT CDialogue_Font::Render()
|
||||||
{
|
{
|
||||||
if (!m_pCurrentDialogue.empty())
|
for (auto it : m_pCurrentDialogue)
|
||||||
{
|
{
|
||||||
for (auto it : m_pCurrentDialogue)
|
it->Render();
|
||||||
{
|
|
||||||
it->Render();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return S_OK;
|
return S_OK;
|
||||||
@@ -346,18 +349,9 @@ void CDialogue_Font::Quest()
|
|||||||
if (m_bChoiceText == true)
|
if (m_bChoiceText == true)
|
||||||
{
|
{
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
||||||
if (m_pNpc->Get_NpcID() == 4)
|
|
||||||
{
|
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("Change"));
|
ENDText();
|
||||||
m_bCurrentInteract = false;
|
|
||||||
m_bNpcInteract = false;
|
|
||||||
ENDText();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
|
||||||
ReSet();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@@ -378,11 +372,12 @@ void CDialogue_Font::Quest()
|
|||||||
void CDialogue_Font::ENDText()
|
void CDialogue_Font::ENDText()
|
||||||
{
|
{
|
||||||
_bool bInteract = false;
|
_bool bInteract = false;
|
||||||
|
NPCINTERACT Interact{};
|
||||||
|
Interact.bInteract = bInteract;
|
||||||
|
Interact.fAlpha = 1.f;
|
||||||
|
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
||||||
|
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha);
|
||||||
m_pNpc->Set_NextID(m_iNextID);
|
m_pNpc->Set_NextID(m_iNextID);
|
||||||
m_pCurrentDialogue[0]->Set_Hover(bInteract);
|
|
||||||
m_pCurrentDialogue[0]->Visible(bInteract);
|
|
||||||
m_DialoguInfo.push_back(m_pCurrentDialogue[0]);
|
|
||||||
m_pCurrentDialogue.erase(m_pCurrentDialogue.begin());
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("NpcInteraction"), &bInteract);
|
m_pInfoInstance->Event_CallBack(TEXT("NpcInteraction"), &bInteract);
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
||||||
m_bChoiceText = false;
|
m_bChoiceText = false;
|
||||||
@@ -398,25 +393,16 @@ void CDialogue_Font::ENDText()
|
|||||||
m_DialoguInfo.push_back((*it));
|
m_DialoguInfo.push_back((*it));
|
||||||
it = m_pCurrentDialogue.erase(it);
|
it = m_pCurrentDialogue.erase(it);
|
||||||
}
|
}
|
||||||
if (m_pNpc->Get_NpcID() == 4)
|
|
||||||
{
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("Change"));
|
|
||||||
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, 0.f);
|
|
||||||
m_bCurrentInteract = false;
|
|
||||||
m_bNpcInteract = false;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
NPCINTERACT Interact{};
|
|
||||||
Interact.bInteract = bInteract;
|
|
||||||
Interact.fAlpha = 1.f;
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
|
||||||
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CDialogue_Font::ReSet()
|
void CDialogue_Font::ReSet()
|
||||||
{
|
{
|
||||||
|
NPCINTERACT Interact{};
|
||||||
|
Interact.bInteract = false;
|
||||||
|
Interact.fAlpha = 1.f;
|
||||||
|
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
||||||
|
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha);
|
||||||
m_pNpc->Set_NextID(m_iTextID);
|
m_pNpc->Set_NextID(m_iTextID);
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET"));
|
||||||
m_bChoiceText = false;
|
m_bChoiceText = false;
|
||||||
@@ -432,21 +418,6 @@ void CDialogue_Font::ReSet()
|
|||||||
m_DialoguInfo.push_back((*it));
|
m_DialoguInfo.push_back((*it));
|
||||||
it = m_pCurrentDialogue.erase(it);
|
it = m_pCurrentDialogue.erase(it);
|
||||||
}
|
}
|
||||||
if (m_pNpc->Get_NpcID() == 4)
|
|
||||||
{
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("Change"));
|
|
||||||
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, 0.f);
|
|
||||||
m_bCurrentInteract = false;
|
|
||||||
m_bNpcInteract = false;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
NPCINTERACT Interact{};
|
|
||||||
Interact.bInteract = false;
|
|
||||||
Interact.fAlpha = 1.f;
|
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact);
|
|
||||||
m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CDialogue_Font::MapMove()
|
void CDialogue_Font::MapMove()
|
||||||
@@ -502,7 +473,7 @@ void CDialogue_Font::NextText(_int Index)
|
|||||||
m_pCurrentDialogue.erase(m_pCurrentDialogue.begin());
|
m_pCurrentDialogue.erase(m_pCurrentDialogue.begin());
|
||||||
if (m_bChoiceText == true)
|
if (m_bChoiceText == true)
|
||||||
{
|
{
|
||||||
ReSet();
|
ENDText();
|
||||||
}
|
}
|
||||||
NpcDialogue(Index);
|
NpcDialogue(Index);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -236,17 +236,14 @@ void CDialogue_Panel::Update(_float fTimeDelta)
|
|||||||
m_fTime += fTimeDelta;
|
m_fTime += fTimeDelta;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_fTime >= 1.5f)
|
|
||||||
|
if (m_fTime >= 0.8f)
|
||||||
{
|
{
|
||||||
if (m_bBroomRace == true)
|
if (m_bBroomRace == true)
|
||||||
{
|
{
|
||||||
m_bBroomRace = false;
|
m_bBroomRace = false;
|
||||||
m_pInfoInstance->Event_CallBack(TEXT("BROOMRACENPCINTERACT"));
|
m_pInfoInstance->Event_CallBack(TEXT("BROOMRACENPCINTERACT"));
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (m_fTime >= 0.8f)
|
|
||||||
{
|
|
||||||
if (m_bBttle == true)
|
if (m_bBttle == true)
|
||||||
{
|
{
|
||||||
m_bBttle = false;
|
m_bBttle = false;
|
||||||
|
|||||||
@@ -105,25 +105,7 @@ void CEnemy_HpBar::Update(_float fTimeDelta)
|
|||||||
|
|
||||||
m_fHpBar = m_fCurrentHp / m_fMaxHp;
|
m_fHpBar = m_fCurrentHp / m_fMaxHp;
|
||||||
|
|
||||||
if (m_fCurrentHp <= 0.f)
|
|
||||||
{
|
|
||||||
m_bAnimation = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (m_bAnimation == true)
|
|
||||||
{
|
|
||||||
m_fTime += fTimeDelta * m_fTimeMult;
|
|
||||||
m_fSizeX += 3.f;
|
|
||||||
m_fSizeY += 3.f;
|
|
||||||
static_cast<CUIObject*>(m_pOwner)->Function_Callback(TEXT("Enemy_HpDie"));
|
|
||||||
}
|
|
||||||
if (m_fTime >= 0.9f)
|
|
||||||
{
|
|
||||||
SizeUpdate(m_fLerpX, m_fLerpY);
|
|
||||||
m_bAnimation = false;
|
|
||||||
m_bHover = false;
|
|
||||||
m_fTime = 0.f;
|
|
||||||
}
|
|
||||||
__super::Update(fTimeDelta);
|
__super::Update(fTimeDelta);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ void CQuest_Data::Set_ClearQuest(_int Index)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
QuestInfos[Index].iAcceptState = ENUM_CLASS(QUESTSTATE::CLEARED);
|
QuestInfos[Index].iAcceptState = ENUM_CLASS(QUESTSTATE::CLEARED);
|
||||||
m_QuestEndInfos.push_back(QuestInfos[Index]);
|
m_QuestEndInfos.push_back(m_QuestAcceptedInfos[Index].QeustInfo);
|
||||||
m_iClearQeustCount++;
|
m_iClearQeustCount++;
|
||||||
if (m_iAcceptQeustCount >= 0)
|
if (m_iAcceptQeustCount >= 0)
|
||||||
m_iAcceptQeustCount--;
|
m_iAcceptQeustCount--;
|
||||||
@@ -198,22 +198,26 @@ void CQuest_Data::Update_AcceptQuest(_int MonsterID)
|
|||||||
auto* quest = static_cast<CQuestInstance*>(it->QeustData);
|
auto* quest = static_cast<CQuestInstance*>(it->QeustData);
|
||||||
auto& info = it->QeustInfo;
|
auto& info = it->QeustInfo;
|
||||||
|
|
||||||
_bool QuestClear = static_cast<CQuestInstance*>(quest)->Update_Objective(MonsterID);
|
for (auto& obj : info.ObjectiveInfo)
|
||||||
|
{
|
||||||
|
if (obj.iTargetID != MonsterID)
|
||||||
|
continue;
|
||||||
|
|
||||||
if (QuestClear == true)
|
if (obj.iCurrentCount < obj.iRequiredCount)
|
||||||
|
{
|
||||||
|
obj.iCurrentCount++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
_bool QuestClear = quest->Update_Objective(MonsterID);
|
||||||
|
|
||||||
|
if (QuestClear)
|
||||||
{
|
{
|
||||||
Set_ClearQuest(quest->Get_QuestID());
|
Set_ClearQuest(quest->Get_QuestID());
|
||||||
it = m_QuestAcceptedInfos.erase(it);
|
it = m_QuestAcceptedInfos.erase(it);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
for (auto& obj : info.ObjectiveInfo)
|
|
||||||
{
|
|
||||||
if (obj.iTargetID == MonsterID)
|
|
||||||
{
|
|
||||||
obj.iCurrentCount++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
++it;
|
++it;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ HRESULT CQuest_Panel::Initialize(void* pArg)
|
|||||||
Visible(true);
|
Visible(true);
|
||||||
ElementAllVisible(true);
|
ElementAllVisible(true);
|
||||||
Set_Status();
|
Set_Status();
|
||||||
//m_pInfoInstance->Set_AcceptQuest(0);
|
m_pInfoInstance->Set_AcceptQuest(0);
|
||||||
//m_pInfoInstance->Set_AcceptQuest(1);
|
//m_pInfoInstance->Set_AcceptQuest(1);
|
||||||
//m_pInfoInstance->Set_AcceptQuest(6);
|
//m_pInfoInstance->Set_AcceptQuest(6);
|
||||||
Add_Function(TEXT("Click"), [this](void* p) {this->Slot_Hover(*reinterpret_cast<_int*>(p)); });
|
Add_Function(TEXT("Click"), [this](void* p) {this->Slot_Hover(*reinterpret_cast<_int*>(p)); });
|
||||||
|
|||||||
@@ -330,6 +330,45 @@ void CUI_Manager::Update(_float fTimeDelta)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
m_bCutSceneInfo = m_pInfoInstance->IsActiveCutScene();
|
||||||
|
|
||||||
|
if (m_bCutSceneInfo != m_bCurrentCutSceneInfo)
|
||||||
|
{
|
||||||
|
m_bCurrentCutSceneInfo = m_bCutSceneInfo;
|
||||||
|
|
||||||
|
if (m_bCutSceneInfo == true || m_bRace == true || m_bBattle == true)
|
||||||
|
{
|
||||||
|
m_pMouse_Cursor->Set_Visible(false);
|
||||||
|
m_pCamera_LockOn->Set_Visible(false);
|
||||||
|
|
||||||
|
static_cast<CCanvasObject*>(m_pGamePlay_Canves)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pSpell_Canvas)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pQuest_Canvas)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pSpellLearn_Canvas)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pDialogue_Canvas)->Visible(false);
|
||||||
|
|
||||||
|
static_cast<CGameObject*>(m_pInteraction_Key)->Set_Visible(false);
|
||||||
|
static_cast<CGameObject*>(m_pBroom_TargetGate)->Set_Visible(false);
|
||||||
|
|
||||||
|
m_pNPCInteraction->Set_Visible(!m_bRace);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
m_pMouse_Cursor->Set_Visible(false);
|
||||||
|
m_pCamera_LockOn->Set_Visible(false);
|
||||||
|
|
||||||
|
static_cast<CCanvasObject*>(m_pGamePlay_Canves)->Visible(true);
|
||||||
|
static_cast<CCanvasObject*>(m_pDialogue_Canvas)->Visible(true);
|
||||||
|
|
||||||
|
static_cast<CGameObject*>(m_pInteraction_Key)->Set_Visible(true);
|
||||||
|
|
||||||
|
static_cast<CCanvasObject*>(m_pSpell_Canvas)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pQuest_Canvas)->Visible(false);
|
||||||
|
static_cast<CCanvasObject*>(m_pSpellLearn_Canvas)->Visible(false);
|
||||||
|
|
||||||
|
m_pNPCInteraction->Set_Visible(!m_bRace);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (m_pGameInstance->Key_Down(DIK_M) && m_pGameInstance->Key_Pressing(DIK_L))
|
if (m_pGameInstance->Key_Down(DIK_M) && m_pGameInstance->Key_Pressing(DIK_L))
|
||||||
Set_Enviroment();
|
Set_Enviroment();
|
||||||
|
|||||||
@@ -57,6 +57,7 @@ class CUI_Manager final : public CUIObject
|
|||||||
void Set_Race(_bool bRace);
|
void Set_Race(_bool bRace);
|
||||||
void Set_Battle(_bool bBattle);
|
void Set_Battle(_bool bBattle);
|
||||||
void FadeIn(_float fAlphaVelue);
|
void FadeIn(_float fAlphaVelue);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
CInfoInstance* m_pInfoInstance = { nullptr };
|
CInfoInstance* m_pInfoInstance = { nullptr };
|
||||||
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
|
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
|
||||||
@@ -101,6 +102,9 @@ class CUI_Manager final : public CUIObject
|
|||||||
_bool m_bBattle = { false };
|
_bool m_bBattle = { false };
|
||||||
_bool m_bGate = { false };
|
_bool m_bGate = { false };
|
||||||
_float m_fGateTime{};
|
_float m_fGateTime{};
|
||||||
|
|
||||||
|
_bool m_bCurrentCutSceneInfo = { false };
|
||||||
|
_bool m_bCutSceneInfo = { false };
|
||||||
public:
|
public:
|
||||||
static CUI_Manager* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
static CUI_Manager* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||||
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
|
virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override;
|
||||||
|
|||||||
@@ -74,10 +74,9 @@
|
|||||||
<Line ID="12" Tag="1" Type="1" Text="아, 맞다." NextID="13"/>
|
<Line ID="12" Tag="1" Type="1" Text="아, 맞다." NextID="13"/>
|
||||||
<Line ID="13" Tag="1" Type="1" Text="아직 근처에 고블린이 남아 있어." NextID="14"/>
|
<Line ID="13" Tag="1" Type="1" Text="아직 근처에 고블린이 남아 있어." NextID="14"/>
|
||||||
<Line ID="14" Tag="1" Type="2" Text="한 번만 더 도와줄래?" NextID="-1">
|
<Line ID="14" Tag="1" Type="2" Text="한 번만 더 도와줄래?" NextID="-1">
|
||||||
<Choice Type="4" Text="알겠어." NextID="-1" QuestID="0" />
|
<Choice Type="4" Text="알겠어." NextID="0" QuestID="0" />
|
||||||
<Choice Type="0" Text="여기까지만 할게." NextID="-1" QuestID="-1" />
|
<Choice Type="0" Text="여기까지만 할게." NextID="0" QuestID="-1" />
|
||||||
</Line>
|
</Line>
|
||||||
<Line ID="999" Tag="1" Type="0" Text="아직 덜 잡았네" NextID="7"/>
|
|
||||||
</Dialogue>
|
</Dialogue>
|
||||||
|
|
||||||
<Dialogue NpcName="PEEVES" NpcID="5" NpcInrteract="1">
|
<Dialogue NpcName="PEEVES" NpcID="5" NpcInrteract="1">
|
||||||
|
|||||||
Reference in New Issue
Block a user