mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
no more children
This commit is contained in:
parent
8dbcaf25c3
commit
d73b86c16a
3 changed files with 5 additions and 9 deletions
|
@ -329,8 +329,6 @@ public:
|
|||
return {trs};
|
||||
}
|
||||
|
||||
//! List of child joints
|
||||
std::vector<SJoint *> Children;
|
||||
|
||||
//! List of attached meshes
|
||||
std::vector<u32> AttachedMeshes;
|
||||
|
|
|
@ -528,8 +528,6 @@ bool CXMeshFileLoader::parseDataObjectFrame(SkinnedMesh::SJoint *Parent)
|
|||
#ifdef _XREADER_DEBUG
|
||||
os::Printer::log("using joint ", name.c_str(), ELL_DEBUG);
|
||||
#endif
|
||||
if (Parent)
|
||||
Parent->Children.push_back(joint);
|
||||
}
|
||||
|
||||
// Now inside a frame.
|
||||
|
|
|
@ -404,12 +404,12 @@ SECTION("simple skin")
|
|||
};
|
||||
|
||||
// Check the node hierarchy
|
||||
const auto parent = findJoint([](auto joint) {
|
||||
return !joint->Children.empty();
|
||||
const auto *parent = findJoint([](auto *joint) {
|
||||
return !joint->ParentJointID;
|
||||
});
|
||||
const auto child = findJoint([&](auto *joint) {
|
||||
return joint->ParentJointID && *joint->ParentJointID == parent->JointID;
|
||||
});
|
||||
REQUIRE(parent->Children.size() == 1);
|
||||
const auto child = parent->Children[0];
|
||||
REQUIRE(child != parent);
|
||||
|
||||
SECTION("transformations are correct")
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue