浏览代码

Classref fixes

(cherry picked from commit 98452b288a114ff9ffbbbcf0db1adf1d61c78ff3)
Max Hilbrunner 2 年之前
父节点
当前提交
cede79e089
共有 1 个文件被更改,包括 8 次插入11 次删除
  1. 8 11
      classes/class_immediatemesh.rst

+ 8 - 11
classes/class_immediatemesh.rst

@@ -26,17 +26,14 @@ Here's a sample on how to generate a triangular face:
 
 .. tabs::
 
-var mesh = ImmediateMesh.new()
-
-mesh.surface_begin(Mesh.PRIMITIVE_TRIANGLES)
-
-mesh.surface_add_vertex(Vector3.LEFT)
-
-mesh.surface_add_vertex(Vector3.FORWARD)
-
-mesh.surface_add_vertex(Vector3.ZERO)
-
-mesh.surface_end()
+ .. code-tab:: gdscript
+
+    var mesh = ImmediateMesh.new()
+    mesh.surface_begin(Mesh.PRIMITIVE_TRIANGLES)
+    mesh.surface_add_vertex(Vector3.LEFT)
+    mesh.surface_add_vertex(Vector3.FORWARD)
+    mesh.surface_add_vertex(Vector3.ZERO)
+    mesh.surface_end()