Skip to content

Commit

Permalink
Modify center of object for pretiest rotation
Browse files Browse the repository at this point in the history
  • Loading branch information
mattgu74 committed May 27, 2011
1 parent f9098de commit 9827f38
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/tetris.opa
Expand Up @@ -90,22 +90,22 @@ Tetris(size, nbcol, nbline, speed, color) = {{
cases = [{x=0 ; y=0}, {x=0 ; y=1}, {x=1 ; y=0}, {x=1; y=1}]
},{ // L
color = Color.rgb(250,125,125) ;
cases = [{x=0;y=0}, {x=0;y=1}, {x=0;y=2}, {x=1;y=2}]
cases = [{x=0;y=-1}, {x=0;y=0}, {x=0;y=1}, {x=1;y=1}]
},{ // L REVERSED
color = Color.rgb(125,125,250) ;
cases = [{x=1;y=0}, {x=1;y=1}, {x=1;y=2}, {x=0;y=2}]
cases = [{x=0;y=-1}, {x=0;y=0}, {x=0;y=1}, {x=-1;y=1}]
},{ // S
color = Color.rgb(250,250,125) ;
cases = [{x=0;y=0}, {x=0;y=1}, {x=1;y=1}, {x=1;y=2}]
cases = [{x=0;y=-1}, {x=0;y=0}, {x=1;y=0}, {x=1;y=1}]
},{ // Z
color = Color.rgb(125,250,250) ;
cases = [{x=1;y=0}, {x=1;y=1}, {x=0;y=1}, {x=0;y=2}]
cases = [{x=0;y=-1}, {x=0;y=0}, {x=-1;y=0}, {x=-1;y=1}]
},{ // T
color = Color.rgb(250,125,250) ;
cases = [{x=0;y=0}, {x=1;y=0}, {x=2;y=0}, {x=1;y=1}]
cases = [{x=-1;y=0}, {x=0;y=0}, {x=1;y=0}, {x=0;y=1}]
},{ // |
color = Color.rgb(125,125,125) ;
cases = [{x=0;y=0}, {x=0;y=1}, {x=0;y=2}, {x=0;y=3}]
cases = [{x=0;y=-1}, {x=0;y=0}, {x=0;y=1}, {x=0;y=2}]
}]

///////////////////////////////
Expand Down

0 comments on commit 9827f38

Please sign in to comment.