浏览代码

Comment the shader template light function by default

This is a minor usability tweak.

The light functions replace the default ones, so even if empty
they will avoid the current shader to have proper lighting and
users will have no idea why.

Code was changed to have the shader function commented by default,
indicating that uncommenting replaces the default function.
Juan Linietsky 1 年之前
父节点
当前提交
c430ff2396
共有 1 个文件被更改,包括 6 次插入4 次删除
  1. 6 4
      editor/shader_create_dialog.cpp

+ 6 - 4
editor/shader_create_dialog.cpp

@@ -175,9 +175,10 @@ void fragment() {
 	// Called for every pixel the material is visible on.
 }
 
-void light() {
+//void light() {
 	// Called for every pixel for every light affecting the material.
-}
+	// Uncomment to replace the default light processing function with this one.
+//}
 )";
 						break;
 					case Shader::MODE_CANVAS_ITEM:
@@ -190,9 +191,10 @@ void fragment() {
 	// Called for every pixel the material is visible on.
 }
 
-void light() {
+//void light() {
 	// Called for every pixel for every light affecting the CanvasItem.
-}
+	// Uncomment to replace the default light processing function with this one.
+//}
 )";
 						break;
 					case Shader::MODE_PARTICLES: