$(document).ready(function(){
	
	//This keeps track of the slideshow's current location
	//we set it to 1 for the initial page load
	
	var current = 1;//initial reset for page load
	var start=1;
	//store the dimensions so that we can call them to action whenever we want
	var top = 250;//height of the image
	var zero = 0;//resetting the image to the first one
	//time it takes to change from one slide to the other
	var transition = 5000;
	
	$.timer(transition*2, function (change) {
		//determine the current location, and transition to next image
		switch(current){
		
			case 1:
				$(".slide").stop().animate({top: -top+"px"}, { duration: transition});
				current++;
			break;			

			case 2:
				$(".slide").stop().animate({top: -top*2+"px"}, { duration: transition});
				current++;
			break;
			
			case 3:
				$(".slide").stop().animate({top: -top*3+"px"}, { duration: transition});
				current++;
			break;
			
			case 4:
				$(".slide").stop().animate({top: -top*4+"px"}, { duration: transition});
				current++;
			break;
			
			case 5:
				$(".slide").stop().animate({top: -top*5+"px"}, { duration: transition});
				current++;
			break;

			case 6:
				$(".slide").stop().animate({top: -top*4+"px"}, { duration: transition});
				current++;
			break;	
			
			case 7:
				$(".slide").stop().animate({top: -top*3+"px"}, {duration: transition});
				current++;
			break;

			case 8:
				$(".slide").stop().animate({top: -top*2+"px"}, {duration: transition});
				current++;
			break;

			case 9:
				$(".slide").stop().animate({top: -top+"px"}, {duration: transition});
				current++;
			break;

			case 10:
				$(".slide").stop().animate({top: top*0+"px"}, {duration: transition});
				current=start;
			break;	
			
			
	  		timer.reset();
		}
	});
	
	
});
