public S_Box RetNextBox(){
		//System.out.println("doing while(counter >= t)     counter :" + counter + " t: " + t);
		if((counter-1) >= t && counter != 0){
			return null;
		}
		if(counter != 0){
			PMove();
			//System.out.println("E has been moved to: " + E.toString());
		}else{
			//System.out.println("counter == 0. Not moving E.");
		}
		
		S_Box i = VelToBox();
		
		if((double)counter >= CdR && Rem!=0 && CdR != 0){
			//System.out.println("Special case has occured. Moving E additionally...");
			if(x==t){
				if(y>0){
					i.loc.y += 1;
					PMove(0,1);
				}else{
					i.size.y += 1;
					PMove(0,-1);
				}
			}else{
				if(x>0){
					i.size.x += 1;
					PMove(1,0);
				}else{
					i.loc.x += 1;
					PMove(-1,0);
				}
			}
			//System.out.println("E has been moved to: " + E.toString());
			CdR += dR;
		}
		counter += 1;
		return i;
	}