Mark01 5 Posted April 7 Hi All! I am trying to simply advect particles using the geometry of an object moving past them - I'm just looking for a small bit of interaction between them. Could someone point me in the right direction. Searching it online, all I seem to find is "popAdvectByVolume". Thanks so much!! Share this post Link to post Share on other sites
Librarian 629 Posted April 7 @Mark01 Open in Houdini 16.5 CHOKOLADA.hipnc 1 Share this post Link to post Share on other sites
Mark01 5 Posted April 7 @Librarian Thank so much for that! I'm running h18. Is this file only for h16.5? Share this post Link to post Share on other sites
Librarian 629 Posted April 7 @Mark01 Old particle system "POPNET" from 16.5 can be reproduced in 18.5... if you have time download 16.5 open and investigate..Have Fun Share this post Link to post Share on other sites
Librarian 629 Posted April 8 (edited) @Mark01 if someone Have Time? to make this for solver and 18.5 I don't understand clearly #pragma label damp "Damp" #pragma label springIdx "Spring Index" #pragma label magExp "Magnet Exponent" #pragma label magnetScale "Magnet Scale" #pragma label maxDist "Max Distance" sop SpringMagnet(float damp = 0.9; float springIdx = 0.5; float magExp = 1; float magnetScale = 0.5; float maxDist = 1; ) { vector target = point(1, "P", 0); vector rest = point(geoself(), "rest", ptnum); // get the spring force based on the rest position vector displace = rest - P; vector springForce = displace * springIdx; // get the magnet force from the target position vector magDist = P - target; float distance = length(magDist); vector magnetForce = set(0,0,0); if(length(distance) < maxDist){ distance = pow(fit(distance, 0 , maxDist, 1, 0), magExp); magnetForce = normalize(magDist) * distance; } vector mainAcc = magnetForce * magnetScale + springForce; v += mainAcc; v = v * damp; P += v; } Edited April 8 by Librarian 1 Share this post Link to post Share on other sites