Merge pull request #85455 from xiongyaohua/fix_CSGPolygon_not_following_Path3D

Notify CSGPolygon about transform changes in Path3D
This commit is contained in:
Rémi Verschelde 2024-02-15 15:44:39 +01:00
commit 4859f8090f
No known key found for this signature in database
GPG key ID: C3336907360768E1
3 changed files with 18 additions and 6 deletions

View file

@ -1826,11 +1826,13 @@ CSGBrush *CSGPolygon3D::_build_brush() {
if (path) {
path->disconnect("tree_exited", callable_mp(this, &CSGPolygon3D::_path_exited));
path->disconnect("curve_changed", callable_mp(this, &CSGPolygon3D::_path_changed));
path->set_update_callback(Callable());
}
path = current_path;
if (path) {
path->connect("tree_exited", callable_mp(this, &CSGPolygon3D::_path_exited));
path->connect("curve_changed", callable_mp(this, &CSGPolygon3D::_path_changed));
path->set_update_callback(callable_mp(this, &CSGPolygon3D::_path_changed));
}
}