How to make "object" not render?

Get help using Construct 2

Post » Sun Oct 23, 2011 6:03 pm

What I mean is, just like one can turn a layer invisible, I though that making so, will affect any object in it to not render (and not load) as well. I have some graphics in there that I think kneel the game down in fps, so instead of deleting the graphic, how can I just make it disbled as to say for testing purposes? It would be nice to actually NOT render and load anyhing in an invisible layer.
B
10
S
1
G
2
Posts: 47
Reputation: 1,615

Post » Sun Oct 23, 2011 6:08 pm

Isn't that what setting an object invisible does?
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Sun Oct 23, 2011 6:18 pm

In the editor yes, it doesn't apear, but when I run the preview everything apears even if invisible. I should add that I run preview in "file" mode since "http" mode doesn't seem to work for me (HTTP Error 503. The service is unavailable.)
B
10
S
1
G
2
Posts: 47
Reputation: 1,615

Post » Sun Oct 23, 2011 7:09 pm

Can you make a .capx file? Setting things invisible works fine for me.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Sun Oct 23, 2011 7:44 pm

Well...the specific project doesn't really matter as it happens in any project I try. If you do need it though I can send you a scene with a black ball :-). It's allways the same. Again...in "File" preview mode.
B
10
S
1
G
2
Posts: 47
Reputation: 1,615

Post » Sun Oct 23, 2011 8:03 pm

Works fine for me in all browsers in both preview modes: test

This is why you should always provide a .capx: it seems to be working fine here, so presumably you're doing something else you hadn't realised that is causing a problem.Ashley2011-10-23 20:03:36
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Sun Oct 23, 2011 8:21 pm

Thanks for answering...

Obviously there was a confusion, because I was taking about turning a whole layer invisible. While it does work setting a Layer invisible through events, it doesn't if you UNcheck the box in the Layers window on top-left and run the game, without using any events whatsoever.

Obviously this is no big deal, since one can change Layer Visibility from within events.
B
10
S
1
G
2
Posts: 47
Reputation: 1,615

Post » Sun Oct 23, 2011 9:13 pm

Ah, I see the confusion now. You've missed the 'initial visibility' property :)

Layers have two properties:
Initial visibility - only affects the runtime
Visible in editor - only affects the editor

The checkbox is a shortcut for the "visible in editor" option. So if you want to change the runtime use the "initial visibility" option!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Sun Oct 23, 2011 9:24 pm

Oh.. O.o Silly of me.. Thanks. That's exactly what happened :)
B
10
S
1
G
2
Posts: 47
Reputation: 1,615


Return to How do I....?

Who is online

Users browsing this forum: Artpunk, gregorysforster, onzephyr and 3 guests