function Rotate()
{
	var imageBuffer = new Array();
	var currentImage = 0;
	/* This pre-loads the images for display
	 * @param arr | The array of images to be shown
	 * @param path of the images;
	 * @param x the horizontal position on the screen
	 * @param y the vertical position on the screen
	 */
	this.loadImages = function(/*Array*/arr,/*String*/path,/*Number*/x,/*Number*/y) {
		//loop through array and store in the buffer
		for ( var i = 0; i < arr.length; i++) {
			imageBuffer[i] = new Image();
			imageBuffer[i].src = path + arr[i];
			imageBuffer[i].x = x;
			imageBuffer[i].y = y;
		}
	};
	
	//this draws the current image
	this.drawImage = function()
	{
		if(document.images) { document.BCL.src = imageBuffer[currentImage].src; }
		//document.write(imageBuffer[currentImage].src);
	}
	
	// check the timer and execute when it reaches it
	this.counter = function()
	{
		this.checkCurrentImage();
		this.drawImage();
	}
	
	/* check to see if end of list reached.
	   @description True: Loops the list | False: increments the counter
	*/
	this.checkCurrentImage = function()
	{
		if(currentImage == (imageBuffer.length-1)) { currentImage = 0; }
		else { currentImage++; }
	}
}
