FVerbaas opened this issue on Dec 13, 2017 ยท 6 posts
FVerbaas posted Wed, 13 December 2017 at 3:23 PM Forum Coordinator
I am getting on with my MarvelousSynchroniser.
I have come to the point that the script puts up a stay-on-top dialog with a button that does trigger the export to (.obj format) and a text box showing the text 'synchronised' after succesful completion. The dialog stays on until dismissed.
I now want to make the text box show whether the figure pose is still as exported, so change to 'click to update' if a parameter of the selected figure is changed.
Is there an example how to do this? : I recall having seen some 'onParameterChange()' somewhere but I cannot find it anymore now.
structure posted Thu, 14 December 2017 at 4:46 AM Forum Coordinator
you may be looking for kEventCodeParmChanged, however, there is very little information on it in the manual.
Locked Out
ironsoul posted Thu, 14 December 2017 at 12:41 PM
Not sure if its what you had in mind but here's the parmCallback.py script in the program's runtime C:/Program Files/Smith Micro/Poser 11/Runtime/Python/poserScripts/SampleCallbacks.
FVerbaas posted Thu, 14 December 2017 at 1:34 PM Forum Coordinator
@Structure: That does it!
An event with kEventCodeParmChanged is raised the first time you spin a dial after selecting it. It is Not raised when you spin the dial again without first selecting another so there is no deluge of events when the dial is spinned in small steps.
One thing I learned here in experimenting: if you do not add a clearEventCallback() in the code to kill that @#$% event handler you created, the messages of the test script will bug you until you kill Poser. LOL!!. Also it does not react to master dial changes.
structure posted Mon, 18 December 2017 at 7:27 AM Forum Coordinator
@FVerbaas - glad you managed to get it working .
Locked Out
adp001 posted Tue, 19 December 2017 at 9:15 AM
You can add a Callback to a parameter (dial): parm.SetUpdateCallback(
Any callback must be disabled before removing an actor or the scene is closed (e.g.: save and close or 'new').