Ejemplo n.º 1
0
 public void dealWithTrans() {
   if (!isCoordinateLock) {
     isTransforStart = true;
     cTetrisBlock.tetrisBlockShapeTransformation(m_blockGrid);
     cGameDc.repaint();
     isTransforStart = false;
   }
 }
Ejemplo n.º 2
0
 public void dealWithRight() {
   if (!isCoordinateLock) {
     if (!isRightToEnd(cTetrisBlock.m_blockRightX))
       cTetrisBlock.setCoordinateXY(
           cTetrisBlock.getTetrisCoordinateX() + 20, cTetrisBlock.getTetrisCoordinateY());
     cGameDc.repaint();
   }
 }
Ejemplo n.º 3
0
 public void dealWithDown() {
   if (!isCoordinateLock) {
     if (!isToEnd(cTetrisBlock.m_blockBottomY))
       cTetrisBlock.setCoordinateXY(
           cTetrisBlock.getTetrisCoordinateX(), cTetrisBlock.getTetrisCoordinateY() + 20);
     cGameDc.repaint();
   }
 }
Ejemplo n.º 4
0
 /** the method for c++ dll */
 public void dealWithLeft() {
   System.out.println("nihaoma");
   if (!isCoordinateLock) {
     if (!isLeftToEnd(cTetrisBlock.m_blockLeftX))
       cTetrisBlock.setCoordinateXY(
           cTetrisBlock.getTetrisCoordinateX() - 20, cTetrisBlock.getTetrisCoordinateY());
     cGameDc.repaint();
   }
 }