summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2023-11-07 23:20:45 +0100
committerJuan Linietsky <reduzio@gmail.com>2023-11-07 23:20:45 +0100
commitc430ff2396d1f7372c88a8ea080ecbf94a43fc9e (patch)
tree3ce1f31f6828e1d5c69eeff1f944538cdbcc8d2b
parent3e7f638d7b574785f521beafaf52a6ad95be016f (diff)
downloadredot-engine-c430ff2396d1f7372c88a8ea080ecbf94a43fc9e.tar.gz
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.
-rw-r--r--editor/shader_create_dialog.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/editor/shader_create_dialog.cpp b/editor/shader_create_dialog.cpp
index 28776cbddc..e5851d9333 100644
--- a/editor/shader_create_dialog.cpp
+++ b/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: