Hello everyone,
Trying to create a quasar of sorts for use in the skybox, but it's a little flat at the moment, so I thought I'd add some swirling clouds of mass to create some more depth.
Now the problem is I need something along the lines of -this example on the UDN-
"This is the result of using a point attractor in combination with a line attractor with its strength animated over the life of the particle to create the swirling effect."
I've been messing with it for a while now but I don't understand how they achieved it... anybody who knows how this is done?
Replies
1. Start with a basic particle emitter. I deleted the velocity on mine but you can keep it if you want to affect those properties of the effect as well.
2. The first thing you want to adjust is the origin and offset your emitter (since you want to pull the particles to the center with the attractor module). I added an Initial Location module and put the effect at X:256 Y:256 Z:000
3. Next I added a Size By Life module to make them smaller as they got to the center.
4. From there I simply added some Initial Rotation and Initial RotRate to change up the sprites as they spawn.
5. Now for the pull, add a Point Attractor module and turn on 3D Draw Mode under the Cascade properties of the module so that it becomes visible in cascade. Keep the Position at X:000 Y:000 Z:000 since were pulling them into the center. I set the Range to 512 so that the attractor fully encapsulates my particles, depending on the size of your particles this value might change but you should be able to figure out the size you need once you see the attractor in cascade. Next set the Strength to 2000. You should now see your particles getting pulled into the center.
6. Finally the swirl, add a Line Attractor module and make sure to turn on the 3D Draw mode for this too. For End Point 0 I used X:128 Y:000 Z: 000. For End Point 1 its X:128 Y:000 Z:256. My Range is set to 500 and the Strength is at 1.5.
The trick was getting the line attractor to have values that made it swirl along the desired axis. If your end points are right on the particle they will not draw as youve already described. You dont have to use these exact values but just look at the pattern for my end points. For end point 0 you want to change the value of 1 axis, and for end point 1 you will change the value of 2 axis. So your choices are X,Z/Y,Z/X,Y. Depending on which you choose will change the axis that the swirling effect aligns to. If you change the values of all three axis then the result will be particles moving all around in full 3d rather than being locked along one axis.
One last thing to make note of was the Strength values in both attractors. These are both working together so adjust them to your liking by increasing and decreasing the values, just remember that the line attractor is much more sensitive.
Heres an image of mine in cascade. I've cloned the emitter four times, they share the same things except for the Initial Location. Im using the latest version of UDK by the way.
Hope this helps.
Thanks again btw!
been working on some other things as well, trying to create particle nebulae, moderately succesful I suppose
These don't make use of any swirling particles though. But I can foresee loads of uses for it anyway.
A bit of critique though, your single stars are looking a little too repetitive, try making a sub uv texture with 4 different looking stars. Also try setting their Initial Rotation to be something between 0 and 90 degrees (which in cascade would translate to a value of .25 for your Max since a value of 1 equals a full 360 degrees). This way you'll have a more random looking effect (when working with fx the more randomness you have the better). To get a better idea of different star textures just do a google image search for "star clusters" and you'll see what I mean.
Keep posting your progress and whenever you get a chance post a video too.
If I google pictures of star clusters I do see a lot of different colours but the lens effect seems consistent all the way through the picture: http://farm3.static.flickr.com/2341/2026823169_843de9e112_o.jpg for example.
Anyways keep up the good work.
The swirling particles work fine in cascade as seen here;
When I go ingame however
The particles essentially spawn and remain motionless at that point (just the 2 opposite ends that should be swirling.)
First, if your particle systems translation is set to X:000 Y:000 Z:000 in your map the effect works just fine, the emitters are swirling and everythings ok, but its unlikely that this is the final location of the particle system in your map and you might want to clone it around. When the particle system is moved to another location on your map the two emitters no longer swirl, so thats the first thing.
Second thing I did was turn off Use Local Space. That fixes the first issue I mentioned, but I havent rotated the particle system on the map at all, Ive only regained my ability to move it around without losing any control over the particle system.
The first thing youll notice is that theyre not even being pulled in by the Point Attractor. I increased the Strength on the Point Attractor from 5000 to 20,000. The emitters should now be getting pulled in so that was the first thing that was easy to fix. The strength needed to be increased because your particles were pretty large.
My next attempt was to bring back the swirl to the emitters. First thing I changed on your Line Attractor was the Range. I set it from 1800 to 2500 to fully encapsulate your particles. Next I adjusted the value on your End Point 1 from Z: 256 to Z: 1024. The particles should now be swirling.
Remember I still havent rotated the particle system on the map yet. Now Ill rotate it by 45 degrees on the Y-Axis and here is where I found the third strange result. One emitter refuses to swirl because its Initial Location has negative values. If you change the values to something positive it swirls just like the other one, but you want two swirling emitters on opposite ends. Alternatively if you rotate the particle system on the X-Axis instead of the Y-Axis like I did then the emitter with negative values on the Initial location will work but the other wont, so were back to square one.
Ive tried different combinations of using and not using local space, giving the emitter its own line attractor with negative values, separating the correct single swirl as its own particle system cloning it then rotating it, and even making it completely from scratch but only one swirl will work.
I wasnt able to figure it out, but now Im really curious about how this issue can be fixed, so hopefully someone else will be able to help find a solution.
Any polycounters have any ideas? Thanks in advance.
Hope this helps!
Now you dont even need an Initial Location or any type of Attractor modules. I added the Orbit module to a regular particle emitter, set the Offset Amount Distribution to be Vector Constant Curve, left the first key at zero all around, and for my second key I set the In Val at 1 second with an Out Val of Y:256. This value might change for you Nielsen since your particles are much larger but youll know how much youll want to offset them by when you have it up against your other emitters. Under the Offset Options I turned on Process During Update, I think this was the flag imbueFX was talking about, otherwise it wont work.
Next I set the Rotation Amount Distribution to be Vector Constant and left them all at zero. Finally I set the Rotation Rate Distribution to be Vector Constant and gave it a value of Z: 0.35, use a negative value to get it going in the other direction. The higher the value the faster the rotations will be, so use accordingly. Last step was to turn on the Process During Update again for this option. Heres an image of it in UDK, I cloned the particle system a couple of times so you can see my results.
As you can see the entire particle system can be rotated however you like on any axis and they will still behave the way you want them too, I should also mention that Use Local Space is not turned on.
I do have one question for this method though. With the Orbit module the particles go from the spawn origin and extend out to the offset value, is there a way to get the reverse of this behavior? If possible this would mimic the "swirling in" behavior that we were getting before, thanks again for the help imbueFX.
Edit: Just read your post more carefully imbueFX, the Offset Amount needs a value in the first key, I used Y:128. Then the second key you leave at 0 all around, except for the In Val which is still at 1 second. Now the particles swirl inwards, thanks again.
Thanks for the help anyways! I'll get a short video up this weekend.
Hope you like it, suggested improvements are very welcome ofcourse.
(I know the purple plane clips midway... unfortunate, forgot to fix that)
[ame="http://www.youtube.com/watch?v=nR97vSbESj4"]Quasar_NebulaeTest.wmv - YouTube[/ame]
http://udn.epicgames.com/Three/MaterialsCompendium.html#PixelDepth