How do I find both the nearest and the second nearest?

Get help using Construct 2

Post » Fri Jul 24, 2015 1:42 pm

I've been using "pick nearest" successfully. But now I need to pick the two nearest elements. Any suggestions for the most elegant way to do this? Thanks!
B
4
Posts: 5
Reputation: 217

Post » Fri Jul 24, 2015 1:48 pm

For each ordered ascending, using a distance() call as the expression. Add a stop loop if loopindex = 1 to limit the number of iteration to two.
B
67
S
28
G
24
Posts: 970
Reputation: 18,675


Return to How do I....?

Who is online

Users browsing this forum: SputnikCZ and 4 guests