private synchronized void updateInvaders() {
		
		float left1  = -1;
		float left2  = -1;
		float left3  = -1;
		float right1 = -1;
		float right2 = -1;
		float right3 = -1;
		
		if(invader1.getEntity(0) != null) {left1 = invader1.getEntity(0).getX();}
		if(invader2.getEntity(0) != null) {left2 = invader2.getEntity(0).getX();}
		if(invader3.getEntity(0) != null) {left3 = invader3.getEntity(0).getX();}
		
		if(invader1.getEntity(invader1.getEntityCount()-1) != null) {right1 = invader1.getEntity(invader1.getEntityCount()-1).getX();}
		if(invader2.getEntity(invader2.getEntityCount()-1) != null) {right2 = invader2.getEntity(invader2.getEntityCount()-1).getX();}
		if(invader3.getEntity(invader3.getEntityCount()-1) != null) {right3 = invader3.getEntity(invader3.getEntityCount()-1).getX();}
		
		float[] leftSide  = {left1 , left2 , left3 };
		float[] rightSide = {right1, right2, right3};
		
		int prevDrop = drop;
		for(int i=0; i<3; i++) {
			
			if(leftSide[i] != -1 && leftSide[i] < 32) {
				direction = 1;
				if(drop == 0) {drop = 1;}
				else          {drop = 2;}
				break;
			}
			
			if(rightSide[i] != -1 && rightSide[i] > 704) {
				direction = -1;
				if(drop == 0) {drop = 1;}
				else          {drop = 2;}
				break;
			}
			
		}
		if(drop == prevDrop) {drop = 0;}
		
		//Check which row the bottom invaders are on
		int level = getLevel();
		if(level == 12) {endGame(1); return;}
		
		Sprite[] invader = {invader1, invader2, invader3};
		for(int i=0; i<invader.length; i++) {
			for(int n=0; n<invader[i].getEntityCount(); n++) {
				
				if(drop == 1) {
					invader[i].getEntity(n).setY(invader[i].getEntity(n).getY()+32);
					invader[i].setInterval(1000-(level*50));
				} else {invader[i].getEntity(n).setHorVelocity(0.005f*level*direction);}
				
			    drawInvader(invader[i].getEntity(n));
			}
		}
		
	}