Increment array(structure) index inside of loop

I have a two dimensional array structure. I am using a while loop inside of another while loop to iterate through all the positions in the array. Works fine. But I need to compare each position in the array with the next position in the array while I am still inside the inner While Loop. I can do this in Java like the following.

   if (board[row][col] == board[row][col+1] && board[row][col] == board[row]col+2] && board[row][col] == board[row][col+3])

Is this possible in GDevelop? I have tried the following. I do not get any errors but it does not work. It is the +“1”, +“2”, +“3” that I need to figure out. winRow is my outer loop counter and winCol is my inner loop counter. The child called “empty” contains either null, red, or blue.

if boardColumns[VariableString(winRow)][VariableString(winCol)].empty =
if boardColumns[VariableString(winRow)][VariableString(winCol)].empty =
if boardColumns[VariableString(winRow)][VariableString(winCol)].empty =

This is for a Connect Four game I am making. This logic will be checking to see if there are four coins next to each other horizontally. In other words, a winner. Therefore, I cannot have the loop counters change until all columns have been checked each time.

Any ideas anyone?

HEY, I do not have the answer, but I have a similiar but easier problem.
Do you have the idea where is the problem

PS: the only solution seems to read the values into a script, then iterate the for loop the repass to gdevelop, but i do not have any idea on using about Javascript