game/_incl_data/__config.php

39 lines
894 B
PHP
Raw Normal View History

2022-06-06 21:30:34 +00:00
<?php
2022-12-20 01:57:09 +00:00
use Core\Config;
//error_reporting(E_ALL);
2022-06-06 21:30:34 +00:00
date_default_timezone_set('Europe/Moscow');
2022-12-19 18:26:14 +00:00
header('Cache-Control: no-cache, no-store, must-revalidate');
header('Pragma: no-cache');
header('Expires: 0');
2022-06-06 21:30:34 +00:00
2022-12-19 18:26:14 +00:00
require_once 'mysql_override.php';
2022-06-06 21:30:34 +00:00
2022-12-19 18:26:14 +00:00
// Попробуем в автозагрузку.
// Никогда не заработает с такими названиями классов и файлов!
// "На потом."
spl_autoload_register(function ($className) {
# 1 with namespaces
# 2 without
$fileName = [
__DIR__ . '/class/' . str_replace('\\', '/', $className . '.php'),
2023-07-31 17:06:51 +00:00
__DIR__ . '/class/' . $className . '.php',
];
2022-12-19 18:26:14 +00:00
foreach ($fileName as $file) {
if (file_exists($file)) {
require_once $file;
break;
}
}
});
2022-12-19 18:26:14 +00:00
$code = '1';
2022-12-20 01:57:09 +00:00
Config::init();
$c = Config::get();
//Tournament::startAllBattles();
2022-12-19 20:16:24 +00:00