Arrays algorithm to detect walls and corners

Get help using Construct 2

Post » Sat Oct 26, 2013 12:12 pm

Hi everyone, I was using arrays correctly after all but because of how the debug display is shown I thought I was using it wrongly.

I managed to get it working to this stage but the method I'm using to detect the walls is flawed it seems. As soon as I added in another wall it messed the whole thing up.

As you can see the corners should be 7,8,9 and 10. While the north wall should be 3, east wall is 4, south is 5 and west is 6.

https://dl.dropboxusercontent.com/u/57137706/image3782.png

I am trying to detect which sprite is a wall and assign a variable to it for easy access.

Since the event list is too long now here is a capx.

https://dl.dropboxusercontent.com/u/57137706/arraytest.capx

Thanks you for your time and help

Kind Regards.
RockmanZero2013-10-26 21:02:52
B
25
S
161
G
3
Posts: 51
Reputation: 18,702

Return to How do I....?

Who is online

Users browsing this forum: dand, heater19, Yahoo [Bot] and 22 guests

cron