Search - User list
Full Version: @pintoanimation in Wrangle node does not work
Root » Work in Progress » @pintoanimation in Wrangle node does not work
ZacFilms
Hallo,

I have following Problem: I need to simulate a person dissolving to ash and particles. Particle sim is working so far, but if I connect both simulations, the ash doesnt work. I have a Boolean object, which is getting bigger and bigger and bools away the object, while transfering its white color to the dissolving object over attributetransfer. The particles are emitted from white scattered Points. I connect the Attributetransfer before he Attributewrangle in the other simulation, so I have the same color attributes. In the Wrangle node I tried to set @pintoanimation to 0 if the points have a @Cd bigger than 0.1, but it doesnt work. I think its a tiny mistake somewhere, but I cant find it. I would appreciate any help.
Thanks, Zac
neil_math_comp
ZacFilms
I think its a tiny mistake somewhere
I'm not 100% sure, but I suspect so too. Perhaps the last line of code in attribwrangle2 is scrolled out of view on your screen?

f@b = @Cd.r;

if (f@b > 0.1) {
f@pintoanimation = 0;
}
if (f@b < 0.1) {
f@pintoanimation = 1;
}
f@pintoanimation = 0;

That last line will always set f@pintoanimationto 0, regardless of the value of @Cd.r, since it's not in an if statement. Hopefully that's all that was amiss.
ZacFilms
Oh, thank you. I changed it, but its still not working.
ZacFilms
Gosh, looks like I have to figure it out in my own… Anyone want to help a poor student and collect some Karma-Points?
Benjamin Lemoine
Hey ZacFilms !
i took a look at your file , i switch of some stuff for testing purpose
i saw a few problem …
number one , your script …ndickson was right , you only need :

f@b = @Cd.r;

if (f@b > 0.1) {
f@pintoanimation = 0;
}
if (f@b < 0.1) {
f@pintoanimation = 1;
}

number two :

i add a solver to have the white color accumulate

number three :

the cloth geometry is only import in the first frame
if you want the solver to take the changing attribute pintoanimation into account you need to do that in a sop solver

that's what i've done …

and it seems to work….

what do you think ???
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB