[Add] Human Duelist 추가
This commit is contained in:
@@ -28,6 +28,7 @@ StructuredBuffer<uint> g_BoneRemap : register(t6);
|
||||
StructuredBuffer<int> g_SkipBone : register(t7);
|
||||
|
||||
|
||||
|
||||
RWStructuredBuffer<float4x4> g_LocalMatrixOut : register(u0);
|
||||
|
||||
cbuffer AnimCB : register(b0)
|
||||
@@ -48,7 +49,7 @@ cbuffer AnimCB : register(b0)
|
||||
float HeadAimWeight;
|
||||
|
||||
int SkipCount;
|
||||
int _pad0;
|
||||
int IsSkip;
|
||||
int _pad1;
|
||||
int _pad2;
|
||||
|
||||
@@ -366,7 +367,7 @@ void CS_LOCAL(uint3 DTid : SV_DispatchThreadID)
|
||||
if (bone >= BoneCount)
|
||||
return;
|
||||
|
||||
if (SkipCount != 0)
|
||||
if (SkipCount != 0 && IsSkip)
|
||||
{
|
||||
for (int i = 0; i < SkipCount; i++)
|
||||
{
|
||||
|
||||
@@ -29,7 +29,7 @@ cbuffer AnimCB : register(b0)
|
||||
float HeadAimWeight;
|
||||
|
||||
int SkipCount;
|
||||
int _pad0;
|
||||
int IsSkip;
|
||||
int _pad1;
|
||||
int _pad2;
|
||||
|
||||
|
||||
@@ -1578,19 +1578,19 @@ void CModel::Initialize_BoneMasks()
|
||||
BuildMask(m_iBoneIndex[ENUM_CLASS(BLEND_BONE::NECK)], m_BoneMask[ENUM_CLASS(BLEND_BONE::NECK)]);
|
||||
BuildMask(m_iBoneIndex[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)], m_BoneMask[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)]);
|
||||
|
||||
if (m_iBoneIndex[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)] != -1)
|
||||
{
|
||||
for (_uint i = 0; i < (_uint)m_BoneMask[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)].size(); i++)
|
||||
{
|
||||
if (m_BoneMask[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)][i] == 1)
|
||||
{
|
||||
if (i == m_iBoneIndex[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)])
|
||||
continue;
|
||||
m_iSkipBoneCount++;
|
||||
m_SkipBoneindex.push_back(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
//if (m_iBoneIndex[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)] != -1)
|
||||
//{
|
||||
// for (_uint i = 0; i < (_uint)m_BoneMask[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)].size(); i++)
|
||||
// {
|
||||
// if (m_BoneMask[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)][i] == 1)
|
||||
// {
|
||||
// if (i == m_iBoneIndex[ENUM_CLASS(BLEND_BONE::HIPS_CLOTH)])
|
||||
// continue;
|
||||
// m_iSkipBoneCount++;
|
||||
// m_SkipBoneindex.push_back(i);
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
|
||||
for (_uint i = 0; i < m_Bones.size(); i++)
|
||||
{
|
||||
@@ -1600,6 +1600,19 @@ void CModel::Initialize_BoneMasks()
|
||||
m_BoneMask[ENUM_CLASS(BLEND_BONE::SHOULDER_NECK_R)][i] =
|
||||
m_BoneMask[ENUM_CLASS(BLEND_BONE::SHOULDER_R)][i] | m_BoneMask[ENUM_CLASS(BLEND_BONE::NECK)][i];
|
||||
}
|
||||
|
||||
|
||||
for (_uint i = 0; i < (_uint)m_BoneMask[ENUM_CLASS(BLEND_BONE::SHOULDER_NECK_L)].size(); i++)
|
||||
{
|
||||
if (m_BoneMask[ENUM_CLASS(BLEND_BONE::SHOULDER_NECK_L)][i] == 1)
|
||||
{
|
||||
//if (i == m_iBoneIndex[ENUM_CLASS(BLEND_BONE::SHOULDER_NECK_L)])
|
||||
// continue;
|
||||
m_iSkipBoneCount++;
|
||||
m_SkipBoneindex.push_back(i);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
HRESULT CModel::Create_ComputeShader()
|
||||
@@ -1997,7 +2010,7 @@ void CModel::ComputeLocal(_uint AnimIndex, _uint MeshIndex)
|
||||
pDesc->HeadAimWeight = m_fHeadAimWeight;
|
||||
|
||||
pDesc->SkipCount = m_iSkipBoneCount;
|
||||
pDesc->padding0 = 0;
|
||||
pDesc->IsSkip = m_IsSkip;
|
||||
pDesc->padding1 = 0;
|
||||
pDesc->padding2 = 0;
|
||||
|
||||
|
||||
@@ -307,6 +307,9 @@ STATEANIM::ESTATE CUnit::StringToStateAnim(const string& s)
|
||||
|
||||
// LIGHT ATTACK
|
||||
{ "LIGHT_ATTACK", LIGHT_ATTACK },
|
||||
{ "LIGHT_ATTACK2", LIGHT_ATTACK2 },
|
||||
{ "LIGHT_ATTACK3", LIGHT_ATTACK3 },
|
||||
{ "LIGHT_ATTACK4", LIGHT_ATTACK4 },
|
||||
{ "LIGHT_ATTACK_180_R", LIGHT_ATTACK_180_R },
|
||||
{ "LIGHT_ATTACK_90_L", LIGHT_ATTACK_90_L },
|
||||
{ "LIGHT_ATTACK_90_R1", LIGHT_ATTACK_90_R1 },
|
||||
|
||||
@@ -25,7 +25,7 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
_float HeadAimWeight;
|
||||
|
||||
_int SkipCount;
|
||||
_int padding0;
|
||||
_int IsSkip;
|
||||
_int padding1;
|
||||
_int padding2;
|
||||
|
||||
@@ -84,19 +84,20 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
_float Get_CurrentTrackProgressRatio();
|
||||
_float Get_TrackProgressRatio(_uint iIndex);
|
||||
|
||||
size_t Get_AnimSize() { return m_Animations.size(); }
|
||||
void Set_PlayAnim(_bool bPlayAnim) { m_bPlayAnim = bPlayAnim; }
|
||||
_bool Get_PlayAnim() const { return m_bPlayAnim; }
|
||||
_int Get_AnimIndex() const { return m_iCurrentAnimIndex; }
|
||||
_int Get_SecondAnimIndex() const { return m_iCurrSecondAnimIndex; }
|
||||
_float Get_AnimSpeed();
|
||||
void Set_AnimSpeed(_float fSpeed);
|
||||
size_t Get_AnimSize() { return m_Animations.size(); }
|
||||
void Set_PlayAnim(_bool bPlayAnim) { m_bPlayAnim = bPlayAnim; }
|
||||
_bool Get_PlayAnim() const { return m_bPlayAnim; }
|
||||
_int Get_AnimIndex() const { return m_iCurrentAnimIndex; }
|
||||
_int Get_SecondAnimIndex() const { return m_iCurrSecondAnimIndex; }
|
||||
_float Get_AnimSpeed();
|
||||
void Set_AnimSpeed(_float fSpeed);
|
||||
|
||||
HRESULT Anim_Event(_float fRatio, _uint AnimIndex, function<void()> Event);
|
||||
HRESULT Anim_Event(_float fRatio, _uint AnimIndex, function<void()> Event);
|
||||
|
||||
void Set_BlendDuration(_float Duration) { m_fBlendDuration = Duration; }
|
||||
void Set_BlendDuration(_float Duration) { m_fBlendDuration = Duration; }
|
||||
|
||||
_float4 Get_RootBoneMomentum() { return m_RootBoneMomentum; }
|
||||
|
||||
_float4 Get_RootBoneMomentum() { return m_RootBoneMomentum; }
|
||||
#pragma endregion
|
||||
#pragma region Mesh
|
||||
const _char* Get_MeshName(_uint iIndex);
|
||||
@@ -127,6 +128,7 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
_uint Get_BoneAbsoluteCount();
|
||||
HRESULT Set_BoneCombinedTransformation(const _char* pBoneName, _fmatrix newTransformation);
|
||||
HRESULT Capture_BoneBuffer(class CMotion_Trail* pTrail, const _float4x4& CurrentWorldMatrix);
|
||||
void IsSkip(_bool bSkip) { m_IsSkip = bSkip; }
|
||||
// HRESULT Set_BoneLocalTransformationMatrix(const _char* pBoneName, _fmatrix newTransformation);
|
||||
|
||||
#pragma endregion
|
||||
@@ -224,9 +226,9 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
_float m_fRadius = { 0.f }; // 컬링용 Radius
|
||||
_int m_iRootBoneIndex = { -1 }; // 루트본의 인덱스
|
||||
_uint m_iIndexAnimPlayableMesh = { 0 };
|
||||
_float4 m_OutScale;
|
||||
_float4 m_OutRotation;
|
||||
_float4 m_OutTranslation;
|
||||
_float4 m_OutScale = {};
|
||||
_float4 m_OutRotation = {};
|
||||
_float4 m_OutTranslation = {};
|
||||
|
||||
|
||||
vector<_uint> m_iBoneMask;
|
||||
@@ -249,6 +251,7 @@ class ENGINE_DLL CModel final : public CComponent
|
||||
_bool m_bQueuedLoop = false;
|
||||
_bool m_bQueuedAnim = { false };
|
||||
_float4 m_RootBoneMomentum = {};
|
||||
_bool m_IsSkip = {false};
|
||||
|
||||
|
||||
private:
|
||||
|
||||
@@ -15,7 +15,7 @@ enum ESTATE
|
||||
DODGE,DODGE_BLINK, DODGE_LEFT, DODGE_RIGHT,DODGE_ATTACK,
|
||||
COMBAT, SKILL, SKILL2,
|
||||
SPELL, SPELL_180_R, SPELL_90_R, SPELL_90_L, SPELL_90_L2,
|
||||
LIGHT_ATTACK,LIGHT_ATTACK_180_R, LIGHT_ATTACK_90_L, LIGHT_ATTACK_90_R1, LIGHT_ATTACK_90_R2, LIGHT_ATTACK_90_R3,
|
||||
LIGHT_ATTACK, LIGHT_ATTACK2, LIGHT_ATTACK3, LIGHT_ATTACK4,LIGHT_ATTACK_180_R, LIGHT_ATTACK_90_L, LIGHT_ATTACK_90_R1, LIGHT_ATTACK_90_R2, LIGHT_ATTACK_90_R3,
|
||||
ATTACK_END,
|
||||
SHUFFLE1, SHUFFLE2, SHUFFLE3, SHUFFLE4,
|
||||
MAPHELP,POTION,
|
||||
|
||||
Reference in New Issue
Block a user