Should I still use render cells on a layer with moving stuff

Get help using Construct 2

Post » Sun Jan 10, 2016 1:10 pm

The manual says to use render cells on large layers with many static objects, which I have except there are a few moving objects on it too. Should I still use render cells or will that cause some problems?
B
8
S
1
Posts: 54
Reputation: 824

Post » Sun Jan 10, 2016 2:29 pm

Hey again Sam, :)

Ashley actually wrote up a really cool explanation and analysis of C2's render cell system, which you can find here:
https://www.scirra.com/blog/ashley/14/h ... cells-work

If you're more interested in "how to use it" than "how it works", You may want to jump to the following sections:
  • When to use it?
  • When to avoid it?
  • Extra tips

That said, if you have the time, it's worth reading the whole thing, to get an idea of how and why the benefits of render cells are so dependent on the situation.

From what I gather, render cells are per-layer, so for any layer that will have tons of essentially static objects out of frame, it might be a good candidate. So the main game layer, with enemies and particles and such, not so much; but a static decorative backdrop layer, with tons of individual objects, might be a good candidate.

In your case, with mixed layers, any moving object will need it's render cells updated, but that may not amount to that much if there are 1000 static objects and only 10 moving ones.

Ultimately you may want to just try it out both ways and see if there's any noticeable change in performance. You may be able to use the debug preview mode to get an idea, as it has a built-in performance profiler, though definitely click the "undock" button on the debug panel to separate it from your game window, or you'll likely get a performance hit just from the debug window itself.
B
26
S
17
G
8
Posts: 322
Reputation: 6,017

Post » Sun Jan 10, 2016 2:59 pm

Really helpful! Thanks again :)
B
8
S
1
Posts: 54
Reputation: 824


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 4 guests