-
Notifications
You must be signed in to change notification settings - Fork 7
/
init.php
41 lines (33 loc) · 1003 Bytes
/
init.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
/*
Name: Init.php
URI: http://ezrpgproject.net/
Author: Zeggy, UAKTags
Package: ezRPG-Core
*/
namespace ezRPG;
use Pimple\Container;
if (file_exists(__DIR__ . '/vendor/autoload.php')) {
require __DIR__ . '/vendor/autoload.php';
} else {
die('You must initialize composer!');
}
// This page cannot be viewed, it must be included
defined('IN_EZRPG') or exit;
global $debugTimer;
// Start Session
//session_start();
// Constants
define('CUR_DIR', realpath(dirname(__FILE__)));
define('MOD_DIR', CUR_DIR . '/modules/');
define('ADMIN_DIR', CUR_DIR . '/admin');
define('LIB_DIR', CUR_DIR . '/lib');
define('EXT_DIR', LIB_DIR . '/ext');
define('HOOKS_DIR', CUR_DIR . '/hooks');
define('THEME_DIR', CUR_DIR . '/templates/');
define('CACHE_DIR', CUR_DIR . '/cache/');
if(file_exists(CUR_DIR . '/config.php'))
require_once(CUR_DIR . '/config.php');
$debugTimer['Config Loaded:'] = microtime(1);
require_once(CUR_DIR . '/lib.php');
$debugTimer['Library Loaded:'] = microtime(1);