loran
02-26-2009, 11:40 AM
I want to change the value of my expression ctrl by using a custom attribute.
I dont find how to point the custom attributes value (here :????)
please help
a=box height:10 width:10
b=cylinder height:20 radius:10 sides:6
-- add custom attributes to a
newAttrib = attributes customattrib
(
Parameters main rollout:params
(
Radius Type:#float UI: Radius Default:30.0
)
Rollout params "cylinder ctrl"
(
spinner Radius "z rotation:" Type:#float Range:[0,10000,30]
)
)
custAttributes.add a newAttrib
--add expression ctrl to cylinder z rotation
b.rotation.controller.z_rotation.controller = Float_Expression()
b.rotation.controller.z_rotation.controller.addScalarTarget "brot" ????
b.rotation.controller.z_rotation.controller.setExpression "brot*4"
I dont find how to point the custom attributes value (here :????)
please help
a=box height:10 width:10
b=cylinder height:20 radius:10 sides:6
-- add custom attributes to a
newAttrib = attributes customattrib
(
Parameters main rollout:params
(
Radius Type:#float UI: Radius Default:30.0
)
Rollout params "cylinder ctrl"
(
spinner Radius "z rotation:" Type:#float Range:[0,10000,30]
)
)
custAttributes.add a newAttrib
--add expression ctrl to cylinder z rotation
b.rotation.controller.z_rotation.controller = Float_Expression()
b.rotation.controller.z_rotation.controller.addScalarTarget "brot" ????
b.rotation.controller.z_rotation.controller.setExpression "brot*4"
