[Bf-blender-cvs] [32c1827] master: Fix T38881: cloth preset rubber not working with "translated data names" i18n option

Bastien Montagne noreply at git.blender.org
Fri Feb 28 17:32:06 CET 2014


Commit: 32c18276ef4e3b4035d03f459399f87517798c4e
Author: Bastien Montagne
Date:   Fri Feb 28 17:28:01 2014 +0100
https://developer.blender.org/rB32c18276ef4e3b4035d03f459399f87517798c4e

Fix T38881: cloth preset rubber not working with "translated data names" i18n option

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!).

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

M	release/scripts/presets/cloth/rubber.py

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

diff --git a/release/scripts/presets/cloth/rubber.py b/release/scripts/presets/cloth/rubber.py
index c2d7625..cb35416 100644
--- a/release/scripts/presets/cloth/rubber.py
+++ b/release/scripts/presets/cloth/rubber.py
@@ -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




More information about the Bf-blender-cvs mailing list