/* settings */
var images = $$('.foto IMG');
if (images) {
	var showDuration = 3000;
	var currentIndex = 0;

	/* opacity and fade */
	images.each(function(img,i){ 
		if(i > 0) img.set('opacity',0);
		img.set('tween', {duration: 1500})
	});

	/* worker */
	var show = function() {
		images[currentIndex].fade('out');
		images[currentIndex = currentIndex < images.length - 1 ? currentIndex+1 : 0].fade('in');
	};

	/* start SlideShow */
	var interval = show.periodical(showDuration);
}
