diff --git a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp index f96b43f1b..10096fbcd 100644 --- a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp +++ b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp @@ -72,7 +72,6 @@ void CBroomRaceManager::Priority_Update(_float fTimeDelta) m_bRaceEnd = true; _float Alpha = 2.f; m_pInfoInstance->Event_CallBack(TEXT("UIFadeIn"), &Alpha); - for (auto& racer : m_Racers) { if (racer.pAI) @@ -163,6 +162,7 @@ void CBroomRaceManager::Update(_float fTimeDelta) pTransform->Set_State(STATE::POSITION, XMLoadFloat4(&m_OriginPos)); pCharacter->Set_Position(XMLoadFloat4(&m_OriginPos)); m_bRaceEnd = false; + m_pInfoInstance->Event_CallBack(TEXT("RACEREADY"), &m_bRaceEnd); m_fDelay = 0.f; m_bCurrentRace = false; m_pGameInstance->Sound_Stop(SOUND::SD_KIND::BROOM_BOOST, SD_CHANNEL_GROUP::EFFECT); @@ -177,7 +177,6 @@ void CBroomRaceManager::Update(_float fTimeDelta) } } - m_bCurrentRace = true; #ifdef _DEBUG //Describe_Entity(); #endif // _DEBUG @@ -521,6 +520,7 @@ void CBroomRaceManager::RaceReady() m_pGameInstance->Sound_StopChannel(SD_CHANNEL_GROUP::BGM); m_pGameInstance->Sound_Play(SOUND::SD_KIND::BGM_RACE, SD_CHANNEL_GROUP::BGM, true, 0.8f); + m_bCurrentRace = true; } void CBroomRaceManager::SetTargetRing(CGameObject* pRacer) diff --git a/Jusin154_Team3D/Client/Private/Dialogue_Font.cpp b/Jusin154_Team3D/Client/Private/Dialogue_Font.cpp index fdf3c5113..d8075bbb5 100644 --- a/Jusin154_Team3D/Client/Private/Dialogue_Font.cpp +++ b/Jusin154_Team3D/Client/Private/Dialogue_Font.cpp @@ -90,12 +90,14 @@ void CDialogue_Font::Update(_float fTimeDelta) break; case ENUM_CLASS(NPCTEXTTYPE::BROOM): - m_pInfoInstance->Event_CallBack(TEXT("RACEREADY"), &Map); + m_bRace = true; + m_pInfoInstance->Event_CallBack(TEXT("RACEREADY"), &m_bRace); MapMove(); break; case ENUM_CLASS(NPCTEXTTYPE::BATTLE): - m_pInfoInstance->Event_CallBack(TEXT("BATTLE"), &Map); + m_bBattle = true; + m_pInfoInstance->Event_CallBack(TEXT("BATTLE"), &m_bBattle); MapMove(); break; @@ -132,15 +134,13 @@ void CDialogue_Font::Update(_float fTimeDelta) } } - - - if (m_fTime >= 0.f) + if (m_fTime > 0.f) { m_fTime -= fTimeDelta; - } - else - { - m_fTime = 0.f; + if (m_fTime <= 0.f) + { + m_fTime = 0.f; + } } } @@ -193,8 +193,6 @@ HRESULT CDialogue_Font::Bind_ShaderResources() HRESULT CDialogue_Font::Ready_Components(void* pArg) { - - return S_OK; } @@ -257,6 +255,7 @@ void CDialogue_Font::NpcInfo(void* pArg) m_pNpcName = Info->pName; m_pName = Info->pNPCName; m_iTextID = Info->iTextID; + m_iNextID = Info->iNextID; } void CDialogue_Font::NpcInteract(_bool bInteract) @@ -266,7 +265,16 @@ void CDialogue_Font::NpcInteract(_bool bInteract) void CDialogue_Font::NpcDialogue() { - auto Info = m_pInfoInstance->Get_Dialogue(m_pNpcName, m_iNextID); + _int ID{}; + if (m_iNextID == 0) + { + ID = m_iTextID; + } + else + { + ID = m_iNextID; + } + auto Info = m_pInfoInstance->Get_Dialogue(m_pNpcName, ID); m_bTag = Info.bTag; if (m_bTag == false) { @@ -293,6 +301,7 @@ void CDialogue_Font::NpcDialogue(CNPCStat* Stat) m_Info.fTime = 3.f; m_iType = Info.iType; m_iNextID = Info.NextTextID; + m_iTextID = Info.iLineID; m_bTag = Info.bTag; Npc_Dialogue(m_Info); } @@ -309,7 +318,6 @@ void CDialogue_Font::NpcNextText() { m_Info.pName = m_pName; } - m_Info.pName = m_pName; m_Info.pText = Info.pText; m_Info.fTime = 99999.f; Npc_Dialogue(m_Info); @@ -317,6 +325,7 @@ void CDialogue_Font::NpcNextText() void CDialogue_Font::CHoice() { + m_NextLevel.clear(); m_bCurrentChoiceText = true; size_t InfoCount = m_pInfoInstance->Get_Dialogue(m_pNpcName, m_iTextID).ChoiceInfo.size(); for (size_t i = 0; i < InfoCount; ++i) @@ -350,7 +359,6 @@ void CDialogue_Font::Quest() if (m_bChoiceText == true) { m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET")); - m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact); ENDText(); } @@ -376,36 +384,35 @@ void CDialogue_Font::ENDText() NPCINTERACT Interact{}; Interact.bInteract = bInteract; Interact.fAlpha = 1.f; - m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact); + m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact.bInteract); m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha); m_pNpc->Set_NextID(m_iNextID); m_pInfoInstance->Event_CallBack(TEXT("NpcInteraction"), &bInteract); m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET")); + m_pInfoInstance->Event_CallBack(TEXT("ReSetNPC")); m_bChoiceText = false; m_bCurrentChoiceText = false; m_bRace = false; m_bBattle = false; vector<_int> Dummy; m_NextLevel.swap(Dummy); - for (auto it = m_pCurrentDialogue.begin(); it != m_pCurrentDialogue.end();) + for (auto it = m_pCurrentDialogue.begin(); it != m_pCurrentDialogue.end(); ++it) { - (*it)->Set_Hover(false); - (*it)->Visible(false); - m_DialoguInfo.push_back((*it)); - it = m_pCurrentDialogue.erase(it); + (*it)->Set_Time(3.f); } - } void CDialogue_Font::ReSet() { NPCINTERACT Interact{}; Interact.bInteract = false; - Interact.fAlpha = 1.f; + Interact.fAlpha = 0.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_iNextID); + m_pInfoInstance->Event_CallBack(TEXT("NpcInteraction"), &Interact); m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET")); + m_pInfoInstance->Event_CallBack(TEXT("ReSetNPC")); m_bChoiceText = false; m_bCurrentChoiceText = false; m_bRace = false; @@ -423,12 +430,17 @@ void CDialogue_Font::ReSet() void CDialogue_Font::MapMove() { - m_pNpc->Set_NextID(m_iTextID); + 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_iNextID); + m_pInfoInstance->Event_CallBack(TEXT("NpcInteraction"), &Interact); m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET")); + m_pInfoInstance->Event_CallBack(TEXT("ReSetNPC")); m_bChoiceText = false; m_bCurrentChoiceText = false; - m_bRace = false; - m_bBattle = false; vector<_int> Dummy; m_NextLevel.swap(Dummy); for (auto it = m_pCurrentDialogue.begin(); it != m_pCurrentDialogue.end();) @@ -438,11 +450,13 @@ void CDialogue_Font::MapMove() m_DialoguInfo.push_back((*it)); it = m_pCurrentDialogue.erase(it); } - NPCINTERACT Interact{}; - Interact.bInteract = false; - Interact.fAlpha = 1.5f; - m_pInfoInstance->Event_CallBack(TEXT("NpcInteract"), &Interact); - m_pNpc->Set_Flow(m_pNpc->Get_Flow() + 1, Interact.fAlpha); + + if (m_bRace == true) + { + m_pInfoInstance->Event_CallBack(TEXT("UIFadeIn"), &Interact.fAlpha); + } + m_bRace = false; + m_bBattle = false; } void CDialogue_Font::Quest_Complete() @@ -451,11 +465,22 @@ void CDialogue_Font::Quest_Complete() } void CDialogue_Font::NextText() +{ + if (m_bChoiceText == true) + { + m_bChoiceText = false; + m_bCurrentChoiceText = false; + m_pInfoInstance->Event_CallBack(TEXT("CHOICERESET")); + } + Skip(); + NpcDialogue(); +} + +void CDialogue_Font::Skip() { m_pCurrentDialogue[0]->Visible(false); m_DialoguInfo.push_back(m_pCurrentDialogue[0]); m_pCurrentDialogue.erase(m_pCurrentDialogue.begin()); - NpcDialogue(); } void CDialogue_Font::NextLevel(CHOICEINFO Choice) @@ -464,7 +489,9 @@ void CDialogue_Font::NextLevel(CHOICEINFO Choice) m_iType = Choice.iType; m_iQuestID = Choice.QuestID; m_bChoiceText = true; - NpcNextText(); + Skip(); + if (m_iType != 0) + NpcNextText(); } void CDialogue_Font::NextText(_int Index) diff --git a/Jusin154_Team3D/Client/Private/Dialogue_Panel.cpp b/Jusin154_Team3D/Client/Private/Dialogue_Panel.cpp index 515677ad6..f2525ade2 100644 --- a/Jusin154_Team3D/Client/Private/Dialogue_Panel.cpp +++ b/Jusin154_Team3D/Client/Private/Dialogue_Panel.cpp @@ -111,11 +111,13 @@ void CDialogue_Panel::Choice_Slot(CHOICEINFO Choice) case ENUM_CLASS(NPCTEXTTYPE::BROOM): m_pInfoInstance->Event_CallBack(TEXT("NPCNEXTTEXT"), &Choice); m_bBroomRace = true; + m_fTime = 0.f; break; case ENUM_CLASS(NPCTEXTTYPE::BATTLE): m_pInfoInstance->Event_CallBack(TEXT("NPCNEXTTEXT"), &Choice); m_bBttle = true; + m_fTime = 0.f; break; default: @@ -237,7 +239,7 @@ void CDialogue_Panel::Update(_float fTimeDelta) } - if (m_fTime >= 0.8f) + if (m_fTime >= 1.f) { if (m_bBroomRace == true) { @@ -249,6 +251,8 @@ void CDialogue_Panel::Update(_float fTimeDelta) m_bBttle = false; Change_Map(); } + m_pInfoInstance->Event_CallBack(TEXT("ReSetNPC")); + m_fTime = 0.f; } __super::Update(fTimeDelta); diff --git a/Jusin154_Team3D/Client/Private/Elf.cpp b/Jusin154_Team3D/Client/Private/Elf.cpp index 26e85b021..593ec9ae0 100644 --- a/Jusin154_Team3D/Client/Private/Elf.cpp +++ b/Jusin154_Team3D/Client/Private/Elf.cpp @@ -71,15 +71,15 @@ void CElf::Update(_float fTimeDelta) Set_Anim(); - if (m_pGameInstance->Key_Down(DIK_U)) - { - m_iCurrentFlow++; - } + //if (m_pGameInstance->Key_Down(DIK_U)) + //{ + // m_iCurrentFlow++; + //} - if (m_bFlow == true) - { - m_fFlowTime -= fTimeDelta; - } + //if (m_bFlow == true) + //{ + // m_fFlowTime -= fTimeDelta; + //} if (m_fFlowTime <= 0.f && m_bFlow == true) { @@ -247,7 +247,6 @@ _int CElf::Get_NpcID() void CElf::Set_Flow(_int Index, _float fTime) { m_iFlowIndex = Index; - m_fFlowTime = fTime; m_bFlow = true; } diff --git a/Jusin154_Team3D/Client/Private/Human_Duelist.cpp b/Jusin154_Team3D/Client/Private/Human_Duelist.cpp index 5b0321e32..d04145478 100644 --- a/Jusin154_Team3D/Client/Private/Human_Duelist.cpp +++ b/Jusin154_Team3D/Client/Private/Human_Duelist.cpp @@ -116,6 +116,14 @@ void CHuman_Duelist::Update(_float fTimeDelta) } Play_Event(); + if (m_fBattleEndTimer >= 2.f) + { + m_pInfoInstance->Event_CallBack(TEXT("UIManagerFadeIn")); + m_pGameInstance->Sound_StopChannel(SD_CHANNEL_GROUP::BGM); + m_pGameInstance->Sound_Play(SOUND::SD_KIND::BGM_HOGWART_0, SD_CHANNEL_GROUP::BGM, true, 0.8f); + + } + __super::Update(fTimeDelta); #ifdef _DEBUG Describe_Entity(); diff --git a/Jusin154_Team3D/Client/Private/Loader.cpp b/Jusin154_Team3D/Client/Private/Loader.cpp index 888d9c1b7..734ee5300 100644 --- a/Jusin154_Team3D/Client/Private/Loader.cpp +++ b/Jusin154_Team3D/Client/Private/Loader.cpp @@ -2466,7 +2466,7 @@ HRESULT CLoader::Loading_For_GamePlay() CVIBuffer_UI_Instance::UI_INSTANCE_DESC Quest_Slot_Desc{}; - Quest_Slot_Desc.iNum = 10; + Quest_Slot_Desc.iNum = 6; if (FAILED(m_pGameInstance->Add_Asset_Prototype(g_iStaticLevel, TEXT("Prototype_Component_VIBuffer_Quest_Slot"), CVIBuffer_UI_Instance::Create(m_pDevice, m_pContext, &Quest_Slot_Desc)))) { diff --git a/Jusin154_Team3D/Client/Private/NPCInteraction.cpp b/Jusin154_Team3D/Client/Private/NPCInteraction.cpp index 1b197b476..dae4003a7 100644 --- a/Jusin154_Team3D/Client/Private/NPCInteraction.cpp +++ b/Jusin154_Team3D/Client/Private/NPCInteraction.cpp @@ -201,13 +201,13 @@ void CNPCInteraction::Priority_Update(_float fTimeDelta) void CNPCInteraction::Update(_float fTimeDelta) { - if (m_bVisible != true) + if (m_bActive != true) return; } void CNPCInteraction::Late_Update(_float fTimeDelta) { - if (m_bVisible != true) + if (m_bActive != true) return; if (m_bActive == true || m_bBoxActive) diff --git a/Jusin154_Team3D/Client/Private/Player.cpp b/Jusin154_Team3D/Client/Private/Player.cpp index 0c6cb5e16..8e70cd4aa 100644 --- a/Jusin154_Team3D/Client/Private/Player.cpp +++ b/Jusin154_Team3D/Client/Private/Player.cpp @@ -125,7 +125,7 @@ HRESULT CPlayer::Initialize(void* pArg) m_pInfoInstance->Add_Event(TEXT("UseSpell"), [this](void* p) {this->Get_Spell(*reinterpret_cast<_int*>(p)); }); m_pInfoInstance->Add_Event(TEXT("Player_CanvasChange"), [this](void* p) {this->Get_UIState(*reinterpret_cast(p)); }); m_pInfoInstance->Add_Event(TEXT("NpcInteraction"), [this](void* p) {this->Set_Interaction(*reinterpret_cast<_bool*>(p)); }); - m_pInfoInstance->Add_Event(TEXT("SpellLearningSuccess"), [this](void* p) {this->Set_Spell_Learning_Success(); }); + m_pInfoInstance->Add_Event(TEXT("ReSetNPC"), [this](void* p) {this->ReSetNPC(); }); m_bAI = false; @@ -393,6 +393,7 @@ HRESULT CPlayer::Update_RaycastElements() XMStoreFloat4(&Pos, static_cast(pFoundNPC)->Get_WorldPostion()); Info.fNPCPosition = Pos; Info.iTextID = static_cast(pFoundNPC)->Get_TextID(); + Info.iNextID = static_cast(pFoundNPC)->Get_NextID(); m_bNpcInteraction = true; m_pInfoInstance->Event_CallBack(TEXT("NPCInteractionOn"), &Info); } @@ -415,10 +416,7 @@ HRESULT CPlayer::Update_RaycastElements() { if (m_pCurrentNpcInteraction && !m_bCurrentInteraction) { - m_bNpcInteraction = false; - m_pCurrentNpcInteraction = nullptr; - m_pInfoInstance->Event_CallBack(TEXT("NPCInteractionOff")); - m_pInfoInstance->Event_CallBack(TEXT("BOXInteractionOff")); + ReSetNPC(); } } @@ -428,10 +426,7 @@ HRESULT CPlayer::Update_RaycastElements() { if (m_pCurrentNpcInteraction && !m_bCurrentInteraction) { - m_bNpcInteraction = false; - m_pCurrentNpcInteraction = nullptr; - m_pInfoInstance->Event_CallBack(TEXT("NPCInteractionOff")); - m_pInfoInstance->Event_CallBack(TEXT("BOXInteractionOff")); + ReSetNPC(); } } @@ -454,6 +449,14 @@ void CPlayer::Add_TurboBoost(_float fAmount) m_pBroom->Add_TurboBoost(fAmount); } +void CPlayer::ReSetNPC() +{ + m_bNpcInteraction = false; + m_pCurrentNpcInteraction = nullptr; + m_pInfoInstance->Event_CallBack(TEXT("NPCInteractionOff")); + m_pInfoInstance->Event_CallBack(TEXT("BOXInteractionOff")); +} + HRESULT CPlayer::Render_Shadow(SHADOW eType) { if (FAILED(m_pShaderCom->Bind_Matrix("g_WorldMatrix", m_pTransformCom->Get_WorldMatrixPtr()))) { diff --git a/Jusin154_Team3D/Client/Private/Player_States.cpp b/Jusin154_Team3D/Client/Private/Player_States.cpp index 5f11ee8f0..2302781c2 100644 --- a/Jusin154_Team3D/Client/Private/Player_States.cpp +++ b/Jusin154_Team3D/Client/Private/Player_States.cpp @@ -1799,7 +1799,8 @@ void CPlayer::Behavior_AncientSpellExit() void CPlayer::Behavior_ShieldEnter() { pair<_uint, _bool> pairAnimInfo; - + DIALOGUEINFO Info; + Info.pName = m_pStat->Get_Stat().pUnit_Name; m_pFSM->Enable_State(FSMSTATE::SHIELD); pairAnimInfo = m_Animation[STATEANIM::SKILL2]; @@ -1812,11 +1813,13 @@ void CPlayer::Behavior_ShieldEnter() [this]() {m_pEffectPool->Use_Skill(SKILL_TYPE::PROTEGO, this); }, 0.1f); - /* 왜 빠져있는거임? */ Add_Sound_Event(pairAnimInfo.first, [this]() {m_pGameInstance->Sound_Play(SOUND::SD_KIND::VOICE_PROTEGO, SD_CHANNEL_GROUP::VOICE, false, 0.7f); }, 0.01f); + Info.pText = TEXT("프로테고!"); + m_pInfoInstance->Event_CallBack(TEXT("Dialogue"), &Info); + Add_Sound_Event(pairAnimInfo.first, [this]() { _int iRand = m_pGameInstance->Real_Random_Int(0, 4); @@ -2000,6 +2003,8 @@ void CPlayer::Behavior_BlockExit() void CPlayer::Behavior_ParryEnter() { pair<_uint, _bool> pairAnimInfo; + DIALOGUEINFO Info; + Info.pName = m_pStat->Get_Stat().pUnit_Name; _int iCurrAnimIndex = m_pModelCom->Get_AnimIndex(); _float fRatio = m_pModelCom->Get_CurrentTrackProgressRatio(); _float fEventRatio = 0.2f; @@ -2079,9 +2084,13 @@ void CPlayer::Behavior_ParryEnter() fEventRatio); Add_Sound_Event(pairAnimInfo.first, + + + [this]() {m_pGameInstance->Sound_Play(SOUND::SD_KIND::VOICE_STUPEFY, SD_CHANNEL_GROUP::EFFECT, false, 0.8f); }, 0.01f); - + Info.pText = TEXT("스투페파이!"); + m_pInfoInstance->Event_CallBack(TEXT("Dialogue"), &Info); Add_Sound_Event(pairAnimInfo.first, [this]() {m_pGameInstance->Sound_Play(SOUND::SD_KIND::SP_BOMBARD_24, SD_CHANNEL_GROUP::EFFECT, false, 0.7f); }, 0.01f); diff --git a/Jusin154_Team3D/Client/Private/Quest_Slot.cpp b/Jusin154_Team3D/Client/Private/Quest_Slot.cpp index 8ad76355c..baf646590 100644 --- a/Jusin154_Team3D/Client/Private/Quest_Slot.cpp +++ b/Jusin154_Team3D/Client/Private/Quest_Slot.cpp @@ -333,6 +333,7 @@ void CQuest_Slot::Hover() //m_pVIBufferCom->Set_Hover(m_iIndex); Font_Size(); m_iPrevIndex = m_iIndex; + m_pGameInstance->Sound_Play(SOUND::SD_KIND::SLOT_HOVER, SD_CHANNEL_GROUP::EFFECT, false, 1.f); } } diff --git a/Jusin154_Team3D/Client/Private/Spell_Hover.cpp b/Jusin154_Team3D/Client/Private/Spell_Hover.cpp index 7c18a81e2..906fc87fe 100644 --- a/Jusin154_Team3D/Client/Private/Spell_Hover.cpp +++ b/Jusin154_Team3D/Client/Private/Spell_Hover.cpp @@ -46,6 +46,7 @@ HRESULT CSpell_Hover::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_iCurrentSpellType = 99; static_cast(m_pOwner)->Add_Function(TEXT("Slot_Hover"), [this](void* p) {this->Set_SkillType(*reinterpret_cast<_int*>(p)); }); return S_OK; } @@ -95,6 +96,15 @@ void CSpell_Hover::Update(_float fTimeDelta) m_pVIBufferCom->Set_Hover_Index(m_iSpellType); } + if (m_iSpellType >= 0) + { + if (m_iCurrentSpellType != m_iSpellType) + { + m_iCurrentSpellType = m_iSpellType; + m_pGameInstance->Sound_Play(SOUND::SD_KIND::SLOT_HOVER, SD_CHANNEL_GROUP::EFFECT, false, 1.f); + } + } + m_fTime += fTimeDelta * m_fTimeMult; __super::Update(fTimeDelta); } diff --git a/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp b/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp index ee8334f5e..0fabbb0c8 100644 --- a/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp +++ b/Jusin154_Team3D/Client/Private/Spell_Overlay.cpp @@ -122,6 +122,8 @@ void CSpell_Overlay::Spell_Setting(_int SlotIndex, _int SpellIndex) m_bSpellUsed[SlotIndex] = m_pInfoInstance->Get_Spell_Info(SpellIndex).bUse_Skill; m_vUV[SlotIndex] = Compute_UI(SpellIndex); m_iSpellType[SlotIndex] = m_pInfoInstance->Get_Spell_Info(SpellIndex).iSpell_Type; + m_pGameInstance->Sound_Play(SOUND::SD_KIND::EQUIP_SPELL, SD_CHANNEL_GROUP::EFFECT, false, 1.f); + } void CSpell_Overlay::Use_Spell() diff --git a/Jusin154_Team3D/Client/Private/UI_Manager.cpp b/Jusin154_Team3D/Client/Private/UI_Manager.cpp index dbcfaaeab..894bf5f55 100644 --- a/Jusin154_Team3D/Client/Private/UI_Manager.cpp +++ b/Jusin154_Team3D/Client/Private/UI_Manager.cpp @@ -89,14 +89,7 @@ void CUI_Manager::Canvas_Change(UI_STATE eType) static_cast(m_pDialogue_Canvas)->Visible(true); static_cast(m_pInteraction_Key)->Set_Visible(true); static_cast(m_pBroom_TargetGate)->Set_Visible(false); - if (m_bRace == false) - { - static_cast(m_pNPCInteraction)->Set_Visible(true); - } - else - { - static_cast(m_pNPCInteraction)->Set_Visible(false); - } + m_pGameInstance->Toggle_MouseCenter(true); break; @@ -268,9 +261,17 @@ void CUI_Manager::Update(_float fTimeDelta) if (m_bCurrentNPCInteract == true && m_bNPCInteract == false) { + m_fAlphaVelue = 1.f; m_bCurrentNPCInteract = m_bNPCInteract; + if (m_bCurrentNPCInteract != m_bNPCInteract) + m_bCurrentNPCInteract = m_bNPCInteract; - if (m_bActive == false) + if (m_eType == UI_STATE::NPC_INTERACT) + { + Canvas_Change(UI_STATE::GAMEPLAYER); + } + + /*if (m_bActive == false) { m_bActive = true; m_bAlphaZero = true; @@ -278,7 +279,7 @@ void CUI_Manager::Update(_float fTimeDelta) { m_eType = UI_STATE::GAMEPLAYER; } - } + }*/ } if (m_bActive == true && m_bHover == false) @@ -340,36 +341,28 @@ void CUI_Manager::Update(_float fTimeDelta) { m_pMouse_Cursor->Set_Visible(false); m_pCamera_LockOn->Set_Visible(false); - static_cast(m_pGamePlay_Canves)->Visible(false); static_cast(m_pSpell_Canvas)->Visible(false); static_cast(m_pQuest_Canvas)->Visible(false); static_cast(m_pSpellLearn_Canvas)->Visible(false); static_cast(m_pDialogue_Canvas)->Visible(false); - static_cast(m_pInteraction_Key)->Set_Visible(false); static_cast(m_pBroom_TargetGate)->Set_Visible(false); - - m_pNPCInteraction->Set_Visible(!m_bRace); + static_cast(m_pNPCInteraction)->Set_Visible(false); } else { m_pMouse_Cursor->Set_Visible(false); m_pCamera_LockOn->Set_Visible(false); - static_cast(m_pGamePlay_Canves)->Visible(true); static_cast(m_pDialogue_Canvas)->Visible(true); - static_cast(m_pInteraction_Key)->Set_Visible(true); - static_cast(m_pSpell_Canvas)->Visible(false); static_cast(m_pQuest_Canvas)->Visible(false); static_cast(m_pSpellLearn_Canvas)->Visible(false); - - m_pNPCInteraction->Set_Visible(!m_bRace); + static_cast(m_pNPCInteraction)->Set_Visible(true); } } - if (m_pGameInstance->Key_Down(DIK_M) && m_pGameInstance->Key_Pressing(DIK_L)) Set_Enviroment(); @@ -630,11 +623,11 @@ void CUI_Manager::NpcInteract(void* pArg) NPCINTERACT Interact = *reinterpret_cast(pArg); m_bNPCInteract = Interact.bInteract; - m_bHover = Interact.bInteract; - m_bActive = Interact.bInteract; - m_fAlpha= Interact.fAlpha; - m_bAlphaZero = true; - m_fAlphaVelue = 1.f; + //m_bHover = Interact.bInteract; + //m_bActive = Interact.bInteract; + //m_fAlpha= Interact.fAlpha; + //m_bAlphaZero = true; + //m_fAlphaVelue = 1.f; } void CUI_Manager::Chage() @@ -667,7 +660,7 @@ void CUI_Manager::Set_Race(_bool bRace) void CUI_Manager::Set_Battle(_bool bBattle) { m_bBattle = bBattle; - //FadeIn(1.5f); + FadeIn(1.5f); } void CUI_Manager::FadeIn(_float fAlphaVelue) diff --git a/Jusin154_Team3D/Client/Public/Client_Struct.h b/Jusin154_Team3D/Client/Public/Client_Struct.h index 209731778..6ba065307 100644 --- a/Jusin154_Team3D/Client/Public/Client_Struct.h +++ b/Jusin154_Team3D/Client/Public/Client_Struct.h @@ -76,6 +76,7 @@ typedef struct tegNPCInteractionInfo _wstring pName; _float4 fNPCPosition{}; _int iTextID{}; + _int iNextID{}; }NPCINTERACTIONINFO; typedef struct tegBoxInteractionInfo diff --git a/Jusin154_Team3D/Client/Public/Dialogue_Font.h b/Jusin154_Team3D/Client/Public/Dialogue_Font.h index 751bfd68f..08efc2d55 100644 --- a/Jusin154_Team3D/Client/Public/Dialogue_Font.h +++ b/Jusin154_Team3D/Client/Public/Dialogue_Font.h @@ -44,6 +44,7 @@ class CDialogue_Font final : public CGameObject void Npc_Dialogue(DIALOGUEINFO Info); void NextText(); + void Skip(); void NextLevel(CHOICEINFO Choice); void ENDText(); void NextText(_int Index); diff --git a/Jusin154_Team3D/Client/Public/Player.h b/Jusin154_Team3D/Client/Public/Player.h index edb1ab082..868de73ba 100644 --- a/Jusin154_Team3D/Client/Public/Player.h +++ b/Jusin154_Team3D/Client/Public/Player.h @@ -60,6 +60,7 @@ class CPlayer final : public CUnit void ExitBattle(); void Set_OriginPos(_vector vPos) { XMStoreFloat4(&m_OriginPos, vPos); } void Add_TurboBoost(_float fAmount); + void ReSetNPC(); #ifdef _DEBUG void Render_CameraCoordinateSystem(); #endif // _DEBUG diff --git a/Jusin154_Team3D/Client/Public/Spell_Hover.h b/Jusin154_Team3D/Client/Public/Spell_Hover.h index 316b57221..fc305015e 100644 --- a/Jusin154_Team3D/Client/Public/Spell_Hover.h +++ b/Jusin154_Team3D/Client/Public/Spell_Hover.h @@ -51,6 +51,8 @@ class CSpell_Hover final : public CElementObject _float m_fOffSetX{}; _float m_fOffSetY{}; _uint m_iCols{}; + + _int m_iCurrentSpellType{}; public: static CSpell_Hover* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext); virtual CGameObject* Clone(void* pArg, class CGameObject* pOwner) override; diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Dialogue/Dialogue.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/Dialogue/Dialogue.xml index 62ad9d3d1..c863c895a 100644 --- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Dialogue/Dialogue.xml +++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Dialogue/Dialogue.xml @@ -22,9 +22,9 @@ - + - + @@ -37,15 +37,15 @@ - + - + - + diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/Quest/QuestData.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/Quest/QuestData.xml index 13845a688..cac9f1d40 100644 --- a/Jusin154_Team3D/Editor/Bin/Resources/Data/Quest/QuestData.xml +++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/Quest/QuestData.xml @@ -42,15 +42,7 @@ - - - - - - - - - + @@ -58,29 +50,5 @@ - - - - - - - - - - - - - - - - - - - - - - - - - + \ No newline at end of file diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Equip_Spell.wav b/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Equip_Spell.wav new file mode 100644 index 000000000..75a061eb8 Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Equip_Spell.wav differ diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Slot_Hover.wav b/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Slot_Hover.wav new file mode 100644 index 000000000..a58eb01ca Binary files /dev/null and b/Jusin154_Team3D/Editor/Bin/Resources/Sounds/UI/Slot_Hover.wav differ diff --git a/Jusin154_Team3D/Engine/Private/SoundSrc.cpp b/Jusin154_Team3D/Engine/Private/SoundSrc.cpp index 8433c5fac..bac471343 100644 --- a/Jusin154_Team3D/Engine/Private/SoundSrc.cpp +++ b/Jusin154_Team3D/Engine/Private/SoundSrc.cpp @@ -1053,6 +1053,8 @@ TEXT("Broom/broom_up_8.wav"), #pragma region UI TEXT("UI/Logo_Intro.wav"), + TEXT("UI/Slot_Hover.wav"), + TEXT("UI/Equip_Spell.wav"), #pragma endregion diff --git a/Jusin154_Team3D/Engine/Private/Unit.cpp b/Jusin154_Team3D/Engine/Private/Unit.cpp index 9c599d218..bfdb98989 100644 --- a/Jusin154_Team3D/Engine/Private/Unit.cpp +++ b/Jusin154_Team3D/Engine/Private/Unit.cpp @@ -133,17 +133,28 @@ _int CUnit::Get_TextID() return m_iCurrentFlow; } +_int CUnit::Get_NextID() +{ + return m_iCurrentNext; +} + +void CUnit::Set_TextID(_int ID) +{ +} + void CUnit::Set_NextID(_int ID) { + m_iCurrentNext = ID; } void CUnit::Set_Flow(_int Index, _float fTime) { + m_iCurrentFlow = Index; } _int CUnit::Get_Flow() { - return _int(); + return m_iCurrentFlow; } HRESULT CUnit::Ready_Components(void *pArg) diff --git a/Jusin154_Team3D/Engine/Public/SoundSrc.h b/Jusin154_Team3D/Engine/Public/SoundSrc.h index 46cf30e4a..56fb7210e 100644 --- a/Jusin154_Team3D/Engine/Public/SoundSrc.h +++ b/Jusin154_Team3D/Engine/Public/SoundSrc.h @@ -1056,6 +1056,8 @@ RANROK_FOOTSTEP_21, #pragma region UI LOGO_INTRO, + SLOT_HOVER, + EQUIP_SPELL, #pragma endregion diff --git a/Jusin154_Team3D/Engine/Public/Unit.h b/Jusin154_Team3D/Engine/Public/Unit.h index 7013f4edf..55625231a 100644 --- a/Jusin154_Team3D/Engine/Public/Unit.h +++ b/Jusin154_Team3D/Engine/Public/Unit.h @@ -61,6 +61,8 @@ class ENGINE_DLL CUnit abstract : public CContainerObject virtual _wstring Get_NpcName(); virtual _int Get_NpcID(); virtual _int Get_TextID(); + virtual _int Get_NextID(); + virtual void Set_TextID(_int ID); virtual void Set_NextID(_int ID); virtual void Set_Flow(_int Index, _float fTime); virtual _int Get_Flow(); @@ -99,7 +101,7 @@ class ENGINE_DLL CUnit abstract : public CContainerObject _int m_eHitType = {}; _int m_iCurrentFlow = 0; - + _int m_iCurrentNext = 0; private: virtual void Add_FSM() {}; virtual void Set_FSM() {};