Flint Particle System Forum - Stop Method for Steady counter2010-12-25T18:54:53+00:00http://flintparticles.org/forum/
Lussumo Vanilla & Feed Publisher
Stop Method for Steady counterhttp://flintparticles.org/forum/comments.php?DiscussionID=40&Focus=214#Comment_2142008-06-12T21:25:30+01:002008-06-13T13:05:02+01:00swd120http://flintparticles.org/forum/account.php?u=33
I'm having some issues using the stop method on a steady counter - how exactly to I reference it? Basically I want to be able to toggle the particles on and off.
Stop Method for Steady counterhttp://flintparticles.org/forum/comments.php?DiscussionID=40&Focus=215#Comment_2152008-06-13T13:04:51+01:002010-12-25T18:54:53+00:00Richardhttp://flintparticles.org/forum/account.php?u=1
Either retain a reference to your counter -
var steadyCounter:Steady = new Steady( 100 );
emitter.counter = steadyCounter;
steadyCounter.stop();
or cast the counter reference from the ...
var steadyCounter:Steady = new Steady( 100 ); emitter.counter = steadyCounter; steadyCounter.stop();
or cast the counter reference from the emitter
emitter.counter = new Steady( 100 ); Steady( emitter.counter ).stop();
A future version will require all counters to have a stop method, so stop can be rolled into the Counter interface and there will be no need for the type cast.]]>