TrackManiaControl/application/ManiaControl.php

31 lines
727 B
PHP
Raw Normal View History

2013-11-09 11:19:21 +01:00
<?php
use ManiaControl\ManiaControl;
// Define base dir
2013-11-09 11:19:21 +01:00
define('ManiaControlDir', __DIR__);
// Set process settings
ini_set('memory_limit', '128M');
if (function_exists('date_default_timezone_get') && function_exists('date_default_timezone_set')) {
date_default_timezone_set(@date_default_timezone_get());
}
// Error handling
ini_set('log_errors', 1);
ini_set('error_reporting', -1);
if (!is_dir('logs')) {
mkdir('logs');
}
ini_set('error_log', 'logs/ManiaControl_' . getmypid() . '.log');
2013-11-09 11:19:21 +01:00
// Load ManiaControl class
require_once __DIR__ . '/core/ManiaControl.php';
2013-11-09 11:19:21 +01:00
// Start ManiaControl
error_log('Loading ManiaControl v' . ManiaControl::VERSION . '...');
2013-11-09 11:19:21 +01:00
$maniaControl = new ManiaControl();
$maniaControl->run();
2013-11-09 11:19:21 +01:00
?>