View Full Version : PEN Attribute Holder for Max 8 Available.

10 October 2005, 01:30 PM
For those of you that use the PEN Attribute Holder script for your custom attributes I have had to make changes to the code that will only work in Max 8. This code corrects issues I had in previous version of Max where I had to expliot a bug to get around a bug so that they fly out menues would stay in scope of the modifier. Both bugs were corrected in Max and breaking this tool but a proper solution was added that is now part of V:2.06

You can down load the new script at in the scripts section.

10 October 2005, 03:35 PM
good stuff, paul do you know if rollout floaters launched from modifiers can now also access the modifier's scope? i think this is the same bug

(remember my pm about this?)

10 October 2005, 04:25 PM
good stuff, paul do you know if rollout floaters launched from modifiers can now also access the modifier's scope? i think this is the same bug

(remember my pm about this?)

I have played with this but it is a nightmare to manage the rollouts. If you use a rollout floater you are now out of scope of the plugin and if you use createDialog you run into the problem of having to manage multiple rollouts. Easy if you only have one rollout but as I always have dealing with more is a real problem as you can't scroll rollouts in a dialog like you can in a rollout floater. I'm not sure what to do about it at this stage but i would like to set up a system that allows for the rollouts to be floated into a dialog. Also if I float the UI for the PEN Attribute holder itself on say the right hand I can't then float one for the left hand as well because it is an instance of it.

All round there is no easy way to handle this. Bobo, if you are there I would love to know if you have any tricks to do this sort of thing.

10 October 2005, 10:17 PM
PEN, the current script i'm working on already has the functionality i need, but with a dirty workaround... i was able to get a rollout floater while preserving the scope of the plugin, i can put all the rollouts of my modifier into the floater, it doesn't get around some of the problems you described though (like launching multiple instances of the modifier into rollouts)

i can have a button (launchFlt_bt) within the modifier to launch the floater, i then switch to the create panel so the rollouts i want to put in the floater are not displayed anymore, then i switch back to the modify panel...

if the floater is then closed, the rollouts are put back in the modify panel by switching to the create panel and back again

here's an event handler i use within the modifier to do this, it puts and instance of the modifier into a global variable, works like a charm so far for what i need

any chance this will be easier with max8?

on launchFlt_bt pressed do (
if rolloutFlt == undefined then (
setCommandPanelTaskMode mode:#create

if fltPosX > 0 and fltPosY > 0 then (
rolloutFlt = newRolloutFloater "Aearon CharTools" 179 530 fltPosX fltPosY
) else (
rolloutFlt = newRolloutFloater "Aearon CharTools" 179 530

global Aearon_CharTools_myMod = this

-- this rollout is actually only in the floater to call
-- its own "on close" event when the floater is closed
-- it restores the rollouts within the modifier if the
-- modify panel currently displays the modifier the floater
-- was called from. if you call this handler in a rollout
-- that is also in the modifier that rollout won't appear
-- because it's still open in the floater when this handler
-- is called and can only be open once
Rollout about_rlt "About" rolledUp:true (
label copyright_lbl " Kai Stavginski 2005"

on about_rlt close do (
Aearon_CharTools_myMod.fltPosX = Aearon_CharTools_myMod.rolloutFlt.pos[1]
Aearon_CharTools_myMod.fltPosY = Aearon_CharTools_myMod.rolloutFlt.pos[2]

Aearon_CharTools_myMod.rolloutFlt = undefined

if modPanel.getCurrentObject() == Aearon_CharTools_myMod then (
setCommandPanelTaskMode mode:#create
setCommandPanelTaskMode mode:#modify
modPanel.setCurrentObject Aearon_CharTools_myMod

Aearon_CharTools_myMod == undefined

--add all the modifier's rollouts
addRollout this.layers_rlt rolloutFlt
addRollout this.cas_rlt rolloutFlt
addRollout this.poses_rlt rolloutFlt

--add the extra rollout
addRollout about_rlt rolloutFlt

setCommandPanelTaskMode mode:#modify
modPanel.setCurrentObject this

10 October 2005, 11:59 PM

I just tried this with mine and pauls modifier. Create a new rollout. Remove all the rollouts from the modifier that you plan on moving to the floating rollout. Now add them to the floating rollout. If you click off of the object with the modifier then click back onto it while the floating rollout holds the rollout the modifier will not respawn the rollout. If you kill the rollout the modifier will bring back the rollout the next time you click back onto it.


on testFloat pressed do
newRoll = newRolloutFloater "Test Floater" 150 400
removeRollout this.dummy_hiearchy_roll
addRollout this.dummy_hiearchy_roll newRoll

10 October 2005, 12:15 AM
You can only have one instance of a rollout as far as I know. So once it is floating it will not display in the modifier panel. Ryan showed me that you can scroll rollouts in dialogs so I think that I will take a stab at floating the UI again.

10 October 2005, 11:24 AM
I know I'm posting off the theme but it is really important for me so...could Pau or anybody look at this one.
Its the script from the advanced rigging dvd's where you showed the technique to add custom rollouts to attribute holder so I wrote it almost the same script you showed.
But the problem is that when I run it, it doesnt do anything. :(
I know it is really easy script, but still, could anybody help me.
Using max 7.

10 October 2005, 07:31 AM
No worries I solved the problem. There were some syntax problems ... lol.

10 October 2005, 01:01 PM
Usualy the case with my scripts as well. I'm glad that you have it working.

02 February 2006, 12:56 PM
Paul, i hope this is the right place to post this:

i'm using your attribute holder for some of my stuff, and here's a feature request should you ever find the time

i would really like the reset button to not reset the parameters to 0, but to their individual default value... for some parameters having them zero'd out just doesn't make that much sense, so i think this would be nice

02 February 2006, 01:03 PM
The problem is you can't query what the range values are so they would have to be stored by the user in defdata when then definition is added to the modifiier. I always rig my characters so that every thing is 0 for the T pose. animators like to know that when they see values of 0 in track view that means it is in the default pose. It also keeps all the function curves around the same area in track view so that when you zoom extents on them you are not seeing some huge value range.

I have several additions that I want to add to it and even got started on it but like every one I'm not paid to work on my own stuff. One day I will release version 3 and you will see lots of changes to it.

02 February 2006, 03:28 PM
i thought this was possible by reading the PBBlock data, looks like it's not! ;)

you're right, having them all at zero does have some advantages, just for parameters like 'pupil size' and stuff like that it seems a little awkward, but i guess i can live with that

but like every one I'm not paid to work on my own stuff.

i know what you're talking about ;) i guess you just have to sell as much as possible as "this is needed to do the job properly" hehe

CGTalk Moderation
02 February 2006, 03:28 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.