var ind = 0;
function ref(gn) {
	ih = '<div id="g_title"><a href="http://xilike.net/game/'+gn.getId()+'" target="_top">'+gn.getName()+'</a></div><div id="g_pic"><a href="http://xilike.net/game/'+gn.getId()+'" target="_top"><img height="120" border="0" width="85" alt="'+gn.getName()+'" src="'+gn.getBoxart()+'"/></a></div><div id="saved-buttons" class="saved_buttons'
	if (gn.getVote()==1) {
		ih += ' liked';
	}
	else {
		ih += ' disliked';
	}
	ih += '" onclick="parent.location.href=\'http://xilike.net/game/'+gn.getId()+'\'" /><div id="g_voted">';
	if (gn.getOverall()>0) ih += gn.getOverall()+'%';
	ih += '</div>';
	document.getElementById('the_widget').innerHTML = ih;
}
function cycle() {
	ref(g[ind]);
	ind += 1;
	if (ind == 10) ind=0;
	setTimeout('cycle()',8000);
}
