home *** CD-ROM | disk | FTP | other *** search
- function rrr()
- {
- a = new Array();
- i = 0;
- while(i < 8)
- {
- a[i] = new Array("0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0");
- i++;
- }
- a[0][0] = random(4) + 1;
- a[0][1] = random(4) + 1;
- a[0][2] = random(4) + 1;
- a[0][3] = random(4) + 1;
- a[0][4] = random(4) + 1;
- a[1][0] = random(4) + 1;
- a[1][1] = random(4) + 1;
- a[1][2] = random(4) + 1;
- a[1][3] = random(4) + 1;
- a[1][4] = random(4) + 1;
- a[2][0] = random(4) + 1;
- a[2][1] = random(4) + 1;
- a[2][2] = random(4) + 1;
- a[2][3] = random(4) + 1;
- a[2][4] = random(4) + 1;
- a[3][0] = random(4) + 1;
- a[3][1] = random(4) + 1;
- a[3][2] = random(4) + 1;
- a[3][3] = random(4) + 1;
- a[3][4] = random(4) + 1;
- a[4][0] = random(4) + 1;
- a[4][1] = random(4) + 1;
- a[4][2] = random(4) + 1;
- a[4][3] = random(4) + 1;
- a[4][4] = random(4) + 1;
- a[5][0] = random(4) + 1;
- a[5][1] = random(4) + 1;
- a[5][2] = random(4) + 1;
- a[5][3] = random(4) + 1;
- a[5][4] = random(4) + 1;
- a[6][0] = random(4) + 1;
- a[6][1] = random(4) + 1;
- a[6][2] = random(4) + 1;
- a[6][3] = random(4) + 1;
- a[6][4] = random(4) + 1;
- a[7][0] = random(4) + 1;
- a[7][1] = random(4) + 1;
- a[7][2] = random(4) + 1;
- a[7][3] = random(4) + 1;
- a[7][4] = random(4) + 1;
- }
- function rrrb()
- {
- b = new Array();
- i = 0;
- while(i < 8)
- {
- b[i] = new Array("0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0");
- i++;
- }
- b[0][0] = random(4) + 1;
- b[0][1] = random(4) + 1;
- b[0][2] = random(4) + 1;
- b[0][3] = random(4) + 1;
- b[0][4] = random(4) + 1;
- b[1][0] = random(4) + 1;
- b[1][1] = random(4) + 1;
- b[1][2] = random(4) + 1;
- b[1][3] = random(4) + 1;
- b[1][4] = random(4) + 1;
- b[2][0] = random(4) + 1;
- b[2][1] = random(4) + 1;
- b[2][2] = random(4) + 1;
- b[2][3] = random(4) + 1;
- b[2][4] = random(4) + 1;
- b[3][0] = random(4) + 1;
- b[3][1] = random(4) + 1;
- b[3][2] = random(4) + 1;
- b[3][3] = random(4) + 1;
- b[3][4] = random(4) + 1;
- b[4][0] = random(4) + 1;
- b[4][1] = random(4) + 1;
- b[4][2] = random(4) + 1;
- b[4][3] = random(4) + 1;
- b[4][4] = random(4) + 1;
- b[5][0] = random(4) + 1;
- b[5][1] = random(4) + 1;
- b[5][2] = random(4) + 1;
- b[5][3] = random(4) + 1;
- b[5][4] = random(4) + 1;
- b[6][0] = random(4) + 1;
- b[6][1] = random(4) + 1;
- b[6][2] = random(4) + 1;
- b[6][3] = random(4) + 1;
- b[6][4] = random(4) + 1;
- b[7][0] = random(4) + 1;
- b[7][1] = random(4) + 1;
- b[7][2] = random(4) + 1;
- b[7][3] = random(4) + 1;
- b[7][4] = random(4) + 1;
- }
- function ggg()
- {
- cheng = 0;
- i = 0;
- while(i < 8)
- {
- j = 0;
- while(10 >= j)
- {
- if(a[i][j] == 1)
- {
- attachMovie("red","gg" add (j * 8 + i),cheng);
- setProperty("gg" add (j * 8 + i), _X, i * 35 + 35);
- setProperty("gg" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(a[i][j] == 2)
- {
- attachMovie("blue","gg" add (j * 8 + i),cheng);
- setProperty("gg" add (j * 8 + i), _X, i * 35 + 35);
- setProperty("gg" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(a[i][j] == 3)
- {
- attachMovie("green","gg" add (j * 8 + i),cheng);
- setProperty("gg" add (j * 8 + i), _X, i * 35 + 35);
- setProperty("gg" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(a[i][j] == 4)
- {
- attachMovie("yellow","gg" add (j * 8 + i),cheng);
- setProperty("gg" add (j * 8 + i), _X, i * 35 + 35);
- setProperty("gg" add (j * 8 + i), _Y, j * 35 + 55);
- }
- cheng += 1;
- j++;
- }
- cheng += 1;
- dic = cheng + 50;
- i++;
- }
- }
- function gggb()
- {
- chengb = cheng + 1000;
- i = 0;
- while(i < 8)
- {
- j = 0;
- while(10 >= j)
- {
- if(b[i][j] == 1)
- {
- attachMovie("red","gb" add (j * 8 + i),chengb);
- setProperty("gb" add (j * 8 + i), _X, i * 35 + 362);
- setProperty("gb" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(b[i][j] == 2)
- {
- attachMovie("blue","gb" add (j * 8 + i),chengb);
- setProperty("gb" add (j * 8 + i), _X, i * 35 + 362);
- setProperty("gb" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(b[i][j] == 3)
- {
- attachMovie("green","gb" add (j * 8 + i),chengb);
- setProperty("gb" add (j * 8 + i), _X, i * 35 + 362);
- setProperty("gb" add (j * 8 + i), _Y, j * 35 + 55);
- }
- else if(b[i][j] == 4)
- {
- attachMovie("yellow","gb" add (j * 8 + i),chengb);
- setProperty("gb" add (j * 8 + i), _X, i * 35 + 362);
- setProperty("gb" add (j * 8 + i), _Y, j * 35 + 55);
- }
- chengb += 1;
- j++;
- }
- chengb += 1;
- i++;
- }
- }
- function sss()
- {
- sound.gotoandplay("next");
- i = 7;
- while(i >= 0)
- {
- j = 10;
- while(j >= 0)
- {
- a[i][j + 1] = a[i][j];
- removeMovieClip("gg" add (i * 8 + j));
- j--;
- }
- i--;
- }
- a[7][0] = random(4) + 1;
- a[6][0] = random(4) + 1;
- a[5][0] = random(4) + 1;
- a[4][0] = random(4) + 1;
- a[3][0] = random(4) + 1;
- a[2][0] = random(4) + 1;
- a[1][0] = random(4) + 1;
- a[0][0] = random(4) + 1;
- ggg();
- }
- function sssb()
- {
- sound.gotoandplay("next");
- i = 7;
- while(i >= 0)
- {
- j = 10;
- while(j >= 0)
- {
- b[i][j + 1] = b[i][j];
- removeMovieClip("gb" add (i * 8 + j));
- j--;
- }
- i--;
- }
- b[7][0] = random(4) + 1;
- b[6][0] = random(4) + 1;
- b[5][0] = random(4) + 1;
- b[4][0] = random(4) + 1;
- b[3][0] = random(4) + 1;
- b[2][0] = random(4) + 1;
- b[1][0] = random(4) + 1;
- b[0][0] = random(4) + 1;
- gggb();
- }
-