Преглед на файлове

Fix incorrect example in shader language (uniforms section)

Yuri Rubinsky преди 3 години
родител
ревизия
b578978c8e
променени са 1 файла, в които са добавени 3 реда и са изтрити 1 реда
  1. 3 1
      tutorials/shaders/shader_reference/shading_language.rst

+ 3 - 1
tutorials/shaders/shader_reference/shading_language.rst

@@ -727,7 +727,9 @@ GDScript:
 
 ::
 
-  material.set_shader_param("some_value", some_value)
+  material.set_shader_uniform("some_value", some_value)
+
+  material.set_shader_uniform("colors", [Vector3(1, 0, 0), Vector3(0, 1, 0), Vector3(0, 0, 1)])
 
 .. note:: The first argument to ``set_shader_param`` is the name of the uniform
           in the shader. It must match *exactly* to the name of the uniform in