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
71
S
30
G
25
Posts: 984
Reputation: 19,503


Return to How do I....?

Who is online

Users browsing this forum: Resslx and 30 guests