Hey again! I was wondering if any one could dynamic expressions? I
have a set of particles which have instanced geomentry but i need to
create a simple runtime expression to control the rotation of these
objects. Now i've heard that python is terrible for expressions and
i've read another posts on here about dynamic expressions but have not
been able to get them to work. It's not that complex of an expression,
and i'm only calling particle attributes and not any variables i've
defined in Python.
Well, here's the expression -
string $runTime = "if ( frame <= 2.0 ) { \n" +
" rotateInitPP = << rand( rotMultMin,
rotMultMax ), rand(rotMultMin,rotMultMax), rand(rotMultMin,
rotMultMax ) >>; \n" +
" mass *= rand
( massMultMin, massMultMax ); \n" +
"} else { \n" +
" vector $vel =
velocity; \n" +
" vector $rot =
rotateInitPP; \n " +
" rotatePP += <<
$vel.x * $rot.x, $vel.y * $rot.y, $vel.z * $rot.z >>; \n" +
"} \n"
I was wondering if any one could help me in getting this to work in a
dynExpression. I was thinking maybe a simple MEL wrapper would work
but i havn't been able to get that working so any ideas any one has
would be welcome : - ).
--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/python_inside_maya
-~----------~----~----~----~------~----~------~--~---