I'm uncertain how to write this in Construct 2. I'm attempting to assess a 2D array. One column is a value name for a location check while the other is a boolean switch. I'm trying to run through the array and if the switch is true, append the name value of the boolean to a text variable. Here's what I got:
Array proximity
Sprite player
Local text string = ""
Local number i = 0
For "" from 0 to proximity.Width, add 1 to i
-->proximity Value at (i,1) = 1, Set String & proximity.At(i,0)
If i >= proximity.Width, then set player.proximity to string
Some sample values within the array:
Wall,1
Floor,1
Ceiling,0
Ledge,0
Expected output: player.proximity=WallFloor
I can append the string if I have everything on the for loop and get every name value, but I can't seem to figure out how to add conditions within it to just get name values that are true.