procedural RBD activation problem

   3904   5   0
User Avatar
Member
512 posts
Joined: July 2009
Offline
hi guys,

I created a very simple scene of cubes of whom each cube
gets an attribute “ymin” and is sent into the a dopnet.
In the Dopnet I move a plane upwards and have an ActiveValue Node
in which I basically say this:
if “ty” of the plane is bigger than “ymin” of each cube then set the active value to 1.

It should really be that easy, but something in my scene is wrong so the cubes in the simulation don't behave like they shoud!!

hip is attached, please help me out

all the best,

Manu

Attachments:
procedural RBD activation.hipnc (143.6 KB)

http://vimeo.com/user2522760 [vimeo.com]
http://stormbornvfx.com/ [stormbornvfx.com]
Manuel Tausch
User Avatar
Member
586 posts
Joined: Nov. 2005
Offline
hi Manuel

modify your dopfield expression in the rbdstate node to:

if( dopoption(“.”, “grid”, “Position”, “ty”) >= point(“/obj/dopnet:mygroup_”+($OBJID-3)+“/Geometry”, 0, “ymin”, 0), 1, 0)

Your box naming starts at zero, but the objid is allready at 3, as 0,1 and 2 are allready occupied by other objects.

I'm also looking for a way to reference this more bulletproof


cheers Martin
User Avatar
Member
512 posts
Joined: July 2009
Offline
thanks buddy, you're always one step ahead

I have an idea, didn't test it out yet, though! As the groups are created at SOP level, one could combine the existent expression with the argc(primgrouplist()) expression and on that way return the exact group names with the numeric suffixes at their ends.

I'm quite busy right now but I'll give it a shot tomorrow!
http://vimeo.com/user2522760 [vimeo.com]
http://stormbornvfx.com/ [stormbornvfx.com]
Manuel Tausch
User Avatar
Member
586 posts
Joined: Nov. 2005
Offline
mh, not sure about the argc expression, but maybe I didn't get your idea
i was thinking about linking them by a additional data in dops, we will see.

Martin
User Avatar
Member
512 posts
Joined: July 2009
Offline
ok, sorry I was wrong, actually I meant the arg() expression!
you could write arg(primgrouplist(“/obj/boxes/foreach1), 2).
2 would give you the second argument then: mygroup_02
Now the whole thing becomes complicated again as one would have to find a way to stamp the number that describes the argument.
That could certainly be achieved with the applydata DOP where you can define a variable and stamp this value. As a convenience we already created the ”class" attribute in the SOP context so maybe this could be used to stamp!
know what I mean?
http://vimeo.com/user2522760 [vimeo.com]
http://stormbornvfx.com/ [stormbornvfx.com]
Manuel Tausch
User Avatar
Member
586 posts
Joined: Nov. 2005
Offline
you mean the copyDataDOP? I'm sure there are more than one way to achieve it, as usual, hehe
  • Quick Links