
function animate_photomap() {
	var points = new Array("403,96", "231,70", "131,92", "244,83", "328,115", "247,93", "145,203", "244,83");
	var p;

	for (p=0;p<points.length;p++) {
	  xy = points[p].split(",")
	  new Effect.Move($('pointer'), { x: parseInt(xy[0])-10, y: parseInt(xy[1])-34, mode: 'absolute', queue: {scope:'map', position:'end'}, afterFinish: ghost(p) });
	  new Effect.Move($('pointer' + p), { x: parseInt(xy[0])-10, y: parseInt(xy[1])-34, mode: 'absolute', queue: {scope:'map', position:'end'}, duration: 0 });
	  // new Effect.Puff($('pointer' + p), {queue: "end"});
	  new Effect.Appear($('pm' + (p + 1)), {queue: {scope:'map', position:'end'}, duration: 2});
	  new Effect.Appear($('pointer' + p), {queue: {scope:'map', position:'end'}});

	}
	// sw = $('slogan-txt').scrollWidth;
	// new Effect.Morph($('slogan'), {style: {width: sw + 'px'}, queue: {scope:'map', position:'end'}});	
	// new Effect.Highlight($('slogan'), {queue: "end"});	
}


function ghost(p){
  var basicpointer = $('pointer');
  var clone = basicpointer.cloneNode(true);
  clone.id = 'pointer' + p;
  clone.className = 'ghost';
  clone.style.display = 'none';
  basicpointer.parentNode.appendChild(clone); 
}

// Non funziona! Probabilmente viene riscritto da qualche plugin. Funzione spostata su home.php
if ($('map_wrapper')) {
  window.onload=function(){
    // animate_photomap();
  }
}