function GameSlide(){
	this.htmlCode='';
}

GameSlide.prototype.init=function(target,titleHTML,contentHTML){
	this.target=target;
	//this.css=css;
	this.htmlCode='<div id="gameSlide" class="selector" title="'+titleHTML+'">';
	this.htmlCode+='<div id="gameSlideInner" >';
	this.htmlCode+=contentHTML;
	this.htmlCode+='</div>';		
	this.htmlCode+='</div>';
	
}

GameSlide.prototype.add=function(){
	$(this.target).html(this.htmlCode);
	
	$('#gameSlide').css(this.css);
	$('#gameSlide').dialog({
		'draggable':false,
		'closeOnEscape': false,
		'position':'center',
		'close': function(event,ui) { 
			$('#gameDescription').remove();
			basket.show();
				
			game.slide.hide();
			$('body').append('<div id="Tip"></div>');
			game.resetGame();		
			$.post('gameplay.php','screen=game&ball='+game.ball,game.displayScreen,"json");
		},
		'buttons': { 
			"Play": function() { 
				$('#gameDescription').remove();
				basket.show();
				
				game.slide.hide();
				$('body').append('<div id="Tip"></div>');
				game.resetGame();		
				$.post('gameplay.php','screen=game&ball='+game.ball,game.displayScreen,"json");
			}
		}
	});
	$('#gameSlide').hide();
}
	
GameSlide.prototype.hide=function(){
		$('#gameSlide').remove();
}

GameSlide.prototype.show=function(){
	$('#gameSlide').fadeIn(1600);
}