Forums Index >> Modding >> Emitter Functions Tutorial - How to make the perfe...
Page : <1> :
Damn, he got them before me....
I had something a bit like that Nathan©, but mine was slightly less extensive, and some of them weren't defined. Thanks for clearing all that up a bit more.
Yup that's me, the one who is constantly copying and pasting.
Thanks for all your comments, and thanks to MAX-CR for clearing alot of them up. ;)
Lol ice...
Damn, he got them before me....
you seem to know everything...btw-where'd you get your animated pic?don't tell me you made it yourself!
He made it himself. It's not hard.
I cant even get emitters to work for me... :[ :[ :[ :[ :[ :[ :[ :[ :[ :[
Then ur not much of a code master r u sry couldnt resist :P
How do I get them weapon emitters like that green or yellow or pink stuff behind the bullets ? Not that lightprojectile.emitter=rocksmokeemitter; I dont want the smoke one.
Read my first post in this thread lmao
I dont want the colour, size or shape all I want is to get it to work for weapons so like if you shoot speedy like pink stars come out with it like smoke but diferent.
This is meant for people who already know what they're doing, but aren't quite sure what all the variables are for.
Nate do you have your (old) Four Corners mod? I like it! %)
Cb.
Hey. I did everything you told me about emitters but what about the beggining for example: new TTstatic(). What is it for emitters? Please help me out. :'(
Nate do you have your (old) Four Corners mod? I like it!
Cb.
I'm sure I do, somewhere. XD If I find it, I'll toss it up on Nate's Mod CLASSICS server.
Hey. I did everything you told me about emitters but what about the beggining for example: new TTstatic(). What is it for emitters? Please help me out.
I'd love to help, but I already stated that this is for people who know what they're doing. There are lots of other emitter tuts out there that will help you get goin.
Page : <1> :
Have you ever been trying to make the perfect emitter, but it's always the wrong size, shape, color, or all of the above? Well look no further, in this tutorial I go over every function of the particle datablock, and the emitter datablock. Remember, not all may be correct, my definitions are simply made by in-game tests. Don't take this too seriousely, it is only meant as a guide.
Here we go! XD
THE PARTICLE DATABLOCK
animatetexture - This specifies whether or not the particle's texture will animate. Set this to 1 if you want the texture to cycle through various art, set it to 0 if you do not.
animTexName[0] - This is the first frame of the animation. If you want the texture to animate, specify another texture by adding an "animtexname[1]" line. The game will loop through all specified textures if "animatetexture" is set to 1 .
colors[0] - colors[1] - These are the four stages of color. They are in RBG format, like the fog. The front of the emitter will use color 0, the end will use color 3. You can add more stages by adding more colors.
constantAcceleration - Whether or not the emitter will just stay put, or will constantly move forward. This will have the most effect if the emitter is used on a projectile. This is a yes/no value, so use 1 for yes, 0 for no.
dragCoefficient - I have yet to find a use for this, however I believe it will vary the rate of spread of the emitter particles.
framesPerSec - Doesn't seem to do anything.
gravityCoefficient - How much gravity effects the particle. The larger the number, the faster it falls. A negitive value will cause the emitter to float upwards. 0 will make it stand almost still. A higher number is recommended to reduce lag.
inheritedVelFactor - Unknown, but I believe this effects the amount of velocity gained over time.
lifetimeMS - The time in aproximate milliseconds that the particle will remain visable. 1000 will make the emitter stay for 1 second.
lifetimeVarianceMS - Don't make this number larger than lifetimeMS. The amount of slack in either direction you give the lifetimeMS value. 400 will make lifetimeMS vary by 0.4 seconds.
sizes[0] - sizes[3] - The size of the emitter particles. 0 indicates the front, 3 indicates the back. Do not make the emitter get bigger from front to back. You can add stages as necessary.
spinRandomMax - The maximum amount of degrees the emitter is allowed to spin. 360 will allow free-range spinning, 0 will not allow the emitter to spin.
spinRandomMin - The minimum amount of degrees the emitter is allowed to spin. 0 will allow free range spinning, 360 will not allow the emitter to spin.
spinSpeed - The rate of speed that the emitter spins at. The higher the number, the faster it spins.
textureName - The texture that the emitter uses. If you use a colored texture, colors will not be accurate.
times[0] - times[3] - Be sure there are the same amount of times values as size values. Make sure these numbers get from smaller to bigger. Unknown use, however I believe it effects the spawn rate of particles.
useInvAlpha - 1 will allow transparency, 0 will make the emitter solid. If your emitter is transparent, there will be more lag.
windCoefficient - 1 is recommended to allow realism, however, if you don't want the wind to effect the emitter, set this to 0.</p>
<p><hr /></p>
<p>THE EMITTER DATA
ejectionOffset - The amount of degrees the emitter will spawn the particles. 360 will make some really funky effects. ;)
ejectionperiodMS - Unknown, however I believe it effects the time between "pulses" where the emitter spawns particles.
ejectionVelocity - The speed that the particles spawn from the emitter. The higher the number, the faster they shoot out.
lifetimeMS - If this is set to 0, it could be why your emitters don't show up :). It's recommended that you set this to around 1000 - 5000. Any more will cause lag.
lifetimeVarianceMS - Why must they taunt me with these values? I don't know, try it out. :)
orientOnVelocity - I almost needed a dictionary for this one. Setting this to 1 will make the particles stay uniform behind the emitter. 0 will allow them to float all over.
orientParticles - Seems like it should do the same as orientonvelocity. I don't know what this does.
overrideAdvance - Your guess is as good as mine. XD
particleFarDist - Has something to do with the distance that the particles are viewable. A small number will make the emitters pop out of site.
particles - Set this to the name of the PARTICLE DATABLOCK I told you how to make at the start of this tut.
periodVarianceMS - I'm gonna be honest. I have no clue. May be something with the spawning of the particles.
phiReferenceVel - Phi wha? Reference velocity? What is that?
phiVariance - Hmmm, I have mine set on 360 all the time, so you should too. :)
thetaMax - To ta max! Make this larger than thetamin.
thetaMin - To ta minimum! Make this smaller than thetamax.
useEmitterColors - Whether or not to use the colors you specified in the particle datablock.
useEmitterSizes - Whether or not to use the sizes you specified in the particle datablock.
<hr />
Hopefully this helped some, I whipped this up in a few minutes, so if you see any errors, let me know.
Last edited: Sunday, July 18, 2004 at 1:32:51 AM