Fix T38881: cloth preset rubber not working with "translated data names" i18n option
authorBastien Montagne <montagne29@wanadoo.fr>
Fri, 28 Feb 2014 16:28:01 +0000 (17:28 +0100)
committerBastien Montagne <montagne29@wanadoo.fr>
Fri, 28 Feb 2014 16:30:30 +0000 (17:30 +0100)
Actually, was broken for any custom modifier name, since it was explicitly using 'Cloth' one. Changed to mimic other cloth pressets (wonder why this one was different!).

release/scripts/presets/cloth/rubber.py

index c2d7625d3339fc61d7e51d0738618b0f8eca5c73..cb354168daa769b2f9773c1828351755f7c89315 100644 (file)
@@ -1,7 +1,7 @@
 import bpy
-bpy.context.active_object.modifiers['Cloth'].settings.quality = 7
-bpy.context.active_object.modifiers['Cloth'].settings.mass = 3
-bpy.context.active_object.modifiers['Cloth'].settings.structural_stiffness = 15
-bpy.context.active_object.modifiers['Cloth'].settings.bending_stiffness = 25
-bpy.context.active_object.modifiers['Cloth'].settings.spring_damping = 25
-bpy.context.active_object.modifiers['Cloth'].settings.air_damping = 1
+bpy.context.cloth.settings.quality = 7
+bpy.context.cloth.settings.mass = 3
+bpy.context.cloth.settings.structural_stiffness = 15
+bpy.context.cloth.settings.bending_stiffness = 25
+bpy.context.cloth.settings.spring_damping = 25
+bpy.context.cloth.settings.air_damping = 1