Flint Particle System Forum - Accessing global x, global y, and velocity info for a Particle2011-10-16T20:53:38+01:00http://flintparticles.org/forum/
Lussumo Vanilla & Feed Publisher
Accessing global x, global y, and velocity info for a Particlehttp://flintparticles.org/forum/comments.php?DiscussionID=365&Focus=1229#Comment_12292010-06-16T19:24:28+01:002011-10-16T20:53:38+01:00NateJChttp://flintparticles.org/forum/account.php?u=376
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, ...
I've tried accessing emitter.particles[n].image.x, but this always returns 0.]]>
Accessing global x, global y, and velocity info for a Particlehttp://flintparticles.org/forum/comments.php?DiscussionID=365&Focus=1230#Comment_12302010-06-16T19:32:34+01:002011-10-16T20:53:38+01:00NateJChttp://flintparticles.org/forum/account.php?u=376
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 = ...
var p:Particle2D = Particle2D(emitter.particles[n]); p.x p.y p.velX p.velY
Thanks!]]>
Accessing global x, global y, and velocity info for a Particlehttp://flintparticles.org/forum/comments.php?DiscussionID=365&Focus=1722#Comment_17222011-09-19T16:23:16+01:002011-10-16T20:53:38+01:00mfrdorovhttp://flintparticles.org/forum/account.php?u=544
Thanx man! i search for this.