Example #1
0
// Define where your client path is (where you put your grfs, data, etc.)
Client::$data_ini = "DATA.INI";
// The name of your DATA.INI (to locate your grfs, if not set: grfs will not be loaded)
Client::$AutoExtract = true;
// If true, client will save extracted files from GRF into the data folder.
//- DB
DB::$path = __ROOT__ . "db/";
// The db folder (where is located the lua likes files)
//- Sql
Controller::$hostname = "127.0.0.1";
// Mysql Host
Controller::$database = "ragnarok";
// Database Name
Controller::$username = "******";
// Database Username
Controller::$password = "******";
// Database Pass
/// -----------------------------------------------------------------
// No write access to directory ? disable cache.
if (Cache::$time && !is_writable(Cache::$path)) {
    Cache::$time = 0;
    Debug::write('Disable Cache system, don\'t have write acess to "' . Cache::$path . '".', 'error');
}
if (Client::$AutoExtract && !is_writable(Client::$path . 'data/')) {
    Client::$AutoExtract = false;
    Debug::write('Disable GRF auto-extract mode, don\'t have write access to "' . Client::$path . 'data/".', 'error');
}
// Don't cache images when debug mode is on
if (Debug::isEnable()) {
    Cache::$time = 0;
}
Example #2
0
// Define where your client path is (where you put your grfs, data, etc.)
Client::$data_ini = "DATA.INI";
// The name of your DATA.INI (to locate your grfs, if not set: grfs will not be loaded)
Client::$AutoExtract = true;
// If true, client will save extracted files from GRF into the data folder.
//- DB
DB::$path = __ROOT__ . "db/";
// The db folder (where is located the lua likes files)
//- Sql
Controller::$hostname = $settings['db_host'];
// Mysql Host
Controller::$database = $settings['db_name'];
// Database Name
Controller::$username = $settings['db_user'];
// Database Username
Controller::$password = $settings['db_pass'];
// Database Pass
/// -----------------------------------------------------------------
// No write access to directory ? disable cache.
if (Cache::$time && !is_writable(Cache::$path)) {
    Cache::$time = 0;
    Debug::write('Disable Cache system, don\'t have write acess to "' . Cache::$path . '".', 'error');
}
if (Client::$AutoExtract && !is_writable(Client::$path . 'data/')) {
    Client::$AutoExtract = false;
    Debug::write('Disable GRF auto-extract mode, don\'t have write access to "' . Client::$path . 'data/".', 'error');
}
// Don't cache images when debug mode is on
if (Debug::isEnable()) {
    Cache::$time = 0;
}