Do particles still use memory when invisible?

Discussion and feedback on Construct 2

Post » Tue May 27, 2014 11:30 am

Just wondering, I have several particle effects set to 'continuous spray' and pinned to my sprite, so I can turn them on and off by toggling their visibility. Does they still use up the same memory when invisible? It's not a performance issue at the moment but I wanted to know if I'll take a hit by adding more and more of these.
B
15
S
4
G
1
Posts: 286
Reputation: 1,988

Post » Tue May 27, 2014 11:47 am

even whey they are invisible, the location of each single particle has to be calculated.
B
44
S
10
G
8
Posts: 437
Reputation: 6,468

Post » Tue May 27, 2014 1:09 pm

I think invisible just means "do not render me on screen"

You could maybe check if it is invisible to make it spawn nothing in that case
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
53
S
22
G
18
Posts: 2,122
Reputation: 17,123

Post » Tue May 27, 2014 1:36 pm

That's cool, I just set it to create, pin and then destroy after 0.4 seconds, same effect. Thanks!
B
15
S
4
G
1
Posts: 286
Reputation: 1,988

Post » Tue May 27, 2014 2:45 pm

Hi,
accourding to the engine, the invisible objects are used by engine and he reserve them some memory.
try to put a bullet sprite invisible and fire it, you will see that he do the job !
i'm not a Construct 2 developer, but i'm a programmer and i know that Construct 2 is a normal software that is built with a C++ or whatever language that uses variables or memory.
in coding languages, the compilators reserve memory for variables even not used by user.
2D Game GUI Designer
B
12
S
4
G
3
Posts: 130
Reputation: 3,778

Post » Tue May 27, 2014 4:03 pm

Manarsoft wrote:Hi,
accourding to the engine, the invisible objects are used by engine and he reserve them some memory.
try to put a bullet sprite invisible and fire it, you will see that he do the job !
i'm not a Construct 2 developer, but i'm a programmer and i know that Construct 2 is a normal software that is built with a C++ or whatever language that uses variables or memory.
in coding languages, the compilators reserve memory for variables even not used by user.


In that case, they are actually used by the engine (something invisible still exists and still works the same way, as the name says, it is just not visible, nothing more nothing less). It concerns more destroyed objects that are recycled whenever possible so the browsers don t take too much time cleaning the garbage (since there is no control over that), which is why I suggested to do less work on invisible objects if he can
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
53
S
22
G
18
Posts: 2,122
Reputation: 17,123

Post » Tue May 27, 2014 11:24 pm

Yes they will still use memory.
B
90
S
18
G
9
Posts: 2,455
Reputation: 15,038


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 13 guests