View Full Version : Particles to deform sphere
03-06-2009, 12:25 AM
Hi, I was wondering if anyone could point me in the right direction to make a stream of particles hit a sphere and bounce off but also cause the sphere to deform? Thanks!
03-06-2009, 12:29 AM
With Maya 2009 you can just make the sphere nCloth and create nParticles and they will deform the sphere.
03-06-2009, 12:32 AM
Thank you I've read about that, unfortunately I'm running 2008. Is there a way to do it in 08?
03-06-2009, 01:03 AM
You could make the particles the source of a radial field(use selected as source of field) then under special effects on the field turn on apply per vertex. Also set the max distance relatively low on the field( perhaps a little larger than the sphere triangle size).Turn the sphere into a soft body and have the field affect it but not the particle system. Lower conserve on the soft body to keep it from moving too much. You then do makeCollide between the sphere and the particles.
03-06-2009, 01:22 AM
Sorry about this but I'm fairly new to dynamics in Maya. I've tried what you have suggested but I think I must not be doing it right. Under the radial field, apply per vertex seems to be locked. I'm not sure if the "use selected as source of field" part is even doing anything, I select the emitter and then the field and click it but nothing is happening. I tried selecting the emitter and then the sphere and doing "make collide" but the particles are still passing through the sphere, although the sphere is a soft body.
03-06-2009, 01:49 AM
Ok, here is a step by step workflow:
1. create a poly sphere and a particle emitter.
2. select the sphere and do create soft body
3. select pSphere1Particle (child of pSphere1) and create a radial field
4. select radialField1, then particleShape1 and do "use selected as source of field"
5. On radialField1 toggle on applyPerVertex (should not be greyed out if you did step 4 with the correct selection) Set maxDistance to .5, magnitude to 100.
6. On the softbody (pSphere1Particle) make conserve zero.
7. select particleShape1 followed by pSphere1 and do particles:make collide.
If you want to get fancier you could select the pSphere1Particle and create springs.
03-06-2009, 02:14 AM
Thank you very much for your help! That's a definite improvement, but still not quite what I'm looking for yet. At the moment the particles hit the sphere and punch through the front side and out the back, creating a deformation and hole in both sides. Is there a way to have the particles hit the sphere and bounce/ricochet off instead of punching through, while creating smaller deformations on the sphere, something more like small waves or jiggles for every particle that hits? I really appreciate your help :)
03-06-2009, 06:06 PM
It will help if your sphere is high resolution with lots of vertices. Adjust the field max distance and magnitude to get the right amount of push relative to rebound. If the particles are pushing right through the sphere creating holes then the magnitude is too high. Also you might make the field dropoff zero. Note that with smaller triangles on the soft body you can make the maxDistance lower for more detail, although very fast moving particles may tend to bounce without pushing the softbody. If the particle moves more in a step than the max distance, you might not get a push. Making the resilience( or bounce ) zero will tend to insure that you always get a push, but the particles will then not rebound.
Note that as the surface dents the vertices will tend to push apart, which then would resist further denting for some hits. If you attach weak springs to your soft body then it will tend to preserve the edge lengths of the triangles. (although if the springs are too strong it will just wiggle instead of denting) It is probably best to see how close you can get without using springs first.
03-06-2009, 06:47 PM
I noticed you mentioned jiggles or waves... this is quite possible instead of denting, although would involve adding springs to the mesh. If one increases conserve( very close to 1) with loose springs the mesh will move and jiggle when hit. One could also create a duplicate mesh then attract to it, which can be used to create a waterlike surface with waves.
Instead of softbodies you might use nCloth (if you have unlimited). The same radial field can affect nCloth just as it can the soft body, and one has way more options as to the surface behavior.
Note also that one can turn off all the edge and face relative behavior on an nCloth so that it is essentially like a bunch of particles. (collisions = vertices, stretch/compression/bend = 0) One could then fire mesh vertices of such an nCloth(like having nParticles) at a second nCloth, allowing one to get more realistic collisions and denting than with the particle setup.
03-06-2009, 09:39 PM
Thank you once again! I have tried using nCloth instead, the problem at the moment is that the particles tend to eventually push the entire sphere out of the way and off the screen, I would prefer it to stay in one place and only change it's shape. Is there a certain attribute or anything that might create this effect?
03-06-2009, 09:43 PM
It seems that I've at least partially answered my own question, friction reduces the amount it actually translates while keeping at least some of the impact deformation occurring on the surface.
03-11-2009, 01:46 AM
To keep an ncloth sphere from sliding away you could simply constrain the position of a few vertices with a transform constraint. Or increasing the drag will tend to keep the sphere from moving. Note that if you want you could even constrain all the vertices on the sphere and set the glue strength... where it was hit it might be strong enough to break the constraint and create a dent while the other points would still be held (you need to get the glue strength at just the right value for this to work).
03-11-2009, 01:46 AM
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.
vBulletin v3.0.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.