# Search:

Type: Posts; User: jtmnf

1. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

3 hours later...

public void verifica_inicio(int[][] matriz, int n){
int i;
int j;
int temp;
int temp_2;
int temp_3 = n;
Random rand = new Random();
2. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

I can answer with this:

matriz[pos_x][pos_y] == matriz[pos_x][pos_y-1] && matriz[pos_x][pos_y] == matriz[pos_x][pos_y-2]
matriz[pos_x][pos_y] == matriz[pos_x][pos_y+1] && matriz[pos_x][pos_y] ==...
3. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

There aren't counters...

My thought: search in the rows... Search for a sequence of 3 or more numbers... If it find it, change the first number to another... Now, it returns to search in the rows...
4. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

matriz[pos_x][pos_y] == matriz[pos_x][pos_y-1] && matriz[pos_x][pos_y] == matriz[pos_x][pos_y-2]
matriz[pos_x][pos_y] == matriz[pos_x][pos_y+1] && matriz[pos_x][pos_y] == matriz[pos_x][pos_y+2]...
5. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

I already do that, I swear... I don't understand what's missing :S I already have Array out of bounds a bunch of times...
6. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

I already do that, but I appears that at the end, there is, once more, a sequence of 3 or more pieces of the same color... :S I cannot do anything more, I exhausted...
7. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

pos_x/pos_y is the position in the matrix
fig_aleat is the random piece that is randomized at the moment

When returns 1, it indicates that there's no 3 or more pieces (numbers) in sequence!
8. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

I messed up... It's a nxn grid, not nxm, sorry... But yes! If 3 or more numbers are the same, I have to change the 1st appearence of that number to other!
9. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

This situation:
1652

The green rectangles...
10. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### Re: [Help]

The code should see if there are 3 or more pieces in consecutive positions...
The "aleat_fig" as the values 0 to 5 (6 pieces)!

For example, I cannot have this combination:

# EDIT -> it's nxn,...
11. ## Thread: [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

by jtmnf
Replies
20
Views
304

### [Help][SOLVED] - Catch sequence of 3 or more pieces of same color [BEJEWELED GAME]

I need help... I'm doing Bejeweled in JAVA, but I need help to overpass a problem...

When I start the board for the first time, I cannot have 3 or more pieces of the same color, but my function...
Results 1 to 11 of 11