Commit: 94a069a7950c37bb2240b3b846ce2587e8446452
Author: Brecht Van Lommel
Date:   Wed Nov 28 18:48:02 2018 +0100
Branches: blender2.8
https://developer.blender.org/rB94a069a7950c37bb2240b3b846ce2587e8446452

Startup.blend: rename Lamp to Light.

===================================================================

M       source/blender/blenloader/intern/versioning_defaults.c

===================================================================

diff --git a/source/blender/blenloader/intern/versioning_defaults.c 
b/source/blender/blenloader/intern/versioning_defaults.c
index 055e4b065a1..d040ff9d6ed 100644
--- a/source/blender/blenloader/intern/versioning_defaults.c
+++ b/source/blender/blenloader/intern/versioning_defaults.c
@@ -243,14 +243,24 @@ void BLO_update_defaults_startup_blend(Main *bmain, const 
char *app_template)
                        BKE_view_layer_rename(bmain, scene, 
scene->view_layers.first, "View Layer");
                }
 
+               /* Rename lamp objects. */
+               for (Object *ob = bmain->object.first; ob; ob = ob->id.next) {
+                       if (STREQ(ob->id.name, "OBLamp")) {
+                               STRNCPY(ob->id.name, "OBLight");
+                       }
+               }
+               for (Lamp *lamp = bmain->lamp.first; lamp; lamp = 
lamp->id.next) {
+                       if (STREQ(lamp->id.name, "LALamp")) {
+                               STRNCPY(lamp->id.name, "LALight");
+                       }
+               }
+
                for (Mesh *mesh = bmain->mesh.first; mesh; mesh = 
mesh->id.next) {
                        /* Match default for new meshes. */
                        mesh->smoothresh = DEG2RADF(30);
                }
-       }
 
-       /* Grease Pencil New Eraser Brush */
-       if (builtin_template) {
+               /* Grease Pencil New Eraser Brush */
                Brush *br;
                /* Rename old Hard Eraser */
                br = (Brush *)BKE_libblock_find_name(bmain, ID_BR, "Eraser 
Hard");

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to