Performance of Scaled Collision Objects

Discussion and feedback on Construct 2

Post » Tue Aug 13, 2013 8:12 pm

I'm currently blocking out levels for my game, and was wondering if there are any performance hits scaling collision objects to very large sizes vs using multiple collision objects.

Here is an example.


These objects are on an invisible layer and must be sprites to work with the Physics behavior. I would assume 2 Scaled Objects would be better since it reduces the number of objects and collision checks, but that's just a guess. Are there any tradeoffs to using this scaling method vs multiple objects?

Thanks
B
79
S
51
G
37
Posts: 365
Reputation: 23,695

Post » Tue Aug 13, 2013 9:06 pm

Checking collisions with 2 objects instead of 6 would be faster since less needs to be checked. With a small number of sprites the performance difference would be negligible, but it could be more beneficial if you have many.
B
89
S
30
G
95
Posts: 5,160
Reputation: 63,456

Post » Wed Aug 14, 2013 12:52 am

Size of polygons does not matter, only quantity does.
B
140
S
71
G
17
Posts: 1,773
Reputation: 20,511

Post » Wed Aug 14, 2013 1:53 am

I thought that might be the case, thanks for the answers.
B
79
S
51
G
37
Posts: 365
Reputation: 23,695


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 3 guests