public void update() {
		
		if (!won && !dead) {
			if (hasStarted) {
				elapsedMS = (System.nanoTime() - startTime) / 1000000;
				fromattedTime = formatTime(elapsedMS);
			} else {
				startTime = System.nanoTime();
			}
		}
		checkKeys();
		for (int row = 0; row < ROWS; row++) {
			for (int col = 0; col < COLS; col++) {
				Tile current = board[row][col];
				if (current == null)
					continue;
				current.update();
				resetPosition(current, row, col);
			}
		}
	}