mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 02:51:49 +00:00
fix fatal error when skeleton is missing
This commit is contained in:
parent
b2df0a7e91
commit
8b5261f4f1
3 changed files with 16 additions and 5 deletions
|
|
@ -64,7 +64,7 @@ dv::value Entity::serialize() const {
|
|||
root[COMP_RIGIDBODY] =
|
||||
rigidbody.serialize(def.save.body.velocity, def.save.body.settings);
|
||||
|
||||
if (skeleton != nullptr) {
|
||||
if (skeleton != nullptr && skeleton->config != nullptr) {
|
||||
if (skeleton->config->getName() != def.skeletonName) {
|
||||
root["skeleton-name"] = skeleton->config->getName();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue