public void dealWithTrans() { if (!isCoordinateLock) { isTransforStart = true; cTetrisBlock.tetrisBlockShapeTransformation(m_blockGrid); cGameDc.repaint(); isTransforStart = false; } }
public void dealWithRight() { if (!isCoordinateLock) { if (!isRightToEnd(cTetrisBlock.m_blockRightX)) cTetrisBlock.setCoordinateXY( cTetrisBlock.getTetrisCoordinateX() + 20, cTetrisBlock.getTetrisCoordinateY()); cGameDc.repaint(); } }
public void dealWithDown() { if (!isCoordinateLock) { if (!isToEnd(cTetrisBlock.m_blockBottomY)) cTetrisBlock.setCoordinateXY( cTetrisBlock.getTetrisCoordinateX(), cTetrisBlock.getTetrisCoordinateY() + 20); cGameDc.repaint(); } }
/** 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(); } }