Using the Stick to Surface and Stick to Location compounds, you can make particles stick to an obstacle's surface, or to a specific location on an object's surface, upon collision and remain there for the duration of their lifetime, unless you set up some condition that makes them fall off the obstacle (unstick).
For example, you can create effects such as paint being sprayed onto a surface, metal filings being attracted and sticking to a magnet, or sprinkles getting stuck in the icing on a cupcake. Obstacles can be deform-animated and the particles will follow the shape of the changing surface. This is useful for creating wet snow or mud hitting a surface.
You can choose to use the Stick to Surface and Stick to Location compounds on their own or as part of a more extensive effect via a State system.
Particles stick to surface of the sphere (obstacle) as it passes through a field of falling particles.
Create one or more objects that you want to use as surfaces for the particles to stick on. These objects need to have geometric surfaces, such as polygon meshes or NURBS surface objects. Make sure that the particles will reach these obstacles at some point in the simulation.
Create a particle emission — see Creating a Basic Particle Emission.
Choose Particles Collision Stick to Surface from the ICE toolbar.
This command adds the compound to the ICE tree, plugging it into the Execute port of the Simulation Root compound.
Pick one or more objects to use as the surfaces for sticking. Each object's Get data node is then plugged into the Surface port of the Stick to Surface compound.
You can also add more objects to the ICE tree later — drag each object's name into the ICE Tree view to create a Get Data node for it, then plug it in as the other obstacles.
In the Stick to Surface property editor, set the collision method (for deformed objects or static), use the particle size or create an offset from the obstacle, and align the particles to the obstacle's surface normals.
To unstick the particles from the surface, see Detaching (Unsticking) Particles from Obstacles.
Create the appropriate object that you want to use for the stick location for the particles. This can be:
Create a particle emission — see Creating a Basic Particle Emission.
Choose Particles After Emission Stick to Location from the ICE toolbar.
This command adds the Stick to Location compound to the ICE tree, plugging it into the Execute port of the Simulation Root compound.
In the Stick to Location property editor, define the appropriate location for where the particles will stick according to the type of object you're using (see step 1).
Create a particle emission — see Creating a Basic Particle Emission.
In the ICE Tree, set up State compounds as you like, as described in Overview of Creating a Particle State Setup.
Plug the Stick to Surface or Stick to Location compound's Execute output into an Execute Every Frame port of a State compound.
Plug the Stick to Surface or Stick to Location compound's Execute output into an Execute Every Frame port of a State compound.
Continue with creating the effect you want with the State compound.
If particles are stuck to an obstacle using the Stick to Surface compound, you can detach (unstick) them from obstacle's surface by either setting parameters in the Stick to Surface property editor, or you can use the Unstick from Surface compound in a State system.
Particles become unstuck from the sphere when the force and angle threshold values have been reached.
In the Stick to Surface property editor, you can set up the conditions that release the particle from the surface.
Set up the particles to stick to an object as described in the previous sections, Making Particles Stick to Obstacles.
Open the Stick to Surface property editor and set these parameters:
Select the Allow Unstick parameter. This allows the particles to be released from the surface of the object if the Angle and Force Thresholds are at appropriate values.
Set the Angle Threshold, which is the angle at which the object needs to be before particles will fall off it (unstick). This is based on the obstacle's surface normals and gravity or other forces in the scene. At a low angle, the particles will not unstick easily, whereas at a high angle, they will.
Set the Force Threshold, which is the maximum force required to make the particles fall off the obstacle (unstick). This is used mostly when the obstacle is moving and you want the particles to release from the surface based on the obstacle's velocity. A high threshold makes it more difficult for the particles to unstick, whereas a low threshold makes it easy.
Create a particle emission — see Creating a Basic Particle Emission.
In the ICE Tree, set up State compounds as you like, as described in Overview of Creating a Particle State Setup.
Plug the Stick to Surface compound's Execute output into an Execute Every Frame port of a State compound.
Drag the Unstick from Surface compound from the Surface Interaction group into the ICE view.
Plug its Execute output into the Execute Once on Enter State port of the State compound.
Continue with creating the effect you want with the State compound.
Except where otherwise noted, this work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License