Particles.

For questions about using Classic.

Post » Wed Apr 01, 2009 3:35 am

Hello everyone.

I have a technical question about the particle object. If a particle object is not producing particles(i.e. a rate of 0), does it have any performance footprint?

I can see thanks to the lovely debug, that when set to "one shot" the particle instance is removed after it's done it's dash. I've made a little fire effect, that peters outs, however the fire particle object instance stays.

I have set up a private variable that will destroy it, but it looks bad if i pause using the time scale, as the PV continues to build and will destroy the object mid pause. While it works, it looks bad, so any help would be awesome.
B
9
S
2
G
4
Posts: 346
Reputation: 2,726

Post » Wed Apr 01, 2009 5:25 am

If you pause by setting time delta to 0, then objects wont move and the particle object will stop spawning particles.

I imagine you might be writing:

Set life to life - 1

instead, replace 1 with timedelta*60

That way, pausing will work, and if you decide to add slow motion into your game, you wont need to worry about particles being destroyed too fast :)
B
4
S
2
G
5
Posts: 641
Reputation: 3,011

Post » Wed Apr 01, 2009 6:23 am

Wow, nice :D

I have it all working nicely now thank you. There is a drastic time difference between TimeDelta and Ticks hey?

I assume TimeDelta*60=1 second?
B
9
S
2
G
4
Posts: 346
Reputation: 2,726

Post » Wed Apr 01, 2009 6:34 am

[quote="Steven":2ck5ev9z]Wow, nice :D

I have it all working nicely now thank you. There is a drastic time difference between TimeDelta and Ticks hey?

I assume TimeDelta*60=1 second?[/quote:2ck5ev9z]

If your frame rate is 60 then yes
Image Image
B
161
S
48
G
91
Posts: 7,358
Reputation: 67,271


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: Exabot [Bot] and 4 guests