core/src/de/lksbhm/mona/puzzle/Piece.java
/**
	 * Implements a small queue somehow, so that the more recently changed in or
	 * out direction should be out
	 * 
	 * @param d
	 */
Implements a small queue somehow, so that the more recently changed in or
out direction should be out

@param d
Implements a small queue somehow so that the more recently changed in or out direction should be out @param d
public boolean pushInOutDirection(Direction d, boolean notify) {
		if (type == Type.INVISIBLE && d != Direction.NONE) {
			throw new RuntimeException(
					"Try to set in/out connection of invisible tile to something different than NONE");
		}
		if (in == d || out == d) {
			return false;
		}
		if (!isOutContinued() || isInContinued()) {
			if (in != Direction.NONE) {
				out = in;
			}
		}
		in = d;
		if (notify) {
			notifyOnChange();
		}
		return true;
	}
public boolean pushInOutDirection ( Direction d , boolean notify ) { if ( type == Type . INVISIBLE && d != Direction . NONE ) { throw new RuntimeException ( "Try to set in/out connection of invisible tile to something different than NONE" ) ; } if ( in == d || out == d ) { return false ; } if ( ! isOutContinued ( ) || isInContinued ( ) ) { if ( in != Direction . NONE ) { out = in ; } } in = d ; if ( notify ) { notifyOnChange ( ) ; } return true ; }
Implements a small queue somehow, so that the more recently changed in or
 out direction should be out
Implements a small queue somehow so that the more recently changed in or out direction should be out
// don't set d twice // nothing changed // drop previous 'out' in favor of (newer) 'in', except for when 'out' // is continued and 'in' is not // prevent evicting 'out' with Direction.NONE