Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Particle stream - always forward..

Haplo Voss
Registered User
Join date: 18 Nov 2006
Posts: 137
09-09-2007 03:55
Ok, I've tried reading everything I can about rotations and poitions, and implementing them, but I can't seem to get this quite right...

Along with a friend, we created and entered a new Autobot in a contest, now after the fact we are dressing it up a bit, and I've made a nice looking weapon / pulse cannon for the arm, that expands out via SetPrimitiveParams and SetScale... works nicely...

Now what I want to do, is create just a nice and simple particle stream (easy enough) to shoot straight out of the weapon for a nice display during the final show if we make the finals.

Problem... whenever the weapon moves, of course the particles are only going to move in the direction of the vector they are told.

I've tried all variations of get rotation I can think of and nothing will keep it in line with the barrel, I am of course using a sphere in the center of the barrel so I can use whatever axis I need to, but it's stil driving me nuts.

I realize that things act differently as attachments, so there again, it may be throwing me off course, at this point I've kind of thrown in the towel..

Does anyone know of a freebie script, sort of like a 'reverse follower' for a prim that they would be willing to throw me a bone here?

Thanks for your time,
Hap
Noctua Janus
Registered User
Join date: 22 Mar 2007
Posts: 29
09-10-2007 00:36
Just tell the particles to follow the orientation of the source prim:
PSYS_PART_FOLLOW_SRC_MASK
Senuka Harbinger
A-Life, one bit at a time
Join date: 24 Oct 2005
Posts: 491
09-10-2007 05:29
what you need to do is define your particle system as an arc, and then restrain the size of that arc to a single point, for example using the START and END parameters as PI and PI+.01 will give the illusion of the particles streaming out at the point PI in an arc relative to the root prim.

using the acceleration parameter will only set it's velocity relative to the world, not the prim itself, so aside from a falling debris trail utelizing the a <0,0,z> acceleration, I'd set that parameter to ZERO_VECTOR. also, the PSYS_PART_FOLLOW_SRC_MASK, will mean that the particles will move with the originating prim, not relative to the world; if you move, all the particles you shot will move accordingly, probably breaking the effect you are trying to achieve.
_____________________
My SLExchange shop

Typos are forgiven; desecrating the english language with reckless abandon and necrophilic acts is not.


The function is working perfectly fine. It's just not working the way you wanted it to work.