Setup/Data

* move custom data from setup scripts to DB
 * move strings from DB to locale files
 * use common function to calculate coordinates of dungeon entrances instead of inline sql
 * fixed manual data zones and itemset
 * fixed typos across the board
This commit is contained in:
Sarjuuk
2022-02-21 22:51:25 +01:00
parent 10805a1f70
commit bc71ae762c
32 changed files with 481 additions and 373 deletions

View File

@@ -130,7 +130,7 @@ function loadConfig(bool $noPHP = false) : void
if ($php)
ini_set(strtolower($k), $val);
else
else if (!defined('CFG_'.strtoupper($k)))
define('CFG_'.strtoupper($k), $val);
}
}
@@ -162,6 +162,8 @@ set_error_handler(function($errNo, $errStr, $errFile, $errLine)
$errName = 'E_RECOVERABLE_ERROR';
Util::addNote($uGroup, $errName.' - '.$errStr.' @ '.$errFile. ':'.$errLine);
if (CLI)
CLI::write($errName.' - '.$errStr.' @ '.$errFile. ':'.$errLine, $errNo & 0x40A ? CLI::LOG_WARN : CLI::LOG_ERROR);
if (DB::isConnectable(DB_AOWOW))
DB::Aowow()->query('INSERT INTO ?_errors (`date`, `version`, `phpError`, `file`, `line`, `query`, `userGroups`, `message`) VALUES (UNIX_TIMESTAMP(), ?d, ?d, ?, ?d, ?, ?d, ?) ON DUPLICATE KEY UPDATE `date` = UNIX_TIMESTAMP()',