From 0d15bc47a7afb6f605737156dedcc039620045bb Mon Sep 17 00:00:00 2001 From: hyunbin14 Date: Fri, 2 Jan 2026 11:39:07 +0900 Subject: [PATCH] =?UTF-8?q?[Fix]=20=EB=9E=80=EB=A1=9D=20=ED=8F=AC=EC=A6=88?= =?UTF-8?q?=20=EC=9C=84=EC=B9=98=20=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8=20?= =?UTF-8?q?[Fix]=20BroomRaceManager=20=EB=A0=88=EC=9D=B4=EC=84=9C=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80=20=EB=A1=9C=EC=A7=81=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Client/Private/BroomRaceManager.cpp | 43 +++-- .../Client/Private/BroomRacerAI.cpp | 12 +- .../Client/Private/Broom_States.cpp | 4 +- .../Client/Private/Level_GamePlay.cpp | 28 +-- Jusin154_Team3D/Client/Private/Loader.cpp | 6 +- Jusin154_Team3D/Client/Private/Monster.cpp | 6 +- Jusin154_Team3D/Client/Private/Player.cpp | 54 +++--- Jusin154_Team3D/Client/Private/PlayerRobe.cpp | 4 +- .../Client/Private/Player_States.cpp | 175 ++++++++++++------ Jusin154_Team3D/Client/Private/Ranrok.cpp | 142 ++++++++------ .../Client/Private/Ranrok_States.cpp | 19 +- Jusin154_Team3D/Client/Public/Broom.h | 1 + Jusin154_Team3D/Client/Public/BroomRacerAI.h | 2 - Jusin154_Team3D/Client/Public/Client_Macro.h | 1 + Jusin154_Team3D/Client/Public/Monster.h | 1 + Jusin154_Team3D/Client/Public/Player.h | 10 +- Jusin154_Team3D/Client/Public/Ranrok.h | 2 +- .../Resources/Data/RanrokPos/RanrokPos.xml | 116 ++++++++---- .../BLDG_HogsheadInn/Meshes/Temp.txt | 0 .../Hogsmeade/BLDG_Potions/Meshes/Temp.txt | 0 .../SK_GOB_M_Assassin_Master_Tumble.bin | 3 + .../SK_GOB_M_Assassin_Master_Tumble.fbx | 3 + .../ShaderFiles/Shader_Mesh_Compute.hlsl | 2 +- .../Editor/Private/Camera_Debug.cpp | 8 + .../Editor/Private/Level_ObjectViewer.cpp | 12 +- .../Editor/Private/Loader_ObjectViewer.cpp | 5 + Jusin154_Team3D/Editor/Private/Player.cpp | 10 +- .../ShaderFiles/Shader_Mesh_Compute.hlsl | 2 +- Jusin154_Team3D/Engine/Private/Unit.cpp | 5 + Jusin154_Team3D/Engine/Public/Unit.h | 1 + 30 files changed, 426 insertions(+), 251 deletions(-) create mode 100644 Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_HogsheadInn/Meshes/Temp.txt create mode 100644 Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Potions/Meshes/Temp.txt create mode 100644 Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.bin create mode 100644 Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.fbx diff --git a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp index 9989ee920..f381a9d13 100644 --- a/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp +++ b/Jusin154_Team3D/Client/Private/BroomRaceManager.cpp @@ -78,8 +78,6 @@ void CBroomRaceManager::Update(_float fTimeDelta) } } - - #ifdef _DEBUG Describe_Entity(); #endif // _DEBUG @@ -162,16 +160,25 @@ void CBroomRaceManager::Describe_Entity() { if (GUI::Button("Add Race Ring")) { - if (FAILED(Load_RaceRing())) - { - MSG_BOX("Failed Load RaceRing"); - } + } if (GUI::Button("Race Start")) { m_eRaceState = ENUM_CLASS(RACE_STATE::READY); const _float SPAWN_DISTANCE = 80.f; + if (FAILED(Load_RaceRing())) + { + MSG_BOX("Failed Load RaceRing"); + } + + for (_uint i = 0; i < 3; i++) + { + if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_RACERAI, this))) + return; + } + m_pGameInstance->Get_Layer(NEXT_LEVEL, LAYER_PLAYER)->Get_Object()->Set_RaceInfo(); + for (auto& racer : m_Racers) { CTransform* pRingTransform = @@ -185,20 +192,20 @@ void CBroomRaceManager::Describe_Entity() if (racer.pAI) { - CTransform* pBroomTransform = - racer.pAI->Get_Broom()->Get_Component(); + CTransform* pTransform = + racer.pAI->Get_Component(); _float fRand = m_pGameInstance->Real_Random_Float(-10.f, 10.f); - spawnPos.m128_f32[2] += fRand; + spawnPos.m128_f32[0] += fRand; + + pTransform->Set_State(STATE::POSITION, spawnPos); + pTransform->LookAt(pRingTransform->Get_State(STATE::POSITION)); - pBroomTransform->Set_State(STATE::POSITION, spawnPos); - pBroomTransform->LookAt(pRingTransform->Get_State(STATE::POSITION)); racer.pAI->Get_Broom()->Set_Move(false); } else if (racer.pRacer) { CTransform* pTransform = racer.pRacer->Get_Component(); - spawnPos.m128_f32[1] -= 2.f; pTransform->Set_State(STATE::POSITION, spawnPos); pTransform->LookAt(pRingTransform->Get_State(STATE::POSITION)); racer.pRacer->Get_Component()->Change_State(FSMSTATE::BROOM_RIDE); @@ -337,12 +344,12 @@ void CBroomRaceManager::SetTargetRing(CGameObject* pRacer) { if (racer.pAI) { - if (racer.curRing == m_pRaceRings.size() - 1) + racer.pAI->Set_RaceRing(m_pRaceRings[racer.curRing]); + if (racer.curRing == m_pRaceRings.size()) { racer.pAI->Get_Broom()->Set_Hover(true); racer.pAI->Get_Broom()->Set_Move(false); } - racer.pAI->Set_RaceRing(m_pRaceRings[racer.curRing]); } } } @@ -350,16 +357,18 @@ void CBroomRaceManager::SetTargetRing(CGameObject* pRacer) { if (racer.pRacer == pRacer) { - if (racer.curRing == m_pRaceRings.size() - 1) + racer.pRacer->Set_RaceRing(m_pRaceRings[racer.curRing]); + if (racer.curRing == m_pRaceRings.size()) { racer.pRacer->Get_Broom()->Set_Hover(true); racer.pRacer->Get_Broom()->Set_Move(false); + } - racer.pRacer->Set_RaceRing(m_pRaceRings[racer.curRing]); m_pInfoInstance->Event_CallBack(TEXT("CurrentRing")); + m_iLastRing++; } } - m_iLastRing++; + } } diff --git a/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp b/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp index b4252b716..68701f7d6 100644 --- a/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp +++ b/Jusin154_Team3D/Client/Private/BroomRacerAI.cpp @@ -59,7 +59,7 @@ HRESULT CBroomRacerAI::Initialize(void* pArg) Add_FSM(); - Load_AnimXML("../Bin/Resources/Data/AnimList/RacerAI.xml"); + Load_AnimXML("../Bin/Resources/Data/AnimList/BroomRacerAI.xml"); { CFSM::FSM_DESC FSMDesc{}; @@ -90,13 +90,13 @@ HRESULT CBroomRacerAI::Initialize(void* pArg) m_pBroomRaceManager = static_cast(pArg); - /*CBroomRaceManager::RacerInfo Info; + CBroomRaceManager::RacerInfo Info; Info.pAI = this; Info.curRing = 0; Info.prevPos = Get_WorldPostion(); - m_pBroomRaceManager->Push_BroomRacer(Info);*/ + m_pBroomRaceManager->Push_BroomRacer(Info); m_LaneOffsetX = m_pGameInstance->Real_Random_Float(-3.f, 3.f); m_LaneOffsetY = m_pGameInstance->Real_Random_Float(-3.f, 3.f); @@ -750,12 +750,12 @@ void CBroomRacerAI::Set_Input(_float fTimeDelta) InputDesc.Y = 0.f; InputDesc.Z = 0.f; - /*if (m_bMove) - {*/ + if (m_pBroom->Get_Move()) + { InputDesc.Z = 1.f; InputDesc.X = targetX*m_TurnGain; InputDesc.Y = targetY*m_HeightGain; - //} + } InputDesc.bHoverToggle = (m_pBroomRaceManager->Get_RaceState() != ENUM_CLASS(CBroomRaceManager::RACE_STATE::RACING)); diff --git a/Jusin154_Team3D/Client/Private/Broom_States.cpp b/Jusin154_Team3D/Client/Private/Broom_States.cpp index 7b7ea8f28..91624bc24 100644 --- a/Jusin154_Team3D/Client/Private/Broom_States.cpp +++ b/Jusin154_Team3D/Client/Private/Broom_States.cpp @@ -205,12 +205,10 @@ HRESULT CBroom::Behavior_Broom_HoverExitCheck(_float fTimeDelta) m_pTransformCom->Go_LerpStraight(m_fSpeed, fTimeDelta); pairAnimInfo = m_Animation[STATEANIM::BROOM_HOVER_STOP_B]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); return S_OK; } - - - if (m_bHoverToggle) { _float fTargetVertSpeed = 0.f; diff --git a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp index b57f6525d..e4d274489 100644 --- a/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp +++ b/Jusin154_Team3D/Client/Private/Level_GamePlay.cpp @@ -98,9 +98,9 @@ HRESULT CLevel_GamePlay::Initialize(void* pArg) // return E_FAIL; //} - if (FAILED(Ready_Layer_ReparoObject(TEXT("Layer_ReparoObject")))) { - return E_FAIL; - } + //if (FAILED(Ready_Layer_ReparoObject(TEXT("Layer_ReparoObject")))) { + // return E_FAIL; + //} if (FAILED(Ready_Layer_SkyBox(TEXT("Layer_SkyBox")))) { return E_FAIL; @@ -108,12 +108,12 @@ HRESULT CLevel_GamePlay::Initialize(void* pArg) if (FAILED(Ready_Layer_Player(LAYER_PLAYER))) { return E_FAIL; } - if (FAILED(Ready_Layer_BroomRacerAI(TEXT("Layer_BroomRacerAI")))) { + /*if (FAILED(Ready_Layer_BroomRacerAI(TEXT("Layer_BroomRacerAI")))) { return E_FAIL; - } - if (FAILED(Ready_Layer_Monster())) { - return E_FAIL; - } + }*/ + //if (FAILED(Ready_Layer_Monster())) { + // return E_FAIL; + //} if(FAILED(m_pInfoInstance->Late_Initialize())) return E_FAIL; @@ -329,9 +329,9 @@ HRESULT CLevel_GamePlay::Ready_Background() isReady_Hogwart = true; #endif // gimch #ifdef Bin - isReady_Background = false; - isReady_Hogsmeade = false; - isReady_Hogwart = false; + isReady_Background = true; + isReady_Hogsmeade = true; + isReady_Hogwart = true; #endif // #ifdef 진우 isReady_Background = false; @@ -695,7 +695,7 @@ HRESULT CLevel_GamePlay::Ready_Layer_Player(const _wstring& strLayerTag) #endif // #ifdef Bin - + isLoad_NPC = false; #endif // Bin #endif // _DEBUG @@ -724,7 +724,7 @@ HRESULT CLevel_GamePlay::Ready_Layer_Player(const _wstring& strLayerTag) HRESULT CLevel_GamePlay::Ready_Layer_BroomRacerAI(const _wstring& strLayerTag) { #ifdef Bin - for (_uint i = 0; i < 0; ++i) { + for (_uint i = 0; i < 5; ++i) { if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, m_pBroomRaceManager))) { return E_FAIL; } @@ -740,7 +740,7 @@ HRESULT CLevel_GamePlay::Ready_Layer_Item(const _wstring& strLayerTag) HRESULT CLevel_GamePlay::Ready_Layer_RaceRing(const _wstring& strLayerTag) { - for (_uint i = 0; i < 1; ++i) { + for (_uint i = 0; i < 10; ++i) { CRaceRing::RACERING_DESC RaceRingDesc{}; RaceRingDesc.pBroomRaceManager = m_pBroomRaceManager; diff --git a/Jusin154_Team3D/Client/Private/Loader.cpp b/Jusin154_Team3D/Client/Private/Loader.cpp index b53fc3c2b..79b8ad3f6 100644 --- a/Jusin154_Team3D/Client/Private/Loader.cpp +++ b/Jusin154_Team3D/Client/Private/Loader.cpp @@ -396,9 +396,9 @@ HRESULT CLoader::Loading_For_GamePlay() isLoad_UI_SEQUANTIAL = false; #endif // #ifdef Bin - isLoad_Background = false; - isLoad_Hogwart = false; - isLoad_UI_SEQUANTIAL = false; + isLoad_Background = true; + isLoad_Hogwart = true; + isLoad_UI_SEQUANTIAL = true; #endif // Bin #endif // _DEBUG diff --git a/Jusin154_Team3D/Client/Private/Monster.cpp b/Jusin154_Team3D/Client/Private/Monster.cpp index 24148ddf9..96d89955d 100644 --- a/Jusin154_Team3D/Client/Private/Monster.cpp +++ b/Jusin154_Team3D/Client/Private/Monster.cpp @@ -180,7 +180,6 @@ _float2 CMonster::Get_Hp() { return { m_pStat->Get_Stat().fCurrentHp, m_pStat->Get_Stat().fMaxHp }; } - CStat* CMonster::Get_Stat() { return m_pStat; @@ -191,6 +190,11 @@ const _float4x4* CMonster::Get_HeadMatrix() return m_pModelCom->Get_BoneMatrixPtr("Head"); } +float CMonster::Get_HpRatio() +{ + return Get_Hp().x / Get_Hp().y; +} + void CMonster::CameraShake(_float ClampValue, _float Min, _float Max, _float Time) { CPlayer* pPlayer = static_cast(m_pInfoInstance->Get_NearestPlayerAlly(Get_WorldPostion()).first); diff --git a/Jusin154_Team3D/Client/Private/Player.cpp b/Jusin154_Team3D/Client/Private/Player.cpp index 7cfa775c4..d017f1b2b 100644 --- a/Jusin154_Team3D/Client/Private/Player.cpp +++ b/Jusin154_Team3D/Client/Private/Player.cpp @@ -93,17 +93,6 @@ HRESULT CPlayer::Initialize(void* pArg) m_pTransformCom->Rotation(vRotQ); m_pBroomRaceManager = pDesc->pBroomRaceManager; - - /*if (m_pBroomRaceManager) - { - CBroomRaceManager::RacerInfo Info; - - Info.pRacer = this; - Info.curRing = 0; - Info.prevPos = Get_WorldPostion(); - - m_pBroomRaceManager->Push_BroomRacer(Info); - }*/ } #ifdef _DEBUG @@ -121,7 +110,7 @@ HRESULT CPlayer::Initialize(void* pArg) m_bAI = false; - //XMLoadFloat4x4(m_pBroomModel->Get_BoneMatrixPtr("broomSocket")); + XMLoadFloat4x4(m_pBroomModel->Get_BoneMatrixPtr("broomSocket")); m_pModelCom->Set_Temp(true); @@ -219,20 +208,6 @@ void CPlayer::Late_Update(_float fTimeDelta) m_pTransformCom->Set_State(STATE::UP, up); m_pTransformCom->Set_State(STATE::LOOK, look); //////////////////////////////////////////////////////////////////////////// - - - if (nullptr == m_pRobePart) { - { - CPlayerRobe::PlayerRobe_DESC Desc{}; - Desc.pModel = m_pModelCom; - Desc.pParentTransform = m_pTransformCom; - Desc.pSocketMatrix = m_pModelCom->Get_BoneMatrixPtr("Hips_Cloth"); - if (FAILED(Add_PartObject("RobePart", g_iStaticLevel, &m_pRobePart, &Desc))) { - assert(false); - } - } - } - } @@ -419,6 +394,20 @@ void CPlayer::Set_RaceRing(CRaceRing* pRaceRing) SAFE_ADDREF(m_pRaceRing); } +void CPlayer::Set_RaceInfo() +{ + if (m_pBroomRaceManager) + { + CBroomRaceManager::RacerInfo Info; + + Info.pRacer = this; + Info.curRing = 0; + Info.prevPos = Get_WorldPostion(); + + m_pBroomRaceManager->Push_BroomRacer(Info); + } +} + HRESULT CPlayer::Ready_Components() { CTransform::TRANSFORM_DESC Desc = {}; @@ -530,6 +519,19 @@ HRESULT CPlayer::Ready_Parts() return E_FAIL; } + //m_pModelCom->Play_Animation() + //XMLoadFloat4x4(m_pModelCom->Get_BoneMatrixPtr("broomSocket")); + { + CPlayerRobe::PlayerRobe_DESC Desc{}; + Desc.pModel = m_pModelCom; + Desc.pParentTransform = m_pTransformCom; + Desc.pSocketMatrix = m_pModelCom->Get_BoneMatrixPtr("Hips_Cloth"); + if (FAILED(Add_PartObject("RobePart", g_iStaticLevel, &m_pRobePart, &Desc))) { + assert(false); + } + } + + return S_OK; } diff --git a/Jusin154_Team3D/Client/Private/PlayerRobe.cpp b/Jusin154_Team3D/Client/Private/PlayerRobe.cpp index 8c8849385..e232635cf 100644 --- a/Jusin154_Team3D/Client/Private/PlayerRobe.cpp +++ b/Jusin154_Team3D/Client/Private/PlayerRobe.cpp @@ -47,7 +47,9 @@ void CPlayerRobe::Late_Update(_float fTimeDelta) HRESULT CPlayerRobe::Render() { #ifdef _DEBUG - Render_BonePhysX(); +#ifdef 기무리 + //Render_BonePhysX(); +#endif // 기무리 #endif // _DEBUG return S_OK; } diff --git a/Jusin154_Team3D/Client/Private/Player_States.cpp b/Jusin154_Team3D/Client/Private/Player_States.cpp index 7ab1a8200..f783cfbcc 100644 --- a/Jusin154_Team3D/Client/Private/Player_States.cpp +++ b/Jusin154_Team3D/Client/Private/Player_States.cpp @@ -344,6 +344,7 @@ HRESULT CPlayer::Behavior_IdleExitCheck(_float fTimeDelta) void CPlayer::Behavior_IdleExit() { m_pFSM->Disable_State(FSMSTATE::IDLE | FSMSTATE::IDLE_TURN); + Reset_Event(); } void CPlayer::Behavior_MoveEnter() @@ -781,6 +782,7 @@ HRESULT CPlayer::Behavior_MoveExitCheck(_float fTimeDelta) void CPlayer::Behavior_MoveExit() { m_pFSM->Disable_State(FSMSTATE::MOVE | FSMSTATE::SPRINT | FSMSTATE::JOG | FSMSTATE::WALK | FSMSTATE::STOP); + Reset_Event(); } void CPlayer::Behavior_JumpEnter() @@ -831,6 +833,7 @@ HRESULT CPlayer::Behavior_JumpExitCheck() void CPlayer::Behavior_JumpExit() { m_pFSM->Disable_State(FSMSTATE::JUMP); + Reset_Event(); } void CPlayer::Behavior_LandEnter() @@ -884,6 +887,7 @@ void CPlayer::Behavior_LandExit() m_pFSM->Disable_State(FSMSTATE::LAND); m_pCharacter_Controller->Set_GravityAmount(m_fOriginGravityAmount); m_fGravityAmount = 0.f; + Reset_Event(); } void CPlayer::Behavior_FallEnter() @@ -906,6 +910,7 @@ HRESULT CPlayer::Behavior_FallExitCheck(_float fTimeDelta) void CPlayer::Behavior_FallExit() { m_pFSM->Disable_State(FSMSTATE::FALL); + Reset_Event(); } void CPlayer::Behavior_DodgeEnter() @@ -943,6 +948,7 @@ HRESULT CPlayer::Behavior_DodgeExitCheck(_float fTimeDelta) void CPlayer::Behavior_DodgeExit() { m_pFSM->Disable_State(FSMSTATE::DODGE); + Reset_Event(); } void CPlayer::Behavior_BlinkEnter() @@ -1001,6 +1007,7 @@ void CPlayer::Behavior_BlinkExit() { m_pFSM->Disable_State(FSMSTATE::BLINK); m_fBlinkTime = 0.f; + Reset_Event(); } void CPlayer::Behavior_SlideEnter() @@ -1053,6 +1060,7 @@ void CPlayer::Behavior_SlideExit() { m_pFSM->Disable_State(FSMSTATE::SLIDE); m_fSlideSpeed = 0.f; + Reset_Event(); } void CPlayer::Behavior_CombatEnter() @@ -1062,64 +1070,71 @@ void CPlayer::Behavior_CombatEnter() if (m_pModelCom->Get_SecondAnimIndex() == m_Animation[STATEANIM::LUMOS].first) { - m_pModelCom->Set_Second_AnimationIndex(ENUM_CLASS(BLEND_BONE::SHOULDER_R) ,-1) ; + m_pModelCom->Set_Second_AnimationIndex(ENUM_CLASS(BLEND_BONE::SHOULDER_R), -1); m_eSpell = ENUM_CLASS(SKILL_TYPE::END); } - if (m_pGameInstance->Key_Down(DIK_R)) { - m_pFSM->Enable_State(FSMSTATE::SKILL); - pairAnimInfo = m_Animation[STATEANIM::SKILL]; - m_pEffectPool->Use_Skill(SKILL_TYPE::REVELIO, this); - } - else if (m_pGameInstance->Key_Down(DIK_Q)) { - m_pFSM->Change_State(FSMSTATE::SHIELD); - return; - } - else if (m_pGameInstance->Mouse_Down(DIM_LBUTTON)) { - m_pFSM->Change_State(FSMSTATE::LIGHT_ATTACK); - return; - } - else if (SUCCEEDED(InputSpell())) { - m_pFSM->Change_State(FSMSTATE::SPELL); - return; - } - else if (m_pGameInstance->Key_Down(DIK_V)) { - m_pFSM->Enable_State(FSMSTATE::MAPHELP); - pairAnimInfo = m_Animation[STATEANIM::MAPHELP]; - } - else if (m_pGameInstance->Key_Down(DIK_X)) { - m_pFSM->Change_State(FSMSTATE::ANCIENT_SPELL); - return; - } - else if (m_pGameInstance->Key_Down(DIK_Z)) { - - if (nullptr != m_LockOnInfo.pInteractive) { - m_pFSM->Enable_State(FSMSTATE::ANCIENT_THROW); - pairAnimInfo = m_Animation[STATEANIM::ANCIENT_THROW]; - m_pGrapInteractive = m_LockOnInfo.pInteractive; - SAFE_ADDREF(m_pGrapInteractive); - m_pGrapInteractive->Set_KinematicFlag(true); - m_vGrapInteratableLerp.x = 0.f; + if (SUCCEEDED(InputAction()) || SUCCEEDED(InputSpell())) + { + if (m_pGameInstance->Key_Down(DIK_R)) { + m_pFSM->Enable_State(FSMSTATE::SKILL); + pairAnimInfo = m_Animation[STATEANIM::SKILL]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + m_pEffectPool->Use_Skill(SKILL_TYPE::REVELIO, this); } - else { + else if (m_pGameInstance->Key_Down(DIK_Q)) { + + m_pFSM->Change_State(FSMSTATE::SHIELD); return; } + else if (m_pGameInstance->Mouse_Down(DIM_LBUTTON)) { + m_pFSM->Change_State(FSMSTATE::LIGHT_ATTACK); + return; + } + else if (SUCCEEDED(InputSpell())) { + m_pFSM->Change_State(FSMSTATE::SPELL); + return; + } + else if (m_pGameInstance->Key_Down(DIK_V)) { + m_pFSM->Enable_State(FSMSTATE::MAPHELP); + pairAnimInfo = m_Animation[STATEANIM::MAPHELP]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + } + else if (m_pGameInstance->Key_Down(DIK_X)) { + m_pFSM->Change_State(FSMSTATE::ANCIENT_SPELL); + return; + } + else if (m_pGameInstance->Key_Down(DIK_Z)) { - Add_Event(pairAnimInfo.first, - [this]() { m_bLookAt = true; }, - 0.12f); + if (nullptr != m_LockOnInfo.pInteractive) { + m_pFSM->Enable_State(FSMSTATE::ANCIENT_THROW); + pairAnimInfo = m_Animation[STATEANIM::ANCIENT_THROW]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + m_pGrapInteractive = m_LockOnInfo.pInteractive; + SAFE_ADDREF(m_pGrapInteractive); + m_pGrapInteractive->Set_KinematicFlag(true); + m_vGrapInteratableLerp.x = 0.f; + } + else { + return; + } - Add_Event(pairAnimInfo.first, - [this]() { Throwing_Interactive(); }, - 0.2f); + Add_Event(pairAnimInfo.first, + [this]() { m_bLookAt = true; }, + 0.12f); - Add_Event(pairAnimInfo.first, - [this]() { - m_pGameInstance->SlowMotion(0.1f, 0.35f); - }, - 0.1f); + Add_Event(pairAnimInfo.first, + [this]() { Throwing_Interactive(); }, + 0.2f); + + Add_Event(pairAnimInfo.first, + [this]() { + m_pGameInstance->SlowMotion(0.1f, 0.35f); + }, + 0.1f); + } } - m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + } HRESULT CPlayer::Behavior_CombatExitCheck() @@ -1209,6 +1224,7 @@ void CPlayer::Behavior_CombatExit() { m_pFSM->Disable_State(FSMSTATE::COMBAT | FSMSTATE::SKILL | FSMSTATE::MAPHELP | FSMSTATE::ANCIENT_THROW); + Reset_Event(); } void CPlayer::Behavior_LightAttackEnter() @@ -1391,6 +1407,7 @@ void CPlayer::Behavior_LightAttackExit() { m_pFSM->Disable_State(FSMSTATE::LIGHT_ATTACK); m_pModelCom->Set_BlendDuration(0.3f); + Reset_Event(); m_bLookAt = false; } @@ -1422,12 +1439,21 @@ void CPlayer::Behavior_SpellEnter() _vector vCross = XMVector3Cross(vLook, vCameraLook); _float Cross = XMVectorGetY(vCross); - if (Degree <= 45.f) + if (Degree <= 30.f) { pairAnimInfo = m_Animation[STATEANIM::SPELL]; fRatio = 0.2f; } - else if (Degree <= 85.f) + else if (Degree <= 60.f) + { + pairAnimInfo = m_Animation[STATEANIM::SPELL]; + fRatio = 0.2f; + Add_Event(m_Animation[STATEANIM::SPELL].first, + [this]() {m_bLookAt = true; + }, + 0.01f); + } + else if (Degree <= 120.f) { if (Cross < 0.f) { @@ -1441,7 +1467,10 @@ void CPlayer::Behavior_SpellEnter() pairAnimInfo = m_Animation[STATEANIM::SPELL_90_L2]; break; } - + Add_Event(pairAnimInfo.first, + [this]() {m_bLookAt = true; + }, + 0.95f); fRatio = 0.17f; } else { @@ -1458,8 +1487,14 @@ void CPlayer::Behavior_SpellEnter() break; case 1: pairAnimInfo = m_Animation[STATEANIM::SPELL_90_R]; - fRatio = 0.17f; - fAnimSpeed = 1.3f; + fRatio = 0.14f; + if (Degree >= 120.f) + { + Add_Event(pairAnimInfo.first, + [this]() {m_bLookAt = true; + }, + 0.01f); + } break; } } @@ -1467,6 +1502,10 @@ void CPlayer::Behavior_SpellEnter() else { pairAnimInfo = m_Animation[STATEANIM::SPELL_180_R]; fRatio = 0.23f; + Add_Event(pairAnimInfo.first, + [this]() {m_bLookAt = true; + }, + 0.01f); } m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second, 1.f, true, fAnimSpeed); @@ -1546,15 +1585,19 @@ HRESULT CPlayer::Behavior_SpellExitCheck() } else if (SUCCEEDED(InputAction()) || SUCCEEDED(InputSpell())) { - if (fRatio >= 0.5f) - { - m_pFSM->Change_State(FSMSTATE::COMBAT); - return E_FAIL; + if (iIndex != m_Animation[STATEANIM::AVADA_KEDAVRA].first) { + if (fRatio >= 0.5f) + { + m_pFSM->Change_State(FSMSTATE::COMBAT); + return E_FAIL; + } + return S_OK; } - return S_OK; } } - else if (m_pGameInstance->Key_Down(DIK_Q)) { + else if (iIndex != m_Animation[STATEANIM::AVADA_KEDAVRA].first) + { + if (m_pGameInstance->Key_Down(DIK_Q)) { m_pFSM->Change_State(FSMSTATE::SHIELD); return E_FAIL; } @@ -1575,6 +1618,8 @@ HRESULT CPlayer::Behavior_SpellExitCheck() } return S_OK; } + } + Play_SpellHitAnim(); @@ -1604,10 +1649,11 @@ HRESULT CPlayer::Behavior_SpellExitCheck() void CPlayer::Behavior_SpellExit() { m_pFSM->Disable_State(FSMSTATE::SPELL); - m_pModelCom->Set_BlendDuration(0.3f); + Reset_Event(); m_bLookAt = false; m_bSpellHit = false; + } void CPlayer::Behavior_AncientSpellEnter() @@ -1663,6 +1709,7 @@ HRESULT CPlayer::Behavior_AncientSpellExitCheck() void CPlayer::Behavior_AncientSpellExit() { m_pFSM->Disable_State(FSMSTATE::ANCIENT_SPELL); + Reset_Event(); m_bLookAt = false; } @@ -1798,6 +1845,7 @@ void CPlayer::Behavior_ShieldExit() { m_pFSM->Disable_State(FSMSTATE::SHIELD); m_pFSM->Disable_State(FSMSTATE::PARRY); + Reset_Event(); m_bShield = false; m_bLookAt = false; } @@ -1930,6 +1978,7 @@ HRESULT CPlayer::Behavior_HitExitCheck() void CPlayer::Behavior_HitExit() { m_pFSM->Disable_State(FSMSTATE::HIT); + Reset_Event(); m_bLookAt = false; } @@ -1978,6 +2027,7 @@ HRESULT CPlayer::Behavior_Broom_RideExitCheck(_float fTimeDelta) void CPlayer::Behavior_Broom_RideExit() { m_pFSM->Disable_State(FSMSTATE::BROOM_RIDE); + Reset_Event(); } void CPlayer::Behavior_Broom_Ride_MoveEnter() @@ -2007,6 +2057,7 @@ HRESULT CPlayer::Behavior_Broom_Ride_MoveExitCheck(_float fTimeDelta) void CPlayer::Behavior_Broom_Ride_MoveExit() { m_pFSM->Disable_State(FSMSTATE::BROOM_RIDE_MOVE); + Reset_Event(); } void CPlayer::Behavior_Broom_HoverEnter() @@ -2153,6 +2204,7 @@ void CPlayer::Behavior_Broom_HoverExit() void CPlayer::Behavior_Broom_FlyEnter() { m_pFSM->Enable_State(FSMSTATE::FLY); + Reset_Event(); m_fNeutralTime = 0.f; m_fNoInputTime = 0.f; } @@ -2344,6 +2396,7 @@ HRESULT CPlayer::Behavior_Broom_FlyExitCheck(_float fTimeDelta) void CPlayer::Behavior_Broom_FlyExit() { m_pFSM->Disable_State(FSMSTATE::FLY); + Reset_Event(); } void CPlayer::Behavior_Broom_TurboFlyEnter() @@ -2493,6 +2546,7 @@ HRESULT CPlayer::Behavior_Broom_TurboFlyExitCheck(_float fTimeDelta) void CPlayer::Behavior_Broom_TurboFlyExit() { m_pFSM->Disable_State(FSMSTATE::TURBOFLY); + Reset_Event(); } void CPlayer::Behavior_Broom_DismountEnter() @@ -2552,6 +2606,7 @@ HRESULT CPlayer::Behavior_Broom_DismountExitCheck(_float fTimeDelta) void CPlayer::Behavior_Broom_DismountExit() { m_pFSM->Disable_State(FSMSTATE::BROOM_DISMOUNT); + Reset_Event(); } void CPlayer::Player_InterpTurn(_float fTimeDelta) diff --git a/Jusin154_Team3D/Client/Private/Ranrok.cpp b/Jusin154_Team3D/Client/Private/Ranrok.cpp index c643077f3..8c859c22c 100644 --- a/Jusin154_Team3D/Client/Private/Ranrok.cpp +++ b/Jusin154_Team3D/Client/Private/Ranrok.cpp @@ -67,8 +67,8 @@ HRESULT CRanrok::Initialize(void* pArg) if (NEXT_LEVEL == ENUM_CLASS(LEVEL::FIELD)) { - m_pCharacter_Controller->Set_Position(XMVectorSet(58.990f, 71.321f, 241.628f, 1.f)); - m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(58.990f, 71.321f, 241.628f, 1.f)); + m_pCharacter_Controller->Set_Position(XMVectorSet(75.550f, 33.734f, 164.013f, 1.f)); + m_pTransformCom->Set_State(STATE::POSITION, XMVectorSet(75.550f, 33.734f, 164.013f, 1.f)); } else { @@ -250,7 +250,7 @@ void CRanrok::OnCollision(CGameObject* pOther, void* pDesc) ON_COLLISION_INFO* CollisionDesc = static_cast(pDesc); - m_DamageInfo.vTarget_Pos = m_pCharacter_Controller->Get_HeadPosition(); + //m_DamageInfo.vTarget_Pos = m_pCharacter_Controller->Get_HeadPosition(); CEffect_Container* pEffect_Container = dynamic_cast(pOther); @@ -302,17 +302,32 @@ void CRanrok::OnCollision(CGameObject* pOther, void* pDesc) } - m_DamageInfo.fDamage = damagePair.first; - m_pInfoInstance->Event_CallBack(TEXT("Monster_Hit"), &m_DamageInfo); + /*m_DamageInfo.fDamage = damagePair.first; + m_pInfoInstance->Event_CallBack(TEXT("Monster_Hit"), &m_DamageInfo);*/ if (0 == damagePair.second) { m_pFSM->Change_State(FSMSTATE::DEAD); return; } - if (damagePair.second <= Get_Hp().y / 2.f && m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_AIR)) + + + if (Get_HpRatio() == 0.85f) { - m_pFSM->Change_State(FSMSTATE::LAND); + m_pFSM->Change_State(FSMSTATE::TUCKED); return; } + else if (Get_HpRatio() == 0.7f) { + m_pFSM->Change_State(FSMSTATE::TUCKED); + return; + } + else if (Get_HpRatio() == 0.5f) + { + m_ePhase = ENUM_CLASS(RANROK_PHASE::PHASE_GROUND); + m_pFSM->Change_State(FSMSTATE::TUCKED); + return; + } + + + m_pFSM->Change_State(FSMSTATE::HIT); } @@ -627,8 +642,9 @@ void CRanrok::MoveTo(_float fTimeDelta) _vector toTarget = Target - CurPos; _float fDist = XMVectorGetX(XMVector3Length(toTarget)); + GUI::Text("Dist %.2f", fDist); - if (m_iCurrentPoint + 1 < m_Points[m_iCurrentFlow].size() && fDist < 30.f) + if (m_iCurrentPoint + 1 < m_Points[m_iCurrentFlow].size() && fDist < 15.f) { NextTarget = m_Points[m_iCurrentFlow][m_iCurrentPoint + 1]; } @@ -638,7 +654,7 @@ void CRanrok::MoveTo(_float fTimeDelta) if (m_iCurrentPoint == m_Points[m_iCurrentFlow].size() - 1) { - if (fDist < 10.f) + if (fDist < 5.f) { if (m_iCurrentPoint == m_Points[m_iCurrentFlow].size() - 1) { @@ -650,7 +666,7 @@ void CRanrok::MoveTo(_float fTimeDelta) return; } } - else if (fDist < 20.f) + else if (fDist < 10.f) { if (m_iCurrentPoint == m_Points[m_iCurrentFlow].size() - 1) { @@ -664,7 +680,7 @@ void CRanrok::MoveTo(_float fTimeDelta) _vector LerpTarget = XMVectorLerp(Target, NextTarget, 0.5f); - m_pTransformCom->LookAt_Lerp(LerpTarget, fTimeDelta,2.5f); + m_pTransformCom->LookAt_Lerp(LerpTarget, fTimeDelta,5.f); m_pCharacter_Controller->Set_Position(CurPos + vLook * m_fTuckedSpeed * fTimeDelta); } @@ -778,55 +794,65 @@ void CRanrok::Describe_Entity() m_pCharacter_Controller->Set_Position(XMVectorSetW(XMLoadFloat3(&Pos), 1.f)); } - GUI::SameLine(); - - if (GUI::SmallButton("Copy")) - { - char buf[128]; - sprintf_s(buf, "", Pos.x, Pos.y, Pos.z); - - GUI::SetClipboardText(buf); - - m_Points[0].push_back(XMVectorSet(Pos.x, Pos.y, Pos.z, 1.f)); - } - - GUI::SameLine(); - - if (GUI::SmallButton("Clear")) - { - m_Points[0].clear(); - } - - GUI::Separator(); - GUI::Text("Points[0] Count : %d", (_int)m_Points[0].size()); - - for (_uint i = 0; i < m_Points[0].size();) - { - _vector v = m_Points[0][i]; - XMFLOAT3 p; - XMStoreFloat3(&p, v); - - GUI::PushID(i); - - GUI::Text("[%d] (%.2f, %.2f, %.2f)", i, p.x, p.y, p.z); - - GUI::SameLine(); - - if (GUI::SmallButton("X")) - { - m_Points[0].erase(m_Points[0].begin() + i); - GUI::PopID(); - continue; - } - - GUI::PopID(); - i++; - } - - if (GUI::Button("MovePos")) { - m_pCharacter_Controller->Set_Position(XMVectorSet(m_pGameInstance->Get_CamPosition()->x, m_pGameInstance->Get_CamPosition()->y, m_pGameInstance->Get_CamPosition()->z,1.f)); + m_pCharacter_Controller->Set_Position(XMVectorSet(m_pGameInstance->Get_CamPosition()->x, m_pGameInstance->Get_CamPosition()->y, m_pGameInstance->Get_CamPosition()->z, 1.f)); + } + + for (_uint i = 0; i < m_Points.size(); ++i) + { + GUI::Separator(); + + if (GUI::TreeNode(("Points " + to_string(i)).c_str())) + { + if (GUI::SmallButton("Copy")) + { + char buf[128]; + sprintf_s(buf, "", Pos.x, Pos.y, Pos.z); + + GUI::SetClipboardText(buf); + + m_Points[i].push_back(XMVectorSet(Pos.x, Pos.y, Pos.z, 1.f)); + } + + GUI::Text("Points[%d] Count : %d", i, (_int)m_Points[i].size()); + + for (_uint j = 0; j < m_Points[i].size(); ) + { + _float3 p; + XMStoreFloat3(&p, m_Points[i][j]); + + GUI::PushID((int)(i * 10000 + j)); + + GUI::Text("[%d] (%.2f, %.2f, %.2f)", j, p.x, p.y, p.z); + GUI::SameLine(); + + if (GUI::SmallButton("Move")) + { + m_pCharacter_Controller->Set_Position( + XMVectorSet(p.x, p.y, p.z, 1.f)); + } + + GUI::SameLine(); + + if (GUI::SmallButton("X")) + { + m_Points[i].erase(m_Points[i].begin() + j); + GUI::PopID(); + continue; + } + + GUI::PopID(); + ++j; + } + + if (GUI::SmallButton(("Clear##" + to_string(i)).c_str())) + { + m_Points[i].clear(); + } + GUI::TreePop(); + } + } m_pTransformCom->Describe_Entity(); diff --git a/Jusin154_Team3D/Client/Private/Ranrok_States.cpp b/Jusin154_Team3D/Client/Private/Ranrok_States.cpp index e38667d77..6ed6c8463 100644 --- a/Jusin154_Team3D/Client/Private/Ranrok_States.cpp +++ b/Jusin154_Team3D/Client/Private/Ranrok_States.cpp @@ -314,6 +314,11 @@ void CRanrok::Behavior_FireBreathEnter() { pairAnimInfo = m_Animation[STATEANIM::FIREBREATH_G]; m_fSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)] = m_fMaxSkillCoolTime[ENUM_CLASS(RANROK_SKILL::FIREBREATH)]; + + Add_Event(pairAnimInfo.first, + [this]() { + m_pEffectPool->Use_Skill(SKILL_TYPE::RANROK_BREATH, this); + }, 0.1f); } m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); } @@ -521,7 +526,7 @@ HRESULT CRanrok::Behavior_FireBallExitCheck(_float fTimeDelta) return E_FAIL; } else if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_GROUND)) { - m_pFSM->Change_State(FSMSTATE::GROUND); + m_pFSM->Change_State(FSMSTATE::COMBAT); return E_FAIL; } } @@ -711,8 +716,15 @@ HRESULT CRanrok::Behavior_TuckedExitCheck(_float fTimeDelta) if (m_bTucked && iCurrAnimIndex != m_Animation[STATEANIM::FLY_TO_HOVER].first) { m_iCurrentFlow++; - pairAnimInfo = m_Animation[STATEANIM::FLY_TO_HOVER]; - m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + if (m_ePhase == ENUM_CLASS(RANROK_PHASE::PHASE_GROUND)) { + pairAnimInfo = m_Animation[STATEANIM::LAND]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second,1.f,false,1.5f); + } + else { + pairAnimInfo = m_Animation[STATEANIM::FLY_TO_HOVER]; + m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); + } + } if (m_pModelCom->IsFinishedAnim() && iCurrAnimIndex == m_Animation[STATEANIM::FLY_TO_HOVER].first) @@ -739,7 +751,6 @@ void CRanrok::Behavior_LandEnter() pair<_uint, _bool> pairAnimInfo = {}; m_pFSM->Enable_State(FSMSTATE::LAND); m_pCharacter_Controller->SetGravity(true); - m_ePhase = ENUM_CLASS(RANROK_PHASE::PHASE_GROUND); pairAnimInfo = m_Animation[STATEANIM::LAND]; m_pModelCom->Set_AnimationIndex(pairAnimInfo.first, pairAnimInfo.second); diff --git a/Jusin154_Team3D/Client/Public/Broom.h b/Jusin154_Team3D/Client/Public/Broom.h index f3dd3b8bd..89ca31c54 100644 --- a/Jusin154_Team3D/Client/Public/Broom.h +++ b/Jusin154_Team3D/Client/Public/Broom.h @@ -38,6 +38,7 @@ class CBroom final : public CUnit void Set_Input(BroomInput broomInput) { m_Input = broomInput; } void Set_AISpeed(_float speedMul, _float accelMul); void Set_Move(_bool bMove) { m_bMove = bMove; } + _bool Get_Move() { return m_bMove; } HRESULT Ready_Child(); private: CInfoInstance* m_pInfoInstance = { nullptr }; diff --git a/Jusin154_Team3D/Client/Public/BroomRacerAI.h b/Jusin154_Team3D/Client/Public/BroomRacerAI.h index 876b052f1..ef983a41d 100644 --- a/Jusin154_Team3D/Client/Public/BroomRacerAI.h +++ b/Jusin154_Team3D/Client/Public/BroomRacerAI.h @@ -41,7 +41,6 @@ class CBroomRacerAI final : public CUnit virtual void OnHit(CGameObject* pOther, CGameObject* pCaller = nullptr)override; void Set_RaceRing(class CRaceRing* pRaceRing) {m_pRaceRing = pRaceRing;} class CBroom* Get_Broom() { return m_pBroom; } - void Set_Move(_bool bMove) { m_bMove = bMove; } private: CLight* m_pLightCom = { nullptr }; LIGHT_DESC LightDesc = {}; @@ -99,7 +98,6 @@ class CBroomRacerAI final : public CUnit _float m_fScaleSmoothSpeed = 2.5f; _float m_fAnimTime = {}; _bool m_bTurbo = {}; - _bool m_bMove = {}; _float m_LaneOffsetX = 0.f; _float m_LaneOffsetY = 0.f; _float m_TurnGain = 1.f; diff --git a/Jusin154_Team3D/Client/Public/Client_Macro.h b/Jusin154_Team3D/Client/Public/Client_Macro.h index 82a9a0e03..d78e087bf 100644 --- a/Jusin154_Team3D/Client/Public/Client_Macro.h +++ b/Jusin154_Team3D/Client/Public/Client_Macro.h @@ -68,6 +68,7 @@ namespace Client { #define LAYER_DOOR TEXT("Layer_Door") #define LAYER_HIDDEN TEXT("Layer_HIDDEN") #define LAYER_RING TEXT("Layer_Ring") +#define LAYER_RACERAI TEXT("Layer_RacerAI") #define LAYER_MAPOBJECTMANAGER TEXT("Layer_MapObjectManager") diff --git a/Jusin154_Team3D/Client/Public/Monster.h b/Jusin154_Team3D/Client/Public/Monster.h index f76ce6264..f5b30b555 100644 --- a/Jusin154_Team3D/Client/Public/Monster.h +++ b/Jusin154_Team3D/Client/Public/Monster.h @@ -33,6 +33,7 @@ class CMonster abstract : public CUnit virtual _float2 Get_Hp(); virtual CStat* Get_Stat(); const _float4x4* Get_HeadMatrix(); + _float Get_HpRatio(); void CameraShake(_float ClampValue, _float Min, _float Max, _float Time); protected: diff --git a/Jusin154_Team3D/Client/Public/Player.h b/Jusin154_Team3D/Client/Public/Player.h index 8a99456da..97b472977 100644 --- a/Jusin154_Team3D/Client/Public/Player.h +++ b/Jusin154_Team3D/Client/Public/Player.h @@ -34,6 +34,7 @@ class CPlayer final : public CUnit _int Get_UIState() { return m_eUIState; } void Set_RaceRing(class CRaceRing* pRaceRing); class CBroom* Get_Broom() { return m_pBroom; } + void Set_RaceInfo(); #ifdef _DEBUG void Render_CameraCoordinateSystem(); #endif // _DEBUG @@ -60,6 +61,8 @@ class CPlayer final : public CUnit _float m_fOriginGravityAmount = {}; _float m_fGravityAmount = {}; + _float m_fTempWeight = {}; + class CCamPosition_Shoulder* m_pCamPosition_ShoulderPart = { nullptr }; class CCamPosition_Head* m_pCamPosition_HeadPart = { nullptr }; @@ -80,13 +83,6 @@ class CPlayer final : public CUnit class CBroomRaceManager* m_pBroomRaceManager = { nullptr }; class CRaceRing* m_pRaceRing = { nullptr }; - - - - - - - _float m_fTempWeight = {}; private: virtual HRESULT Initialize_Prototype() override; virtual HRESULT Initialize(void* pArg) override; diff --git a/Jusin154_Team3D/Client/Public/Ranrok.h b/Jusin154_Team3D/Client/Public/Ranrok.h index 8dfd69cfd..a9cf905af 100644 --- a/Jusin154_Team3D/Client/Public/Ranrok.h +++ b/Jusin154_Team3D/Client/Public/Ranrok.h @@ -115,7 +115,7 @@ class CRanrok final : public CMonster _float m_fHeadAimWeight = {}; class CEffect_Container* m_pRanrok_Point = { nullptr }; - _float m_fTuckedSpeed = { 75.f }; + _float m_fTuckedSpeed = { 50.f }; void Behavior_IdleEnter(); HRESULT Behavior_IdleExitCheck(); diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Data/RanrokPos/RanrokPos.xml b/Jusin154_Team3D/Editor/Bin/Resources/Data/RanrokPos/RanrokPos.xml index 13af489ce..c31b7fa1b 100644 --- a/Jusin154_Team3D/Editor/Bin/Resources/Data/RanrokPos/RanrokPos.xml +++ b/Jusin154_Team3D/Editor/Bin/Resources/Data/RanrokPos/RanrokPos.xml @@ -1,115 +1,153 @@ - - + - + - + - + - + - + - + - + - + - - - - + - + - + - + - + - + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - + - + + + + + + + - + - + - + - + - + - + - + - + - + - + + + + + + + + + + + + + - diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_HogsheadInn/Meshes/Temp.txt b/Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_HogsheadInn/Meshes/Temp.txt new file mode 100644 index 000000000..e69de29bb diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Potions/Meshes/Temp.txt b/Jusin154_Team3D/Editor/Bin/Resources/Models/MapMesh/Game/Environment/Hogsmeade/BLDG_Potions/Meshes/Temp.txt new file mode 100644 index 000000000..e69de29bb diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.bin b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.bin new file mode 100644 index 000000000..4b95638f7 --- /dev/null +++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.bin @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4c3c4d445c454b1e335c79c165f9a88cca87a2c8d24f0683db75f919a16a6ac +size 4418133 diff --git a/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.fbx b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.fbx new file mode 100644 index 000000000..9736db4d0 --- /dev/null +++ b/Jusin154_Team3D/Editor/Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:267467c09021c0a29061e8ecea291dd8fb26f7e186b3a49dd143f55fda8bef6b +size 3482236 diff --git a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl index 6e54e5656..3cf999034 100644 --- a/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl +++ b/Jusin154_Team3D/Editor/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl @@ -54,7 +54,7 @@ void CS_MAIN(uint3 DTid : SV_DispatchThreadID) int p = g_ParentBuffer[global]; while (p != -1) { - combined = mul(combined,g_LocalMatIn[p]); + combined = mul(combined, g_LocalMatIn[p]); p = g_ParentBuffer[p]; } diff --git a/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp b/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp index a796ec039..b34a27319 100644 --- a/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp +++ b/Jusin154_Team3D/Editor/Private/Camera_Debug.cpp @@ -62,6 +62,14 @@ void CCamera_Debug::Priority_Update(_float fTimeDelta) Set_InitialPos(); } + _long LWheel = m_pGameInstance->Get_DIMouseMove(MOUSEMOVESTATE::W); + if (LWheel > 0) + { + m_pTransformCom->Add_SpeedPerSec(0.5f); + } + else if (LWheel < 0) + m_pTransformCom->Add_SpeedPerSec(-0.5f); + #pragma endregion #pragma region Angle diff --git a/Jusin154_Team3D/Editor/Private/Level_ObjectViewer.cpp b/Jusin154_Team3D/Editor/Private/Level_ObjectViewer.cpp index d84838442..7ee275571 100644 --- a/Jusin154_Team3D/Editor/Private/Level_ObjectViewer.cpp +++ b/Jusin154_Team3D/Editor/Private/Level_ObjectViewer.cpp @@ -759,13 +759,13 @@ HRESULT CLevel_ObjectViewer::Ready_Layer_UI(const _wstring& strLayerTag) HRESULT CLevel_ObjectViewer::Ready_Layer_Dummy(const _wstring& strLayerTag) { - //if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_EffectPool")))) //플레이어보다 먼저 생성해야함! - //{ - // return E_FAIL; - //} + if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, TEXT("Layer_EffectPool")))) //플레이어보다 먼저 생성해야함! + { + return E_FAIL; + } - //if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, nullptr, nullptr, &m_Test))) - // return E_FAIL; + if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, strLayerTag, nullptr, nullptr, &m_Test))) + return E_FAIL; if (FAILED(m_pGameInstance->Add_GameObject_ToLayer(g_iStaticLevel, NEXT_LEVEL, LAYER_CUBE))) return E_FAIL; diff --git a/Jusin154_Team3D/Editor/Private/Loader_ObjectViewer.cpp b/Jusin154_Team3D/Editor/Private/Loader_ObjectViewer.cpp index b2a988d02..8c26560ec 100644 --- a/Jusin154_Team3D/Editor/Private/Loader_ObjectViewer.cpp +++ b/Jusin154_Team3D/Editor/Private/Loader_ObjectViewer.cpp @@ -91,6 +91,11 @@ HRESULT CLoader::Loading_For_ObjectViewer() TEXT("Prototype_Component_SK_GOB_M_Assassin_Master_Model") )); + futures.emplace_back(Deferred_ModelLoad( + MODEL::ANIM, "../Bin/Resources/Models/Monster/Goblin_Assassin/SK_GOB_M_Assassin_Master_Tumble.fbx", XMMatrixRotationZ(XMConvertToRadians(180.f)) * XMMatrixIdentity(), + TEXT("Prototype_Component_SK_GOB_M_Assassin_Master_Model") + )); + if (FAILED(m_pGameInstance->Add_Asset_Prototype(ENUM_CLASS(LEVEL::STATIC), TEXT("Prototype_Component_GoblinSpector_Model"), CModel::Create(m_pDevice, m_pContext, MODEL::ANIM, "../Bin/Resources/Models/Monster/GoblinSpector/GoblinSpector.bin", XMMatrixRotationY(XMConvertToRadians(180.f)) * XMMatrixIdentity())))) return E_FAIL; diff --git a/Jusin154_Team3D/Editor/Private/Player.cpp b/Jusin154_Team3D/Editor/Private/Player.cpp index 1c5dcdc1c..ce7141dc0 100644 --- a/Jusin154_Team3D/Editor/Private/Player.cpp +++ b/Jusin154_Team3D/Editor/Private/Player.cpp @@ -109,7 +109,8 @@ HRESULT CPlayer::Initialize(void* pArg) void CPlayer::Priority_Update(_float fTimeDelta) { ReLockOnTarget(); - SetGravity(); + if (m_pCharacter_Controller->Get_GravityAmount() > 0.f) + SetGravity(); m_pTransformCom->RewindMomentum(); __super::Priority_Update(fTimeDelta); @@ -497,6 +498,13 @@ void CPlayer::Describe_Entity() { GUI::Begin("PLAYER_DESC"); m_pCharacter_Controller->Describe_Entity(); + + if (m_pGameInstance->Key_Up(DIK_HOME)) + { + m_pCharacter_Controller->Set_GravityAmount(0.f); + m_pCharacter_Controller->Set_Position(XMVectorSet(m_pGameInstance->Get_CamPosition()->x, m_pGameInstance->Get_CamPosition()->y, m_pGameInstance->Get_CamPosition()->z, 1.f)); + } + _float4 vMomentum = {}; XMStoreFloat4(&vMomentum, m_pTransformCom->Get_CurrentMomentum()); GUI::Text("%.2f %.2f %.2f %.2f ", vMomentum.x, vMomentum.y, vMomentum.z, vMomentum.w); diff --git a/Jusin154_Team3D/Engine/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl b/Jusin154_Team3D/Engine/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl index 6e54e5656..3cf999034 100644 --- a/Jusin154_Team3D/Engine/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl +++ b/Jusin154_Team3D/Engine/Bin/Resources/ShaderFiles/Shader_Mesh_Compute.hlsl @@ -54,7 +54,7 @@ void CS_MAIN(uint3 DTid : SV_DispatchThreadID) int p = g_ParentBuffer[global]; while (p != -1) { - combined = mul(combined,g_LocalMatIn[p]); + combined = mul(combined, g_LocalMatIn[p]); p = g_ParentBuffer[p]; } diff --git a/Jusin154_Team3D/Engine/Private/Unit.cpp b/Jusin154_Team3D/Engine/Private/Unit.cpp index 9dc13de85..c7c292f5b 100644 --- a/Jusin154_Team3D/Engine/Private/Unit.cpp +++ b/Jusin154_Team3D/Engine/Private/Unit.cpp @@ -162,6 +162,11 @@ void CUnit::Add_Event(_uint AnimIndex, function Callback, _float fRatio, m_PendingEvents.push_back(Desc); } +void CUnit::Reset_Event() +{ + m_PendingEvents.clear(); +} + void CUnit::Check_HitAngle(_vector ProjectileDir) { _vector vProjectileDir = ProjectileDir; diff --git a/Jusin154_Team3D/Engine/Public/Unit.h b/Jusin154_Team3D/Engine/Public/Unit.h index 22fcfd6e9..e814ef13a 100644 --- a/Jusin154_Team3D/Engine/Public/Unit.h +++ b/Jusin154_Team3D/Engine/Public/Unit.h @@ -93,6 +93,7 @@ class ENGINE_DLL CUnit abstract : public CContainerObject HRESULT Ready_Components(void*pArg); void Play_Event(); void Add_Event(_uint AnimIndex, function Callback, _float fRatio = 0.f, _bool bKeep = false); + void Reset_Event(); void Check_HitAngle(_vector ProjectileDir); void Load_AnimXML(const string& path); STATEANIM::ESTATE StringToStateAnim(const string& s);