Дозаливка
This commit is contained in:
parent
73d69cb0ae
commit
2f6517f5b3
10515
_incl_data/class/Battle.php
Normal file
10515
_incl_data/class/Battle.php
Normal file
File diff suppressed because it is too large
Load Diff
87
_incl_data/class/Core/Config.php
Normal file
87
_incl_data/class/Core/Config.php
Normal file
@ -0,0 +1,87 @@
|
||||
<?php
|
||||
|
||||
namespace Core;
|
||||
|
||||
class Config
|
||||
{
|
||||
|
||||
public static function get(?string $key = null)
|
||||
{
|
||||
$c['ver'] = '1.8.3.7';
|
||||
/* Конфигурации игры */
|
||||
$c['name'] = 'Бойцовский Клуб';
|
||||
$c['title'] = '«' . $c['name'] . '» - Бесплатная,браузерная онлайн игра'; //Название игры
|
||||
$c['title2'] = ' - Бесплатная, онлайн игра посвященная сражениям и магии!';
|
||||
$c['title3'] = $c['name'];
|
||||
$c['keys'] = $c['name'] . ', combats.com, ' . $c['name'] . ' игра, ' . $c['name'] . ' играть, игра ' . $c['name'] . ', старый ' . $c['name'] . ', ' . $c['name'] . ' онлайн игра, ' . $c['name'] . ' браузерная игра, играть в ' . $c['name'] . ', игра бк, бк игра, старый бк, играть в бк, бк онлайн игра, новый бк, Легендарный ' . $c['name'] . ', легендарный бк, combats, комбатс, combats ru, combats com, OldBK, oldbk ru, oldbk com, олдбк, old bk, олд бк, mycombats, rebk, recombats, oldcombats, obk2'; //Ключевые слова META
|
||||
$c['desc'] = '«' . $c['name'] . '» – это бесплатная увлекательная браузерная онлайн игра 2004-2009г, в которой сконцентрировано все самое лучшее от современных онлайн игр. В этой браузерной игре заложены самые интересные традиции всем известной онлайн игры под названием «' . $c['name'] . ' 2004-2009», которая, кстати, стала первооткрывателем всех браузерных игр.'; //Описание META
|
||||
|
||||
//Сервера
|
||||
$c['host'] = 'new-combats.com';
|
||||
$c['forum'] = 'forum.' . $c['host'];
|
||||
$c['img'] = 'img.' . $c['host'];
|
||||
$c['thiscity'] = 'capitalcity';
|
||||
$c['capitalcity'] = $c['host'];
|
||||
$c['abandonedplain'] = $c['host'];
|
||||
$c['exit'] = '<script>top.location="https://' . $c['host'] . '/";</script>';
|
||||
|
||||
//Валюта
|
||||
$c['curency_name'] = 'RUB';
|
||||
$c['curency_value'] = 30;
|
||||
|
||||
//Бот клон
|
||||
$c['bot_level'] = 0; // до какого лвл бот (включительно)
|
||||
$c['propsk_die'] = 0; //Смерть при пропуске ходов, 0 - выкл. , >= 1 - количество пропусков до смерти при нападении
|
||||
|
||||
//Скупка
|
||||
$c['exp'] = 0; //бонус опыта
|
||||
$c['shop_type1'] = 100; //в гос НЕ ТРОГАТЬ
|
||||
$c['shop_type2'] = 90; //в березку НЕ ТРОГАТЬ
|
||||
$c['shop_all'] = 0; //Скупка на все! , 0 - сделать для отключения скупки.
|
||||
$c['shop_all_type1'] = 100; //Скупка только с госе! , 0 - сделать для отключения скупки.
|
||||
$c['shop_all_type2'] = 100; //Скупка только с березки! , 0 - сделать для отключения скупки.
|
||||
//
|
||||
$c['nosanich'] = true; //Странички Саныча не выпадают - true , выпадают - false
|
||||
$c['zuby'] = false; //зубы
|
||||
$c['limitedexp'] = false; //лимит опыта
|
||||
$c['infinity5level'] = false; //вечные 5 уровни
|
||||
$c['expstop'] = 2999999; //9; //Опыт на котором останавливаемся 11 149999999
|
||||
$c['expstopu'] = 2999999; //Опыт на котором останавливаемся
|
||||
$c['noobgade'] = false; //нуб квест (пещера)
|
||||
$c['bonusonline'] = true; //бонус за онлайн
|
||||
$c['level_ransfer'] = 8; //С какого уровня разрешены передачи
|
||||
$c['znahar'] = true; //бесплатный знахарь
|
||||
$c['nolevel'] = false; //лимитирование уровней
|
||||
$c['noitembuy'] = false; //Не требует ресурсы для покупки
|
||||
$c['effz'] = 0; //Скольким секундам равен заряд
|
||||
$c['money_haot'] = true; //кр за хаоты
|
||||
$c['crtoecr'] = 500; //Курс обмена кр на екр (если 0, то выключено)
|
||||
$c['ecrtocr'] = 200; //Курс обмена екр на кр
|
||||
$c['bonuslevel'] = true; //Бонус уровня
|
||||
$c['bonussocial'] = false; //Бонус социальный
|
||||
|
||||
$c['w'] = date('w');
|
||||
$c['m'] = date('m');
|
||||
|
||||
$c['counters'] = '';
|
||||
$c['counters_noFrm'] = '';
|
||||
$c['securetime'] = 0; //Время последнего возможного взлома персов (подбор пароля по базам данных других игр)
|
||||
|
||||
$c['copyright'] = 'Copyright © ' . date('Y') . ' « Новый Бойцовский Клуб »';
|
||||
return $c[$key] ?? $c;
|
||||
}
|
||||
|
||||
public static function init(): void
|
||||
{
|
||||
error_reporting(E_ALL ^ E_NOTICE);
|
||||
setlocale(LC_CTYPE, "ru_RU.CP1251");
|
||||
|
||||
ini_set('display_errors', 'Off');
|
||||
ini_set('default_charset', 'windows-1251');
|
||||
ini_set('date.timezone', 'Europe/Moscow');
|
||||
|
||||
header('Cache-Control: no-cache, no-store, must-revalidate');
|
||||
header('Pragma: no-cache');
|
||||
header('Expires: 0');
|
||||
}
|
||||
}
|
39
_incl_data/class/Core/Database.php
Normal file
39
_incl_data/class/Core/Database.php
Normal file
@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
# Let's hope it will work.
|
||||
|
||||
namespace Core;
|
||||
|
||||
use PDO;
|
||||
|
||||
class Database
|
||||
{
|
||||
private const DB = 'newcom1_abk';
|
||||
private const USER = 'newcom1_abk';
|
||||
private const PASSWORD = '4nWYsIM[c?}P';
|
||||
private const DSN = 'mysql:host=localhost;dbname=' . self::DB;
|
||||
|
||||
//todo: remove PDO from files and connect through new pdoinit().
|
||||
public static function init(): PDO
|
||||
{
|
||||
|
||||
mysql_select_db(self::DB, mysql_connect('localhost', self::USER, self::PASSWORD));
|
||||
mysql_query('SET NAMES cp1251');
|
||||
|
||||
return self::pdoinit();
|
||||
}
|
||||
|
||||
public static function pdoinit(): PDO
|
||||
{
|
||||
return new PDO(
|
||||
self::DSN,
|
||||
self::USER,
|
||||
self::PASSWORD,
|
||||
[
|
||||
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
|
||||
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
|
||||
PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES cp1251",
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
3223
_incl_data/class/FightRequest.php
Normal file
3223
_incl_data/class/FightRequest.php
Normal file
File diff suppressed because it is too large
Load Diff
159
_incl_data/class/Filter.php
Normal file
159
_incl_data/class/Filter.php
Normal file
@ -0,0 +1,159 @@
|
||||
<?php
|
||||
|
||||
class Filter
|
||||
{
|
||||
public function str_count($str, $col)
|
||||
{
|
||||
if (strlen($str) > $col) {
|
||||
$str = substr($str, 0, $col);
|
||||
}
|
||||
return ($str);
|
||||
}
|
||||
//
|
||||
//Ñìàéëèêè
|
||||
private $sm = ["laugh" => 1, "fingal" => 1, "eek" => 1, "smoke" => 1, "hi" => 1, "bye" => 1, "king" => 1, "king2" => 1, "boks2" => 1, "boks" => 1, "gent" => 1, "lady" => 1, "tongue" => 1, "smil" => 1, "rotate" => 1, "ponder" => 1, "bow" => 1, "angel" => 1, "angel2" => 1, "hello" => 1, "dont" => 1, "idea" => 1, "mol" => 1, "super" => 1, "beer" => 1, "drink" => 1, "baby" => 1, "tongue2" => 1, "sword" => 1, "agree" => 1, "loveya" => 1, "kiss" => 1, "kiss2" => 1, "kiss3" => 1, "kiss4" => 1, "rose" => 1, "love" => 1, "love2" => 1, "confused" => 1, "yes" => 1, "no" => 1, "shuffle" => 1, "nono" => 1, "maniac" => 1, "privet" => 1, "ok" => 1, "ninja" => 1, "pif" => 1, "smash" => 1, "alien" => 1, "pirate" => 1, "gun" => 1, "trup" => 1, "mdr" => 1, "sneeze" => 1, "mad" => 1, "friday" => 1, "cry" => 1, "grust" => 1, "rupor" => 1, "fie" => 1, "nnn" => 1, "row" => 1, "red" => 1, "lick" => 1, "help" => 1, "wink" => 1, "jeer" => 1, "tease" => 1, "nunu" => 1, "inv" => 1, "duel" => 1, "susel" => 1, "nun" => 1, "kruger" => 1, "flowers" => 1, "horse" => 1, "hug" => 1, "str" => 1, "alch" => 1, "pal" => 1, "mag" => 1, "sniper" => 1, "vamp" => 1, "doc" => 1, "doc2" => 1, "sharp" => 1, "naem" => 1, "naem2" => 1, "naem3" => 1, "invis" => 1, "chtoza" => 1, "beggar" => 1, "sorry" => 1, "sorry2" => 1, "creator" => 1, "grace" => 1, "dustman" => 1, "carreat" => 1, "lordhaos" => 1, "ura" => 1, "elix" => 1, "dedmoroz" => 1, "snegur" => 1, "showng" => 1, "superng" => 1, "podz" => 1, "sten" => 1, "devil" => 1, "cat" => 1, "owl" => 1, "lightfly" => 1, "snowfight" => 1, "rocket" => 1, "ball" => 1, "smile" => 1, "fuck" => 1];
|
||||
|
||||
public function e($t)
|
||||
{
|
||||
mysql_query(
|
||||
'INSERT INTO `chat` (`text`,`city`,`to`,`type`,`new`,`time`) VALUES ("#' . date('d.m.Y') . ' %' . date(
|
||||
'H:i:s'
|
||||
) . ': <b>' . mysql_real_escape_string($t) . '</b>","capitalcity","Èãðîìèð","6","1","-1")'
|
||||
);
|
||||
}
|
||||
|
||||
public function setOnline($online, $uid)
|
||||
{
|
||||
$add = 0;
|
||||
|
||||
if (time() - $online >= 1) {
|
||||
if (time() - $online < 60) {
|
||||
$add += time() - $online;
|
||||
} else {
|
||||
$add += 60;
|
||||
}
|
||||
}
|
||||
|
||||
if ($add > 0) {
|
||||
$on = mysql_fetch_array(mysql_query('SELECT * FROM `online` WHERE `uid` = "' . $uid . '" LIMIT 1'));
|
||||
if (isset($on['id'])) {
|
||||
$mt = 0;
|
||||
$lst = time();
|
||||
if (date('d', $on['lastUp']) != date('d', $lst)) {
|
||||
$on['time_today'] = $add;
|
||||
} else {
|
||||
$on['time_today'] += $add;
|
||||
}
|
||||
$add = $on['time_all'] + $add;
|
||||
mysql_query(
|
||||
'UPDATE `online` SET `mainTime` = "' . $mt . '",`time_today` = "' . $on['time_today'] . '",`lastUp` = "' . $lst . '",`time_all` = "' . $add . '" WHERE `id` = "' . $on['id'] . '" LIMIT 1'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public function mystr($string)
|
||||
{
|
||||
$str = strtolower($string);
|
||||
if (strtolower('S') != 's') {
|
||||
$ru = 'ÀÁÂÃÄŨÆÇÈÉÊËÌÍÎÐÏÑÒÓÔÕÖ×ØÙÚÜÛÝÞß';
|
||||
$ru2 = 'àáâãäå¸æçèéêëìíîðïñòóôõö÷øùúüûýþÿ';
|
||||
$en = 'QWERTYUIOPASDFGHJKLZXCVBNM';
|
||||
$en2 = 'qwertyuiopasdfghjklzxcvbnm';
|
||||
$i = 0;
|
||||
while ($i < 33) {
|
||||
if (isset($ru[$i])) {
|
||||
$str = strtr($str, $ru[$i], $ru2[$i]);
|
||||
}
|
||||
if (isset($en[$i])) {
|
||||
$str = strtr($str, $en[$i], $en2[$i]);
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
return $str;
|
||||
}
|
||||
|
||||
public function spamFiltr($txt)
|
||||
{
|
||||
|
||||
$txt = str_replace('¸', 'å', $txt);
|
||||
|
||||
$nospam = 0;
|
||||
$txt = str_replace('>', '', $txt);
|
||||
$txt = str_replace('<', '', $txt);
|
||||
$txt = str_replace('"', '', $txt);
|
||||
$txt = $this->mystr($txt);
|
||||
$i = 0;
|
||||
while ($i <= count($this->sm)) {
|
||||
if (isset($this->sm[$i])) {
|
||||
$txt = preg_replace('/:' . $this->sm[$i] . ':/', "", $txt);
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
/* ôèëüòð */
|
||||
$spam = mysql_fetch_array(mysql_query('SELECT * FROM `spam_word` WHERE `id` = 1 LIMIT 1'));
|
||||
$spam = $spam['data'];
|
||||
//
|
||||
$testEN = preg_replace('/[^A-z]*/i', '', $txt);
|
||||
$testEN2 = $txt;
|
||||
|
||||
$testEN2 = str_replace('"', '', $testEN2);
|
||||
$testEN2 = str_replace(' ', '', $testEN2);
|
||||
$testEN2 = str_replace('à', 'a', $testEN2);
|
||||
$testEN2 = str_replace('á', 'b', $testEN2);
|
||||
$testEN2 = str_replace('ñ', 'c', $testEN2);
|
||||
$testEN2 = str_replace('â', 'b', $testEN2);
|
||||
$testEN2 = str_replace('å', 'e', $testEN2);
|
||||
$testEN2 = str_replace('ò', 't', $testEN2);
|
||||
$testEN2 = str_replace('î', 'o', $testEN2);
|
||||
$testEN2 = str_replace('ð', 'p', $testEN2);
|
||||
$testEN2 = str_replace('ì', 'm', $testEN2);
|
||||
$testEN2 = str_replace('í', 'h', $testEN2);
|
||||
$testEN2 = str_replace('ó', 'y', $testEN2);
|
||||
$testEN2 = str_replace('ê', 'k', $testEN2);
|
||||
$testEN2 = str_replace('è', 'u', $testEN2);
|
||||
$testEN2 = str_replace('õ', 'x', $testEN2);
|
||||
$testEN2 = str_replace('ÿ', '9', $testEN2);
|
||||
$testEN2 = str_replace('()', 'o', $testEN2);
|
||||
$testEN2 = str_replace('0', 'o', $testEN2);
|
||||
$testEN2 = preg_replace('/[^A-z]*/i', '', $testEN2);
|
||||
$testRU = preg_replace('/[^À-ÿ]*/i', '', $txt);
|
||||
|
||||
$testRU2 = $txt;
|
||||
$testRU2 = str_replace('a', 'à', $testRU2);
|
||||
$testRU2 = str_replace('b', 'á', $testRU2);
|
||||
$testRU2 = str_replace('c', 'ñ', $testRU2);
|
||||
$testRU2 = str_replace('b', 'â', $testRU2);
|
||||
$testRU2 = str_replace('e', 'å', $testRU2);
|
||||
$testRU2 = str_replace('t', 'ò', $testRU2);
|
||||
$testRU2 = str_replace('o', 'î', $testRU2);
|
||||
$testRU2 = str_replace('p', 'ð', $testRU2);
|
||||
$testRU2 = str_replace('m', 'ì', $testRU2);
|
||||
$testRU2 = str_replace('h', 'í', $testRU2);
|
||||
$testRU2 = str_replace('y', 'ó', $testRU2);
|
||||
$testRU2 = str_replace('k', 'ê', $testRU2);
|
||||
$testRU2 = str_replace('x', 'õ', $testRU2);
|
||||
$testRU2 = str_replace('u', 'è', $testRU2);
|
||||
$testRU2 = str_replace('()', 'î', $testRU2);
|
||||
$testRU2 = str_replace('0', 'î', $testRU2);
|
||||
$testRU2 = preg_replace('/[^À-ÿ]*/i', ' ', $testRU2);
|
||||
$testRU2 = preg_replace('/[^À-ß]*/i', ' ', $testRU2);
|
||||
$i = 0;
|
||||
$spe = explode('|', $spam);
|
||||
while ($i <= count($spe)) {
|
||||
if (isset($spe[$i]) && $spe[$i] != '' && $spe[$i] != 'new-combats.com' && (stristr(
|
||||
$testEN, $spe[$i]
|
||||
) || stristr($testRU, $spe[$i]))) {
|
||||
$nospam .= '%' . $spe[$i];
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
return $nospam;
|
||||
}
|
||||
|
||||
public function __clone()
|
||||
{
|
||||
trigger_error('Äóáëèðîâàíèå íå äîïóñêàåòñÿ.', E_USER_ERROR);
|
||||
}
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
<?php
|
||||
|
||||
namespace Insallah;
|
||||
|
||||
class TournamentUserCheckModel
|
||||
{
|
||||
private $id;
|
||||
private $level;
|
||||
|
||||
/**
|
||||
* @param $id
|
||||
*/
|
||||
public function __construct($id)
|
||||
{
|
||||
$this->id = $id;
|
||||
$this->level = Db::getValue('select level from users where id = ? and level between 8 and 12 and battle = 0', [$id]);
|
||||
}
|
||||
|
||||
/**
|
||||
* ïðîâåðêà óðîâíÿ, ñòîèìîñòè ýêâèïà, ïðî÷èå ïðîâåðêè, ÷òî ïåðñîíàæ ñâîáîäåí
|
||||
* òàéìåð îæèäàíèÿ 30 ìèíóò
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getLevel()
|
||||
{
|
||||
|
||||
return $this->level;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $price
|
||||
* @return bool
|
||||
*/
|
||||
public function isEkrOverpriced($price)
|
||||
{
|
||||
$wearedItemsEkrPrice = Db::getValue('select sum(2price) from items_users where inOdet > 0 and uid = ?', [$this->id]);
|
||||
return $wearedItemsEkrPrice > $price;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $minExp
|
||||
* @return bool
|
||||
*/
|
||||
public function isEnoughExperience($minExp)
|
||||
{
|
||||
return Db::getValue('select exp from stats where id = ?', [$this->id]) >= $minExp;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
public function IsRestrictedToJoin()
|
||||
{
|
||||
$delayEffect = Db::getValue(
|
||||
'select count(*) from eff_users where uid = ? and id_eff = 486 and `delete` = 0', [$this->id]
|
||||
);
|
||||
return (bool)$delayEffect;
|
||||
}
|
||||
}
|
46
_incl_data/class/Learming.php
Normal file
46
_incl_data/class/Learming.php
Normal file
@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use Insallah\Db;
|
||||
|
||||
class Learming
|
||||
{
|
||||
private $uid;
|
||||
private $shouldStartLearning;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
/** @var User $user */
|
||||
$user = User::start();
|
||||
$this->uid = $user->info['id'];
|
||||
$this->shouldStartLearning = $user->info['shouldStartLearning'];
|
||||
}
|
||||
|
||||
public function getLearningStatus()
|
||||
{
|
||||
if (!isset($this->shouldStartLearning)) {
|
||||
Db::sql('insert into users_learming (uid) value (?)' ,
|
||||
[$this->uid]);
|
||||
return 1;
|
||||
}
|
||||
return (bool)$this->shouldStartLearning;
|
||||
}
|
||||
|
||||
public function hasLearned()
|
||||
{
|
||||
if (!isset($this->shouldStartLearning)) {
|
||||
return false;
|
||||
}
|
||||
$this->shouldStartLearning = 0;
|
||||
$this->save();
|
||||
return true;
|
||||
}
|
||||
|
||||
private function save()
|
||||
{
|
||||
if (empty($this->uid) || empty($this->shouldStartLearning)) {
|
||||
return;
|
||||
}
|
||||
Db::sql('replace into users_learming (uid, shouldStartLearming) values (?,?)',
|
||||
[$this->uid, $this->shouldStartLearning]);
|
||||
}
|
||||
}
|
1992
_incl_data/class/Magic.php
Normal file
1992
_incl_data/class/Magic.php
Normal file
File diff suppressed because it is too large
Load Diff
2847
_incl_data/class/Priems.php
Normal file
2847
_incl_data/class/Priems.php
Normal file
File diff suppressed because it is too large
Load Diff
1010
_incl_data/class/Quests.php
Normal file
1010
_incl_data/class/Quests.php
Normal file
File diff suppressed because it is too large
Load Diff
31
_incl_data/class/Season.php
Normal file
31
_incl_data/class/Season.php
Normal file
@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
use Insallah\Db;
|
||||
|
||||
class Season
|
||||
{
|
||||
public static $yy = [
|
||||
1 => [1, '01', 'ίνβΰπό', 'ίνβΰπόρκθι'],
|
||||
2 => [2, '02', 'Τεβπΰλό', 'Τεβπΰλόρκθι'],
|
||||
3 => [3, '03', 'Μΰπς', 'Μΰπςξβρκθι'],
|
||||
4 => [4, '04', 'ΐοπελό', 'ΐοπελόρκθι'],
|
||||
5 => [5, '05', 'Μΰι', 'Μΰιρκθι'],
|
||||
6 => [6, '06', 'Θώνό', 'Θώνόρκθι'],
|
||||
7 => [7, '07', 'Θώλό', 'Θώλόρκθι'],
|
||||
8 => [8, '08', 'ΐβγσρς', 'ΐβγσρςξβρκθι'],
|
||||
9 => [9, '09', 'Ρενς<CEBD>από', 'Ρενς<CEBD>απόρκθι'],
|
||||
10 => [10, '10', 'Ξκς<CEBA>από', 'Ξκς<CEBA>απόρκθι'],
|
||||
11 => [11, '11', 'Νξ<CE9D>από', 'Νξ<CE9D>απόρκθι'],
|
||||
12 => [12, '12', 'Δεκΰαπό', 'Δεκΰαπόρκθι'],
|
||||
];
|
||||
public static $date = [];
|
||||
public static $m = [];
|
||||
|
||||
public static function data($val)
|
||||
{
|
||||
self::$m = Db::getRow('select * from sss_m where id = ?', [$val]);
|
||||
if (self::$m['s'] != self::$date['m']) {
|
||||
self::$m = [];
|
||||
}
|
||||
}
|
||||
}
|
10706
_incl_data/class/User.php
Normal file
10706
_incl_data/class/User.php
Normal file
File diff suppressed because it is too large
Load Diff
16
_incl_data/class/UserIp.php
Normal file
16
_incl_data/class/UserIp.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
class UserIp
|
||||
{
|
||||
public static function get()
|
||||
{
|
||||
return $_SERVER['HTTP_CLIENT_IP']
|
||||
?? $_SERVER["HTTP_CF_CONNECTING_IP"] # when behind cloudflare
|
||||
?? $_SERVER['HTTP_X_FORWARDED']
|
||||
?? $_SERVER['HTTP_X_FORWARDED_FOR']
|
||||
?? $_SERVER['HTTP_FORWARDED']
|
||||
?? $_SERVER['HTTP_FORWARDED_FOR']
|
||||
?? $_SERVER['REMOTE_ADDR']
|
||||
?? '0.0.0.0';
|
||||
}
|
||||
}
|
46
_incl_data/class/magic/sun_per_kruv.php
Normal file
46
_incl_data/class/magic/sun_per_kruv.php
Normal file
@ -0,0 +1,46 @@
|
||||
<?
|
||||
if(!defined('GAME'))
|
||||
{
|
||||
die();
|
||||
}
|
||||
|
||||
$io .= '<i>Ïîäàðî÷íûé êîìïëåêò Óâîðîòà</i>, ';
|
||||
$this->addItem(4953,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4953,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4596,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4598,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2469,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4961,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4967,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4969,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4601,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4599,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4986,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4595,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4597,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4597,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4597,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4401,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
|
||||
$io .= '<i>Ñâèòêè è ïðî÷èå ìàòåðèàëû....</i>, ';
|
||||
$this->addItem(2712,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2643,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2643,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4736,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4736,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4736,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4736,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4736,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(872,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2139,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2140,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(5046,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2390,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2390,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(2390,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(4941,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(994,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(1001,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
$this->addItem(3102,$this->info['id'],'|nosale=1|srok=864000|sudba='.$this->info['login']);
|
||||
|
||||
?>
|
678
_incl_data/mysql_override.php
Normal file
678
_incl_data/mysql_override.php
Normal file
@ -0,0 +1,678 @@
|
||||
<?php
|
||||
/**
|
||||
* Make mysql_connect work like mysqli_connect for future php versions.
|
||||
*
|
||||
* @author Ivor Barhansky
|
||||
* @version 0.1
|
||||
*/
|
||||
|
||||
//ini_set('default_charset', 'windows-1251');
|
||||
//ini_set('date.timezone', 'Europe/Moscow');
|
||||
|
||||
// Make sure the MySQL extension is not loaded and there is no other drop in replacement active
|
||||
if (!extension_loaded('mysql') && !function_exists('mysql_connect')) {
|
||||
// Validate if the MySQLi extension is present
|
||||
if (!extension_loaded('mysqli')) {
|
||||
trigger_error('The extension "MySQLi" is not available', E_USER_ERROR);
|
||||
}
|
||||
|
||||
// The function name "getLinkIdentifier" will be used to return a valid link_indentifier, make it is available
|
||||
if (function_exists('getLinkIdentifier')) {
|
||||
trigger_error('The function name "getLinkIdentifier" is already defined, please change the function name', E_USER_ERROR);
|
||||
}
|
||||
|
||||
// Define MySQL constants
|
||||
define('MYSQL_CLIENT_COMPRESS', MYSQLI_CLIENT_COMPRESS);
|
||||
define('MYSQL_CLIENT_IGNORE_SPACE', MYSQLI_CLIENT_IGNORE_SPACE);
|
||||
define('MYSQL_CLIENT_INTERACTIVE', MYSQLI_CLIENT_INTERACTIVE);
|
||||
define('MYSQL_CLIENT_SSL', MYSQLI_CLIENT_SSL);
|
||||
|
||||
define('MYSQL_ASSOC', MYSQLI_ASSOC);
|
||||
define('MYSQL_NUM', MYSQLI_NUM);
|
||||
define('MYSQL_BOTH', MYSQLI_BOTH);
|
||||
|
||||
// Will contain the link identifier
|
||||
$link = null;
|
||||
|
||||
/**
|
||||
* Get the link identifier
|
||||
*
|
||||
* @param mysqli $mysqli
|
||||
* @return mysqli|null
|
||||
*/
|
||||
function getLinkIdentifier(mysqli $mysqli = null)
|
||||
{
|
||||
if (!$mysqli) {
|
||||
global $link;
|
||||
$mysqli = $link;
|
||||
}
|
||||
|
||||
return $mysqli;
|
||||
}
|
||||
|
||||
/**
|
||||
* Open a connection to a MySQL Server
|
||||
*
|
||||
* @param $server
|
||||
* @param $username
|
||||
* @param $password
|
||||
* @return mysqli|null
|
||||
*/
|
||||
function mysql_connect($server, $username, $password, $new_link = false, $client_flags = 0)
|
||||
{
|
||||
global $link;
|
||||
|
||||
$link = mysqli_connect($server, $username, $password);
|
||||
return $link;
|
||||
}
|
||||
|
||||
/**
|
||||
* Open a persistent connection to a MySQL server
|
||||
*
|
||||
* @param $server
|
||||
* @param $username
|
||||
* @param $password
|
||||
* @return mysqli|null
|
||||
*/
|
||||
function mysql_pconnect($server, $username, $password, $new_link = false, $client_flags = 0)
|
||||
{
|
||||
global $link;
|
||||
|
||||
$link = mysqli_connect('p:' . $server, $username, $password);
|
||||
return $link;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $databaseName
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_select_db($databaseName)
|
||||
{
|
||||
global $link;
|
||||
|
||||
return mysqli_select_db($link, $databaseName);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $query
|
||||
* @param mysqli $mysqli
|
||||
* @return bool|mysqli_result
|
||||
*/
|
||||
function mysql_query($query, mysqli $mysqli = null)
|
||||
{
|
||||
return getLinkIdentifier($mysqli)->query($query);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $string
|
||||
* @param mysqli $mysqli
|
||||
* @return string
|
||||
*/
|
||||
function mysql_real_escape_string($string, mysqli $mysqli = null)
|
||||
{
|
||||
return getLinkIdentifier($mysqli)->escape_string($string);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @return bool|array
|
||||
*/
|
||||
function mysql_fetch_assoc(mysqli_result $result)
|
||||
{
|
||||
$result = $result->fetch_assoc();
|
||||
if ($result === null) {
|
||||
$result = false;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @return object|stdClass
|
||||
*/
|
||||
function mysql_fetch_object(mysqli_result $result)
|
||||
{
|
||||
$result = $result->fetch_object();
|
||||
if ($result === null) {
|
||||
$result = false;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @return bool|int
|
||||
*/
|
||||
function mysql_num_rows(mysqli_result $result)
|
||||
{
|
||||
$result = $result->num_rows;
|
||||
if ($result === null) {
|
||||
$result = false;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @return bool|array
|
||||
*/
|
||||
function mysql_fetch_row(mysqli_result $result)
|
||||
{
|
||||
$result = $result->fetch_row();
|
||||
if ($result === null) {
|
||||
$result = false;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return int
|
||||
*/
|
||||
function mysql_affected_rows(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_affected_rows(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return void
|
||||
*/
|
||||
function mysql_client_encoding(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_character_set_name(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_close(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_close(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_create_db($database_name, mysqli $mysqli = null)
|
||||
{
|
||||
trigger_error('This function was deprecated in PHP 4.3.0 and is therefor not supported', E_USER_DEPRECATED);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return int
|
||||
*/
|
||||
function mysql_errno(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_errno(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Not implemented
|
||||
*
|
||||
* @return null
|
||||
* @todo implement
|
||||
*
|
||||
*/
|
||||
function mysql_db_name()
|
||||
{
|
||||
trigger_error('The function mysql_db_name() is not implemented', E_USER_WARNING);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return string
|
||||
*/
|
||||
function mysql_error(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_error(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @param $result_type
|
||||
* @return void
|
||||
*/
|
||||
function mysql_fetch_array(mysqli_result $result, $result_type = MYSQL_BOTH)
|
||||
{
|
||||
return mysqli_fetch_array($result, $result_type);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_ping(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_ping(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $query
|
||||
* @param mysqli $mysqli
|
||||
*/
|
||||
function mysql_unbuffered_query($query, mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_query(getLinkIdentifier($mysqli), $query, MYSQLI_USE_RESULT);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
function mysql_get_client_info()
|
||||
{
|
||||
return mysqli_get_client_info();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli_result $result
|
||||
* @return void
|
||||
*/
|
||||
function mysql_free_result(mysqli_result $result)
|
||||
{
|
||||
return mysqli_free_result($result);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return bool|mysqli_result
|
||||
*/
|
||||
function mysql_list_dbs(mysqli $mysqli = null)
|
||||
{
|
||||
trigger_error('This function is deprecated. It is preferable to use mysql_query() to issue an SQL Query: SHOW DATABASES statement instead.', E_USER_DEPRECATED);
|
||||
|
||||
return mysqli_query(getLinkIdentifier($mysqli), 'SHOW DATABASES');
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $database_name
|
||||
* @param $table_name
|
||||
* @param null $mysqli
|
||||
* @return bool|mysqli_result
|
||||
*/
|
||||
function mysql_list_fields($database_name, $table_name, mysqli $mysqli = null)
|
||||
{
|
||||
trigger_error('This function is deprecated. It is preferable to use mysql_query() to issue an SQL SHOW COLUMNS FROM table [LIKE \'name\'] statement instead.', E_USER_DEPRECATED);
|
||||
|
||||
$mysqli = getLinkIdentifier($mysqli);
|
||||
$db = mysqli_escape_string($mysqli, $database_name);
|
||||
$table = mysqli_escape_string($mysqli, $table_name);
|
||||
|
||||
return mysqli_query($mysqli, sprintf('SHOW COLUMNS FROM %s.%s', $db, $table));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mysqli $mysqli
|
||||
* @return bool|mysqli_result
|
||||
*/
|
||||
function mysql_list_processes(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_query(getLinkIdentifier($mysqli), 'SHOW PROCESSLIST');
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $charset
|
||||
* @param null $mysqli
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_set_charset($charset, mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_set_charset(getLinkIdentifier($mysqli), $charset);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_info(mysqli $mysqli = null)
|
||||
{
|
||||
$result = mysqli_info(getLinkIdentifier($mysqli));
|
||||
if ($result === null) {
|
||||
$result = false;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get current system status
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_stat(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_stat(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the current thread ID
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_thread_id(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_thread_id(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get MySQL host info
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_get_host_info(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_get_host_info(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get MySQL protocol info
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_get_proto_info(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_get_proto_info(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get MySQL server info
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_get_server_info(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_get_server_info(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get table name of field
|
||||
*
|
||||
* @param $result
|
||||
* @param $i
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_tablename($result, $i)
|
||||
{
|
||||
trigger_error('Not implemented', E_USER_WARNING);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the ID generated in the last query
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return int|string
|
||||
*/
|
||||
function mysql_insert_id(mysqli $mysqli = null)
|
||||
{
|
||||
return mysqli_insert_id(getLinkIdentifier($mysqli));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get result data
|
||||
*
|
||||
* @param $result
|
||||
* @param $row
|
||||
* @param int $field
|
||||
* @return mixed
|
||||
*/
|
||||
function mysql_result($result, $row, $field = 0)
|
||||
{
|
||||
$result->data_seek($row);
|
||||
$row = $result->fetch_array();
|
||||
if (!isset($row[$field])) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $row[$field];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get number of fields in result
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @return int
|
||||
*/
|
||||
function mysql_num_fields(mysqli_result $result)
|
||||
{
|
||||
return mysqli_num_fields($result);
|
||||
}
|
||||
|
||||
/**
|
||||
* List tables in a MySQL database
|
||||
*
|
||||
* @param null $mysqli
|
||||
* @return bool|string
|
||||
*/
|
||||
function mysql_list_tables($database_name, mysqli $mysqli = null)
|
||||
{
|
||||
trigger_error('This function is deprecated. It is preferable to use mysql_query() to issue an SQL SHOW TABLES [FROM db_name] [LIKE \'pattern\'] statement instead.', E_USER_DEPRECATED);
|
||||
|
||||
$mysqli = getLinkIdentifier($mysqli);
|
||||
$db = mysqli_escape_string($mysqli, $database_name);
|
||||
|
||||
return mysqli_query($mysqli, sprintf('SHOW TABLES FROM %s', $db));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get column information from a result and return as an object
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param int $field_offset
|
||||
* @return bool|object
|
||||
*/
|
||||
function mysql_fetch_field(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
if ($field_offset) {
|
||||
mysqli_field_seek($result, $field_offset);
|
||||
}
|
||||
|
||||
return mysqli_fetch_field($result);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the length of the specified field
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param int $field_offset
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_field_len(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
trigger_error('This function is not implemented', E_USER_WARNING);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_drop_db()
|
||||
{
|
||||
trigger_error('This function is deprecated since PHP 4.3.0 and therefore not implemented', E_USER_DEPRECATED);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Move internal result pointer
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param int $row_number
|
||||
* @return void
|
||||
*/
|
||||
function mysql_data_seek(mysqli_result $result, $row_number = 0)
|
||||
{
|
||||
return mysqli_data_seek($result, $row_number);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the name of the specified field in a result
|
||||
*
|
||||
* @param $result
|
||||
* @param $field_offset
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_field_name($result, $field_offset = 0)
|
||||
{
|
||||
$props = mysqli_fetch_field_direct($result, $field_offset);
|
||||
return is_object($props) ? $props->name : false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the length of each output in a result
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @return array|bool
|
||||
*/
|
||||
function mysql_fetch_lengths(mysqli_result $result)
|
||||
{
|
||||
return mysqli_fetch_lengths($result);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the type of the specified field in a result
|
||||
* @param mysqli_result $result
|
||||
* @param $field_offset
|
||||
* @return string
|
||||
*/
|
||||
function mysql_field_type(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
$unknown = 'unknown';
|
||||
$info = mysqli_fetch_field_direct($result, $field_offset);
|
||||
if (empty($info->type)) {
|
||||
return $unknown;
|
||||
}
|
||||
|
||||
switch ($info->type) {
|
||||
case MYSQLI_TYPE_FLOAT:
|
||||
case MYSQLI_TYPE_DOUBLE:
|
||||
case MYSQLI_TYPE_DECIMAL:
|
||||
case MYSQLI_TYPE_NEWDECIMAL:
|
||||
return 'real';
|
||||
|
||||
case MYSQLI_TYPE_BIT:
|
||||
return 'bit';
|
||||
|
||||
case MYSQLI_TYPE_TINY:
|
||||
return 'tinyint';
|
||||
|
||||
case MYSQLI_TYPE_TIME:
|
||||
return 'time';
|
||||
|
||||
case MYSQLI_TYPE_DATE:
|
||||
return 'date';
|
||||
|
||||
case MYSQLI_TYPE_DATETIME:
|
||||
return 'datetime';
|
||||
|
||||
case MYSQLI_TYPE_TIMESTAMP:
|
||||
return 'timestamp';
|
||||
|
||||
case MYSQLI_TYPE_YEAR:
|
||||
return 'year';
|
||||
|
||||
case MYSQLI_TYPE_STRING:
|
||||
case MYSQLI_TYPE_VAR_STRING:
|
||||
return 'string';
|
||||
|
||||
case MYSQLI_TYPE_SHORT:
|
||||
case MYSQLI_TYPE_LONG:
|
||||
case MYSQLI_TYPE_LONGLONG:
|
||||
case MYSQLI_TYPE_INT24:
|
||||
return 'int';
|
||||
|
||||
case MYSQLI_TYPE_CHAR:
|
||||
return 'char';
|
||||
|
||||
case MYSQLI_TYPE_ENUM:
|
||||
return 'enum';
|
||||
|
||||
case MYSQLI_TYPE_TINY_BLOB:
|
||||
case MYSQLI_TYPE_MEDIUM_BLOB:
|
||||
case MYSQLI_TYPE_LONG_BLOB:
|
||||
case MYSQLI_TYPE_BLOB:
|
||||
return 'blob';
|
||||
|
||||
case MYSQLI_TYPE_NULL:
|
||||
return 'null';
|
||||
|
||||
case MYSQLI_TYPE_NEWDATE:
|
||||
case MYSQLI_TYPE_INTERVAL:
|
||||
case MYSQLI_TYPE_SET:
|
||||
case MYSQLI_TYPE_GEOMETRY:
|
||||
default:
|
||||
return $unknown;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get name of the table the specified field is in
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param $field_offset
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_field_table(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
$info = mysqli_fetch_field_direct($result, $field_offset);
|
||||
if (empty($info->table)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $info->table;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the flags associated with the specified field in a result
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param int $field_offset
|
||||
* @return bool
|
||||
* @todo implement
|
||||
*
|
||||
*/
|
||||
function mysql_field_flags(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
trigger_error('This function is not implemented', E_USER_WARNING);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set result pointer to a specified field offset
|
||||
*
|
||||
* @param mysqli_result $result
|
||||
* @param int $field_offset
|
||||
* @return bool
|
||||
*/
|
||||
function mysql_field_seek(mysqli_result $result, $field_offset = 0)
|
||||
{
|
||||
return mysqli_field_seek($result, $field_offset);
|
||||
}
|
||||
|
||||
/**
|
||||
* Selects a database and executes a query on it
|
||||
*
|
||||
* @param $database
|
||||
* @param $query
|
||||
* @param mysqli $mysqli
|
||||
* @return bool
|
||||
* @todo implement
|
||||
*
|
||||
*/
|
||||
function mysql_db_query($database, $query, mysqli $mysqli = null)
|
||||
{
|
||||
trigger_error('This function is deprecated since PHP 5.3.0 and therefore not implemented', E_USER_DEPRECATED);
|
||||
return false;
|
||||
}
|
||||
}
|
282
adminion/index.php
Normal file
282
adminion/index.php
Normal file
@ -0,0 +1,282 @@
|
||||
<?
|
||||
|
||||
$sd4 = 'admin';
|
||||
$psw = md5('tip:'.$_SERVER['REMOTE_ADDR'].'t'.date('dh',time()).'t'.$sd4);
|
||||
$psw = $psw[7].$psw[3].$psw[0].$psw[1].$psw[5];
|
||||
$auth = false;
|
||||
|
||||
$_POST['psw'] = $psw;
|
||||
|
||||
if(isset($_COOKIE['pass3']) && $_COOKIE['pass3']==$psw){
|
||||
$auth = true;
|
||||
}
|
||||
if(isset($_GET['code'])){
|
||||
$tpsw = md5('tip:'.$_SERVER['REMOTE_ADDR'].'t'.$_GET['code'].'t'.$sd4);
|
||||
$tpsw = $tpsw[7].$tpsw[3].$tpsw[0].$tpsw[1].$tpsw[5];
|
||||
die($tpsw);
|
||||
}elseif(isset($_POST['psw'])){
|
||||
if($_POST['psw']==$psw) {
|
||||
setcookie('pass3',$_POST['psw'],time()+36000);
|
||||
$_COOKIE['pass3'] = $_POST['psw'];
|
||||
$auth = true;
|
||||
}
|
||||
}elseif(isset($_GET['exit'])){
|
||||
if($_COOKIE['pass3']==$psw){
|
||||
setcookie('pass3',false,time()-3600);
|
||||
unset($_COOKIE['pass3']);
|
||||
$auth = false;
|
||||
}
|
||||
}
|
||||
include_once('../_incl_data/__config.php');
|
||||
define('GAME',true);
|
||||
include_once('../_incl_data/class/__db_connect.php');
|
||||
include_once('../_incl_data/class/__user.php');
|
||||
if($u->info['admin']=0){
|
||||
die(':KING:');
|
||||
}
|
||||
?><!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251" />
|
||||
<meta http-equiv=Cache-Control Content=no-cache>
|
||||
<meta http-equiv=PRAGMA content=NO-CACHE>
|
||||
<meta http-equiv=Expires Content=0>
|
||||
<title>Öåíòð óïðàâëåíèÿ "Adminion"</title>
|
||||
<link href="https://<?=$c['img']?>/css/main.css" rel="stylesheet" type="text/css">
|
||||
<style>
|
||||
.tblbr2 {
|
||||
border-left:1px solid #AEAFAE;
|
||||
border-top:1px solid #AEAFAE;
|
||||
border-bottom:1px solid #EEEFEE;
|
||||
border-right:1px solid #EEEFEE;
|
||||
}
|
||||
.tblbr {
|
||||
border-left:1px solid #EEEFEE;
|
||||
border-top:1px solid #EEEFEE;
|
||||
border-bottom:1px solid #AEAFAE;
|
||||
border-right:1px solid #AEAFAE;
|
||||
}
|
||||
.ñòèëü1 {border-left: 1px solid #AEAFAE; border-top: 1px solid #AEAFAE; border-bottom: 1px solid #EEEFEE; border-right: 1px solid #EEEFEE; font-size: 12px; }
|
||||
.ñòèëü2 {
|
||||
font-size: 12px;
|
||||
color: #999999;
|
||||
}
|
||||
.ñòèëü5 {font-size: 12px}
|
||||
.test a {
|
||||
font-weight: normal;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body style="padding-top:0px; margin-top:2px; background-color:#dedfde;">
|
||||
<table class="tblbr" width="100%" border="0" cellspacing="0" cellpadding="5">
|
||||
<tr>
|
||||
<td class="ñòèëü1"><table width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>Adminion v0.0.0
|
||||
<? if($auth==true){
|
||||
$la = sys_getloadavg();
|
||||
$la[0]=$la[0]/4;
|
||||
$la[1]=$la[1]/4;
|
||||
$la[2]=$la[2]/4;
|
||||
?>
|
||||
/ Âðåìÿ ñåðâåðà: <?=date('H:i')?> ( <?=time()?> ) / <?
|
||||
echo "Íàãðóçêà: ".round($la[0]*100,2)."% ";
|
||||
if ($la[1] < 0.16) {
|
||||
echo "<font color=green>íèçêàÿ</font>";
|
||||
} elseif ($la[1] < 0.25) {
|
||||
echo "<font color=orange>ñðåäíÿÿ</font>";
|
||||
} elseif ($la[1] > 0.25) {
|
||||
echo "<font color=red>âûñîêàÿ</font>";
|
||||
}
|
||||
?>
|
||||
<? }
|
||||
$online = 0;
|
||||
$sp = mysql_query('SELECT `id`,`room`,`city` FROM `users` WHERE `online` > ('.time().'-600)');
|
||||
while($pl = mysql_fetch_array($sp))
|
||||
{
|
||||
$online++;
|
||||
}
|
||||
?> / Îíëàéí: <?=$online?> / Íàãðóçêà USI: <?=round((round($la[2]*100,2)/$online),2)?>%</td>
|
||||
<td> </td>
|
||||
<td><? if($auth==true){ ?><div align="right"><a href="../adminion/?exit=<?=$code?>">Âûéòè</a></div><? } ?></td>
|
||||
</tr>
|
||||
|
||||
</table></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<div align="center">
|
||||
<?
|
||||
if(!isset($_COOKIE['pass3']) || $_COOKIE['pass3']!=$psw){
|
||||
?>
|
||||
<form action="../adminion/index.php" method="post"><center><br><br>
|
||||
<span class="ñòèëü5"><br>
|
||||
Äëÿ âõîäà â ïàíåëü òðåáóåòñÿ ïàðîëü</span>
|
||||
<hr>
|
||||
<span class="ñòèëü5">Ââåäèòå ïàðîëü:
|
||||
<input value="" name="psw" type="password">
|
||||
<input type="submit" value="îê" />
|
||||
</span>
|
||||
</form>
|
||||
</div>
|
||||
<?
|
||||
}else{
|
||||
?>
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td width="200" height="18" valign="top"><table class="test" width="100%" border="0" align="left" cellpadding="2" cellspacing="0">
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Îáùèå íàñòðîéêè</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Íàñòðîéêà ñåðâåðà</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Íàñòðîéêè ìîäóëåé</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Ïåðñîíàæè</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïîèñê ïåðñîíàæåé</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ðàáîòà ñ ïåðñîíàæåì</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ðàáîòà ñ áîòîì</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Ïðåäìåòû</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïîèñê ïðåäìåòà</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ðàáîòà ñ ïðåäìåòîì</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïðåäìåòû ó ïåðñîíàæåé</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Ëîêàöèè</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïîèñê ëîêàöèè</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ðàáîòà ñ ëîêàöèåé</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Äîáàâèòü ëîêàöèþ</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Äåéñòâèÿ</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïðîâåðèòü ïåðåâîäû</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïðîâåðèòü äåéñòâèÿ</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïðîâåðèòü ÷àò</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Ïîåäèíêè</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ïîèñê ïîåäèíêà</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Íàñòðîéêè áàëàíñà</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="left" class="tblbr"><strong style="margin-left:10px;">Ïåùåðû</strong></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="../adminion/?mod=dungeon_list">Ñïèñîê ïåùåð</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="../adminion/?mod=dungeon&r=1">Ðåäàêòîð ëàáèðèíòîâ</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="../adminion/?mod=dungeon_bots">Ðåäàêòîð áîòîâ</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="../adminion/?mod=dungeon_editor">Ðåäàêòîð ïåùåð</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="../adminion/?mod=dobj&r=1">Ðàáîòà ñ îáüåêòàìè</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ñîçäàòü ïåùåðó</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ðàáîòà ñ êâåñòàìè</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"><a href="#">Ñîçäàòü êâåñò</a></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
</tr>
|
||||
</table></td>
|
||||
<td valign="top" style="padding:10px;">
|
||||
<?
|
||||
if(isset($_GET['mod'])){
|
||||
if(file_exists('../adminion/mod/'.htmlspecialchars($_GET['mod'],NULL,'cp1251').'.php')){
|
||||
include('../adminion/mod/'.htmlspecialchars($_GET['mod'],NULL,'cp1251').'.php');
|
||||
}else{
|
||||
echo '<center>Ó âàñ íåò äîñòóïà ê äàííîìó ðàçäåëó</center>';
|
||||
}
|
||||
}else{
|
||||
echo '<center>Âûáåðèòå ðàçäåë</center>';
|
||||
}
|
||||
?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?
|
||||
}
|
||||
?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="center" class="ñòèëü2">new-combats.com <BR>
|
||||
All rights reserved.</div></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
19
adminion/lib/loadItemInfo.php
Normal file
19
adminion/lib/loadItemInfo.php
Normal file
@ -0,0 +1,19 @@
|
||||
<?
|
||||
/*if($_POST['item_id']){
|
||||
include_once('../../_incl_data/__config.php');
|
||||
define('GAME',true);
|
||||
include_once('../../_incl_data/class/__db_connect.php');
|
||||
$item = mysql_fetch_array(mysql_query("SELECT name FROM items_main WHERE id = '".$_POST['item_id']."' LIMIT 1"));
|
||||
echo $item['name']." [".$_POST['item_id']."]";
|
||||
}
|
||||
if($_POST['getListItems'] == true){
|
||||
include_once('../../_incl_data/__config.php');
|
||||
define('GAME',true);
|
||||
include_once('../../_incl_data/class/__db_connect.php');
|
||||
$items = mysql_query("SELECT id, info FROM items_main WHERE `info` LIKE 'Ïðåäìåò äëÿ áîòîâ%'");
|
||||
while($item = mysql_fetch_array($items)){
|
||||
$item['info'] = explode(':',$item['info']);
|
||||
echo $item['info'][1]." [".$item['id']."]";
|
||||
}
|
||||
}*/
|
||||
?>
|
147
adminion/mod/dobj.php
Normal file
147
adminion/mod/dobj.php
Normal file
@ -0,0 +1,147 @@
|
||||
<?
|
||||
if(!defined('GAME'))
|
||||
{
|
||||
die();
|
||||
}
|
||||
|
||||
$stl = 15; //êîë-âî ñòèëåé êëåòîê
|
||||
?>
|
||||
<script src="https://<? echo $c['img']; ?>/js/jx/jquery.js" type="text/javascript"></script>
|
||||
<table class="tblbr2" width="100%" border="0" cellspacing="0" cellpadding="5">
|
||||
<tr>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="300" valign="top">Ãëàâíûå íàñòðîéêè îáüåêòà:</td>
|
||||
<td valign="top">Ñâîéñòâà îáüåêòà:</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="top"><p>Èçîáðàæåíèå:</p>
|
||||
<p align="center"><img src="" /></p></td>
|
||||
<td valign="top" class="tblbr"><table width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td width="170"><div align="left">ID:</div></td>
|
||||
<td><div align="left">
|
||||
<input type="text" name="textfield" id="textfield" />
|
||||
<input type="submit" name="button" id="button" value="Çàãðóçèòü øàáëîí" />
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Íàçâàíèå:</div></td>
|
||||
<td><div align="left">
|
||||
<input type="text" name="textfield2" id="textfield2" />
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Èçîáðàæåíèå:</div></td>
|
||||
<td><div align="left">
|
||||
<input type="text" name="textfield3" id="textfield3" />
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Ðàñïîëîæåíèå:</div></td>
|
||||
<td><div align="left">
|
||||
<table border="0" cellspacing="5" cellpadding="0">
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="checkbox" id="checkbox" /></td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="checkbox8" id="checkbox8" /></td>
|
||||
<td><input type="checkbox" name="checkbox5" id="checkbox5" /></td>
|
||||
<td><input type="checkbox" name="checkbox3" id="checkbox3" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="checkbox6" id="checkbox6" /></td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Ñòîðîíû îáçîðà:</div></td>
|
||||
<td><div align="left">
|
||||
<table border="0" cellspacing="5" cellpadding="0">
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="checkbox2" id="checkbox2" /></td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="checkbox" name="checkbox2" id="checkbox4" /></td>
|
||||
<td><input type="checkbox" name="checkbox2" id="checkbox7" /></td>
|
||||
<td><input type="checkbox" name="checkbox2" id="checkbox9" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td><input type="checkbox" name="checkbox2" id="checkbox10" /></td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Òèï:</div></td>
|
||||
<td><div align="left">
|
||||
<select name="select" id="select">
|
||||
<option value="0">ïóñòî</option>
|
||||
</select>
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Âûñîòà èçîáðàæåíèÿ:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield4" type="text" id="textfield4" size="7" />
|
||||
px</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Øèðèíà èçîáðàæåíèÿ:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield5" type="text" id="textfield5" size="7" />
|
||||
px</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Ñäâèã ââåðõ:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield6" type="text" id="textfield6" size="7" />
|
||||
%</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Ñäâèã âëåâî:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield7" type="text" id="textfield7" size="7" />
|
||||
% </div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"></div></td>
|
||||
<td><div align="left"></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Êîîðäèíàòû X:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield8" type="text" id="textfield8" size="7" />
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left">Êîîðäèíàòû Y:</div></td>
|
||||
<td><div align="left">
|
||||
<input name="textfield9" type="text" id="textfield9" size="7" />
|
||||
</div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><div align="left"></div></td>
|
||||
<td><div align="left"></div></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="top"><div align="left">Äåéñòâèÿ:</div></td>
|
||||
<td><p align="left">
|
||||
<textarea name="textarea" id="textarea" cols="45" rows="5"></textarea>
|
||||
</p>
|
||||
<p align="left"><a href="#">Èíñòðóêöèÿ ê ïîëþ "Äåéñòâèÿ"</a></p></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
490
adminion/mod/dungeon.php
Normal file
490
adminion/mod/dungeon.php
Normal file
@ -0,0 +1,490 @@
|
||||
<?
|
||||
if(!defined('GAME')){
|
||||
die();
|
||||
}
|
||||
|
||||
$stl = 15; //êîë-âî ñòèëåé êëåòîê
|
||||
?>
|
||||
<script src="https://<? echo $c['img']; ?>/js/jx/jquery.js" type="text/javascript"></script>
|
||||
<script>
|
||||
var refnow1 = 0;
|
||||
var md = 0;
|
||||
var xxx = 0;
|
||||
var yyy = 0;
|
||||
function loadDate(){
|
||||
$.post('../../jx/dungeon.php',{x:xxx,y:yyy,ddid:<?=(int)$_GET['r']?>,id:<? echo time(); ?>,mdf:md},function(data){$("#rd").html(data);});
|
||||
setTimeout('refnow1 = 0;',1000);
|
||||
}
|
||||
|
||||
function startDunge(uid,login,level,hp,hpAll,x,y)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
function er(t)
|
||||
{
|
||||
document.getElementById('error').innerHTML = '<font color="red">'+t+'</font>';
|
||||
}
|
||||
|
||||
function addPxMap(id,img,x,y,clk)
|
||||
{
|
||||
var m = document.getElementById('map');
|
||||
if(m!=undefined)
|
||||
{
|
||||
|
||||
}else{
|
||||
er('Îøèáêà ïîñòðîåíèÿ êàðòû...');
|
||||
}
|
||||
}
|
||||
|
||||
function tc(v)
|
||||
{
|
||||
v = v.split('px');
|
||||
v = Math.round(v[0]);
|
||||
return v;
|
||||
}
|
||||
|
||||
function getPix(v)
|
||||
{
|
||||
v = v.split('_');
|
||||
var r = {'x':v[1],'y':v[2]};
|
||||
return r;
|
||||
}
|
||||
|
||||
function goYou()
|
||||
{
|
||||
var you = document.getElementById('map_you');
|
||||
if(you!=undefined)
|
||||
{
|
||||
var l1 = you.offsetLeft;
|
||||
var t1 = you.offsetTop;
|
||||
var pr = you.offsetParent;
|
||||
pr = getPix(pr.id);
|
||||
goPix(pr['x'],pr['y']);
|
||||
}else{
|
||||
er('Îøèáêà ïîëó÷åíèÿ êîîðäèíàò');
|
||||
}
|
||||
}
|
||||
|
||||
var nowGo;
|
||||
var mapNow = '';
|
||||
var mapNew = '';
|
||||
var obj = '';
|
||||
var users = '';
|
||||
//íà÷àëüíûå êîîðäèíàòû
|
||||
var xn = 9;
|
||||
var yn = 9;
|
||||
|
||||
function mapArray(v)
|
||||
{
|
||||
var i=0,j = new Array,k = 0,vl = new Array;
|
||||
v = v.split('|');
|
||||
while(i!=-1)
|
||||
{
|
||||
if(v[i]!=undefined && v[i]!='end' && v[i]!='')
|
||||
{
|
||||
j = v[i].split('=');
|
||||
if(j[0]>0)
|
||||
{
|
||||
vl[j[1]+'_'+j[2]] = j;
|
||||
k++;
|
||||
}
|
||||
}else{
|
||||
i = -2;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
||||
return vl;
|
||||
}
|
||||
|
||||
function testGo(x,y)
|
||||
{
|
||||
$.post('../../jx/dungeon.php',{x:xxx,y:yyy,ddid:<?=(int)$_GET['r']?>,id:<? echo time(); ?>,mdf:md,gox:x,goy:y},function(data){$("#rd").html(data);});
|
||||
setTimeout('refnow1 = 0;',500);
|
||||
}
|
||||
|
||||
//ïåðåðàñïðåäåëåíèå êëåòîê
|
||||
function refleshMapDate()
|
||||
{
|
||||
var i = 0,j = 0,nx,ny,pix;
|
||||
var mapArr = mapArray(mapNew);
|
||||
var ob = new Array();
|
||||
var ob2 = new Array();
|
||||
var ob3 = new Array();
|
||||
var ub = new Array();
|
||||
var ub2 = new Array();
|
||||
var ub3 = new Array();
|
||||
|
||||
//ñîçäàåì îáüåêòû íà êàðòå
|
||||
var k = 0; var o1 = obj.split('|#|'); var ok2 = 1;
|
||||
while(k!=-1)
|
||||
{
|
||||
if(o1[k]!=undefined && o1[k]!='')
|
||||
{
|
||||
var o2 = o1[k].split('|!|');
|
||||
ob[o2[0]] += ok2+'|$|';
|
||||
ob2[ok2] = o2;
|
||||
ob3[o2[5]+'!'+o2[6]] = ok2;
|
||||
ok2++;
|
||||
}else{
|
||||
k = -2;
|
||||
}
|
||||
k++;
|
||||
}
|
||||
|
||||
//ñîçäàåì þçåðîâ íà êàðòå
|
||||
var k = 0; var u1 = users.split('|$|'); var uok2 = 1;
|
||||
|
||||
while(k!=-1)
|
||||
{
|
||||
if(u1[k]!=undefined && u1[k]!='')
|
||||
{
|
||||
var u2 = u1[k].split('=');
|
||||
ub2[uok2] = u2;
|
||||
ub3[u2[3]+'!'+u2[4]] = uok2;
|
||||
uok2++;
|
||||
}else{
|
||||
k = -2;
|
||||
}
|
||||
k++;
|
||||
}
|
||||
|
||||
var oid,ogo,objst;
|
||||
while(i<=17)
|
||||
{
|
||||
j = 0;
|
||||
while(j<=17)
|
||||
{
|
||||
|
||||
pix = document.getElementById('map_'+j+'_'+i+'');
|
||||
|
||||
nx = j-9;
|
||||
ny = i-9;
|
||||
nwx = xn+nx;
|
||||
nwy = yn+ny;
|
||||
|
||||
objst = '';
|
||||
|
||||
//îáíîâëÿåì îáüåêòû
|
||||
if(ob3[''+nwx+'!'+nwy+'']!=undefined)
|
||||
{
|
||||
oid = ob3[''+nwx+'!'+nwy+''];
|
||||
ogo = ob2[oid];
|
||||
objst = '<img src="https://<? echo $c['img']; ?>/dn/'+ogo[3]+'" title="'+ogo[4]+'" />';
|
||||
}
|
||||
|
||||
//îáíîâëÿåì þçåðîâ
|
||||
if(ub3[''+nwx+'!'+nwy+'']!=undefined)
|
||||
{
|
||||
oid = ub3[''+nwx+'!'+nwy+''];
|
||||
ogo = ub2[oid];
|
||||
if(ogo[0]!=<? echo $u->info['id']; ?>)
|
||||
{
|
||||
if(ogo[5]==0)
|
||||
{
|
||||
//èãðîê
|
||||
objst = '<img width="16" height="16" src="https://<? echo $c['img']; ?>/dn/users_.png" title="'+ogo[1]+' ['+ogo[2]+']" />';
|
||||
}else{
|
||||
//áîò
|
||||
objst = '<img width="28" height="28" src="https://<? echo $c['img']; ?>/dn/'+ogo[6]+'" title="'+ogo[1]+' ['+ogo[2]+'] (Áîò)" />';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//îáíîâëÿåì êëåòêó
|
||||
if(pix!=undefined)
|
||||
{
|
||||
//çàìåíÿåì êëåòêè
|
||||
thm = mapArr[''+nwx+'_'+nwy+''];
|
||||
if(thm!=undefined && thm[0]>0)
|
||||
{
|
||||
pix.className = 'dpix'+thm[3];
|
||||
pix.innerHTML = '<div style="height:32px;width:32px;cursor:pointer;" <? if($u->info['admin']>0 || $u->info['id']==1000010){ ?>oncontextmenu="adminion('+thm[1]+','+thm[2]+',event); return false;"<? } ?> onclick="testGo('+nwx+','+nwy+');" id="content_'+j+'_'+i+'">'+objst+'</div>';
|
||||
}else{
|
||||
<? if($u->info['admin']>0 || $u->info['id']==1000010){ ?>
|
||||
pix.className = '';
|
||||
pix.innerHTML = '<div class="newpix" style="height:30px;width:30px;cursor:pointer;" <? if($u->info['admin']>0 || $u->info['id']==1000010){ ?>onClick="testGo('+nwx+','+nwy+')" oncontextmenu="adminion('+nwx+','+nwy+',event); return false;"<? } ?>>'+objst+'</div>';
|
||||
<? }else{ ?>
|
||||
pix.className = '';
|
||||
pix.innerHTML = '';
|
||||
<? } ?>
|
||||
}
|
||||
}
|
||||
|
||||
//îáíîâëÿåì îáüåêòû íà êëåòêå
|
||||
|
||||
j++;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
mapNow = mapNew;
|
||||
goPix(9,9,true);
|
||||
}
|
||||
|
||||
function takeItem(id)
|
||||
{
|
||||
$.post('../../jx/dungeon.php',{x:xxx,y:yyy,ddid:<?=(int)$_GET['r']?>,id:<? echo time(); ?>,takeItem:id},function(data){$("#rd").html(data);});
|
||||
}
|
||||
|
||||
<?
|
||||
if($u->info['admin']>0 || $u->info['id']==1000010)
|
||||
{
|
||||
?>
|
||||
function queryAdmin(act)
|
||||
{
|
||||
$.post('../../jx/dungeon.php',{x:xxx,y:yyy,ddid:<?=(int)$_GET['r']?>,id:<? echo time(); ?>,adminion:1,action:act},function(data){$("#rd").html(data);});
|
||||
}
|
||||
|
||||
function adminion(x,y,event)
|
||||
{
|
||||
var ed = document.getElementById('editor');
|
||||
if(ed!=undefined)
|
||||
{
|
||||
var mapArr = mapArray(mapNow);
|
||||
var pix = mapArr[''+x+'_'+y+''];
|
||||
if(pix==undefined)
|
||||
{
|
||||
pix = new Array;
|
||||
pix[0] = 'íåò';
|
||||
pix[3] = -1;
|
||||
}
|
||||
document.getElementById('map').style.display = 'none';
|
||||
ed.style.display = '';
|
||||
ed.innerHTML += '<Br> X: '+x+',Y: '+y+' <a href="#" title="Çàêðûòü ðåäàêòîð" onClick="closeAdminion(); return false;">[x]</a>, ';
|
||||
ed.innerHTML += ' ID: '+pix[0]+' <a href="#" onClick="queryAdmin(\'delete|$|'+x+'|!|'+y+'\'); return false;">óäàëèòü</a><br>';
|
||||
var chstyle = '';
|
||||
<? $i = 0; while($i<=$stl){ ?>
|
||||
if(<? echo $i; ?>==pix[3])
|
||||
{
|
||||
chstyle += '<div style="width:32px; height:32px; float:left; margin:2px;" class="dpix<? echo $i; ?>"><img title="Óæå óñòàíîâëåííî" src="https://<? echo $c['img']; ?>/good.png"></div>';
|
||||
}else{
|
||||
chstyle += '<div style="width:32px; height:32px; cursor:pointer; float:left; margin:2px;" onClick="queryAdmin(\'select_image|$|<? echo $i; ?>|!|'+x+'|!|'+y+'\');" class="dpix<? echo $i; ?>"></div>';
|
||||
}
|
||||
<? $i++; } ?>
|
||||
gonbotch1 = '';
|
||||
gonbotch2 = '';
|
||||
gonbotch3 = '';
|
||||
gonbotch4 = '';
|
||||
goch1 = '';
|
||||
goch2 = '';
|
||||
goch3 = '';
|
||||
goch4 = '';
|
||||
goch5 = '';
|
||||
if(pix[5]==1){
|
||||
goch1 = 'checked';
|
||||
}
|
||||
if(pix[6]==1){
|
||||
goch2 = 'checked';
|
||||
}
|
||||
if(pix[7]==1){
|
||||
goch3 = 'checked';
|
||||
}
|
||||
if(pix[8]==1){
|
||||
goch4 = 'checked';
|
||||
}
|
||||
if(pix[9]==1){
|
||||
goch5 = 'checked';
|
||||
}
|
||||
if(pix[10]==1){
|
||||
gonbotch1 = 'checked';
|
||||
}
|
||||
if(pix[11]==1){
|
||||
gonbotch2 = 'checked';
|
||||
}
|
||||
if(pix[12]==1){
|
||||
gonbotch3 = 'checked';
|
||||
}
|
||||
if(pix[13]==1){
|
||||
gonbotch4 = 'checked';
|
||||
}
|
||||
console.log(pix[10]);
|
||||
ed.innerHTML += ' '+chstyle+'<br>';
|
||||
ed.innerHTML += ' <table><tr><td>Âîçìîæíûå äâèæåíèÿ:<br><table width="60" border="0" cellspacing="0" cellpadding="0">'+
|
||||
'<tr>'+
|
||||
'<td width="20" height="20"> </td>'+
|
||||
'<td><input name="go3" type="checkbox" id="go3" '+goch3+'></td>'+
|
||||
'<td> </td>'+
|
||||
'</tr>'+
|
||||
'<tr>'+
|
||||
'<td><input name="go2" type="checkbox" id="go2" '+goch2+'></td>'+
|
||||
'<td width="20" height="20"><div align="center">'+
|
||||
'<input name="go5" type="checkbox" id="go5" '+goch5+'>'+
|
||||
'</div></td>'+
|
||||
'<td><input name="go1" type="checkbox" id="go1" '+goch1+'></td>'+
|
||||
'</tr>'+
|
||||
'<tr>'+
|
||||
'<td> </td>'+
|
||||
'<td><input name="go4" type="checkbox" id="go4" '+goch4+'></td>'+
|
||||
'<td width="20" height="20"> </td>'+
|
||||
'</tr>'+
|
||||
'</table></td><td>'+
|
||||
'Çàïðåò äëÿ áîòîâ:<br><table width="60" border="0" cellspacing="0" cellpadding="0">'+
|
||||
'<tr>'+
|
||||
'<td width="20" height="20"> </td>'+
|
||||
'<td><input name="nbot3" type="checkbox" id="nbot1" '+gonbotch1+'></td>'+
|
||||
'<td> </td>'+
|
||||
'</tr>'+
|
||||
'<tr>'+
|
||||
'<td><input name="nbot2" type="checkbox" id="nbot2" '+gonbotch2+'></td>'+
|
||||
'<td width="20" height="20"><div align="center">'+
|
||||
'</div></td>'+
|
||||
'<td><input name="nbot1" type="checkbox" id="nbot4" '+gonbotch4+'></td>'+
|
||||
'</tr>'+
|
||||
'<tr>'+
|
||||
'<td> </td>'+
|
||||
'<td><input name="nbot4" type="checkbox" id="nbot3" '+gonbotch3+'></td>'+
|
||||
'<td width="20" height="20"> </td>'+
|
||||
'</tr>'+
|
||||
'</table>'+
|
||||
'</td></tr></table>'+
|
||||
'<a href="#" onClick="queryAdmin(\'save_go|$|'+x+'|!|'+y+'|!|\'+document.getElementById(\'go1\').checked+\'|!|\'+document.getElementById(\'go2\').checked+\'|!|\'+document.getElementById(\'go3\').checked+\'|!|\'+document.getElementById(\'go4\').checked+\'|!|\'+document.getElementById(\'go5\').checked+\'|!|\'+document.getElementById(\'nbot1\').checked+\'|!|\'+document.getElementById(\'nbot2\').checked+\'|!|\'+document.getElementById(\'nbot3\').checked+\'|!|\'+document.getElementById(\'nbot4\').checked+\'\'); return false;">ñîõðàíèòü âîçìîæíûå äâèæåíèÿ</a>';
|
||||
}
|
||||
}
|
||||
|
||||
function closeAdminion()
|
||||
{
|
||||
document.getElementById('map').style.display = '';
|
||||
document.getElementById('editor').style.display = 'none';
|
||||
document.getElementById('editor').innerHTML = '';
|
||||
goPix(9,9,true);
|
||||
}
|
||||
<?
|
||||
}
|
||||
?>
|
||||
|
||||
function goPix(x,y,fast)
|
||||
{
|
||||
clearTimeout(nowGo);
|
||||
var m = document.getElementById('dataMap');
|
||||
var g = document.getElementById('map_'+x+'_'+y);
|
||||
if(m!=undefined && g!=undefined)
|
||||
{
|
||||
var fs1 = 0;
|
||||
var fs2 = 0;
|
||||
|
||||
var x1 = tc(m.style.left);
|
||||
var x2 = g.offsetLeft;
|
||||
var y1 = tc(m.style.top);
|
||||
var y2 = g.offsetTop;
|
||||
|
||||
if(fast==true)
|
||||
{
|
||||
m.style.left = -Math.round(x2)+171-28+'px';
|
||||
m.style.top = -Math.round(y2)+122-28+'px';
|
||||
}else{
|
||||
if(x1 > -Math.round(x2)+171-28)
|
||||
{
|
||||
m.style.left = tc(m.style.left)-1;
|
||||
}else if(x1 < -Math.round(x2)+171-28){
|
||||
m.style.left = tc(m.style.left)+1;
|
||||
}else{
|
||||
fs1 = 1;
|
||||
}
|
||||
|
||||
if(y1 > -Math.round(y2)+122-28)
|
||||
{
|
||||
m.style.top = tc(m.style.top)-1+'px';
|
||||
}else if(y1 < -Math.round(y2)+122-28){
|
||||
m.style.top = tc(m.style.top)+1+'px';
|
||||
}else{
|
||||
fs2 = 1;
|
||||
}
|
||||
|
||||
if(fs1==0 || fs2==0)
|
||||
{
|
||||
nowGo = setTimeout('goPix('+x+','+y+','+fast+')',15);
|
||||
}else{
|
||||
//äåëàåì ñìåùåíèå
|
||||
|
||||
}
|
||||
}
|
||||
}else{
|
||||
er('Îøèáêà èíèöèàëèçàöèè êàðòû...');
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.newpix {
|
||||
|
||||
}
|
||||
.newpix:hover {
|
||||
background-color:#E4F3DE;
|
||||
border: 1px dotted #00CC00;
|
||||
}
|
||||
<?
|
||||
$i = 0;
|
||||
while($i<=$stl)
|
||||
{
|
||||
?>
|
||||
.dpix<? echo $i; ?> {
|
||||
background-image:url(https://<? echo $c['img']; ?>/dn/dpix<? echo $i; ?>.jpg);
|
||||
}
|
||||
.dpix<? echo $i; ?>:hover {
|
||||
background-image:url(https://<? echo $c['img']; ?>/dn/dpix<? echo $i; ?>.jpg);
|
||||
|
||||
}
|
||||
<? $i++; } ?>
|
||||
</style>
|
||||
|
||||
<table class="tblbr2" width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td valign="top"><table width="470" border="0" align="center" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<div align="left">
|
||||
<div id="users"></div>
|
||||
<div align="left"></div>
|
||||
<div id="items"></div>
|
||||
</div>
|
||||
</td>
|
||||
<td width="470" height="400" valign="top">
|
||||
<div id="rd" style="display:none"></div>
|
||||
<div id="error" style="display:none" align="center"></div>
|
||||
<div style="position:relative;">
|
||||
<div style="position:absolute; z-index:102; width:457px; height:48px; top:275px; left:0px;" align="center">
|
||||
<img src="https://<? echo $c['img']; ?>/dn_btn_ref.png" title="Îáíîâèòü" onClick="loadDate();" style="cursor:pointer;" /><br />
|
||||
Âû ñåé÷àñ íàõîäèòåñü â "<span id="locName">òåñòîâàÿ ëîêàöèÿ</span>".
|
||||
</div>
|
||||
<div style="position:absolute; z-index:101; width:457px; height:349px; top:0px; left:0px;">
|
||||
<? if($u->info['admin']>0){ ?>
|
||||
<div id="editor" style="position:relative; display:none; background-color:#F7F7F7; width:323px; height:227px; overflow:scroll; margin-top:60px; margin-left:67px;"></div>
|
||||
<? } ?>
|
||||
<!-- êàðòà -->
|
||||
<div id="map" style="position:relative; width:323px; height:227px; overflow:hidden; margin-top:60px; margin-left:67px;">
|
||||
<? $x = 17; $y = 17;
|
||||
//Ïåðâàÿ çàãðóçêà êàðòû
|
||||
echo '<table id="dataMap" style="position:absolute; width:'.($x*32-32).'px; height:'.($y*32-32).'px; top:0px; left:0px;" border="0" cellspacing="0" cellpadding="0">';
|
||||
$i = 1;
|
||||
while($i<$y)
|
||||
{
|
||||
echo '<tr>';
|
||||
$j = 1;
|
||||
while($j<$x)
|
||||
{
|
||||
$omap .= '<td align="center" valign="middle" id="obj_'.$j.'_'.(17-$i).'" width="32" height="32"></td>';
|
||||
echo '<td align="center" valign="middle" id="map_'.$j.'_'.(17-$i).'" width="32" height="32"></td>';
|
||||
$j++;
|
||||
}
|
||||
echo '</tr>';
|
||||
$i++;
|
||||
}
|
||||
echo '</table>';
|
||||
?>
|
||||
<div style="position:absolute; width:16px; height:16px; top:98px; left:147px;"><img width="16" height="16" src="https://<? echo $c['img']; ?>/dn/users.png" title="Ýòî Âàø ïåðñîíàæ" /></div>
|
||||
</div>
|
||||
<!-- -->
|
||||
</div>
|
||||
<div style="position:absolute; z-index:100; width:457px; height:349px; top:0px; left:0px; background-image: url(https://<? echo $c['img']; ?>/back_dunger_1.png);"></div>
|
||||
<div style="position:absolute; z-index:99; width:457px; height:349px; top:0px; left:0px; background-image: url(https://<? echo $c['img']; ?>/back_ground1.gif);"></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
<script>
|
||||
loadDate();
|
||||
</script>
|
578
adminion/mod/dungeon_bots.php
Normal file
578
adminion/mod/dungeon_bots.php
Normal file
@ -0,0 +1,578 @@
|
||||
<?
|
||||
if(!defined('GAME')){
|
||||
die();
|
||||
}
|
||||
if(isset($_GET['delete_dungeon_id'])){
|
||||
$delete_dungeon_id = intval($_GET['delete_dungeon_id']);
|
||||
mysql_query("DELETE FROM `dungeon_room` WHERE `id`='".$delete_dungeon_id."'");
|
||||
die("<script>window.location = 'index.php?mod=dungeon_list';</script>");
|
||||
}
|
||||
if(isset($_GET['id_bot'])){
|
||||
$_POST['botSelect'] = $_GET['id_bot'];
|
||||
}
|
||||
|
||||
$Query = mysql_query("SELECT id, login FROM test_bot ORDER BY id ASC");
|
||||
$dungeon_bots = '';
|
||||
while($row = mysql_fetch_assoc($Query)){
|
||||
$dungeon_bots .= '<option value="'.$row['id'].'" '.($row['id']==$_POST['botSelect'] ? 'selected' : '').'>'.$row['login'].'</option>';
|
||||
}
|
||||
$Query = mysql_query("SELECT id, dungeon_id, dungeon_name FROM dungeon_room ORDER BY active, dungeon_id ASC");
|
||||
$dungeon_list = '';
|
||||
while($row = mysql_fetch_assoc($Query)){
|
||||
$dungeon_list .= '<option value="'.$row['dungeon_id'].'" '.($row['dungeon_id']==$_POST['dunSelect'] ? 'selected' : '').'>'.$row['dungeon_name'].'</option>';
|
||||
}
|
||||
?><script src="https://<? echo $c['img']; ?>/js/jx/jquery.js" type="text/javascript"></script>
|
||||
<div align="left">
|
||||
<h3 style="text-align:left;">Пещерные жители</h3>
|
||||
</div>
|
||||
<form method="post" action="../../adminion/mod/index.php?mod=dungeon_bots">
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>По пещере:
|
||||
<select name="dunSelect">
|
||||
<option selected value="0">Все</option>
|
||||
<?php echo $dungeon_list; ?>
|
||||
</select>
|
||||
</td>
|
||||
<td>
|
||||
Бот:
|
||||
<select name="botSelect">
|
||||
<option disabled selected value="0">выберите нужного бота...</option>
|
||||
<?php echo $dungeon_bots; ?>
|
||||
</select>
|
||||
</td>
|
||||
<td>
|
||||
<input type="submit" value="выбрать">
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
<?
|
||||
if ( $_POST['botSelect'] != '0' ) {
|
||||
$sBot = mysql_fetch_assoc(mysql_query("SELECT * FROM test_bot WHERE id='".$_POST['botSelect']."' ORDER BY id ASC"));
|
||||
}
|
||||
|
||||
if( isset($sBot) ){
|
||||
?>
|
||||
<script>
|
||||
var CharacterBased = ['minAtack','maxAtack','zona','zonb','s1','s2','s3','s4','hpAll','m1','m2','m3','m4','m5','m6','m7','m8','m9','m10','za','zm','zma','mib1','mab1','mib2','mab2','mib3','mab3','mib4','mab4','pza','pzm'];
|
||||
var CharacterInfo = {
|
||||
'exp' : 'Получаемый опыт (%)',
|
||||
'align_bs' : 'Служитель закона',
|
||||
'nopryh' : 'Прямое поподание',
|
||||
'puti':'Запрет перемещения',
|
||||
'align':'Склонность',
|
||||
'hpAll':'Уровень жизни (HP)',
|
||||
'mpAll':'Уровень маны',
|
||||
'enAll':'Уровень энергии',
|
||||
'sex':'Пол',
|
||||
'lvl':'Уровень',
|
||||
'zona':'Доп зоны атаки',
|
||||
'zonb':'Зон защиты всего',
|
||||
's1':'Сила',
|
||||
's2':'Ловкость',
|
||||
's3':'Интуиция',
|
||||
's4':'Выносливость',
|
||||
's5':'Интеллект',
|
||||
's6':'Мудрость',
|
||||
's7':'Духовность',
|
||||
's8':'Воля',
|
||||
's9':'Свобода духа',
|
||||
's10':'Божественность',
|
||||
's11':'Энергия',
|
||||
'm1':'Мф. критического удара (%)',
|
||||
'm2':'Мф. против критического удара (%)',
|
||||
'm3':'Мф. мощности крит. удара (%)',
|
||||
'm4':'Мф. увертывания (%)',
|
||||
'm5':'Мф. против увертывания (%)',
|
||||
'm6':'Мф. контрудара (%)',
|
||||
'm7':'Мф. парирования (%)',
|
||||
'm8':'Мф. блока щитом (%)',
|
||||
'm9':'Мф. удара сквозь броню (%)',
|
||||
'm10':'Мф. мощности урона',
|
||||
'm11':'Мф. мощности магии стихий',
|
||||
'm11a':'Мф. мощности магии',
|
||||
'm14':'Мф. абс. критического удара (%)',
|
||||
'm15':'Мф. абс. увертывания (%)',
|
||||
'm16':'Мф. абс. парирования (%)',
|
||||
'm17':'Мф. абс. контрудара (%)',
|
||||
'm18':'Мф. абс. блока щитом (%)',
|
||||
'm19':'Мф. абс. магический промах (%)',
|
||||
'm20':'Мф. удача (%)',
|
||||
'a1':'Мастерство владения ножами, кинжалами',
|
||||
'a2':'Мастерство владения топорами, секирами',
|
||||
'a3':'Мастерство владения дубинами, молотами',
|
||||
'a4':'Мастерство владения мечами',
|
||||
'a5':'Мастерство владения магическими посохами',
|
||||
'a6':'Мастерство владения луками',
|
||||
'a7':'Мастерство владения арбалетами',
|
||||
'aall':'Мастерство владения оружием',
|
||||
'mall':'Мастерство владения магией стихий',
|
||||
'm2all':'Мастерство владения магией',
|
||||
'mg1':'Мастерство владения магией огня',
|
||||
'mg2':'Мастерство владения магией воздуха',
|
||||
'mg3':'Мастерство владения магией воды',
|
||||
'mg4':'Мастерство владения магией земли',
|
||||
'mg5':'Мастерство владения магией Света',
|
||||
'mg6':'Мастерство владения магией Тьмы',
|
||||
'mg7':'Мастерство владения серой магией',
|
||||
'mib1':'Броня головы (мин)',
|
||||
'mab1':'Броня головы (макс)',
|
||||
'mib2':'Броня корпуса (мин)',
|
||||
'mab2':'Броня корпуса (макс)',
|
||||
'mib3':'Броня пояса (мин)',
|
||||
'mab3':'Броня пояса (макс)',
|
||||
'mib4':'Броня ног (мин)',
|
||||
'mab4':'Броня ног (макс)',
|
||||
'tj':'Тяжелая броня',
|
||||
'lh':'Легкая броня',
|
||||
'minAtack':'Минимальный урон',
|
||||
'maxAtack':'Максимальный урон',
|
||||
'pa1':'Мф. мощности колющего урона',
|
||||
'pa2':'Мф. мощности рубящего урона',
|
||||
'pa3':'Мф. мощности дробящий урона',
|
||||
'pa4':'Мф. мощности режущий урона',
|
||||
'pm1':'Мф. мощности магии огня',
|
||||
'pm2':'Мф. мощности магии воздуха',
|
||||
'pm3':'Мф. мощности магии воды',
|
||||
'pm4':'Мф. мощности магии земли',
|
||||
'pm5':'Мф. мощности магии Света',
|
||||
'pm6':'Мф. мощности магии Тьмы',
|
||||
'pm7':'Мф. мощности серой магии',
|
||||
'za':'Защита от урона',
|
||||
'zm':'Защита от магии стихий',
|
||||
'zma':'Защита от магии',
|
||||
'za1':'Защита от колющего урона',
|
||||
'za2':'Защита от рубящего урона',
|
||||
'za3':'Защита от дробящего урона',
|
||||
'za4':'Защита от режущего урона',
|
||||
'zm1':'Защита от магии огня',
|
||||
'zm2':'Защита от магии воздуха',
|
||||
'zm3':'Защита от магии воды',
|
||||
'zm4':'Защита от магии земли',
|
||||
'zm5':'Защита от магии Света',
|
||||
'zm6':'Защита от магии Тьмы',
|
||||
'zm7':'Защита от серой магии',
|
||||
'mg2static_points':'Уровень заряда (Воздух)',
|
||||
'magic_cast':'Дополнительный каст за ход',
|
||||
'min_heal_proc':'Эффект лечения (%)',
|
||||
'notravma':'Защита от травм',
|
||||
'zaproc':'Защита от урона (%)',
|
||||
'zmproc':'Защита от магии стихий (%)',
|
||||
'zm2proc':'Защита от магии Воздуха (%)',
|
||||
'pza':'Понижение защиты от урона',
|
||||
'pzm':'Понижение защиты от магии',
|
||||
'pza1':'Понижение защиты от колющего урона',
|
||||
'pza2':'Понижение защиты от рубящего урона',
|
||||
'pza3':'Понижение защиты от дробящего урона',
|
||||
'pza4':'Понижение защиты от режущего урона',
|
||||
'pzm1':'Понижение защиты от магии огня',
|
||||
'pzm2':'Понижение защиты от магии воздуха',
|
||||
'pzm3':'Понижение защиты от магии воды',
|
||||
'pzm4':'Понижение защиты от магии земли',
|
||||
'pzm5':'Понижение защиты от магии Света',
|
||||
'pzm6':'Понижение защиты от магии Тьмы',
|
||||
'pzm7':'Понижение защиты от серой магии',
|
||||
'speedhp':'Регенерация здоровья (%)',
|
||||
'speedmp':'Регенерация маны (%)',
|
||||
'tya1':'Колющие атаки',
|
||||
'tya2':'Рубящие атаки',
|
||||
'tya3':'Дробящие атаки',
|
||||
'tya4':'Режущие атаки',
|
||||
'tym1':'Огненные атаки',
|
||||
'tym2':'Электрические атаки',
|
||||
'tym3':'Ледяные атаки',
|
||||
'tym4':'Земляные атаки',
|
||||
'tym5':'Атаки Света',
|
||||
'tym6':'Атаки Тьмы',
|
||||
'tym7':'Серые атаки',
|
||||
'pog':'Поглощение урона',
|
||||
'pog2':'Поглощение урона',
|
||||
'pog2p':'Процент поглощение урона',
|
||||
'pog2mp':'Цена поглощение урона',
|
||||
'maxves':'Увеличивает рюкзак',
|
||||
'min_use_mp':'Уменьшает расход маны',
|
||||
'bonusexp':'Увеличивает получаемый опыт',
|
||||
'speeden':'Регенерация энергии (%)',
|
||||
'yza' : 'Уязвимость физическому урона (%)',
|
||||
'yzm' : 'Уязвимость магии стихий (%)',
|
||||
'yzma' : 'Уязвимость магии (%)',
|
||||
'yza1' : 'Уязвимость колющему урона (%)',
|
||||
'yza2' : 'Уязвимость рубящему урона (%)',
|
||||
'yza3' : 'Уязвимость дробящему урона (%)',
|
||||
'yza4' : 'Уязвимость режущему урона (%)',
|
||||
'yzm1' : 'Уязвимость магии огня (%)',
|
||||
'yzm2' : 'Уязвимость магии воздуха (%)',
|
||||
'yzm3' : 'Уязвимость магии воды (%)',
|
||||
'yzm4' : 'Уязвимость магии земли (%)',
|
||||
'yzm5' : 'Уязвимость магии (%)',
|
||||
'yzm6' : 'Уязвимость магии (%)',
|
||||
'yzm7' : 'Уязвимость магии (%)',
|
||||
'rep': 'Репутация Рыцаря',
|
||||
'hpProc':'Уровень жизни (%)',
|
||||
'mpProc':'Уровень маны (%)'
|
||||
};
|
||||
function linkGif (th){
|
||||
$('#linkGo').attr('href', 'https://img.new-combats.com/i/obraz/0/'+$('input[name=obraz]').val()).html('Open '+$(th).val()).click();
|
||||
}
|
||||
function linkPng (th){
|
||||
var t = $('input[name=obraz]').val(); t = t.split('.');
|
||||
$('#linkGo').attr('href', 'https://img.new-combats.com/chars/0/'+t[0]+'.png').html('Open '+$(th).val()).click();
|
||||
}
|
||||
</script>
|
||||
<form method="post" action="../../adminion/mod/index.php?mod=dungeon_bots"><hr>
|
||||
<table valign="top" width="100%" border="0" cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td valign="top" >
|
||||
<table width="400px">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>ID: </td>
|
||||
<td><input name="id_bot" value="<?=$sBot['id'];?>" type="text"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Логин: </td>
|
||||
<td><input name="login" value="<?=$sBot['login'];?>" type="text"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Имя: </td>
|
||||
<td><input name="name" value="<?=$sBot['name'];?>" type="text"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Уровень: </td>
|
||||
<td><input name="level" value="<?=$sBot['level'];?>" type="text"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Склонность: </td>
|
||||
<td><select name="align">
|
||||
<option <? if($sBot['align']==0){ echo "selected"; } ?> value="0">Без склонности</option>
|
||||
<option <? if($sBot['align']==1){ echo "selected"; } ?> value="1">Светлый</option>
|
||||
<option <? if($sBot['align']==2){ echo "selected"; } ?> value="2">Хаосник</option>
|
||||
<option <? if($sBot['align']==3){ echo "selected"; } ?> value="3">Темный</option>
|
||||
<option <? if($sBot['align']==7){ echo "selected"; } ?> value="7">Нейтральный</option>
|
||||
<option <? if($sBot['align']==9){ echo "selected"; } ?> value="9">Марочный</option>
|
||||
<option <? if($sBot['align']==10){ echo "selected"; } ?> value="10">Защитник</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Пол: </td>
|
||||
<td><select name="sex"><option <? if($sBot['sex']==0){ echo "selected"; } ?> value="0">Мужской</option><option <? if($sBot['sex']==1){ echo "selected"; } ?> value="1">Женский</option></select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Образ: </td> <!-- Hors.gif -->
|
||||
<td><input name="obraz" value="<?=$sBot['obraz'];?>" type="text"> <input type="button" value="GIF" onclick="linkGif(this)"> <input type="button" value="PNG" onclick="linkPng(this)"> <a style="font-size:11px;" id="linkGo" target="_blank" href="javascript:void();"> </a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Город: </td>
|
||||
<td><input name="city_reg" value="<?=$sBot['city_reg'];?>" type="text"> {thiscity}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Статы: </td>
|
||||
<td><textarea style="min-height:60px;width: 270px;" id="statsLoad" name="stats" type="text"><?=$sBot['stats'];?></textarea></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Используемые предметы: </td>
|
||||
<td><textarea style="min-height:42px;width: 270px;" id="useItemLoad" name="itemsUse" type="text"><?=$sBot['itemsUse'];?></textarea></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Используемые приемы: </td>
|
||||
<td><textarea style="min-height:42px;width: 270px;" name="priemUse" type="text"><?=$sBot['priemUse'];?></textarea></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Дроп: </td>
|
||||
<td><textarea style="min-height:42px;width: 270px;" id="dropLoad" name="p_items" type="text"><?=$sBot['p_items'];?></textarea></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>
|
||||
<input type="hidden" name="botSelect" value="<?=$_POST['botSelect']?>">
|
||||
<input type="hidden" name="dunSelect" value="<?=$_POST['dunSelect']?>">
|
||||
<input type="submit" style="padding: 5px 12px;background: rgb(234, 234, 234);font-size: 14px;" value="Сохранить">
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
<td valign="top" width="55%" align="left">
|
||||
<style>.brown {
|
||||
border-color:#9C8265;
|
||||
color:brown;
|
||||
font-weight:bold;
|
||||
}</style>
|
||||
<input type="button" id="editStat" value="Редактировать характеристик"> <input type="button" id="editDrop" value="Редактировать дроп"> <input type="button" id="editUseItem" value="Обмундирование">
|
||||
<div id="editorStats"></div>
|
||||
<div id="editorDrop"></div>
|
||||
<div id="editorUseItem"></div>
|
||||
|
||||
<script>
|
||||
function loadItemInfo(th){
|
||||
$.post('/adminion/lib/loadItemInfo.php', {item_id:$(th).parent('td').children('.items').val()}, function(data){
|
||||
$(th).html(data);
|
||||
});
|
||||
}
|
||||
|
||||
function loadListItems(th){
|
||||
$.post('/adminion/lib/loadItemInfo.php', {getListItems:true}, function(data){
|
||||
$(th).html(data);
|
||||
});
|
||||
}
|
||||
|
||||
function StatsUp(){
|
||||
var s1 = parseInt($('.stats[name=s1]').val()) * 6;
|
||||
var s2 = parseInt($('.stats[name=s2]').val()) * 6;
|
||||
var s3 = parseInt($('.stats[name=s3]').val()) * 4;
|
||||
var s4 = (parseInt($('.stats[name=s4]').val()) * 6)+30;
|
||||
var s5 = (parseInt($('.stats[name=s5]').val()) * 1);
|
||||
var s6 = (parseInt($('.stats[name=s6]').val()) * 10);
|
||||
var hpAll = parseInt($('.stats[name=hpAll]').val())+s4;
|
||||
var mpAll = parseInt($('.stats[name=mpAll]').val())+s6;
|
||||
|
||||
var maxAtack = parseInt($('.stats[name=maxAtack]').val());
|
||||
var minAtack = parseInt($('.stats[name=minAtack]').val());
|
||||
|
||||
var m1 = parseInt($('.stats[name=m1]').val())+s3;
|
||||
var m2 = parseInt($('.stats[name=m2]').val())+s3;
|
||||
var m3 = parseInt($('.stats[name=m3]').val());
|
||||
var m4 = parseInt($('.stats[name=m4]').val())+s2;
|
||||
var m5 = parseInt($('.stats[name=m5]').val())+s2;
|
||||
var m7 = parseInt($('.stats[name=m7]').val());
|
||||
var m10 = parseInt($('.stats[name=m10]').val());
|
||||
var m11 = parseInt($('.stats[name=m11]').val());
|
||||
var m14 = parseInt($('.stats[name=m14]').val());
|
||||
var m15 = parseInt($('.stats[name=m15]').val());
|
||||
|
||||
var za = parseInt($('.stats[name=s4]').val()) * 1.5;
|
||||
var zm = parseInt($('.stats[name=s4]').val()) * 1.5;
|
||||
var zma = parseInt($('.stats[name=s4]').val()) * 1.5;
|
||||
|
||||
if (s1 >= 100) m10 += 25;
|
||||
else if (s1 >= 75) m10 += 17;
|
||||
else if (s1 >= 50) m10 += 10;
|
||||
else if (s1 >= 25) m10 += 5;
|
||||
if (s1 >= 125) {
|
||||
maxAtack += 10;
|
||||
minAtack += 10;
|
||||
}
|
||||
|
||||
if (s5 >= 125) m11 += 35;
|
||||
else if (s5 >= 100) m11 += 25;
|
||||
else if (s5 >= 75) m11 += 17;
|
||||
else if (s5 >= 50) m11 += 10;
|
||||
else if (s5 >= 25) m11 += 5;
|
||||
|
||||
if (parseInt($('.stats[name=s4]').val()) >= 100) hpAll += 250;
|
||||
else if (parseInt($('.stats[name=s4]').val()) >= 75) hpAll += 175;
|
||||
else if (parseInt($('.stats[name=s4]').val()) >= 50) hpAll += 100;
|
||||
else if (parseInt($('.stats[name=s4]').val()) >= 25) hpAll += 50;
|
||||
|
||||
|
||||
if (parseInt($('.stats[name=s6]').val()) >= 100) mpAll += 250;
|
||||
else if (parseInt($('.stats[name=s6]').val()) >= 75) mpAll += 175;
|
||||
else if (parseInt($('.stats[name=s6]').val()) >= 50) mpAll += 100;
|
||||
else if (parseInt($('.stats[name=s6]').val()) >= 25) mpAll += 50;
|
||||
|
||||
if (parseInt($('.stats[name=s2]').val()) >= 125) {
|
||||
m7 += 15;
|
||||
m4 += 105;
|
||||
m2 += 40;
|
||||
m15 += 5;
|
||||
} else if (parseInt($('.stats[name=s2]').val()) >= 100) {
|
||||
m7 += 15;
|
||||
m4 += 105;
|
||||
m2 += 40;
|
||||
} else if (parseInt($('.stats[name=s2]').val()) >= 75) {
|
||||
m7 += 15;
|
||||
m4 += 35;
|
||||
m2 += 15;
|
||||
} else if (parseInt($('.stats[name=s2]').val()) >= 50) {
|
||||
m7 += 5;
|
||||
m4 += 35;
|
||||
m2 += 15;
|
||||
} else if (parseInt($('.stats[name=s2]').val()) >= 25) {
|
||||
m7 += 5;
|
||||
}
|
||||
|
||||
if (parseInt($('.stats[name=s3]').val()) >= 125) {
|
||||
m3 += 25;
|
||||
m1 += 105;
|
||||
m5 += 45;
|
||||
m14 += 5;
|
||||
} else if (parseInt($('.stats[name=s3]').val()) >= 100) {
|
||||
m3 += 25;
|
||||
m1 += 105;
|
||||
m5 += 45;
|
||||
} else if (parseInt($('.stats[name=s3]').val()) >= 75) {
|
||||
m3 += 25;
|
||||
m1 += 35;
|
||||
m5 += 15;
|
||||
} else if (parseInt($('.stats[name=s3]').val()) >= 50) {
|
||||
m3 += 10;
|
||||
m1 += 35;
|
||||
m5 += 15;
|
||||
} else if (parseInt($('.stats[name=s3]').val()) >= 25) {
|
||||
m3 +=10;
|
||||
}
|
||||
|
||||
if (parseInt($('.stats[name=s4]').val()) >= 125) za += 25;
|
||||
|
||||
$('.stats[name=minAtack]').val(minAtack);
|
||||
$('.stats[name=maxAtack]').val(maxAtack);
|
||||
$('.stats[name=m1]').val(m1);
|
||||
$('.stats[name=m2]').val(m2);
|
||||
$('.stats[name=m3]').val(m3);
|
||||
$('.stats[name=m4]').val(m4);
|
||||
$('.stats[name=m5]').val(m5);
|
||||
$('.stats[name=m7]').val(m7);
|
||||
$('.stats[name=m10]').val(m10);
|
||||
$('.stats[name=hpAll]').val(hpAll);
|
||||
$('.stats[name=mpAll]').val(mpAll);
|
||||
}
|
||||
function StatsDown(){
|
||||
|
||||
}
|
||||
// Характеристики
|
||||
$('#add_save').live('click', function(){
|
||||
StatsDown();
|
||||
result = '';
|
||||
$('#editorStats #listInputs .stats').each(function(){
|
||||
if (result != '') result +='|';
|
||||
result += $(this).attr('name')+'='+$(this).val()+'';
|
||||
});
|
||||
$('#statsLoad').val(result);
|
||||
$('#editorStats').html('');
|
||||
});
|
||||
$('#add_attr').live('click', function(){
|
||||
$('#listInputs .need').append('<tr><td><span style="font-size:11px;" class="'+$('#add_list').val() +'">'+ CharacterInfo[$('#add_list').val()] +':</span></td><td> <input class="stats" value="0" type="text" name="'+ $('#add_list').val() +'"/><input type="button" name="'+$('#add_list').val() +'" class="delete" value="X"><br/></td></tr>');
|
||||
});
|
||||
|
||||
$('#listInputs .delete').live('click', function() {
|
||||
$(this).parent().parent().remove();
|
||||
});
|
||||
|
||||
$('#editStat').live('click', function() {
|
||||
if ($('#editorStats').html() != '') {
|
||||
$('#editorStats').html('');
|
||||
} else {
|
||||
var text = '';
|
||||
$.each(CharacterBased, function( n, row ){
|
||||
if (row=='zonb') {
|
||||
text += '<tr><td><span style="font-size:11px;" class="'+row+'">'+CharacterInfo[row] + ':</span></td><td> <select class="stats brown" name="'+row+'"><option value="1">3</option><option value="0">2</option><option value="-1">1</option></select> <input type="button" name="'+row+'" class="delete" value="X"><br/></td></tr>';
|
||||
} else {
|
||||
text += '<tr><td><span style="font-size:11px;" class="'+row+'">'+CharacterInfo[row] + ':</span></td><td> <input class="stats brown" value="1" type="text" name="'+row+'"><input type="button" name="'+row+'" class="delete" value="X"><br/></td></tr>';
|
||||
}
|
||||
});
|
||||
var add_list = '';
|
||||
$.each(CharacterInfo, function( k , v ){
|
||||
add_list += '<option value="'+k+'">'+v+'</option>';
|
||||
});
|
||||
$('#editorStats').html(' <div id="listInputs" ><table class="need" width="400px" valign="top" align="left" border="0" cellspacing="0" cellpadding="0"> '+text + ' </table><table><tr><td colspan="2"><hr></td></tr><tr><td><input type="button" value="Добавить" name="add" id="add_attr"></td><td> <select id="add_list">'+add_list+'</select> <br/> </td></tr><tr><td colspan="2"><hr></td></tr><tr><td colspan="2"><input type="button" value="Внести изменения" style="color:brown;" name="add" id="add_save"></td></tr></table></div> ');
|
||||
text='';
|
||||
stats = $('#statsLoad').val();
|
||||
stats = stats.split('|');
|
||||
stats.sort();
|
||||
$.each(stats, function( n, row ){
|
||||
row = row.split('=');
|
||||
|
||||
if ( $('input[name='+row[0]+'].stats').val() > 0 || row[0]=='zonb'){
|
||||
|
||||
|
||||
if (row[0]=='zonb') {
|
||||
$('select[name='+row[0]+'].stats').val(row[1]);
|
||||
$('select[name='+row[0]+'].stats').removeClass('brown');
|
||||
} else {
|
||||
$('input[name='+row[0]+'].stats').val(row[1]);
|
||||
$('input[name='+row[0]+'].stats').removeClass('brown');
|
||||
}
|
||||
} else {
|
||||
text += '<tr><td><span style="font-size:11px;" class="'+row[0]+'">'+CharacterInfo[row[0]] + ':</span></td><td> <input class="stats" value="' + row[1] + '" type="text" name="'+row[0]+'"><input type="button" name="'+row[0]+'" class="delete" value="X"><br/></td></tr>';
|
||||
}
|
||||
});
|
||||
$('#listInputs .need').append(text);
|
||||
StatsUp();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
// Дроп предметов
|
||||
$('#add_saveDrop').live('click', function(){
|
||||
result = '';
|
||||
$('#editorDrop #listInputs td').each(function() {
|
||||
if (result != '') result +='|';
|
||||
result += $(this).children('input[name=itemsId]').val()+'='+$(this).children('input[name=itemsPerc]').val()+'';
|
||||
if ($(this).children('input[name=itemsQuest]').val()) result += '='+$(this).children('input[name=itemsQuest]').val()+'';
|
||||
});
|
||||
$('#dropLoad').val(result);
|
||||
$('#editorDrop').html('');
|
||||
});
|
||||
|
||||
$('#editDrop').live('click', function() {
|
||||
if ($('#editorDrop').html() != '') {
|
||||
$('#editorDrop').html('');
|
||||
} else {
|
||||
var text = '';
|
||||
drop = $('#dropLoad').val();
|
||||
drop = drop.split('|');
|
||||
drop.sort();
|
||||
$.each(drop, function( n, row ){
|
||||
row = row.split('='); //
|
||||
if (row[1] == undefined) row[1] = '';
|
||||
if (row[2] == undefined) row[2] = '';
|
||||
if (row[0] !='') {
|
||||
text += '<tr><td><input class="items" value="' + row[0] + '" type="text" name="itemsId" size="7"> <input size="5" class="itemsPerc" value="' + row[1] + '" type="text" name="itemsPerc"><input class="itemsQuest" size="14" value="' + row[2] + '" type="text" name="itemsQuest"><input type="button" name="delete" class="delete" value="X"> <a target="_blank" href="javascript:void(0);" id="'+ row[0] +'" onclick="loadItemInfo(this);">[load]</a> <br/></td></tr>';
|
||||
}
|
||||
});
|
||||
$('#editorDrop').html(' <div id="listInputs" ><table class="need" width="100%" valign="top" align="left" border="0" cellspacing="0" cellpadding="0"> '+text + ' </table><br/><hr/><input type="button" value="Внести изменения" style="color:brown;" name="add" id="add_saveDrop"> </div> ');
|
||||
}
|
||||
});
|
||||
|
||||
// Обмундирование
|
||||
$('#add_saveUseItem').live('click', function(){
|
||||
result = '';
|
||||
$('#editorUseItem #listInputs td').each(function() {
|
||||
if (result != '') result +=',';
|
||||
result += $(this).children('input[name=itemsId]').val();
|
||||
});
|
||||
$('#useItemLoad').val(result);
|
||||
$('#editorUseItem').html('');
|
||||
});
|
||||
|
||||
$('#add_useitem').live('click', function(){
|
||||
$('#editorUseItem #listInputs .need').append('<tr><td><input class="items useItem" value="0" type="text" name="itemsId" size="7"> <input type="button" name="delete" class="delete" value="X"> <br/></td></tr>');
|
||||
});
|
||||
|
||||
$('#editUseItem').live('click', function() {
|
||||
if ($('#editorUseItem').html() != '') {
|
||||
$('#editorUseItem').html('');
|
||||
} else {
|
||||
var text = '';
|
||||
useItem = $('#useItemLoad').val();
|
||||
useItem = useItem.split(',');
|
||||
useItem.sort();
|
||||
$.each(useItem, function( n, row ){
|
||||
text += '<tr><td><input class="items useItem" value="' + row + '" type="text" name="itemsId" size="7"> <input type="button" name="delete" class="delete" value="X"> <a href="javascript:void(0);" id="'+ row +'" onclick="loadItemInfo(this);">[load]</a> or <a target="_blank" href="https://lib.new-combats.com/items_info.php?id='+ row +'" id="'+ row +'">[lib]</a> <br/></td></tr>';
|
||||
});
|
||||
$('#editorUseItem').html(' <div id="listInputs" ><table class="need" width="100%" valign="top" align="left" border="0" cellspacing="0" cellpadding="0"> '+text + ' </table><hr><input type="button" value="Добавить еще предмет" name="add" id="add_useitem"> <br/><hr/><input type="button" value="Внести изменения" style="color:brown;" name="add" id="add_saveUseItem"> </div> ');
|
||||
}
|
||||
});
|
||||
|
||||
$(document).ready(function(){
|
||||
});
|
||||
</script>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">
|
||||
</td>
|
||||
<td align="right">
|
||||
<div id="testS"></div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</form>
|
||||
<?
|
||||
}
|
||||
?>
|
92
adminion/mod/dungeon_edit.php
Normal file
92
adminion/mod/dungeon_edit.php
Normal file
@ -0,0 +1,92 @@
|
||||
<?
|
||||
if(!defined('GAME')){
|
||||
die();
|
||||
}
|
||||
|
||||
die('Îøèáêà, ñìîòðè ôàéë');
|
||||
|
||||
$dungeon_id = isset($_GET['dungeon_id']) ? intval($_GET['dungeon_id']) : '';
|
||||
|
||||
$dungeon_params = mysql_fetch_assoc(mysql_query("SELECT * FROM `dungeon_room` WHERE `id`='".$dungeon_id."'"));
|
||||
if($_POST['id']){
|
||||
$mysql_query = '';
|
||||
if($dungeon_id){
|
||||
$mysql_query .= "UPDATE `dungeon_room` SET ";
|
||||
$mysql_query .= "`id`='".$_POST['id']."',";
|
||||
$mysql_query .= "`dungeon_id`='".$_POST['dungeon_id']."',";
|
||||
$mysql_query .= "`dungeon_name`='".$_POST['dungeon_name']."' ";
|
||||
$mysql_query .= "`dungeon_room`='".$_POST['dungeon_room']."' ";
|
||||
$mysql_query .= "`dungeon_tag`='".$_POST['dungeon_tag']."' ";
|
||||
$mysql_query .= "`city`='".$_POST['city']."' ";
|
||||
$mysql_query .= "`shop`='".$_POST['shop']."' ";
|
||||
$mysql_query .= "`roomLeave`='".$_POST['roomLeave']."' ";
|
||||
$mysql_query .= "`active`='".$_POST['active']."' ";
|
||||
$mysql_query .= "`quest`='".$_POST['quest']."' ";
|
||||
$mysql_query .= "WHERE `id`='".$dungeon_id."'";
|
||||
}else{
|
||||
$mysql_query .= "INSERT INTO `dungeon_room` ";
|
||||
$mysql_query .= "(`id`,`dungeon_id`,`dungeon_name`,`dungeon_room`,`dungeon_tag`,`shop`,`roomLeave`,`active`,`quest`,`city`)";
|
||||
$mysql_query .= " VALUES ";
|
||||
$mysql_query .= "('".$_POST['id']."','".$_POST['dungeon_id']."','".$_POST['dungeon_name']."','".$_POST['dungeon_room']."','".$_POST['dungeon_tag']."','".$_POST['shop']."','".$_POST['roomLeave']."','".$_POST['active']."','".$_POST['quest']."','".$_POST['city']."');";
|
||||
}
|
||||
mysql_query($mysql_query);
|
||||
die("<script>window.location = 'index.php?mod=dungeon_list';</script>");
|
||||
}
|
||||
?><script src="https://<? echo $c['img']; ?>/js/jx/jquery.js" type="text/javascript"></script>
|
||||
<div align="left">
|
||||
<h3 style="text-align:left;"><?php echo $dungeon_params['id'] ? 'Èçìåíèòü' : 'Äîáàâèòü'; ?> ïåùåðó</h3>
|
||||
</div>
|
||||
<form method="post" action="">
|
||||
<table border="0" cellpadding="0" cellspacing="1">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><font color="red">*</font>ID ïîäçåìåëüÿ: </td>
|
||||
<td><input name="dungeon_id" type="text" value="<?php echo $dungeon_params['dungeon_id']; ?>" size="5" maxlength="255"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><font color="red">*</font>Íàçâàíèå ïåùåðû: </td>
|
||||
<td><input name="dungeon_name" type="text" value="<?php echo $dungeon_params['dungeon_name']; ?>" size="30" maxlength="255"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><font color="red">*</font>Ãîðîä: </td>
|
||||
<td><input name="city" type="text" value="<?php echo $dungeon_params['city']; ?>" size="30" maxlength="255"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><font color="red">*</font>Òýã: </td>
|
||||
<td><input name="dungeon_tag" type="text" value="<?php echo $dungeon_params['dungeon_tag']; ?>" size="30" maxlength="255"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><font color="red">*</font>ID ëîêàöèè (âõîä â ïîäçåìåëüå): </td>
|
||||
<? if($dungeon_params['id'] != 0) $room = mysql_fetch_assoc(mysql_query("SELECT id,name FROM `room` WHERE `id`='".$dungeon_params['id']."'")); else $room['name']=''; ?>
|
||||
<td><input name="id" type="text" value="<?php echo $dungeon_params['id']; ?>" size="5" maxlength="255"><i style="font-size:11px;color: brown;"> <?=$room['name']?></i></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><font color="red">*</font>ID ëîêàöèè (ïîäçåìåëüå): </td>
|
||||
<? if($dungeon_params['dungeon_room'] != 0) $room = mysql_fetch_assoc(mysql_query("SELECT id,name FROM `room` WHERE `id`='".$dungeon_params['dungeon_room']."'")); else $room['name']=''; ?>
|
||||
<td><input name="dungeon_room" type="text" value="<?php echo $dungeon_params['dungeon_room']; ?>" size="5" maxlength="255"><i style="font-size:11px;color: brown;"> <?=$room['name']?></i></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>ID Ðûöàðñêîãî ìàãàçèíà: </td>
|
||||
<? if($dungeon_params['shop'] != 0) $room = mysql_fetch_assoc(mysql_query("SELECT id,name FROM `room` WHERE `id`='".$dungeon_params['shop']."'")); else $room['name']=''; ?>
|
||||
<td><input name="shop" type="text" value="<?php echo $dungeon_params['shop']; ?>" size="5" maxlength="255"><i style="font-size:11px;color: brown;"> <?=$room['name']?></i></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>ID êîìíàòû äëÿ âûõîäà: </td>
|
||||
<? if($dungeon_params['roomLeave'] != 0) $room = mysql_fetch_assoc(mysql_query("SELECT id,name FROM `room` WHERE `id`='".$dungeon_params['roomLeave']."'")); else $room['name']=''; ?>
|
||||
<td><input name="roomLeave" type="text" value="<?php echo $dungeon_params['roomLeave']; ?>" size="5" maxlength="255"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Àêòèâíà: </td>
|
||||
<td><select name="active"><option <? if($dungeon_params['active']=='1') echo' selected="selected" '; ?>value="1">Äà</option><option <? if($dungeon_params['active']!='1') echo' selected="selected" ';?>value="0">Íåò</option></select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Âêëþ÷åíû êâåñòû: </td>
|
||||
<td><select name="quest"><option <? if($dungeon_params['quest']=='1') echo' selected="selected" '; ?>value="1">Äà</option><option <? if($dungeon_params['quest']!='1') echo' selected="selected" ';?>value="0">Íåò</option></select></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p></p>
|
||||
<input name="submit" type="submit" value="Ñîõðàíèòü" style="width: 150px"/>
|
||||
<input name="cancel" type="submit" onclick="document.location='index.php?mod=dungeon_list'; return false;" value="Îòìåíà" />
|
||||
<p><font color="red">*</font> - Îáÿçàòåëüíûå ïîëÿ </p>
|
||||
</form>
|
10
adminion/mod/dungeon_editor.php
Normal file
10
adminion/mod/dungeon_editor.php
Normal file
@ -0,0 +1,10 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="https://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251" />
|
||||
<title>Äîêóìåíò áåç íàçâàíèÿ</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
48
adminion/mod/dungeon_list.php
Normal file
48
adminion/mod/dungeon_list.php
Normal file
@ -0,0 +1,48 @@
|
||||
<?
|
||||
if(!defined('GAME')){
|
||||
die();
|
||||
}
|
||||
if(isset($_GET['delete_dungeon_id'])){
|
||||
$delete_dungeon_id = intval($_GET['delete_dungeon_id']);
|
||||
mysql_query("DELETE FROM `dungeon_room` WHERE `id`='".$delete_dungeon_id."'");
|
||||
die("<script>window.location = 'index.php?mod=dungeon_list';</script>");
|
||||
}
|
||||
|
||||
|
||||
$Query = mysql_query("SELECT * FROM dungeon_room ORDER BY active, dungeon_id ASC");
|
||||
$dungeon_list = '';
|
||||
while($row = mysql_fetch_assoc($Query)){
|
||||
$dungeon_list .= '<tr>
|
||||
<td align="center">' . $row['dungeon_id'] . '</td>
|
||||
<td><a href="?mod=dungeon_edit&dungeon_id=' . $row['id'] . '">' . $row['dungeon_name'] . '</a></td>
|
||||
<td align="center">' . $row['id'] . '</td>
|
||||
<td align="center">' . ( $row['dungeon_room'] == 0 ? '' : $row['dungeon_room']) . '</td>
|
||||
<td align="center">' . ( $row['shop'] == 0 ? '' : $row['shop']) . '</td>
|
||||
<td>' . ( $row['active'] == 1 ? '<span style="color:green">Âêë</span>' : '<span style="color:brown">Âûêë</span>') . '</td>
|
||||
<td>' . ( $row['quest'] == 1 ? '<span style="color:green">Âêë</span>' : '<span style="color:brown">Âûêë</span>'). '</td>
|
||||
<td><a href="?mod=dungeon_list&delete_dungeon_id=' . $row['id'] . '">Óäàëèòü</a></td>
|
||||
<td><a href="?mod=dungeon_edit&dungeon_id=' . $row['id'] . '">Èçìåíèòü</a></td>
|
||||
<td><a target="_blank" href="?mod=dungeon&r=' . $row['dungeon_id'] . '">Êàðòà</a></td>
|
||||
</tr>';
|
||||
}
|
||||
?><script src="https://<? echo $c['img']; ?>/js/jx/jquery.js" type="text/javascript"></script>
|
||||
<div align="left">
|
||||
<h3 style="text-align:left;">Ñïèñîê ïåùåð</h3>
|
||||
</div>
|
||||
<div style="margin-left:8px; margin-bottom:15px"> Ïåùåðû:
|
||||
<table class="tblbr2" border="1" cellspacing="0" cellpadding="5" bordercolor="#C1E1EE">
|
||||
<tr>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Ïåùåðà</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Íàçâàíèå ïåùåðû</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Êîìíàòà<br/>âõîäà</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Ëîêàöèÿ<br/>ïåùåðû</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Ðûöàðñêèé<br/>Ìàãàçèí</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Äîñòóï</strong></div></td>
|
||||
<td bgcolor="#C0C2C0"><div align="center"><strong>Êâåñòû</strong></div></td>
|
||||
|
||||
<td bgcolor="#C0C2C0" colspan="3"><div align="center">Âîçìîæíîñòè</div></td>
|
||||
</tr>
|
||||
<?php echo $dungeon_list; ?>
|
||||
</table>
|
||||
</div>
|
||||
<a href="../../adminion/mod/?mod=dungeon_edit" title="Äîáàâèòü ïåùåðó">Äîáàâèòü ïåùåðó</a>
|
15
api/learning.php
Normal file
15
api/learning.php
Normal file
@ -0,0 +1,15 @@
|
||||
<?php
|
||||
require_once $_SERVER['DOCUMENT_ROOT'] . '/_incl_data/__config.php';
|
||||
$learning = new Learming();
|
||||
//set getLearningStatus to 0 and save
|
||||
if ($_POST['hasLearned'] && $learning->hasLearned()) {
|
||||
echo 'OK';
|
||||
}
|
||||
if ($_POST['getStatus']) {
|
||||
// boolean
|
||||
switch ($learning->getLearningStatus()) {
|
||||
case 0: echo 'should not learn'; break;
|
||||
case 1: echo 'should learn'; break;
|
||||
default: echo 'error: no data'; break;
|
||||
}
|
||||
}
|
BIN
audio/audio_1614275725.mp3
Normal file
BIN
audio/audio_1614275725.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614521605.mp3
Normal file
BIN
audio/audio_1614521605.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614521686.mp3
Normal file
BIN
audio/audio_1614521686.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614523608.mp3
Normal file
BIN
audio/audio_1614523608.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614523867.mp3
Normal file
BIN
audio/audio_1614523867.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614535309.mp3
Normal file
BIN
audio/audio_1614535309.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614797553.mp3
Normal file
BIN
audio/audio_1614797553.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614797685.mp3
Normal file
BIN
audio/audio_1614797685.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614797971.mp3
Normal file
BIN
audio/audio_1614797971.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798061.mp3
Normal file
BIN
audio/audio_1614798061.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798280.mp3
Normal file
BIN
audio/audio_1614798280.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798410.mp3
Normal file
BIN
audio/audio_1614798410.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798412.mp3
Normal file
BIN
audio/audio_1614798412.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798601.mp3
Normal file
BIN
audio/audio_1614798601.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614798634.mp3
Normal file
BIN
audio/audio_1614798634.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614804548.mp3
Normal file
BIN
audio/audio_1614804548.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614804700.mp3
Normal file
BIN
audio/audio_1614804700.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1614805144.mp3
Normal file
BIN
audio/audio_1614805144.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1615219479.mp3
Normal file
BIN
audio/audio_1615219479.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1615588602.mp3
Normal file
BIN
audio/audio_1615588602.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1615588722.mp3
Normal file
BIN
audio/audio_1615588722.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1615620136.mp3
Normal file
BIN
audio/audio_1615620136.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1615630084.mp3
Normal file
BIN
audio/audio_1615630084.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616007843.mp3
Normal file
BIN
audio/audio_1616007843.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616135596.mp3
Normal file
BIN
audio/audio_1616135596.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616339920.mp3
Normal file
BIN
audio/audio_1616339920.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616342879.mp3
Normal file
BIN
audio/audio_1616342879.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616342919.mp3
Normal file
BIN
audio/audio_1616342919.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616359132.mp3
Normal file
BIN
audio/audio_1616359132.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1616676799.mp3
Normal file
BIN
audio/audio_1616676799.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1618124331.mp3
Normal file
BIN
audio/audio_1618124331.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1618592693.mp3
Normal file
BIN
audio/audio_1618592693.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1618609789.mp3
Normal file
BIN
audio/audio_1618609789.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1618646143.mp3
Normal file
BIN
audio/audio_1618646143.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1618646159.mp3
Normal file
BIN
audio/audio_1618646159.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1620849304.mp3
Normal file
BIN
audio/audio_1620849304.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1621065306.mp3
Normal file
BIN
audio/audio_1621065306.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1621065405.mp3
Normal file
BIN
audio/audio_1621065405.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1621065617.mp3
Normal file
BIN
audio/audio_1621065617.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1621618986.mp3
Normal file
BIN
audio/audio_1621618986.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1622585511.mp3
Normal file
BIN
audio/audio_1622585511.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1623098728.mp3
Normal file
BIN
audio/audio_1623098728.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1624223931.mp3
Normal file
BIN
audio/audio_1624223931.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1624226471.mp3
Normal file
BIN
audio/audio_1624226471.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1624561881.mp3
Normal file
BIN
audio/audio_1624561881.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1624738907.mp3
Normal file
BIN
audio/audio_1624738907.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1624739278.mp3
Normal file
BIN
audio/audio_1624739278.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1626435272.mp3
Normal file
BIN
audio/audio_1626435272.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1628161914.mp3
Normal file
BIN
audio/audio_1628161914.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1634228921.mp3
Normal file
BIN
audio/audio_1634228921.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1635181242.mp3
Normal file
BIN
audio/audio_1635181242.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656338463.mp3
Normal file
BIN
audio/audio_1656338463.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656338530.mp3
Normal file
BIN
audio/audio_1656338530.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656338605.mp3
Normal file
BIN
audio/audio_1656338605.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656357658.mp3
Normal file
BIN
audio/audio_1656357658.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656444267.mp3
Normal file
BIN
audio/audio_1656444267.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656514170.mp3
Normal file
BIN
audio/audio_1656514170.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656521179.mp3
Normal file
BIN
audio/audio_1656521179.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656537767.mp3
Normal file
BIN
audio/audio_1656537767.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656620496.mp3
Normal file
BIN
audio/audio_1656620496.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1656853059.mp3
Normal file
BIN
audio/audio_1656853059.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1657817718.mp3
Normal file
BIN
audio/audio_1657817718.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1657818100.mp3
Normal file
BIN
audio/audio_1657818100.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1657820701.mp3
Normal file
BIN
audio/audio_1657820701.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1657957570.mp3
Normal file
BIN
audio/audio_1657957570.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1660569694.mp3
Normal file
BIN
audio/audio_1660569694.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1663086497.mp3
Normal file
BIN
audio/audio_1663086497.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1663087031.mp3
Normal file
BIN
audio/audio_1663087031.mp3
Normal file
Binary file not shown.
BIN
audio/audio_1668262809.mp3
Normal file
BIN
audio/audio_1668262809.mp3
Normal file
Binary file not shown.
106
autopay.php
Normal file
106
autopay.php
Normal file
@ -0,0 +1,106 @@
|
||||
|
||||
<?php
|
||||
date_default_timezone_set('Europe/Moscow');
|
||||
$c = array(
|
||||
/* MySQL Áàçà äàííûõ */
|
||||
'db_name' => 'pay_operations', //Òàáëèöà â êîòîðóþ çàíîñÿòñÿ äàííûå
|
||||
'db_host' => 'localhost',
|
||||
'db_user' => 'newcom1_abk',
|
||||
'db_pass' => '4nWYsIM[c?}P',
|
||||
'db_base' => 'newcom1_abk',
|
||||
/* Íàñòðîéêè ïëàòåæåé
|
||||
'ip_list' => array('127,0,0,1,188.166.34.68,136.243.38.147,136.243.38.149,136.243.38.150,136.243.38.151,136.243.38.189,88.198.88.98'), //Óêàçûâàòü ÷åðåç çàïÿòóþ (Ðàçðåøåííûå IP)
|
||||
'key' => 'qtzl0igb', //gamedealer key
|
||||
'id' => '65643' //ID ïðîåêòà*/
|
||||
);
|
||||
|
||||
|
||||
function connect_db($c) {
|
||||
$db = mysql_connect($c['db_host'],$c['db_user'],$c['db_pass']) or die('Îøèáêà ïîäêëþ÷åíèÿ ê MySQL ñåðâåðó!');
|
||||
mysql_select_db($c['db_base'],$db) or die('Îøèáêà ïîäêëþ÷åíèÿ ê áàçå äàííûõ!');
|
||||
mysql_query('SET NAMES cp1251');
|
||||
}
|
||||
|
||||
//MERCHANT_ORDER_ID=142&P_PHONE=380688028300&P_EMAIL=evhenii_kula%40mail.ru&CUR_ID=94&AMOUNT=90&MERCHANT_ID=65643&SIGN=c0fc70d5446614597d44ff13f2c7a6a5&intid=29728441
|
||||
/*
|
||||
MERCHANT_ORDER_ID
|
||||
P_PHONE
|
||||
P_EMAIL
|
||||
CUR_ID
|
||||
AMOUNT
|
||||
MERCHANT_ID
|
||||
SIGN
|
||||
intid
|
||||
*/
|
||||
|
||||
connect_db($c);
|
||||
$nick = mysql_fetch_array(mysql_query('SELECT * FROM `pay_operation` WHERE `id` = "'.$_POST['MERCHANT_ORDER_ID'].'" LIMIT 1'));
|
||||
$user = mysql_fetch_array(mysql_query('SELECT * FROM `users` WHERE `id` = "'.$nick['uid'].'" LIMIT 1'));
|
||||
if (isset ($_POST['MERCHANT_ORDER_ID']))
|
||||
{
|
||||
if ($nick['good']!=0)
|
||||
{
|
||||
echo "Óæå íà÷èñëåííî";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
mysql_query('UPDATE `users` SET `money2` = `money2` + '.$nick['ekr'].' WHERE `id` = "'.$nick['uid'].'" LIMIT 1');
|
||||
mysql_query('UPDATE `pay_operation` SET `good` = "'.time().'" WHERE `id` = "'.$_POST['MERCHANT_ORDER_ID'].'" LIMIT 1');
|
||||
mysql_query('UPDATE `users` SET `catch` = `catch` + '.$nick['ekr'].' WHERE `id` = "'.$nick['uid'].'" LIMIT 1');
|
||||
|
||||
//mysql_query('INSERT INTO `'.$c['db_name'].'` (`time`,`type`,`ip`,`value`,`money`,`project`) VALUES ("'.time().'","'.mysql_real_escape_string($type).'","'.$_SERVER['HTTP_X_REAL_IP'].'","'.mysql_real_escape_string($value).'","'.mysql_real_escape_string($money).'","'.mysql_real_escape_string($this->id).'")');
|
||||
|
||||
$r = '<span class=date>'.date('d.m.Y H:i').'</span> Àëõèìèê <img src=https://img.new-combats.com/i/align/align50.gif width=12 height=15 /><u><b>Àäìèíèñòðàòîð</b> / Àâòîìàòè÷åñêàÿ îïëàòà</u> ñîîáùàåò: ';
|
||||
if($user['sex'] == 1)
|
||||
{
|
||||
$r .= 'Óâàæàåìàÿ';
|
||||
}
|
||||
else
|
||||
{
|
||||
$r .= 'Óâàæàåìûé';
|
||||
}
|
||||
$r .= ' <b>'.$user['login'].'</b>, íà Âàø èãðîâîé ñ÷åò çà÷èñëåíî '.$nick['ekr'].' Åâðîêðåäèòîâ. Áëàãîäàðèì Âàñ çà ïîêóïêó!';
|
||||
//$str1 = iconv("cp1251","UTF-8",$r);
|
||||
mysql_query("INSERT INTO `chat` (`new`,`city`,`room`,`login`,`to`,`text`,`time`,`type`,`toChat`) VALUES ('1','".$user['city']."','".$user['room']."','','".$user['login']."','".$r."','-1','5','0')");
|
||||
//echo $r."r<br>";
|
||||
|
||||
|
||||
if ($nick['ref'] !=0)
|
||||
{
|
||||
$refecr=round(($nick['ekr']/10));
|
||||
mysql_query('UPDATE `users` SET `money2` = `money2` + '.$refecr.' WHERE `id` = "'.$nick['ref'].'" LIMIT 1');
|
||||
$referal = mysql_fetch_array(mysql_query('SELECT * FROM `users` WHERE `id` = "'.$nick['ref'].'" LIMIT 1'));
|
||||
$r = '<span class=date>'.date('d.m.Y H:i').'</span> Àëõèìèê <img src=https://img.new-combats.com/i/align/align50.gif width=12 height=15 /><u><b>Àäìèíèñòðàòîð</b> / Ðåôåðàëüíûé çàðàáîòîê</u> ñîîáùàåò: ';
|
||||
if($referal['sex'] == 1)
|
||||
{
|
||||
$r .= 'Óâàæàåìàÿ';
|
||||
}
|
||||
else
|
||||
{
|
||||
$r .= 'Óâàæàåìûé';
|
||||
}
|
||||
$r .= ' <b>'.$referal['login'].'</b>, íà Âàø èãðîâîé ñ÷åò çà÷èñëåíî '.$refecr.' Åâðîêðåäèòîâ. Áëàãîäîðÿ âàøåìó ðåôåðàëó!'.$user['login'].'';
|
||||
//$str1 = iconv("cp1251","UTF-8",$r);
|
||||
mysql_query("INSERT INTO `chat` (`new`,`city`,`room`,`login`,`to`,`text`,`time`,`type`,`toChat`) VALUES ('1','".$referal['city']."','".$referal['room']."','','".$referal['login']."','".$r."','-1','5','0')");
|
||||
|
||||
|
||||
}
|
||||
|
||||
echo "Ïîêóïàòåë: ".$user['login']." | ID: ".$nick['uid']." | Ñóììà: ".$nick['ekr']." | ID îïåðàöèè: ".$_POST['MERCHANT_ORDER_ID']."<br>";
|
||||
if (isset ($referal['id']))
|
||||
{
|
||||
echo "Ðåôåðàë(òîò êòî ïðèâåë): ".$referal['login']." | ID: ".$referal['id']." | Ñóììà: ".$refecr."<br>";
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "Ïîëüçîâàòåëü ðåôåðàë íå íàéäåí!!";
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "Ïîêóïàòåëü íå óêàçàí!";
|
||||
}
|
||||
?>
|
11786
bak/Battle.php
Normal file
11786
bak/Battle.php
Normal file
File diff suppressed because it is too large
Load Diff
BIN
bot_q/mini_wm1.png
Normal file
BIN
bot_q/mini_wm1.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.5 KiB |
BIN
bot_q/wm1.jpg
Normal file
BIN
bot_q/wm1.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 67 KiB |
5
casino/SWFP.php
Normal file
5
casino/SWFP.php
Normal file
@ -0,0 +1,5 @@
|
||||
<?
|
||||
$r = '&SWFM=blackjack_v1.09&';
|
||||
|
||||
echo $r;
|
||||
?>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user