function flock(){
$$('ul li').each(function(el) {
	el.addEvent('mouseover', function(){
	
	var decd1 = Math.floor(Math.random()*5);
	var rand = Math.floor(Math.random()*201);
	var rand1 = Math.floor(Math.random()*401);
	var rand2 = Math.floor(Math.random()*401);
	
	if(decd1 == 1){
	el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': rand1, 'margin-left':rand2});
	}
	if(decd1 == 2){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1, 'margin-left':rand2}).highlight('#555555');
	}
	if(decd1 == 3){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': rand1, 'margin-left': '-'+rand2});
	}
	if(decd1 == 4){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1, 'margin-top': '-'+rand2});
	}
	
	});
});
fly();
divide();
}
function fly(){
	var decd1 = Math.floor(Math.random()*5);
	var rand = Math.floor(Math.random()*51);
	var rand1 = Math.floor(Math.random()*201);
	var rand2 = Math.floor(Math.random()*201);
	$each($$('ul li'), function(el) {
	if(decd1 == 1){
	el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': rand1, 'margin-left':rand2});
	}
	if(decd1 == 2){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1, 'margin-left':rand2});
	}
	if(decd1 == 3){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-left': '-'+rand2});;
	}
	if(decd1 == 4){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1});
	}
	});
}
function center(event){
	var height = ($('wrapper').getHeight())/2;
	var width = ($('wrapper').getWidth())/2;
	
  
    tempX = client.x;
    tempY = client.y;
  alert(tempX);

	$each($$('ul li'), function(el) {

		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': '10', 'height':'10','margin-top': 0, 'margin-left':0, 'left':tempX, 'top':tempY});
	
	});
}
function divide(){
	var decd1 = Math.floor(Math.random()*5);
	var rand = Math.floor(Math.random()*51);
	var rand1 = Math.floor(Math.random()*201);
	var rand2 = Math.floor(Math.random()*201);
	var rand3 = Math.floor(Math.random()*2001);
	
	var ele = Math.floor(Math.random()*50);
	$each($$('ul li'), function(el,index) {
	if(index == ele){
	if(decd1 == 1){
	el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': rand1, 'margin-left':rand2});
	}
	if(decd1 == 2){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1, 'margin-left':rand2});
	}
	if(decd1 == 3){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-left': '-'+rand2});;
	}
	if(decd1 == 4){
		el.set('morph', {duration: 2000, transition: Fx.Transitions.Elastic.easeOut}).morph({'width': rand, 'height':rand,'margin-top': '-'+rand1});
	}
	}
	});
	setTimeout(divide, rand1);
}