[Add] ReparoObject 추가

[Add] 빗자루 한종류 추가
This commit is contained in:
hyunbin14
2025-12-31 16:21:20 +09:00
parent a3733f1416
commit 6cfac86a71
38 changed files with 504 additions and 86 deletions
+22
View File
@@ -383,6 +383,12 @@ HRESULT CMesh::Ready_VertexBuffer_For_Anim(const CModel* pModel, SaveMesh* _Save
{
SaveBoneWeight _SaveBoneWeight = _SaveBone.Weights[j];
if (_SaveBoneWeight.VertexId >= m_iNumVertices)
{
continue;
}
if (0.f == pVertices[_SaveBoneWeight.VertexId].vBlendWeight.x)
{
pVertices[_SaveBoneWeight.VertexId].vBlendIndex.x = i;
@@ -406,6 +412,22 @@ HRESULT CMesh::Ready_VertexBuffer_For_Anim(const CModel* pModel, SaveMesh* _Save
}
}
for (_uint i = 0; i < m_iNumVertices; ++i)
{
_float sum =
pVertices[i].vBlendWeight.x +
pVertices[i].vBlendWeight.y +
pVertices[i].vBlendWeight.z +
pVertices[i].vBlendWeight.w;
if (sum <= 0.f)
{
pVertices[i].vBlendIndex.x = 0;
pVertices[i].vBlendWeight.x = 1.f;
}
}
if (0 == m_iNumBones)
{
m_iNumBones = 1;