Merge branch 'Develope' into Effect
@@ -1892,13 +1892,13 @@ PS_OUT PS_SpellLearnBooster(PS_IN In)
|
||||
|
||||
float4 tex3 = g_Texture3.Sample(DefaultSampler, In.vTexcoord);
|
||||
Color = lerp(Color, tex3, tex3.a);
|
||||
}
|
||||
}
|
||||
else if (g_iBoosterOn == 0 && g_iBoosterOff != 0)
|
||||
{
|
||||
float4 tex2 = g_Texture2.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
tex2.rgb *= float3(1.f, 0.f, 0.f);
|
||||
Color = tex;
|
||||
Color = tex;
|
||||
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
}
|
||||
@@ -2259,23 +2259,21 @@ PS_OUT PS_Interaction_Npc(PS_IN In)
|
||||
float4 tex1 = g_Texture.Sample(ClampSampler, Finaluv);
|
||||
|
||||
Color = tex1;
|
||||
|
||||
if (g_iHover != 0)
|
||||
{
|
||||
float2 texpos1 = g_fImageSipos1.xy / g_fCurrent_Size;
|
||||
float2 texsize1 = g_fImageSipos1.zw / g_fCurrent_Size;
|
||||
float2 texlocal1 = (In.vTexcoord - texpos1) / texsize1;
|
||||
bool inside1 = all(texlocal1 >= 0.0f && texlocal1 <= 1.0f);
|
||||
if (inside1)
|
||||
{
|
||||
float2 startUV = g_fImageUV.xy;
|
||||
float2 endUV = g_fImageUV.zw;
|
||||
float2 atlasUV = atlasUV = startUV + texlocal1 * (endUV - startUV);
|
||||
float4 tex2 = g_Texture1.Sample(DefaultSampler, atlasUV);
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
|
||||
}
|
||||
float2 texpos1 = g_fImageSipos1.xy / g_fCurrent_Size;
|
||||
float2 texsize1 = g_fImageSipos1.zw / g_fCurrent_Size;
|
||||
float2 texlocal1 = (In.vTexcoord - texpos1) / texsize1;
|
||||
bool inside1 = all(texlocal1 >= 0.0f && texlocal1 <= 1.0f);
|
||||
if (inside1)
|
||||
{
|
||||
float2 startUV = g_fImageUV.xy;
|
||||
float2 endUV = g_fImageUV.zw;
|
||||
float2 atlasUV = atlasUV = startUV + texlocal1 * (endUV - startUV);
|
||||
float4 tex2 = g_Texture1.Sample(DefaultSampler, atlasUV);
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Color.a *= Alpha;
|
||||
|
||||
|
||||
@@ -170,6 +170,7 @@ call Update_Resources.bat
|
||||
<ClInclude Include="..\Public\Ranrok_FireBall.h" />
|
||||
<ClInclude Include="..\Public\CamPosition_AI.h" />
|
||||
<ClInclude Include="..\public\Dialogue.h" />
|
||||
<ClInclude Include="..\public\Dialogue_Data.h" />
|
||||
<ClInclude Include="..\public\Dialogue_Font.h" />
|
||||
<ClInclude Include="..\public\NPCInteraction.h" />
|
||||
<ClInclude Include="..\public\PointLight.h" />
|
||||
@@ -412,6 +413,7 @@ call Update_Resources.bat
|
||||
<ClCompile Include="..\Private\Ranrok_FireBall.cpp" />
|
||||
<ClCompile Include="..\Private\CamPosition_AI.cpp" />
|
||||
<ClCompile Include="..\private\Dialogue.cpp" />
|
||||
<ClCompile Include="..\private\Dialogue_Data.cpp" />
|
||||
<ClCompile Include="..\private\Dialogue_Font.cpp" />
|
||||
<ClCompile Include="..\private\NPCInteraction.cpp" />
|
||||
<ClCompile Include="..\private\PointLight.cpp" />
|
||||
|
||||
@@ -745,6 +745,9 @@
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Public\CamPosition_AI.h">
|
||||
<Filter>02.GameObjects\Cameras\CameraPosition\AI</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\public\Dialogue_Data.h">
|
||||
<Filter>04.Mechanic\Dialogue\Dialogue_Data</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@@ -1550,6 +1553,9 @@
|
||||
</Filter>
|
||||
<Filter Include="02.GameObjects\Cameras\CameraPosition\AI">
|
||||
<UniqueIdentifier>{a24f4687-f540-44e5-ae47-fe176c4c9042}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="04.Mechanic\Dialogue\Dialogue_Data">
|
||||
<UniqueIdentifier>{b03591a7-a14e-425a-8a3f-2a6a054c884a}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@@ -2243,6 +2249,9 @@
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\Private\CamPosition_AI.cpp">
|
||||
<Filter>02.GameObjects\Cameras\CameraPosition\AI</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\private\Dialogue_Data.cpp">
|
||||
<Filter>04.Mechanic\Dialogue\Dialogue_Data</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -0,0 +1,102 @@
|
||||
#include "pch.h"
|
||||
#include "Dialogue_Data.h"
|
||||
#include "GameObject.h"
|
||||
#include "tinyxml2.h"
|
||||
#include "InfoInstance.h"
|
||||
|
||||
CDialogue_Data::CDialogue_Data()
|
||||
:m_pInfoInstance(CInfoInstance::GetInstance())
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CDialogue_Data::Initialize(ID3D11Device* pDevice, ID3D11DeviceContext* pContex)
|
||||
{
|
||||
Load_SpellInfo("../Bin/Resources/Data/UI/Dialogue/Dialogue.xml");
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
void CDialogue_Data::Update(_float fTimeDelta)
|
||||
{
|
||||
}
|
||||
|
||||
HRESULT CDialogue_Data::Load_SpellInfo(const _char* pFilePath)
|
||||
{
|
||||
tinyxml2::XMLDocument doc;
|
||||
if (doc.LoadFile(pFilePath) != tinyxml2::XML_SUCCESS)
|
||||
return E_FAIL;
|
||||
|
||||
tinyxml2::XMLElement* pDialogueInfo = doc.FirstChildElement("DialogueInfo");
|
||||
if (!pDialogueInfo) return E_FAIL;
|
||||
|
||||
tinyxml2::XMLElement* pDialogue = pDialogueInfo->FirstChildElement("Dialogue");
|
||||
while (pDialogue)
|
||||
{
|
||||
NpcDialogue npc{};
|
||||
pDialogue->QueryIntAttribute("NpcID", &npc.iNpcID);
|
||||
|
||||
tinyxml2::XMLElement* pLine = pDialogue->FirstChildElement("Line");
|
||||
while (pLine)
|
||||
{
|
||||
DialogueInfo line{};
|
||||
pLine->QueryIntAttribute("ID", &line.iLineID);
|
||||
|
||||
int type = 0;
|
||||
pLine->QueryIntAttribute("Type", &type);
|
||||
line.bType = (type == 1);
|
||||
|
||||
const char* text = pLine->Attribute("Text");
|
||||
if (text) line.pText = CMyTools::ToWstring(text);
|
||||
|
||||
pLine->QueryIntAttribute("NextText", &line.NextTextID);
|
||||
|
||||
// 선택지 처리
|
||||
tinyxml2::XMLElement* pChoice = pLine->FirstChildElement("Choice");
|
||||
while (pChoice)
|
||||
{
|
||||
DialogueChoice choice{};
|
||||
int choiceType = 0;
|
||||
pChoice->QueryIntAttribute("Type", &choiceType);
|
||||
choice.eType = choiceType;
|
||||
|
||||
const char* choiceText = pChoice->Attribute("Text");
|
||||
if (choiceText) choice.pText = CMyTools::ToWstring(choiceText);
|
||||
|
||||
pChoice->QueryIntAttribute("NextText", &choice.NextTypeID);
|
||||
|
||||
line.ChoiceInfo.push_back(choice);
|
||||
pChoice = pChoice->NextSiblingElement("Choice");
|
||||
}
|
||||
|
||||
npc.Info.push_back(line);
|
||||
pLine = pLine->NextSiblingElement("Line");
|
||||
}
|
||||
|
||||
m_DialogueInfo.push_back(npc);
|
||||
pDialogue = pDialogue->NextSiblingElement("Dialogue");
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
const NPCDIALOGUEINFO& CDialogue_Data::Get_Info(_uint DialogueID) const
|
||||
{
|
||||
return m_DialogueInfo[DialogueID];
|
||||
}
|
||||
|
||||
CDialogue_Data* CDialogue_Data::Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext)
|
||||
{
|
||||
CDialogue_Data* pInstance = new CDialogue_Data();
|
||||
|
||||
if (FAILED(pInstance->Initialize(pDevice, pContext)))
|
||||
{
|
||||
MSG_BOX("Failed to Created : CDialogue_Data");
|
||||
SAFE_RELEASE(pInstance);
|
||||
}
|
||||
|
||||
return pInstance;
|
||||
}
|
||||
|
||||
void CDialogue_Data::Free()
|
||||
{
|
||||
__super::Free();
|
||||
}
|
||||
@@ -368,7 +368,7 @@ HRESULT CInfoInstance::Initialize_Information(ID3D11Device* pDevice, ID3D11Devic
|
||||
if (FAILED(Stat_FileLoad("../Bin/Resources/Data/Stat/Stat.xml"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(Stat_FileLoad("../Bin/Resources/Data/Stat/NpcStat.xml"))) {
|
||||
if (FAILED(NPC_FileLoad("../Bin/Resources/Data/Stat/NpcStat.xml"))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
#pragma endregion
|
||||
|
||||
@@ -101,9 +101,9 @@ HRESULT CLoding_Panel::Render()
|
||||
if (FAILED(m_pVIBufferCom->Render())) {
|
||||
return E_FAIL;
|
||||
}
|
||||
m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("<- N M ->."), _float2(100.f, 750.f));
|
||||
m_pGameInstance->Render_Text(TEXT("Font_size20"), TEXT("<- N M ->."), _float2(50.f, 850.f));
|
||||
|
||||
m_pGameInstance->Render_Text(TEXT("Font_size20"), ToolTip[m_iToolTip_Count].c_str(), _float2(100.f, 800.f));
|
||||
m_pGameInstance->Render_Text(TEXT("Font_size20"), ToolTip[m_iToolTip_Count].c_str(), _float2(50.f, 900.f));
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
@@ -82,11 +82,6 @@ void CNPCInteraction::NpcInfo(_wstring Name)
|
||||
m_NpcName = Name;
|
||||
}
|
||||
|
||||
void CNPCInteraction::Interaction(_bool bInteraction)
|
||||
{
|
||||
m_bInteraction = bInteraction;
|
||||
}
|
||||
|
||||
void CNPCInteraction::Priority_Update(_float fTimeDelta)
|
||||
{
|
||||
|
||||
@@ -169,15 +164,12 @@ HRESULT CNPCInteraction::Render()
|
||||
m_NpcName.c_str(),
|
||||
m_vFontPosition);
|
||||
|
||||
if (m_bInteraction == true)
|
||||
{
|
||||
m_pGameInstance->Perspective_Render_Text(
|
||||
m_pGameInstance->Get_Transform_Matrix(D3DTS::VIEW),
|
||||
m_pGameInstance->Get_Transform_Matrix(D3DTS::PROJ),
|
||||
TEXT("Font_size15"),
|
||||
TEXT("대화하기"),
|
||||
m_vPosition);
|
||||
}
|
||||
m_pGameInstance->Perspective_Render_Text(
|
||||
m_pGameInstance->Get_Transform_Matrix(D3DTS::VIEW),
|
||||
m_pGameInstance->Get_Transform_Matrix(D3DTS::PROJ),
|
||||
TEXT("Font_size15"),
|
||||
TEXT("대화하기"),
|
||||
m_vPosition);
|
||||
|
||||
|
||||
return S_OK;
|
||||
@@ -243,10 +235,6 @@ HRESULT CNPCInteraction::Bind_ShaderResources()
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
if (FAILED(m_pShaderCom->Bind_RawValue("g_iHover", &m_bInteraction, sizeof(_bool))))
|
||||
{
|
||||
return E_FAIL;
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -33,20 +33,6 @@ void CNPC_Ollivander::Update(_float fTimeDelta)
|
||||
#ifdef _DEBUG
|
||||
Describe_Entity();
|
||||
#endif // _DEBUG
|
||||
|
||||
if (false == m_bHasInteracted)
|
||||
{
|
||||
if (true == InteractWithPlayer()) {
|
||||
m_vEnteringTimer.x += fTimeDelta;
|
||||
if (m_vEnteringTimer.x > m_vEnteringTimer.y) {
|
||||
m_vEnteringTimer.x -= m_vEnteringTimer.y;
|
||||
m_bHasInteracted = true;
|
||||
// Active();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (false == m_bEntered)
|
||||
{
|
||||
if (true == CastToPlayer()) {
|
||||
@@ -54,7 +40,6 @@ void CNPC_Ollivander::Update(_float fTimeDelta)
|
||||
if (m_vEnteringTimer.x > m_vEnteringTimer.y) {
|
||||
m_vEnteringTimer.x -= m_vEnteringTimer.y;
|
||||
m_bEntered = true;
|
||||
m_bHasInteracted = false;
|
||||
// Active();
|
||||
}
|
||||
#ifdef _DEBUG
|
||||
@@ -73,7 +58,6 @@ void CNPC_Ollivander::Update(_float fTimeDelta)
|
||||
if (m_vEnteringTimer.x > m_vEnteringTimer.y) {
|
||||
m_vEnteringTimer.x -= m_vEnteringTimer.y;
|
||||
m_bEntered = false;
|
||||
m_bHasInteracted = false;
|
||||
// DeActive(), Ready To Enter;
|
||||
}
|
||||
#ifdef _DEBUG
|
||||
@@ -116,9 +100,8 @@ void CNPC_Ollivander::Update(_float fTimeDelta)
|
||||
}
|
||||
|
||||
m_pNPCInteraction->Set_Visible(m_bEntered);
|
||||
m_pNPCInteraction->Interaction(m_bHasInteracted);
|
||||
|
||||
if (m_bHasInteracted == true)
|
||||
if (m_bEntered == true)
|
||||
{
|
||||
if (m_pGameInstance->Key_Down(DIK_F))
|
||||
{
|
||||
@@ -253,19 +236,6 @@ _bool CNPC_Ollivander::CastToPlayer()
|
||||
return false;
|
||||
}
|
||||
|
||||
_bool CNPC_Ollivander::InteractWithPlayer()
|
||||
{
|
||||
_vector vCurrentPos = m_pTransformCom->Get_State(STATE::POSITION);
|
||||
_vector vTargetPos = {};
|
||||
pair<CUnit*, CTransform*> pairAllyInfo = m_pInfoInstance->Get_NearestPlayerAlly(m_pTransformCom->Get_State(STATE::POSITION));
|
||||
vTargetPos = pairAllyInfo.second->Get_State(STATE::POSITION);
|
||||
_float fLength = XMVectorGetX(XMVector4Length(vTargetPos - vCurrentPos));
|
||||
if (fLength < m_fInteractionDistance) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
HRESULT CNPC_Ollivander::Initialize_Prototype()
|
||||
{
|
||||
return S_OK;
|
||||
@@ -337,7 +307,7 @@ HRESULT CNPC_Ollivander::Ready_Components(void* pArg)
|
||||
m_pCharacter_Controller->SetGravity(true);
|
||||
}
|
||||
|
||||
if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("OLLIVENDER"), (CComponent**)&m_pStat))) {
|
||||
if (FAILED(Add_Asset_Component(g_iStaticLevel, TEXT("OLLIVENDER"), (CComponent**)&m_pNpcStat))) {
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
@@ -345,7 +315,7 @@ HRESULT CNPC_Ollivander::Ready_Components(void* pArg)
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
m_pNPCInteraction->NpcInfo(m_pStat->Get_Stat().pNpc_Name);
|
||||
m_pNPCInteraction->NpcInfo(m_pNpcStat->Get_Stat().pNpc_Name);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
@@ -379,7 +349,7 @@ void CNPC_Ollivander::Free()
|
||||
__super::Free();
|
||||
|
||||
SAFE_RELEASE(m_pCharacter_Controller);
|
||||
SAFE_RELEASE(m_pStat);
|
||||
SAFE_RELEASE(m_pNpcStat);
|
||||
if (nullptr != m_pInfoInstance) {
|
||||
CInfoInstance* pInfo = m_pInfoInstance;
|
||||
m_pInfoInstance = nullptr;
|
||||
|
||||
@@ -2706,7 +2706,7 @@ void CPlayer::Add_SpellEvent(_uint AnimIndex,_float fRatio)
|
||||
Add_Event(AnimIndex,
|
||||
[this]() {m_pEffectPool->Use_Skill(SKILL_TYPE::TRANSFORMATION_SIDE, Get_PartObject<CWand>()); },
|
||||
0.f);
|
||||
Info.pText = TEXT("봄바르다");
|
||||
Info.pText = TEXT("베라베르토!");
|
||||
m_pInfoInstance->Event_CallBack(TEXT("Dialogue"), &Info);
|
||||
break;
|
||||
|
||||
|
||||
@@ -37,6 +37,28 @@ namespace Client
|
||||
_float fVidio{};
|
||||
}SPELL_INFO;
|
||||
|
||||
typedef struct DialogueChoice
|
||||
{
|
||||
_int eType = {false};
|
||||
_wstring pText;
|
||||
_int NextTypeID{};
|
||||
}DIALOGUECHOICEINFO;
|
||||
|
||||
typedef struct DialogueInfo
|
||||
{
|
||||
_int iLineID{};
|
||||
_bool bType = {false};
|
||||
_wstring pText;
|
||||
_int NextTextID{};
|
||||
vector<DIALOGUECHOICEINFO> ChoiceInfo;
|
||||
}CURRENTDIALOGUEINFO;
|
||||
|
||||
typedef struct NpcDialogue
|
||||
{
|
||||
_int iNpcID{};
|
||||
vector<CURRENTDIALOGUEINFO> Info;
|
||||
}NPCDIALOGUEINFO;
|
||||
|
||||
typedef struct tagLockOnInfo {
|
||||
CUnit* pUnit = { nullptr };
|
||||
class CMapElement_Interactable* pInteractive = { nullptr };
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
#pragma once
|
||||
|
||||
#include "Client_Define.h"
|
||||
#include "Base.h"
|
||||
|
||||
NS_BEGIN(Engine)
|
||||
class CGameInstance;
|
||||
class CUIObject;
|
||||
NS_END
|
||||
|
||||
NS_BEGIN(Client)
|
||||
|
||||
class CDialogue_Data final : public CBase
|
||||
{
|
||||
public:
|
||||
|
||||
private:
|
||||
CDialogue_Data();
|
||||
~CDialogue_Data() = default;
|
||||
|
||||
public:
|
||||
void Update(_float fTimeDelta);
|
||||
|
||||
public:
|
||||
HRESULT Load_SpellInfo(const _char* pFilePath);
|
||||
|
||||
public:
|
||||
const NPCDIALOGUEINFO& Get_Info(_uint DialogueID) const;
|
||||
|
||||
private:
|
||||
CInfoInstance* m_pInfoInstance = { nullptr };
|
||||
|
||||
_int m_iDialogue_Count{};
|
||||
vector<NPCDIALOGUEINFO> m_DialogueInfo;
|
||||
|
||||
private:
|
||||
HRESULT Initialize(ID3D11Device* pDevice, ID3D11DeviceContext* pContex);
|
||||
|
||||
|
||||
public:
|
||||
static CDialogue_Data* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
virtual void Free() override;
|
||||
};
|
||||
|
||||
NS_END
|
||||
@@ -32,7 +32,6 @@ class CNPCInteraction final : public CGameObject
|
||||
|
||||
public:
|
||||
void NpcInfo(_wstring Name);
|
||||
void Interaction(_bool bInteraction);
|
||||
|
||||
private:
|
||||
CTexture* m_pDiffuse_TextureCom = { nullptr };
|
||||
@@ -41,8 +40,6 @@ class CNPCInteraction final : public CGameObject
|
||||
CShader* m_pShaderCom = { nullptr };
|
||||
CVIBuffer_Rect* m_pVIBufferCom = { nullptr };
|
||||
|
||||
_bool m_bInteraction = {false};
|
||||
|
||||
_vector m_vFontPosition{};
|
||||
_vector m_vFontPosition1{};
|
||||
|
||||
|
||||
@@ -32,21 +32,18 @@ class CNPC_Ollivander final : public CUnit
|
||||
CUnit* m_pPlayerAllyUnit = { nullptr };
|
||||
CNPC_Ollivander* m_pNPC_Ollivander = { nullptr };
|
||||
|
||||
class CNPCInteraction* m_pNPCInteraction = { nullptr };
|
||||
class CNPCInteraction* m_pNPCInteraction = { nullptr };
|
||||
|
||||
CNPCStat* m_pStat = { nullptr };
|
||||
_bool m_bEntered = { false };
|
||||
_bool m_bHasInteracted = { false };
|
||||
_float2 m_vEnteringTimer = { 0.f, 1.f };
|
||||
_float m_fEncounterDistance = { 10.f };
|
||||
_float m_fInteractionDistance = { 3.f };
|
||||
CNPCStat* m_pNpcStat = { nullptr };
|
||||
_bool m_bEntered = { false };
|
||||
_float2 m_vEnteringTimer = { 0.f, 1.f };
|
||||
_float m_fEncounterDistance = { 3.f };
|
||||
protected:
|
||||
virtual HRESULT Initialize_Prototype() override;
|
||||
virtual HRESULT Initialize(void* pArg) override;
|
||||
HRESULT Ready_Components(void* pArg);
|
||||
HRESULT Bind_ShaderResources() override;
|
||||
_bool CastToPlayer();
|
||||
_bool InteractWithPlayer();
|
||||
|
||||
public:
|
||||
static CNPC_Ollivander* Create(ID3D11Device* pDevice, ID3D11DeviceContext* pContext);
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<Dialogue>
|
||||
<Npc NpcName="Ollivander" NpcID="0" >
|
||||
<Text ID="0" Size="0" NpcName="올리벤더:" Text="반갑네 친구 나는 올리벤더 라고 하네"></Text>
|
||||
<Text ID="1" Size="0" NpcName="올리벤더:" Text="나는 여기서 지팡이를 팔고있어"></Text>
|
||||
</Npc>
|
||||
</Dialogue>
|
||||
<DialogueInfo>
|
||||
<Dialogue NpcID="0">
|
||||
<Line ID="0000" Type="0" Text="반갑네 친구 나는 올리벤더 라고 하네" NextText="0001"> </Line>
|
||||
<Line ID="0001" Type="0" Text="나는 여기서 지팡이를 팔고있어" NextText="0002"> </Line>
|
||||
<Line ID="0002" Type="1" Text="뭐 필요한게 있나?" >
|
||||
<Choice Type="1" Text="상점 이용하기" NextText="-1" />
|
||||
<Choice Type="2" Text="퀘스트 확인하기" NextText="-1" />
|
||||
<Choice Type="0" Text="다른일 하러가기" NextText="-1" />
|
||||
</Line>
|
||||
</Dialogue>
|
||||
</DialogueInfo>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<StatInfo>
|
||||
<OLLIVENDER Name="올리벤더" TAG="1" SizeX="256"/>
|
||||
<OLLIVENDER ID="0" Name="올리벤더" TAG="1" SizeX="256"/>
|
||||
</StatInfo>
|
||||
|
||||
@@ -1892,13 +1892,13 @@ PS_OUT PS_SpellLearnBooster(PS_IN In)
|
||||
|
||||
float4 tex3 = g_Texture3.Sample(DefaultSampler, In.vTexcoord);
|
||||
Color = lerp(Color, tex3, tex3.a);
|
||||
}
|
||||
}
|
||||
else if (g_iBoosterOn == 0 && g_iBoosterOff != 0)
|
||||
{
|
||||
float4 tex2 = g_Texture2.Sample(DefaultSampler, In.vTexcoord);
|
||||
|
||||
tex2.rgb *= float3(1.f, 0.f, 0.f);
|
||||
Color = tex;
|
||||
Color = tex;
|
||||
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
}
|
||||
@@ -2259,23 +2259,21 @@ PS_OUT PS_Interaction_Npc(PS_IN In)
|
||||
float4 tex1 = g_Texture.Sample(ClampSampler, Finaluv);
|
||||
|
||||
Color = tex1;
|
||||
|
||||
if (g_iHover != 0)
|
||||
{
|
||||
float2 texpos1 = g_fImageSipos1.xy / g_fCurrent_Size;
|
||||
float2 texsize1 = g_fImageSipos1.zw / g_fCurrent_Size;
|
||||
float2 texlocal1 = (In.vTexcoord - texpos1) / texsize1;
|
||||
bool inside1 = all(texlocal1 >= 0.0f && texlocal1 <= 1.0f);
|
||||
if (inside1)
|
||||
{
|
||||
float2 startUV = g_fImageUV.xy;
|
||||
float2 endUV = g_fImageUV.zw;
|
||||
float2 atlasUV = atlasUV = startUV + texlocal1 * (endUV - startUV);
|
||||
float4 tex2 = g_Texture1.Sample(DefaultSampler, atlasUV);
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
|
||||
}
|
||||
float2 texpos1 = g_fImageSipos1.xy / g_fCurrent_Size;
|
||||
float2 texsize1 = g_fImageSipos1.zw / g_fCurrent_Size;
|
||||
float2 texlocal1 = (In.vTexcoord - texpos1) / texsize1;
|
||||
bool inside1 = all(texlocal1 >= 0.0f && texlocal1 <= 1.0f);
|
||||
if (inside1)
|
||||
{
|
||||
float2 startUV = g_fImageUV.xy;
|
||||
float2 endUV = g_fImageUV.zw;
|
||||
float2 atlasUV = atlasUV = startUV + texlocal1 * (endUV - startUV);
|
||||
float4 tex2 = g_Texture1.Sample(DefaultSampler, atlasUV);
|
||||
Color = lerp(Color, tex2, tex2.a);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Color.a *= Alpha;
|
||||
|
||||
|
||||
|
After Width: | Height: | Size: 211 KiB |
|
After Width: | Height: | Size: 47 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 174 KiB |
|
After Width: | Height: | Size: 79 KiB |
|
After Width: | Height: | Size: 387 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 33 KiB |
@@ -16,9 +16,10 @@ CNPCStat::CNPCStat(const CNPCStat& rhs)
|
||||
HRESULT CNPCStat::Initialize_Prototype(tinyxml2::XMLNode* pChild)
|
||||
{
|
||||
auto pElement = pChild->ToElement();
|
||||
pElement->QueryIntAttribute("ID", &m_NpcInfo.iID);
|
||||
m_NpcInfo.pNpc_Name = CMyTools::ToWstring(pElement->Attribute("Name"));
|
||||
pElement->QueryIntAttribute("OBJECTID", &m_NpcInfo.iNpcType);
|
||||
pElement->QueryFloatAttribute("HP", &m_NpcInfo.fFontPos);
|
||||
pElement->QueryIntAttribute("TAG", &m_NpcInfo.iNpcType);
|
||||
pElement->QueryFloatAttribute("SizeX", &m_NpcInfo.fFontPos);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ class ENGINE_DLL CNPCStat final : public CComponent
|
||||
{
|
||||
typedef struct tagNpcInfo
|
||||
{
|
||||
_int iID{};
|
||||
_wstring pNpc_Name;
|
||||
_int iNpcType{};
|
||||
_float fFontPos{};
|
||||
|
||||