浏览代码

Merge pull request #73070 from winterpixelgames/bugfix/linebuilder_box_uvs_3.x

[3.x] Fix Line2D UVs when using BOX end cap mode
lawnjelly 2 年之前
父节点
当前提交
fda3acd94d
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      scene/2d/line_builder.cpp

+ 2 - 0
scene/2d/line_builder.cpp

@@ -407,6 +407,8 @@ void LineBuilder::build() {
 	if (end_cap_mode == Line2D::LINE_CAP_BOX) {
 		pos_up1 += f0 * hw * width_factor;
 		pos_down1 += f0 * hw * width_factor;
+
+		current_distance1 += hw * width_factor;
 	}
 
 	if (texture_mode == Line2D::LINE_TEXTURE_TILE) {