3dcheapskate
Busy Bee
There's already a topic on this subject over there on the Renderosity PoserPython forum but I thought I'd ask here too.
I've detailed the problem in the comments of the script itself, which should appear below as inline code. I've also attached the script, zipped. Can anybody explain why it doesn't work as expected, and instead does what it does ?
I've detailed the problem in the comments of the script itself, which should appear below as inline code. I've also attached the script, zipped. Can anybody explain why it doesn't work as expected, and instead does what it does ?
# This script sets up a simple update callback on the yRotate dial of the currently selected actor
# My understanding of what SHOULD happen:
# - 1) This callback should be called ONLY if the natural* (lower) value of the yRotate dial on the currently selected actor is changed.
# - 2) Each time this callback runs it should increment the keyed* (upper) value of the yRotate dial.
#
# *using the terminology under the heading "Dependant Parameter Dials" on page 222 of the Poser 11 Reference Manual
# What ACTUALLY happens:
# - 1) The callback seems to be called if ANY dial is changed. Or if a different body part is selected, or if you change rooms, etc...
# - 2) The callback seems to be called multiple times, usually between 1 and 5, when any of these things happen
def cheapskatesYRotateCallback(parm,value):
global cheapskatescount
cheapskatescount=cheapskatescount+1
return cheapskatescount
print "Setting up the yRotate callback..."
global cheapskatescount
cheapskatescount=0
poser.Scene().CurrentActor().Parameter("yRotate").SetUpdateCallback(cheapskatesYRotateCallback)
print "...done."