Welcome, Guest
Want to take part in these discussions? Sign in if you have an account, or apply for one below
How do I?: Accessing global x, global y, and velocity info for a Particle
Bottom of Page1 to 3 of 3
-
- CommentAuthorNateJC
- CommentTimeJun 16th 2010
I've got a reference to a Particle (using emitter.particles[n]). How do I access the global x, global y, and current velocity of this particle?
I've tried accessing emitter.particles[n].image.x, but this always returns 0. -
- CommentAuthorNateJC
- CommentTimeJun 16th 2010
Never mind. I realized that all of that information is stored in Particle2D or Particle3D so I just had to cast the returned particle reference:
var p:Particle2D = Particle2D(emitter.particles[n]);
p.x
p.y
p.velX
p.velY
Thanks! -
- CommentAuthormfrdorov
- CommentTimeSep 19th 2011
Thanx man! i search for this.
1 to 3 of 3
