Ensure no crash happens when skeleton is removed, closes #20677
This commit is contained in:
parent
a397d3a46a
commit
c48027af92
|
@ -194,7 +194,7 @@ void Polygon2D::_notification(int p_what) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!invert && bone_weights.size()) {
|
if (skeleton_node && !invert && bone_weights.size()) {
|
||||||
//a skeleton is set! fill indices and weights
|
//a skeleton is set! fill indices and weights
|
||||||
int vc = points.size();
|
int vc = points.size();
|
||||||
bones.resize(vc * 4);
|
bones.resize(vc * 4);
|
||||||
|
|
Loading…
Reference in New Issue