<?php
#--------------------------------
# http://www.yourarcadescript.com
#       index.php
#		VERSION 2.4
#		CC BY-ND 3.0(http://creativecommons.org/licenses/by-nd/3.0/) Liscensed
#       
#--------------------------------
session_start();
if (!file_exists("includes/db_functions.inc.php") || !file_exists("includes/config.inc.php")) {
	echo "Site is not installed";
	exit;
}
include("includes/db_functions.inc.php");
include("includes/config.inc.php");
if ($setting['disabled'] == 'yes') {
	include('siteoff.php');
	exit;
}
include("includes/inc.php");
include('includes/raycache.php');
include('includes/resize.php');
include("templates/".$setting['theme']."/header.php"); 

switch($_GET['act']){
    case 'editavatar':
        include ("templates/".$setting['theme']."/editavatar.php");
        break;
    case 'members':
        include ("templates/".$setting['theme']."/members.php");
		break;
    case 'small_footer':
        include ("templates/".$setting['theme']."/small_footer.php");
        break;
    case 'news':
        include ("templates/".$setting['theme']."/news.php");
        break;
    case 'shownews':
        include ("templates/".$setting['theme']."/shownews.php");
        break;
    case 'favourites':
        include ("templates/".$setting['theme']."/favourites.php");
        break;
    case 'showmember':
        include ("templates/".$setting['theme']."/showmember.php");
        break;
    case 'terms':
        include ("templates/".$setting['theme']."/terms.php");
        break;
    case 'contactus':
        include ("templates/".$setting['theme']."/contactus.php");
        break;
    case 'cat':
        include ("templates/".$setting['theme']."/category.php");
        break;
    case 'search':
        include ("templates/".$setting['theme']."/search.php");
        break;
    case 'register':
        include ("templates/".$setting['theme']."/register.php");
        break;
    case 'topplayers':
        include ("templates/".$setting['theme']."/topplayers.php");
        break;
    case 'links':
        include ("templates/".$setting['theme']."/links.php");
        break;
    case 'addlink':
        include ("templates/".$setting['theme']."/addlink.php");
        break;
    case 'forgotpassword':
        include ("templates/".$setting['theme']."/forgotpassword.php");
        break;
    case 'profile':
        include ("templates/".$setting['theme']."/profile.php");
        break;
    case 'game':
        include ("templates/".$setting['theme']."/game.php");
        break;
    case 'play':
        include ("templates/".$setting['theme']."/play.php");
        break;
	case 'popular':
        include ("templates/".$setting['theme']."/popularbig.php");
        break;
	case 'toprated':
        include ("templates/".$setting['theme']."/topratedbig.php");
        break;
	case 'latest':
        include ("templates/".$setting['theme']."/latestbig.php");
        break;
	case 'privacy':
        include ("templates/".$setting['theme']."/privacy.php");
        break;
	case 'login':
        include ("templates/".$setting['theme']."/login2.php");
        break;
	case 'download':
        include ("templates/".$setting['theme']."/download.php");
        break;
    case 'unsubscribe':
        include ("templates/".$setting['theme']."/unsubscribe.php");
		break;
	default:
        include ("templates/".$setting['theme']."/home.php");
        break;		
}
 include ("templates/".$setting['theme']."/footer.php");
 ?>