How do I determine z order?

Get help using Construct 2

Post » Fri Jul 29, 2016 1:17 pm

Hi

I want to be able to click a stack of sprites and the top one to be moved.

Is there a way to say like on click if at top of z order?

thanks any help appreciated
B
5
S
1
Posts: 65
Reputation: 507

Post » Fri Jul 29, 2016 1:21 pm

Pick the bunch of sprites with any condition
filter with conditoin sprite > Pick top/bottom
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Fri Jul 29, 2016 1:30 pm

@99instances2go

Hi would that only work if they're all instances of the same sprite?
If so is my only option putting each sprite on a new layer?

Cheers
B
5
S
1
Posts: 65
Reputation: 507

Post » Fri Jul 29, 2016 3:33 pm

Can we clarify what 'Z order' we talk about ? Z order based on IID or Z order based on Y(x) ?

Let me try to explain.

Based on IID. When you copy or clone in the layout. The last one created shows above the others. The same for newly created instances during runtime. The last created one show above the others. It has a higher IID (when picking all) and a higher Zindex.
(problem could be solved with a fake IID index in a familie variable)

Based on Y(x). Those objects with a higher Y show above those that have a lower Y. Usaly used for dimetric games.
(problem could be solved with plugins)
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 16 guests