feat: updated engine version to 4.4-rc1

This commit is contained in:
Sara 2025-02-23 14:38:14 +01:00
parent ee00efde1f
commit 21ba8e33af
5459 changed files with 1128836 additions and 198305 deletions

View file

@ -36,18 +36,18 @@
Line2D::Line2D() {
}
#ifdef TOOLS_ENABLED
#ifdef DEBUG_ENABLED
Rect2 Line2D::_edit_get_rect() const {
if (_points.size() == 0) {
return Rect2(0, 0, 0, 0);
}
Vector2 d = Vector2(_width, _width);
Rect2 bounding_rect = Rect2(_points[0] - d, 2 * d);
Vector2 min = _points[0];
Vector2 max = min;
for (int i = 1; i < _points.size(); i++) {
bounding_rect.expand_to(_points[i] - d);
bounding_rect.expand_to(_points[i] + d);
min = min.min(_points[i]);
max = max.max(_points[i]);
}
return bounding_rect;
return Rect2(min, max - min).grow(_width);
}
bool Line2D::_edit_use_rect() const {
@ -299,6 +299,9 @@ void Line2D::_draw() {
}
lb.build();
if (lb.indices.is_empty()) {
return;
}
RS::get_singleton()->canvas_item_add_triangle_array(
get_canvas_item(),