Часть логов теперь пишется в SQLITE, а не в текстовые файлы (#33). Проинициализирован класс Nick в свитках.
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
<?php
|
||||
|
||||
use Battles\GameLogs;
|
||||
use Battles\Nick;
|
||||
|
||||
if ($_SESSION['uid'] == null) {
|
||||
header("Location: index.php");
|
||||
exit;
|
||||
@@ -58,7 +62,7 @@ if ($user['battle'] == 0) {
|
||||
$t1 = implode(";", $t1);
|
||||
$t2 = implode(";", $t2);
|
||||
|
||||
addlog($user['battle'], '<span class=date>' . date("H:i") . '</span> ' . Nick::id($user['id'])->short() . ' переманил клона ' . Nick::id($bot)->short() . ' на свою сторону.<BR>');
|
||||
GameLogs::addBattleLog($user['battle'], '<span class=date>' . date("H:i") . '</span> ' . Nick::id($user['id'])->short() . ' переманил клона ' . Nick::id($bot)->short() . ' на свою сторону.<BR>');
|
||||
mysql_query('UPDATE `battle` SET `teams` = \'' . serialize($battle) . '\', `t1` = \'' . $t1 . '\', `t2` = \'' . $t2 . '\' WHERE `id` = "' . $user['battle'] . '" LIMIT 1');
|
||||
mysql_query("UPDATE `battle` SET `to1` = '" . time() . "', `to2` = '" . time() . "' WHERE `id` = '" . $user['battle'] . "' LIMIT 1");
|
||||
echo mysql_error();
|
||||
|
||||
Reference in New Issue
Block a user