diff --git a/README.md b/README.md index 39af52c..7e2f93b 100644 --- a/README.md +++ b/README.md @@ -1,29 +1,10 @@ # README # -This README would normally document whatever steps are necessary to get your application up and running. +Проект БК1\БК2 времён до появления приёмов. +Версионности не будет, пока проект не станет стабильным на PHP5.6. ### What is this repository for? ### * Quick summary * Version -* [Learn Markdown](https://bitbucket.org/tutorials/markdowndemo) - -### How do I get set up? ### - -* Summary of set up -* Configuration -* Dependencies -* Database configuration -* How to run tests -* Deployment instructions - -### Contribution guidelines ### - -* Writing tests -* Code review -* Other guidelines - -### Who do I talk to? ### - -* Repo owner or admin -* Other community or team contact \ No newline at end of file +* [Learn Markdown](https://bitbucket.org/tutorials/markdowndemo) \ No newline at end of file diff --git a/js/h.js b/_unused-files/h.js similarity index 100% rename from js/h.js rename to _unused-files/h.js diff --git a/img/Thumbs.db b/_unused-files/img/Thumbs.db similarity index 100% rename from img/Thumbs.db rename to _unused-files/img/Thumbs.db diff --git a/img/bg_scroll_01.gif b/_unused-files/img/bg_scroll_01.gif similarity index 100% rename from img/bg_scroll_01.gif rename to _unused-files/img/bg_scroll_01.gif diff --git a/img/bg_scroll_05.gif b/_unused-files/img/bg_scroll_05.gif similarity index 100% rename from img/bg_scroll_05.gif rename to _unused-files/img/bg_scroll_05.gif diff --git a/img/index.html b/_unused-files/img/index.html similarity index 100% rename from img/index.html rename to _unused-files/img/index.html diff --git a/img/index.php b/_unused-files/img/index.php similarity index 100% rename from img/index.php rename to _unused-files/img/index.php diff --git a/img/lib_reg2.gif b/_unused-files/img/lib_reg2.gif similarity index 100% rename from img/lib_reg2.gif rename to _unused-files/img/lib_reg2.gif diff --git a/img/podzem/0.gif b/_unused-files/img/podzem/0.gif similarity index 100% rename from img/podzem/0.gif rename to _unused-files/img/podzem/0.gif diff --git a/img/podzem/0_0.gif b/_unused-files/img/podzem/0_0.gif similarity index 100% rename from img/podzem/0_0.gif rename to _unused-files/img/podzem/0_0.gif diff --git a/img/podzem/1.gif b/_unused-files/img/podzem/1.gif similarity index 100% rename from img/podzem/1.gif rename to _unused-files/img/podzem/1.gif diff --git a/img/podzem/1_0.gif b/_unused-files/img/podzem/1_0.gif similarity index 100% rename from img/podzem/1_0.gif rename to _unused-files/img/podzem/1_0.gif diff --git a/img/podzem/2.gif b/_unused-files/img/podzem/2.gif similarity index 100% rename from img/podzem/2.gif rename to _unused-files/img/podzem/2.gif diff --git a/img/podzem/3.gif b/_unused-files/img/podzem/3.gif similarity index 100% rename from img/podzem/3.gif rename to _unused-files/img/podzem/3.gif diff --git a/img/podzem/Monster.gif b/_unused-files/img/podzem/Monster.gif similarity index 100% rename from img/podzem/Monster.gif rename to _unused-files/img/podzem/Monster.gif diff --git a/img/podzem/Thumbs.db b/_unused-files/img/podzem/Thumbs.db similarity index 100% rename from img/podzem/Thumbs.db rename to _unused-files/img/podzem/Thumbs.db diff --git a/img/podzem/altar_3.JPG b/_unused-files/img/podzem/altar_3.JPG similarity index 100% rename from img/podzem/altar_3.JPG rename to _unused-files/img/podzem/altar_3.JPG diff --git a/img/podzem/b.gif b/_unused-files/img/podzem/b.gif similarity index 100% rename from img/podzem/b.gif rename to _unused-files/img/podzem/b.gif diff --git a/img/podzem/bg.gif b/_unused-files/img/podzem/bg.gif similarity index 100% rename from img/podzem/bg.gif rename to _unused-files/img/podzem/bg.gif diff --git a/img/podzem/bolt.gif b/_unused-files/img/podzem/bolt.gif similarity index 100% rename from img/podzem/bolt.gif rename to _unused-files/img/podzem/bolt.gif diff --git a/img/podzem/bolt_d.gif b/_unused-files/img/podzem/bolt_d.gif similarity index 100% rename from img/podzem/bolt_d.gif rename to _unused-files/img/podzem/bolt_d.gif diff --git a/img/podzem/buttom.gif b/_unused-files/img/podzem/buttom.gif similarity index 100% rename from img/podzem/buttom.gif rename to _unused-files/img/podzem/buttom.gif diff --git a/img/podzem/buttomi.gif b/_unused-files/img/podzem/buttomi.gif similarity index 100% rename from img/podzem/buttomi.gif rename to _unused-files/img/podzem/buttomi.gif diff --git a/img/podzem/buttomii.gif b/_unused-files/img/podzem/buttomii.gif similarity index 100% rename from img/podzem/buttomii.gif rename to _unused-files/img/podzem/buttomii.gif diff --git a/img/podzem/cn1.gif b/_unused-files/img/podzem/cn1.gif similarity index 100% rename from img/podzem/cn1.gif rename to _unused-files/img/podzem/cn1.gif diff --git a/img/podzem/cn2.gif b/_unused-files/img/podzem/cn2.gif similarity index 100% rename from img/podzem/cn2.gif rename to _unused-files/img/podzem/cn2.gif diff --git a/img/podzem/cn3.gif b/_unused-files/img/podzem/cn3.gif similarity index 100% rename from img/podzem/cn3.gif rename to _unused-files/img/podzem/cn3.gif diff --git a/img/podzem/cy3.gif b/_unused-files/img/podzem/cy3.gif similarity index 100% rename from img/podzem/cy3.gif rename to _unused-files/img/podzem/cy3.gif diff --git a/img/podzem/cy3.jpg b/_unused-files/img/podzem/cy3.jpg similarity index 100% rename from img/podzem/cy3.jpg rename to _unused-files/img/podzem/cy3.jpg diff --git a/img/podzem/dob5.gif b/_unused-files/img/podzem/dob5.gif similarity index 100% rename from img/podzem/dob5.gif rename to _unused-files/img/podzem/dob5.gif diff --git a/img/podzem/g.gif b/_unused-files/img/podzem/g.gif similarity index 100% rename from img/podzem/g.gif rename to _unused-files/img/podzem/g.gif diff --git a/img/podzem/g_c.gif b/_unused-files/img/podzem/g_c.gif similarity index 100% rename from img/podzem/g_c.gif rename to _unused-files/img/podzem/g_c.gif diff --git a/img/podzem/g_r.gif b/_unused-files/img/podzem/g_r.gif similarity index 100% rename from img/podzem/g_r.gif rename to _unused-files/img/podzem/g_r.gif diff --git a/img/podzem/hall.jpg b/_unused-files/img/podzem/hall.jpg similarity index 100% rename from img/podzem/hall.jpg rename to _unused-files/img/podzem/hall.jpg diff --git a/img/podzem/hall2.JPG b/_unused-files/img/podzem/hall2.JPG similarity index 100% rename from img/podzem/hall2.JPG rename to _unused-files/img/podzem/hall2.JPG diff --git a/img/podzem/ico_change_leader1.gif b/_unused-files/img/podzem/ico_change_leader1.gif similarity index 100% rename from img/podzem/ico_change_leader1.gif rename to _unused-files/img/podzem/ico_change_leader1.gif diff --git a/img/podzem/ico_kill_member1.gif b/_unused-files/img/podzem/ico_kill_member1.gif similarity index 100% rename from img/podzem/ico_kill_member1.gif rename to _unused-files/img/podzem/ico_kill_member1.gif diff --git a/img/podzem/index.html b/_unused-files/img/podzem/index.html similarity index 100% rename from img/podzem/index.html rename to _unused-files/img/podzem/index.html diff --git a/img/podzem/kluchik.gif b/_unused-files/img/podzem/kluchik.gif similarity index 100% rename from img/podzem/kluchik.gif rename to _unused-files/img/podzem/kluchik.gif diff --git a/img/podzem/koll.gif b/_unused-files/img/podzem/koll.gif similarity index 100% rename from img/podzem/koll.gif rename to _unused-files/img/podzem/koll.gif diff --git a/img/podzem/left.gif b/_unused-files/img/podzem/left.gif similarity index 100% rename from img/podzem/left.gif rename to _unused-files/img/podzem/left.gif diff --git a/img/podzem/lefti.gif b/_unused-files/img/podzem/lefti.gif similarity index 100% rename from img/podzem/lefti.gif rename to _unused-files/img/podzem/lefti.gif diff --git a/img/podzem/leftii.gif b/_unused-files/img/podzem/leftii.gif similarity index 100% rename from img/podzem/leftii.gif rename to _unused-files/img/podzem/leftii.gif diff --git a/img/podzem/lestnica.gif b/_unused-files/img/podzem/lestnica.gif similarity index 100% rename from img/podzem/lestnica.gif rename to _unused-files/img/podzem/lestnica.gif diff --git a/img/podzem/ln1.gif b/_unused-files/img/podzem/ln1.gif similarity index 100% rename from img/podzem/ln1.gif rename to _unused-files/img/podzem/ln1.gif diff --git a/img/podzem/ln2.gif b/_unused-files/img/podzem/ln2.gif similarity index 100% rename from img/podzem/ln2.gif rename to _unused-files/img/podzem/ln2.gif diff --git a/img/podzem/ln3.gif b/_unused-files/img/podzem/ln3.gif similarity index 100% rename from img/podzem/ln3.gif rename to _unused-files/img/podzem/ln3.gif diff --git a/img/podzem/ly1.gif b/_unused-files/img/podzem/ly1.gif similarity index 100% rename from img/podzem/ly1.gif rename to _unused-files/img/podzem/ly1.gif diff --git a/img/podzem/ly2.gif b/_unused-files/img/podzem/ly2.gif similarity index 100% rename from img/podzem/ly2.gif rename to _unused-files/img/podzem/ly2.gif diff --git a/img/podzem/ly3.gif b/_unused-files/img/podzem/ly3.gif similarity index 100% rename from img/podzem/ly3.gif rename to _unused-files/img/podzem/ly3.gif diff --git a/img/podzem/mapdr.jpg b/_unused-files/img/podzem/mapdr.jpg similarity index 100% rename from img/podzem/mapdr.jpg rename to _unused-files/img/podzem/mapdr.jpg diff --git a/img/podzem/maprr.jpg b/_unused-files/img/podzem/maprr.jpg similarity index 100% rename from img/podzem/maprr.jpg rename to _unused-files/img/podzem/maprr.jpg diff --git a/img/podzem/move.gif b/_unused-files/img/podzem/move.gif similarity index 100% rename from img/podzem/move.gif rename to _unused-files/img/podzem/move.gif diff --git a/img/podzem/nav.gif b/_unused-files/img/podzem/nav.gif similarity index 100% rename from img/podzem/nav.gif rename to _unused-files/img/podzem/nav.gif diff --git a/img/podzem/nb.gif b/_unused-files/img/podzem/nb.gif similarity index 100% rename from img/podzem/nb.gif rename to _unused-files/img/podzem/nb.gif diff --git a/img/podzem/panbox_on.gif b/_unused-files/img/podzem/panbox_on.gif similarity index 100% rename from img/podzem/panbox_on.gif rename to _unused-files/img/podzem/panbox_on.gif diff --git a/img/podzem/ref.gif b/_unused-files/img/podzem/ref.gif similarity index 100% rename from img/podzem/ref.gif rename to _unused-files/img/podzem/ref.gif diff --git a/img/podzem/right.gif b/_unused-files/img/podzem/right.gif similarity index 100% rename from img/podzem/right.gif rename to _unused-files/img/podzem/right.gif diff --git a/img/podzem/righti.gif b/_unused-files/img/podzem/righti.gif similarity index 100% rename from img/podzem/righti.gif rename to _unused-files/img/podzem/righti.gif diff --git a/img/podzem/rightii.gif b/_unused-files/img/podzem/rightii.gif similarity index 100% rename from img/podzem/rightii.gif rename to _unused-files/img/podzem/rightii.gif diff --git a/img/podzem/rn1.gif b/_unused-files/img/podzem/rn1.gif similarity index 100% rename from img/podzem/rn1.gif rename to _unused-files/img/podzem/rn1.gif diff --git a/img/podzem/rn2.gif b/_unused-files/img/podzem/rn2.gif similarity index 100% rename from img/podzem/rn2.gif rename to _unused-files/img/podzem/rn2.gif diff --git a/img/podzem/rn3.gif b/_unused-files/img/podzem/rn3.gif similarity index 100% rename from img/podzem/rn3.gif rename to _unused-files/img/podzem/rn3.gif diff --git a/img/podzem/rv.gif b/_unused-files/img/podzem/rv.gif similarity index 100% rename from img/podzem/rv.gif rename to _unused-files/img/podzem/rv.gif diff --git a/img/podzem/ry1.gif b/_unused-files/img/podzem/ry1.gif similarity index 100% rename from img/podzem/ry1.gif rename to _unused-files/img/podzem/ry1.gif diff --git a/img/podzem/ry2.gif b/_unused-files/img/podzem/ry2.gif similarity index 100% rename from img/podzem/ry2.gif rename to _unused-files/img/podzem/ry2.gif diff --git a/img/podzem/ry3.gif b/_unused-files/img/podzem/ry3.gif similarity index 100% rename from img/podzem/ry3.gif rename to _unused-files/img/podzem/ry3.gif diff --git a/img/podzem/sun.gif b/_unused-files/img/podzem/sun.gif similarity index 100% rename from img/podzem/sun.gif rename to _unused-files/img/podzem/sun.gif diff --git a/img/podzem/top.gif b/_unused-files/img/podzem/top.gif similarity index 100% rename from img/podzem/top.gif rename to _unused-files/img/podzem/top.gif diff --git a/img/podzem/top.psd b/_unused-files/img/podzem/top.psd similarity index 100% rename from img/podzem/top.psd rename to _unused-files/img/podzem/top.psd diff --git a/img/podzem/topi.gif b/_unused-files/img/podzem/topi.gif similarity index 100% rename from img/podzem/topi.gif rename to _unused-files/img/podzem/topi.gif diff --git a/img/podzem/topii.gif b/_unused-files/img/podzem/topii.gif similarity index 100% rename from img/podzem/topii.gif rename to _unused-files/img/podzem/topii.gif diff --git a/img/podzem/use_heal_on.gif b/_unused-files/img/podzem/use_heal_on.gif similarity index 100% rename from img/podzem/use_heal_on.gif rename to _unused-files/img/podzem/use_heal_on.gif diff --git a/img/podzem/user.gif b/_unused-files/img/podzem/user.gif similarity index 100% rename from img/podzem/user.gif rename to _unused-files/img/podzem/user.gif diff --git a/img/podzem/v.gif b/_unused-files/img/podzem/v.gif similarity index 100% rename from img/podzem/v.gif rename to _unused-files/img/podzem/v.gif diff --git a/img/podzem/vlevo.gif b/_unused-files/img/podzem/vlevo.gif similarity index 100% rename from img/podzem/vlevo.gif rename to _unused-files/img/podzem/vlevo.gif diff --git a/img/podzem/vpravo.gif b/_unused-files/img/podzem/vpravo.gif similarity index 100% rename from img/podzem/vpravo.gif rename to _unused-files/img/podzem/vpravo.gif diff --git a/img/podzem/yeralti.gif b/_unused-files/img/podzem/yeralti.gif similarity index 100% rename from img/podzem/yeralti.gif rename to _unused-files/img/podzem/yeralti.gif diff --git a/img/podzem/yerustu.gif b/_unused-files/img/podzem/yerustu.gif similarity index 100% rename from img/podzem/yerustu.gif rename to _unused-files/img/podzem/yerustu.gif diff --git a/img/podzem/ziton.gif b/_unused-files/img/podzem/ziton.gif similarity index 100% rename from img/podzem/ziton.gif rename to _unused-files/img/podzem/ziton.gif diff --git a/img/rejting.GIF b/_unused-files/img/rejting.GIF similarity index 100% rename from img/rejting.GIF rename to _unused-files/img/rejting.GIF diff --git a/img/slot_bottom0.gif b/_unused-files/img/slot_bottom0.gif similarity index 100% rename from img/slot_bottom0.gif rename to _unused-files/img/slot_bottom0.gif diff --git a/exptable.html b/exptable.html deleted file mode 100644 index 80ca99c..0000000 --- a/exptable.html +++ /dev/null @@ -1,894 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
УровеньАпОпытУменияПараметрыКредиты
000030
120
10
245
12
375
14
1011013+18
Доступны Физические поединки.
- Закрыт доступ в бои для новичков.
Открыт доступ в Залы Воинов.
1160
12
2215
12
3280
14
4350
18
2041013+116
Доступны групповые и хаотические бои.1530
18
2670
112
3830
116
4950
124
51100
132
30130013+140

11450
110
21650
120
31850
130
42050
140
52200
150
40250015+170
Открыт доступ в Рыцарский Зал, Торговый Зал.
- Доступна передача кредитов/вещей.
Открыт доступ на форум.
Доступно развитие Интеллекта.
Доступен параметр Стойкость.
Открыт вход в Лабиринт Хаоса для новичков.
12900
110
23350
120
33800
130
44200
140
54600
150
50500013+180
16000
115
27000
130
38000
140
49000
150
510000
140
611000
150
712000
160
601250013+190
Открыт вход в Башню Смерти.
-
Открыт вход в Лабиринт Хаоса.
114000
120
215500
130
317000
150
419000
155
521000
150
623000
155
727000
150
703000015+1100
Доступно развитие Мудрости.
-
Открыт вход в Башню Рыцарей-Магов.
Доступно вступление в клан или создание своего.
Доступны бои склонностей.
160000
1100
275000
1100
3150000
1150
4175000
150
5200000
1100
6225000
150
7250000
1100
8260000
150
9280000
1100
8030000015+1700
11500000
1500
21750000
1200
32000000
1300
42175000
1100
52300000
1100
62400000
1100
72500000
1200
82600000
1100
92800000
1200
90300000015+21000
16000000
1200
26500000
1250
37500000
1200
48500000
1250
59000000
1400
69250000
1250
79500000
1400
89750000
1350
99900000
1500
1001000000019+32000
113000000
2200
214000000
2200
315000000
2200
416000000
2200
517000000
2200
617500000
2200
718000000
2200
819000000
2200
9
19500000
2200
1020000000

2250
1130000000
2200
1232000000
2250
1334000000
2200
1435000000
2250
1536000000
2200
1638000000
2250
1740000000
2200
1842000000
2250
1944000000
2350
2047000000
2300
2150000000
2350
11052000000110+33000
158000000
1350
265000000
1300
372000000
1350
477000000
1350
582000000
1300
687000000
1350
792000000
1350
8100000000
1350
9120000000
2400
10140000000
2400
11160000000
2600
12180000000
2400
13210000000
2400
120240000000210+45000
1260000000
2400
2320000000
2400
3400000000
3600
4455000000
2150
5510000000
2100
6600000000
2300
7750000000
5700
8770000000
1400
9815000000
1200
10860000000
1600
111000000000
1300
121100000000
1450
\ No newline at end of file diff --git a/friend.php b/friend.php index 58f2d7b..5448431 100644 --- a/friend.php +++ b/friend.php @@ -97,7 +97,6 @@ echo"Данные контакта ".$_POST['friendedit']." - diff --git a/functions.php b/functions.php index 8db7ca2..8330754 100644 --- a/functions.php +++ b/functions.php @@ -14,6 +14,10 @@ require_once 'config.php'; $u = new users_row($_SESSION['uid']); $user = $u->result(); +if (isset($user['id']) && $user['block'] == 1) { + die(); +} + define("HPADDICTIONEFFECT", 33); $ip = filter_input(INPUT_SERVER,'REMOTE_ADDR', FILTER_VALIDATE_IP); @@ -41,19 +45,17 @@ function createbot($bot, $login = "") } } - #####Для нападалок. Сперва комнаты в которых нельзя напасть, потом персонаж на которого нельзя напасть. -$unkilable = array( - 'rooms' => array(620, 621, 1051, 1052), - 'users' => array(10962, 10964, 10965) -); +$unkilable = [ + 'rooms' => [620, 621, 1051, 1052], + 'users' => [10962, 10964, 10965] +]; +$runes_exp = ['1' => 10500, '2' => 23500, '3' => 38500, '4' => 57000, '5' => 77000, '6' => 103000, '7' => 136500, '8' => 171500, '9' => 212500, '10' => 257500]; -$runes_exp = array('1' => 10500, '2' => 23500, '3' => 38500, '4' => 57000, '5' => 77000, '6' => 103000, '7' => 136500, '8' => 171500, '9' => 212500, '10' => 257500); - -$canalenters = array(620); -$caverooms = array(621); -$userslots = array('sergi', 'kulon', 'perchi', 'weap', 'bron', 'r1', 'r2', 'r3', 'helm', 'shit', 'boots', 'rybax', 'plaw', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'm9', 'm10'); +$canalenters = [620]; +$caverooms = [621]; +$userslots = ['sergi', 'kulon', 'perchi', 'weap', 'bron', 'r1', 'r2', 'r3', 'helm', 'shit', 'boots', 'rybax', 'plaw', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'm9', 'm10']; function getuserdata($id = 0) { @@ -73,41 +75,6 @@ if (!isset($user)) { $user = getuserdata(); } -//if (empty($user['battle']) && ($user['hp'] < @$user['maxhp'])) { -// regenhp($user); -//} - - -function getNum($v) -{ - $plid = $v; - $pi = iconv_strlen($plid); - if ($pi < 5) { - $i = 0; - while ($i <= 5 - $pi) { - $plid = '0' . $plid; - $i++; - } - } - return $plid; -} - -function banks() -{ - $id = $_SESSION['uid']; - $bank = db::c()->query('SELECT `id`, `ekr` FROM `bank` WHERE `id` = ?i ', $id)->fetch_assoc(); - if (isset($bank['id'])) { - echo '
СчётБанковский счёт № {$id}
На счету ' . $bank['ekr'] . ' еврокредитов.
'; - } else { - echo 'У вас нет счета в банке.'; - } -} - -if (isset($user['id']) && $user['block'] == 1) { - die(); -} - - $var_map = array( 'cell_1' => 'Березовая роща', 'cell_2' => 'Березовая просека', 'cell_3' => 'Тёмный угол', 'cell_4' => 'Мрачная опушка', 'cell_5' => 'Тёмное урочище', 'cell_6' => 'Бурелом', 'cell_7' => 'Старая ива', 'cell_8' => 'Разнолесье', @@ -118,7 +85,6 @@ $var_map = array( 'cell_25' => 'Полесье' ); - function close_dangling_tags($html) { preg_match_all("#<([a-z]+)( .*)?(?!/)>#iU", $html, $result); @@ -277,7 +243,6 @@ function battlewithbot($b, $name = '', $time = 3, $blood = 1, $group = 1, $battl return $battleid; } - function backpacksize($u = 0) { // $l * 10 +5 $l = 0; @@ -325,7 +290,6 @@ function backpacksize($u = 0) } } - function placeinbackpack($qty, $userid = 0) { global $user; @@ -547,12 +511,6 @@ function takeshopitem($item, $table = "shop", $present = '', $onlyonetrip = '', $rec1['ecost'] = 0; } -// if ($fields) { -// foreach ($fields as $k => $v) { -// $rec1[$k] = $v; -// } -// } - $sql = ""; while ($rec = mysql_fetch_assoc($r)) { if (!@$flds[$rec['Field']]) continue; @@ -860,39 +818,6 @@ function user_relicts() return $r; } -function lookStats($m) -{ - $ist = array(); - $di = explode('|', $m); - $i = 0; - while ($i < count($di)) { - $de = explode('=', $di[$i]); - if (isset($de[0], $de[1])) { - if (!isset($ist[$de[0]])) { - $ist[$de[0]] = 0; - } - $ist[$de[0]] = $de[1]; - } - $i++; - } - return $ist; -} - -function impStats($m) -{ - $i = 0; - $k = array_keys($m); - $d = ''; - while ($i <= count($k)) { - if ($k[$i] != '') { - $d .= $k[$i] . '=' . $m[$k[$i]] . '|'; - } - $i++; - } - $d = rtrim($d, '|'); - return $d; -} - function add_user_abil($ab, $cost) { global $user, $banks; @@ -1408,12 +1333,6 @@ function topsethp() return "top.setHP($user[hp], $user[maxhp], $delay);"; } -function timetoheal() -{ - $fulltime = 600; - return $fulltime; -} - function getslot($i, $user1 = 0) { global $userslots, $user; @@ -1557,23 +1476,6 @@ function GiveRep($id, $rep) mysql_query("UPDATE `users` SET `doblest` = (`doblest`+$rep), `rep_laba` = (`rep_laba`+$rep) WHERE `id` = '" . $id . "' LIMIT 1"); } -function GiveKr($id, $kr, $text = "Вы получили ") -{ - mysql_query("UPDATE `users` SET `money` = (`money`+{$kr}) WHERE `id` = {$id} LIMIT 1"); - if ($text != null) { - addchp($text . $kr . ' кр. ', '{[]}' . nick::id($id)->short() . '{[]}'); - } - mysql_query("INSERT INTO `delo` (`author`, `pers`, `text`, `type`, `date`) VALUES ('0', '{$id}', '\"" . $user['login'] . "\"" . $text . " " . $kr . " кр. ', '1', '" . time() . "')"); -} - -function GiveDoblest($id, $dobl, $text = "Вы получили ") -{ - mysql_query("UPDATE `users` SET `doblest` = (`doblest`+{$dobl}), `rep_laba` = (`rep_laba`+$dobl) WHERE `id` = {$id} LIMIT 1"); - if ($text != null) { - addchp($text . $dobl . ' доблести. ', '{[]}' . nick::id($id)->short() . '{[]}'); - } - mysql_query("INSERT INTO `delo` (`author`, `pers`, `text`, `type`, `date`) VALUES ('0', '{$id}', '\"" . $user['login'] . "\"" . $text . " " . $dobl . " доблести. ', '1', '" . time() . "')"); -} // полоска НР function setHP($hp, $maxhp) @@ -1789,41 +1691,6 @@ function show_eff_inf($u, $type) return $r; } -//function nick5_1($id, $st) -//{ -// if ($id > _BOTSEPARATOR_) { -// $bots = mysql_fetch_array(mysql_query('SELECT * FROM `bots` WHERE `id` = ' . $id . ' LIMIT 1;')); -// $id = $bots['prototype']; -// $user = mysql_fetch_array(mysql_query("SELECT * FROM `users` WHERE `id` = '{$id}' LIMIT 1;")); -// $user['login'] = $bots['name']; -// $user['hp'] = $bots['hp']; -// $user['id'] = $bots['id']; -// } else { -// $user = mysql_fetch_array(mysql_query("SELECT * FROM `users` WHERE `id` = '{$id}' LIMIT 1;")); -// } -// -// if ($user[0]) { -// $effect = mysql_fetch_array(mysql_query("SELECT `time` FROM `effects` WHERE `owner` = '{$id}' and `type` = '1022' LIMIT 1;")); -// if ($effect) { -// $user['level'] = '??'; -// $user['login'] = 'невидимка'; -// $user['align'] = '0'; -// $user['klan'] = ''; -// $user['id'] = ''; -// $user['hp'] = '??'; -// $user['maxhp'] = '??'; -// $user['mana'] = '??'; -// $user['maxmana'] = '??'; -// } -// $align = ($user['align'] > 0 ? $user['align'] : "0"); -// if ($user['klan'] != '') { -// $klan = ''; -// } -// $userb = "" . $klan . $user['login'] . " [" . $user['level'] . "]\"Инф."; -// return "" . $userb . ""; -// } -//} - function del_efs($uid, $id, $type) { global $user; @@ -1844,30 +1711,6 @@ function del_efs($uid, $id, $type) } } -function haseffect($data, $type) -{ - foreach ($data['effects'] as $k => $v) { - if ($v['type'] == $type) { - return $k; - } - } - return false; -} - -function addictval($a) -{ - $l = 0; - $step = 300; - $curr = 0; - while (true) { - if ($a < $curr + $step) return $l; - $l++; - $curr += $step; - $step += 40; - if ($l == 25) return $l; - } -} - function timetoheals($user) { $efs = mysql_fetch_array(mysql_query('SELECT SUM(`speed`) AS `speed` FROM `effects` WHERE `owner` = "' . $user['id'] . '" LIMIT 1')); @@ -1880,25 +1723,6 @@ function timetoheals($user) return $fulltime; } -function regenhp($us, $update = 1) -{ - global $user; - if ($us['hp'] < $us['maxhp'] && time() > $us['fullhptime']) { - $fulltime = timetoheals($us); - $delta = ceil((time() - $us['fullhptime']) / $fulltime * $us['maxhp']); - if ($delta > 0) { - $us['hp'] = min($us['hp'] + $delta, $us['maxhp']); - if ($update) { - mysql_query("UPDATE `users` SET `hp` = if(`hp`+$delta > `maxhp`, `maxhp`, `hp`+$delta), `fullhptime` = '" . time() . "' WHERE `id` = '$us[id]' LIMIT 1"); - } - if ($us['id'] == $user['id']) { - $user['hp'] = $us['hp']; - } - } - } - return $us['hp']; -} - function showinf_pers($id, $pas = 0, $battle = 0, $me = 0, $main = false) //FIXME 37 запросов! ТРИДЦАТЬ СЕМЬ! Чтобы отобразить предметы на персонаже. { global $rooms; @@ -2207,7 +2031,7 @@ function showinf_pers($id, $pas = 0, $battle = 0, $me = 0, $main = false) //FIXM } $r .= '

'; if (!$pas) { - $r .= 'Опыт: ' . $user['exp'] . ' (' . $user['nextup'] . ')
'; + $r .= 'Опыт: ' . $user['exp'] . ' (' . $user['nextup'] . ')
'; } $r .= 'Уровень: ' . $user['level'] . '
'; $r .= 'Побед: ' . $user['win'] . '
'; @@ -3472,14 +3296,6 @@ function magicinf($id) return db::c()->query('SELECT * FROM `magic` WHERE `id` = ?i', $id)->fetch_assoc(); } -/** - * @param $id - */ -function showpersinfo($id) { - $items = db::c()->query('SELECT * FROM `inventory` WHERE `owner` = ?i', $id)->fetch_assoc(); -} - - /** * Отображение персонажа в main.php * @param $id @@ -3807,122 +3623,6 @@ function undressall($id) } } -function dropitemid_cave($slot, $id) -{ - global $user; - switch ($slot) { - case 'sergi': - $slot = 1; - break; - case 'kulon': - $slot = 2; - break; - case 'weap': - $slot = 3; - break; - case 'bron': - $slot = 4; - break; - case 'r1': - $slot = 5; - break; - case 'r2': - $slot = 6; - break; - case 'r3': - $slot = 7; - break; - case 'helm': - $slot = 8; - break; - case 'perchi': - $slot = 9; - break; - case 'shit': - $slot = 10; - break; - case 'boots': - $slot = 11; - break; - case 'm1': - $slot = 12; - break; - case 'm2': - $slot = 13; - break; - case 'm3': - $slot = 14; - break; - case 'm4': - $slot = 15; - break; - case 'm5': - $slot = 16; - break; - case 'm6': - $slot = 17; - break; - case 'm7': - $slot = 18; - break; - case 'm8': - $slot = 19; - break; - case 'm9': - $slot = 20; - break; - case 'm10': - $slot = 21; - break; - case 'rybax': - $slot = 22; - break; - case 'plaw': - $slot = 23; - break; - } - if (mysql_query('UPDATE `users`, `inventory` SET `users`.' . $slot . ' = 0, `inventory`.`dressed` = 0, `users`.`sila` = `users`.`sila` - `inventory`.`gsila`, `users`.`lovk` = `users`.`lovk` - `inventory`.`glovk`, `users`.`inta` = `users`.`inta` - `inventory`.`ginta`, `users`.`intel` = `users`.`intel` - `inventory`.`gintel`, `users`.`maxhp` = `users`.`maxhp` - `inventory`.`ghp`, `users`.`noj` = `users`.`noj` - `inventory`.`gnoj`, `users`.`topor` = `users`.`topor` - `inventory`.`gtopor`, `users`.`dubina` = `users`.`dubina` - `inventory`.`gdubina`, `users`.`mec` = `users`.`mec` - `inventory`.`gmech`, `users`.`mfire` = `users`.`mfire` - `inventory`.`gfire`, `users`.`mwater` = `users`.`mwater` - `inventory`.`gwater`, `users`.`mair` = `users`.`mair` - `inventory`.`gair`, `users`.`mearth` = `users`.`mearth` - `inventory`.`gearth`, `users`.`mlight` = `users`.`mlight` - `inventory`.`glight`, `users`.`mgray` = `users`.`mgray` - `inventory`.`ggray`, `users`.`mdark` = `users`.`mdark` - `inventory`.`gdark`, `users`.`fkrit` = `users`.`fkrit` - `inventory`.`mfkrit`, `users`.`fakrit` = `users`.`fakrit` - `inventory`.`mfakrit`, `users`.`fuvorot` = `users`.`fuvorot` - `inventory`.`mfuvorot`, `users`.`fauvorot` = `users`.`fauvorot` - `inventory`.`mfauvorot`, `users`.`ubron1` = `users`.`ubron1` - `inventory`.`bron1`, `users`.`ubron2` = `users`.`ubron2` - `inventory`.`bron2`, `users`.`ubron3` = `users`.`ubron3` - `inventory`.`bron3`, `users`.`ubron4` = `users`.`ubron4` - `inventory`.`bron4`, `users`.`uminu` = `users`.`uminu` - `inventory`.`minu`, `users`.`umaxu` = `users`.`umaxu` - `inventory`.`maxu` WHERE `inventory`.`id` = `users`.' . $slot . ' AND `inventory`.`dressed` = 1 AND `inventory`.`owner` = "' . $user['id'] . '" AND `users`.`id` = "' . $user['id'] . '"')) { - mysql_query("UPDATE `users` SET `hp` = `maxhp`, `fullhptime` = " . time() . " WHERE `hp` > `maxhp` AND `id` = '{$id}' LIMIT 1"); - if ($id == $user['id']) { - $user[$slot] = 0; - } - return true; - } else { - echo mysql_error(); - } - -} - -function del_effs($uid, $eff, $txt) -{ - $pers = mysql_fetch_array(mysql_query('SELECT `id`, `login`, `sila`, `lovk`, `inta`, `vinos`, `intel`, `hp`, `maxhp` FROM `users` WHERE `id` = "' . mysql_real_escape_string($uid) . '" LIMIT 1')); - if (isset($pers['id'])) { - $effect = mysql_fetch_array(mysql_query('SELECT `id`, `type`, `name`, `time`, `sila`, `lovk`, `inta`, `vinos`, `hp`, `proc_exp`, `owner`, `sleep`, `lastup`, `can` FROM `effects` WHERE `id` = "' . mysql_real_escape_string($eff) . '" AND `owner` = "' . $pers['id'] . '" LIMIT 1')); - if (isset($effect['id'])) { - if ($effect['type'] == 11 || $effect['type'] == 12 || $effect['type'] == 13 || $effect['type'] == 14) { - $pers['sila'] += $effect['sila']; - $pers['lovk'] += $effect['lovk']; - $pers['inta'] += $effect['inta']; - $pers['vinos'] += $effect['vinos']; - $pers['maxhp'] += $effect['hp']; - } else { - $pers['sila'] -= $effect['sila']; - $pers['lovk'] -= $effect['lovk']; - $pers['inta'] -= $effect['inta']; - $pers['vinos'] -= $effect['vinos']; - $pers['maxhp'] -= $effect['hp']; - } - mysql_query('UPDATE `users` SET `sila` = "' . $pers['sila'] . '", `lovk` = "' . $pers['lovk'] . '", `inta` = "' . $pers['inta'] . '", `vinos` = "' . $pers['vinos'] . '", `maxhp` = "' . $pers['maxhp'] . '" WHERE `id` = "' . $pers['id'] . '" LIMIT 1'); - mysql_query('DELETE FROM `effects` WHERE `owner` = "' . $pers['id'] . '" AND `id` = "' . $effect['id'] . '" LIMIT 1'); - $text = 'Закончилось действие эффекта ' . $effect['name'] . '.'; - if ($txt == 1) { - addchp('Внимание! ' . $text, '{[]}' . nick::id($pers['id'])->short() . '{[]}'); - } - unset($pers, $effect, $uid, $eff, $text); - } - } -} - function dropitemid($slot, $id) { $user = mysql_fetch_array(mysql_query('SELECT * FROM `users` WHERE `id` = "' . $id . '" LIMIT 1')); @@ -4206,57 +3906,6 @@ function dropitem($slot) } } -//сможет держать -function derj($id) -{ - global $user; - $ts = mysql_fetch_array(mysql_query('SELECT `id`, `nalign` FROM `inventory` WHERE `id` = "' . $id . '" LIMIT 1')); - $al = '(1 = 1)'; - if ($ts['nalign'] > 0) { - if ($ts['nalign'] == 1.1) { - if (($user['align'] == 6 || ($user['align'] > 1 && $user['align'] < 2))) { - $al = '(1 = 1)'; - } else { - $al = '(1 = 2)'; - } - } - } - if ($dd = mysql_query("SELECT i.`id` FROM`users` AS `u`, `inventory` AS `i` - WHERE - i.needident = 0 AND - i.id = {$id} AND - i.duration < i.maxdur AND - i.owner = {$user['id']} AND - u.sila >= i.nsila AND - u.lovk >= i.nlovk AND - u.inta >= i.ninta AND - u.vinos >= i.nvinos AND - u.intel >= i.nintel AND - u.mudra >= i.nmudra AND - u.level >= i.nlevel AND - ($al OR (" . (int)$user['align'] . " = i.nalign) or (i.nalign = 0)) AND - u.noj >= i.nnoj AND - u.topor >= i.ntopor AND - u.dubina >= i.ndubina AND - u.mec >= i.nmech AND - u.mfire >= i.nfire AND - u.mwater >= i.nwater AND - u.mair >= i.nair AND - u.mearth >= i.nearth AND - u.mlight >= i.nlight AND - u.mgray >= i.ngray AND - u.mdark >= i.ndark AND - i.setsale = 0 AND - u.id = {$user['id']};")) { - $dd = mysql_fetch_array($dd); - if ($dd[0] > 0) { - return true; - } else { - return false; - } - } -} - function make_seed() { list($usec, $sec) = explode(' ', microtime()); @@ -4266,6 +3915,58 @@ function make_seed() function ref_drop() { global $user; + + //сможет держать + function derj($id) + { + //global $user; + $ts = mysql_fetch_array(mysql_query('SELECT `id`, `nalign` FROM `inventory` WHERE `id` = "' . $id . '" LIMIT 1')); + $al = '(1 = 1)'; + if ($ts['nalign'] > 0) { + if ($ts['nalign'] == 1.1) { + if (($user['align'] == 6 || ($user['align'] > 1 && $user['align'] < 2))) { + $al = '(1 = 1)'; + } else { + $al = '(1 = 2)'; + } + } + } + if ($dd = mysql_query("SELECT i.`id` FROM`users` AS `u`, `inventory` AS `i` + WHERE + i.needident = 0 AND + i.id = {$id} AND + i.duration < i.maxdur AND + i.owner = {$user['id']} AND + u.sila >= i.nsila AND + u.lovk >= i.nlovk AND + u.inta >= i.ninta AND + u.vinos >= i.nvinos AND + u.intel >= i.nintel AND + u.mudra >= i.nmudra AND + u.level >= i.nlevel AND + ($al OR (" . (int)$user['align'] . " = i.nalign) or (i.nalign = 0)) AND + u.noj >= i.nnoj AND + u.topor >= i.ntopor AND + u.dubina >= i.ndubina AND + u.mec >= i.nmech AND + u.mfire >= i.nfire AND + u.mwater >= i.nwater AND + u.mair >= i.nair AND + u.mearth >= i.nearth AND + u.mlight >= i.nlight AND + u.mgray >= i.ngray AND + u.mdark >= i.ndark AND + i.setsale = 0 AND + u.id = {$user['id']};")) { + $dd = mysql_fetch_array($dd); + if ($dd[0] > 0) { + return true; + } else { + return false; + } + } + } + $slot = array('sergi', 'kulon', 'weap', 'bron', 'r1', 'r2', 'r3', 'helm', 'perchi', 'shit', 'boots', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'm9', 'm10'); for ($i = 0; $i <= 20; $i++) { if ($user[$slot[$i]] && !derj($user[$slot[$i]])) { @@ -4275,27 +3976,6 @@ function ref_drop() } } -function GetWeaponType($idwep) -{ - if ($idwep == 0 || $idwep == null || $idwep == '') { - return "kulak"; - } - $wep = mysql_fetch_array(mysql_query('SELECT `otdel`, `minu` FROM `inventory` WHERE `id` = "' . $idwep . '" LIMIT 1')); - if ($wep[0] == '1') { - return "noj"; - } elseif ($wep[0] == '12') { - return "dubina"; - } elseif ($wep[0] == '11') { - return "topor"; - } elseif ($wep[0] == '13') { - return "mech"; - } elseif ($wep[1] > 0) { - return "buket"; - } else { - return "kulak"; - } -} - function stripslashes_deep($text) { while (strstr($text, "\\")) { @@ -4308,6 +3988,27 @@ function countmf() { //TODO пересчитать модификаторы global $user; + function GetWeaponType($idwep) + { + if ($idwep == 0 || $idwep == null || $idwep == '') { + return "kulak"; + } + $wep = mysql_fetch_array(mysql_query('SELECT `otdel`, `minu` FROM `inventory` WHERE `id` = "' . $idwep . '" LIMIT 1')); + if ($wep[0] == '1') { + return "noj"; + } elseif ($wep[0] == '12') { + return "dubina"; + } elseif ($wep[0] == '11') { + return "topor"; + } elseif ($wep[0] == '13') { + return "mech"; + } elseif ($wep[1] > 0) { + return "buket"; + } else { + return "kulak"; + } + } + $zo = mysql_fetch_row(mysql_query("SELECT `id` FROM `effects` WHERE `type` = 201 AND `owner` = {$user['id']} LIMIT 1")); $sokr = mysql_fetch_row(mysql_query("SELECT `id` FROM `effects` WHERE `type` = 202 AND `owner` = {$user['id']} LIMIT 1")); @@ -4494,154 +4195,6 @@ function dressitem($id) } } -function dressitemkomplekt($id, $idd) -{ - global $user; - $item = mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `owner` = " . $user['id'] . " AND `dressed` = 0 AND `duration` < `maxdur` AND `id` = '" . $idd . "' LIMIT 1")); - if (!isset($item['id'])) { - $item = mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `owner` = " . $user['id'] . " AND `dressed` = 0 AND `duration` < `maxdur` AND `name` = '" . $id . "' ORDER BY `duration` DESC LIMIT 1")); - } - - switch ($item['type']) { - case 1: - $slot1 = 'sergi'; - break; - case 2: - $slot1 = 'kulon'; - break; - case 3: - $slot1 = 'weap'; - break; - case 4: - $slot1 = 'bron'; - break; - case 5: - $slot1 = 'r1'; - break; - case 6: - $slot1 = 'r2'; - break; - case 7: - $slot1 = 'r3'; - break; - case 8: - $slot1 = 'helm'; - break; - case 9: - $slot1 = 'perchi'; - break; - case 10: - $slot1 = 'shit'; - break; - case 11: - $slot1 = 'boots'; - break; - case 12: - $slot1 = 'm1'; - break; - case 22: - $slot1 = 'rybax'; - break; - case 23: - $slot1 = 'plaw'; - break; - case 24: - $slot1 = 'rune_1'; - break; - case 25: - $slot1 = 'rune_2'; - break; - case 26: - $slot1 = 'rune_3'; - break; - } - - if ($item['type'] == 5) { - if ($user['r1'] == 0) { - $slot1 = 'r1'; - } elseif ($user['r2'] == 0) { - $slot1 = 'r2'; - } elseif ($user['r3'] == 0) { - $slot1 = 'r3'; - } else { - $slot1 = 'r1'; - dropitem(5); - } - } elseif ($item['type'] == 24) { - if ($user['rune_1'] == 0) { - $slot1 = 'rune_1'; - } elseif ($user['rune_2'] == 0) { - $slot1 = 'rune_2'; - } elseif ($user['rune_3'] == 0) { - $slot1 = 'rune_3'; - } else { - $slot1 = 'rune_1'; - dropitem(24); - } - } elseif ($item['type'] == 12) { - if ($user['m1'] == 0) { - $slot1 = 'm1'; - } elseif ($user['m2'] == 0) { - $slot1 = 'm2'; - } elseif ($user['m3'] == 0) { - $slot1 = 'm3'; - } elseif ($user['m4'] == 0) { - $slot1 = 'm4'; - } elseif ($user['m5'] == 0) { - $slot1 = 'm5'; - } elseif ($user['m6'] == 0) { - $slot1 = 'm6'; - } elseif ($user['m7'] == 0) { - $slot1 = 'm7'; - } elseif ($user['m8'] == 0) { - $slot1 = 'm8'; - } elseif ($user['m9'] == 0) { - $slot1 = 'm9'; - } elseif ($user['m10'] == 0) { - $slot1 = 'm10'; - } else { - $slot1 = 'm1'; - dropitem(12); - } - } else { - dropitem($item['type']); - } - - if (!($item['type'] == 12 && $user['level'] < 4)) { - if (mysql_query("UPDATE `users` AS `u`, `inventory` AS `i` SET `u`.`{$slot1}` = `{$item['id']}`, `i`.`dressed` = 1, - `u`.`sila` = `u`.sila + i.gsila, - `u`.`lovk` = `u`.lovk + i.glovk, - `u`.`inta` = `u`.inta + i.ginta, - `u`.`intel` = `u`.intel + i.gintel, - `u`.`maxhp` = `u`.maxhp + i.ghp, - `u`.`noj` = `u`.noj + i.gnoj, - `u`.`topor` = `u`.topor + i.gtopor, - `u`.`dubina` = `u`.dubina + i.gdubina, - `u`.`mec` = `u`.mec + i.gmech, - `u`.`mfire` = `u`.mfire + i.gfire, - `u`.`mwater` = `u`.mwater + i.gwater, - `u`.`mair` = `u`.mair + i.gair, - `u`.`mearth` = `u`.mearth + i.gearth, - `u`.`mlight` = `u`.mlight + i.glight, - `u`.`mgray` = `u`.mgray + i.ggray, - `u`.`mdark` = `u`.mdark + i.gdark, - `u`.`fkrit` = `u`.fkrit + i.mfkrit, - `u`.`fakrit` = `u`.fakrit + i.mfakrit, - `u`.`fuvorot` = `u`.fuvorot + i.mfuvorot, - `u`.`fauvorot` = `u`.fauvorot + i.mfauvorot, - `u`.`ubron1` = `u`.ubron1 + i.bron1, - `u`.`ubron2` = `u`.ubron2 + i.bron2, - `u`.`ubron3` = `u`.ubron3 + i.bron3, - `u`.`ubron4` = `u`.ubron4 + i.bron4, - `u`.`uminu` = `u`.uminu + i.minu, - `u`.`umaxu` = `u`.umaxu + i.maxu - WHERE `i`.`needident` = 0 AND `i`.`id` = {$item['id']} AND `i`.`dressed` = 0 AND `i`.`owner` = {$user['id']} AND ((('" . $user['align'] . "' > 7) AND ('" . $user['align'] . "' < 8)) OR ('" . (int)$user['align'] . "' = `i`.`nalign`) OR (`i`.`nalign` = 0)) AND `i`.`setsale` = 0 AND `u`.`id` = {$user['id']}")) { - $user[$slot1] = $item['id']; - return true; - } - } -} - // убить предмет function destructitem($id) { @@ -5115,13 +4668,6 @@ function get_meshok() return ($user['sila'] * 4 + $d['ves']); } -function get_meshok_to($to) -{ - $d = mysql_fetch_array(mysql_query("SELECT SUM(`gmeshok`) FROM `inventory` WHERE `owner` = '{$to}' AND `setsale` = 0 AND `gmeshok` > 0")); - $s = mysql_fetch_array(mysql_query("SELECT `sila` FROM `users` WHERE `id` = '{$to}' LIMIT 1")); - return ($s['sila'] * 4 + $d[0]); -} - function getweight($id) { return mysql_fetch_array(mysql_query("SELECT SUM(`massa`) AS `weight`, COUNT(`id`) AS `cnt` FROM `inventory` WHERE `owner` = $id AND `dressed` = 0 AND `setsale` = 0")); @@ -5184,132 +4730,6 @@ function bron_ads($a1, $a2, $a3, $a4, $col) return array('a1' => round(($a1 / 100) * $col), 'a2' => round(($a2 / 100) * $col), 'a3' => round(($a3 / 100) * $col), 'a4' => round(($a4 / 100) * $col)); } -function dressitem2($id) -{ - global $user; - $item = mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `duration` < `maxdur` AND `id` = '{$id}' AND `dressed` = 0; ")); - switch ($item['type']) { - case 1: - $slot1 = 'sergi'; - break; - case 2: - $slot1 = 'kulon'; - break; - case 3: - $slot1 = 'weap'; - break; - case 4: - $slot1 = 'bron'; - break; - case 5: - $slot1 = 'r1'; - break; - case 6: - $slot1 = 'r2'; - break; - case 7: - $slot1 = 'r3'; - break; - case 8: - $slot1 = 'helm'; - break; - case 9: - $slot1 = 'perchi'; - break; - case 10: - $slot1 = 'shit'; - break; - case 11: - $slot1 = 'boots'; - break; - case 12: - $slot1 = 'm1'; - break; - case 22: - $slot1 = 'rybax'; - break; - case 23: - $slot1 = 'plaw'; - break; - } - if ($item['type'] == 5) { - if (!$user['r1']) { - $slot1 = 'r1'; - } elseif (!$user['r2']) { - $slot1 = 'r2'; - } elseif (!$user['r3']) { - $slot1 = 'r3'; - } else { - $slot1 = 'r1'; - dropitem(5); - } - } elseif ($item['type'] == 12) { - if (!$user['m1']) { - $slot1 = 'm1'; - } elseif (!$user['m2']) { - $slot1 = 'm2'; - } elseif (!$user['m3']) { - $slot1 = 'm3'; - } elseif (!$user['m4']) { - $slot1 = 'm4'; - } elseif (!$user['m5']) { - $slot1 = 'm5'; - } elseif (!$user['m6']) { - $slot1 = 'm6'; - } elseif (!$user['m7']) { - $slot1 = 'm7'; - } elseif (!$user['m8']) { - $slot1 = 'm8'; - } elseif (!$user['m9']) { - $slot1 = 'm9'; - } elseif (!$user['m10']) { - $slot1 = 'm10'; - } else { - $slot1 = 'm1'; - dropitem(12); - } - } else { - dropitem($item['type']); - } - //echo $slot1,$id,$user['id'],$user['align'],$item['id']; - if (!($item['type'] == 12 && $user['level'] < 4)) { - if (mysql_query("UPDATE `users` as u, `inventory` as i SET u.{$slot1} = {$id}, i.dressed = 1, - u.sila = u.sila + i.gsila, - u.lovk = u.lovk + i.glovk, - u.inta = u.inta + i.ginta, - u.intel = u.intel + i.gintel, - u.maxhp = u.maxhp + i.ghp, - u.noj = u.noj + i.gnoj, - u.topor = u.topor + i.gtopor, - u.dubina = u.dubina + i.gdubina, - u.mec = u.mec + i.gmech, - u.mfire = u.mfire + i.gfire, - u.mwater = u.mwater + i.gwater, - u.mair = u.mair + i.gair, - u.mearth = u.mearth + i.gearth, - u.mlight = u.mlight + i.glight, - u.mgray = u.mgray + i.ggray, - u.mdark = u.mdark + i.gdark - WHERE - i.needident = 0 AND - i.id = {$id} AND - i.dressed = 0 AND - i.owner = {$user['id']} AND - u.sila >= i.nsila AND - u.lovk >= i.nlovk AND - u.inta >= i.ninta AND - u.vinos >= i.nvinos AND - u.intel >= i.nintel AND - u.mudra >= i.nmudra AND - u.level >= i.nlevel AND - (((" . $user['align'] . " > 7) AND (" . $user['align'] . " < 8)) OR (" . (int)$user['align'] . " = i.nalign) or (i.nalign = 0)) AND - u.id = {$user['id']};")) { - $user[$slot1] = $item['id']; - return true; - } - } -} - function star_sign($month, $day) { $signs = ["10", "11", "12", "1", "2", "3", "4", "5", "6", "7", "8", "9"]; @@ -5413,6 +4833,4 @@ function SolveExp($at_id, $def_id, $damage) function vCode($LocID, $Stamp) { return md5(sha1($LocID . $Stamp)); -} - -?> \ No newline at end of file +} \ No newline at end of file diff --git a/js/CombatsUI.js b/js/CombatsUI.js deleted file mode 100644 index 7416908..0000000 --- a/js/CombatsUI.js +++ /dev/null @@ -1 +0,0 @@ -(function(){function m(){var b={id:341269,t:50,j:true,js:13,rand:Math.random(),r:escape(f.referrer)},a;if(a=screen){b.s=[a.width,a.height].join("*");b.d=a.colorDepth||a.pixelDepth}a=[];for(var c in b)a.push(c+"="+b[c]);c=f.createElement("div");var e=f.createElement("a");e.setAttribute("target","_blank");e.setAttribute("href","http://top.mail.ru/jump?from="+b.id);b=f.createElement("img");b.setAttribute("src","http://top.list.ru/counter?"+a.join(";"));b.setAttribute("title","Рейтинг@Mail.ru");b.setAttribute("border",0);b.setAttribute("height",31);b.setAttribute("width",88);e.appendChild(b);c.appendChild(e);return c}function n(b){b=b+108E5;var a=new Date(b),c=a.getUTCMonth();if(c>2&&c<9)return b+36E5;if(c<2||c>9)return b;var e=a.getUTCDate();c=c===2;if(e<=24)return c?b:b+36E5;var d=a.getUTCDay();if(d===0)return a.getUTCHours()>=2?c?b+36E5:b:c?b:b+36E5;return e-d<=24?c?b:b+36E5:c?b+36E5:b}function o(b){b=new Date(b);var a=b.getUTCMonth()+1;if(a<10)a="0"+a;var c=b.getUTCDate();if(c<10)c="0"+c;var e=b.getUTCHours();if(e<10)e="0"+e;var d=b.getUTCMinutes();if(d<10)d="0"+d;return b.getUTCFullYear()+"."+a+"."+c+"В "+e+":"+d}function p(b){var a=q.ru,c=f.createElement("div"),e,d;(e=c.style).display="inline-block";e.whiteSpace="pre";if(e=b.align){var h;d=f.createElement("a");d.target="_blank";d.href="http://capitalcity.combats.com/encicl/"+((h=parseInt(e))===50?"alchemist":"alignment")+".html";if(a=parseFloat(e)===7?a["7="]:a[h])d.title=a;a=f.createElement("img");a.src="http://img.combats.ru/i/align"+e+".gif";a.width=12;a.height=15;a.border=0;d.appendChild(a);c.appendChild(d)}if(b.hasOwnProperty("clan")){e=b.clan;d=f.createElement("a");d.target="_blank";d.href="/clans_inf.pl?"+e;d.title="Информация Рѕ клане "+e;a=f.createElement("img");a.src="http://img.combats.ru/i/klan/"+e+".gif";a.width=24;a.height=15;a.border=0;d.appendChild(a);c.appendChild(d)}d=f.createElement("b");d.appendChild(f.createTextNode(e=b.login));c.appendChild(d);c.appendChild(f.createTextNode("В ["+b.level+"]"));d=f.createElement("a");d.target="_blank";d.href="/inf.pl?"+b.id;d.title="Информация Рѕ "+e;a=f.createElement("img");a.src="http://img.combats.ru/i/inf.gif";a.width=12;a.height=11;a.border=0;d.appendChild(a);c.appendChild(d);return c}function r(b,a,c){a=a;i||(i=j());g||(g=new i);switch(b){case "get":case "GET":if(c!=undefined)a+=c;g.open("GET",a,false);g.send();break;case "post":case "POST":g.open("POST",a,false);g.send(c);break}if((b=g.status)!==200)return parseInt(b,10);else{var e;try{var d=g.responseText;e=d.substring(0,2)==="//"?k(d.substring(2)):d=="undefined"?void 0:k(d)}catch(h){e=500}return e}}var f=document,l=window,q={ru:{"1":"Белое братство","2":"Хаос","3":"Темное братство","7=":"Нейтральное братство","7":"Орден Очищения Стихий","50":"Алхимики"}},k=typeof JSON==="object"&&JSON.parse?JSON.parse:function(b){return eval("("+b+")")},i,g,j=function(){j=undefined;var b;if(b=l.XMLHttpRequest)return b;if(b=l.ActiveXObject){var a;try{a=new b("MSxml2.XMLHTTP.6.0")}catch(c){}if(a){a=null;return function(){return new b("MSxml2.XMLHTTP.6.0")}}try{a=new b("MSxml2.XMLHTTP.3.0")}catch(e){}if(a){a=null;return function(){return new b("MSxml2.XMLHTTP.3.0")}}try{a=new b("MSxml2.XMLHTTP")}catch(d){}if(a){a=null;return function(){return new b("MSxml2.XMLHTTP")}}try{a=new b("Microsoft.XMLHTTP")}catch(h){}if(a){a=null;return function(){return new b("Microsoft.XMLHTTP")}}}};(function(b){var a=b.CombatsUI;a||(b.CombatsUI=a={});a.CounterMailRu=m;a.UTCMsec2Moscow=n;a.UTCMsec2PlainText=o;a.UserLink=p;a.SyncJSON=r;this.DLoad&&(new this.DLoad.pkg("CombatsUI")).use("LocalText").complete()})(this)})() \ No newline at end of file diff --git a/js/LocalText.js b/js/LocalText.js deleted file mode 100644 index ade7bb0..0000000 --- a/js/LocalText.js +++ /dev/null @@ -1 +0,0 @@ -(function(){function n(b,a,e){e||(e=r);var d={};b=[b];for(var f,j={},h;h=b.length;){f=s;for(var c=0;c=2&&a%10<=4&&(a%100<10||a%100>=20)?2:0}else return b=="en"?a==1||a==-1?1:0:0}function u(b,a,e){var d=a[e+"G"];if(d)return d;a=a[e];if(b=="ru")if(v.test(a))return"F";else if(w.test(a))return"P";return"M"}function x(b,a,e,d){var f,j=e&&e;f=p[b]||(p[b]=n(b,y));if(a<=0)return"0В "+(d&&f["second0"+d]||f.second0);var h,c;l.length=0;for(var g=z;g-=2;){c=m[g];if(a>=c){if(c===1)h=a;else a-=(h=A(a/c))*c;c=m[g+1]+o(b,h);l.push(h+"В "+(d&&f[c+d]||f[c]));if(e&&!--j)break}}return l.join(" ")}function q(b){var a=b.LocalText;a||(b.LocalText=a={});a.Inherit=n;a.PluralForm=o;a.Gender=u;a.PeriodToText=x;a.ExportTo=q}var r={ja:["en","zh"],en:["ru"]},s=[],l=[],t=Math.abs,A=Math.floor,v=/[ая]$/i,w=/[РёС‹]$/i,y={ru:{year0:"лет",year1:"РіРѕРґ",year2:"РіРѕРґР°",month0:"месяцев",month1:"месяц",month2:"месяца",week0:"недель",week1:"неделя",week1ACC:"неделю",week2:"недели",day0:"дней",day1:"день",day2:"РґРЅСЏ",hour0:"часов",hour1:"час",hour2:"часа",minute0:"РјРёРЅСѓС‚",minute1:"минута",minute1ACC:"минуту",minute2:"минуты",second0:"секунд",second1:"секунда",second1ACC:"секунду",second2:"секунды"},en:{year0:"years",year1:"year",month0:"months",month1:"month",week0:"weeks",week1:"week",day0:"days",day1:"day",hour0:"hours",hour1:"hour",minute0:"minutes",minute1:"minute",second0:"seconds",second1:"second"}},m=[0,0,1,"second",60,"minute",3600,"hour",86400,"day",604800,"week",2592E3,"month",31536E3,"year"],z=m.length,p={};q(this);typeof DLoad==="object"&&(new DLoad.pkg("LocalText")).complete()})() \ No newline at end of file diff --git a/js/_e2.js b/js/_e2.js deleted file mode 100644 index 7402b97..0000000 --- a/js/_e2.js +++ /dev/null @@ -1 +0,0 @@ -(function(){function v(a){if(!a._e_version)for(func in j)a[func]=j[func];return a}function w(a){this.o=this.original=a}function q(a,b){w.prototype[b]=function(c,d,i){if(typeof i==="undefined"){if(this[a+"|"+c]===d)return this;this[a+"|"+c]=d;this.original[a](c,d)}else{var f=[];for(g=len=arguments.length;g-- >1;){var l=arguments[g],h=arguments[--g];if(this[a+"|"+h]!==d){this[a+"|"+h]=d;f.push(h,l)}}f.length&&this.original[a].apply(this.original,f)}return this}}function u(a,b){w.prototype[b]=function(c){if(this[a]===c)return this;this[a]=c;this.original[a](c);return this}}function y(a){this.o=this.original=a}function s(a,b,c,d,i,f){var l;try{var h="";if(c||c==0)h=' name="'+c+'"';var z="";if(b)z=' type="'+b+'"';l=n.createElement("")}catch(A){l=n.createElement("input")}l.name=c;l.type=b;b=v(l);if(i&&(d||d==0))b.sp(i,d);a&&a.AppendChild(b);if(f)if(typeof f==="object")b.sp(f);else return b;return a}function p(a,b,c){var d=b.length,i;for(i=0;i') - } - catch(err){ ielem=document.createElement('input') } // Correct way - ielem.name=name; ielem.type=type // Correct way + double it just in case IE way works for some weird reason - return _e(ielem) -} - -function input_return(where, type, name, value, prop, return_new){ - var ielem=input(type, name) - if(prop && (value || value==0)){ ielem.sp(prop, value) } - if(where){ where.AppendChild(ielem) } // IE doesn't allows to change input type after append. - if(return_new){ - if(typeof(return_new)=='object'){ ielem.sp(return_new) } else { return ielem } - } - return where -} - -// Copies properties from arguments to target object. Arguments can be any of -// complete objects - every property will be copied from it or pair -// of key+value strings. You can also mix them. -function set_properties(target, args, method){ - var len=args.length - for(var idx=0; idx=0){clearTimeout(TimerOn);TimerOn=-1} -setHPlocal()} -function setHPlocal(){ -if(tkHP>maxHP){tkHP=maxHP;TimerOn=-1 -}else TimerOn=0; -var a=Math.round(120/maxHP*tkHP), -b=120-a, -c=FindFrameDocument(top,main_uid); -if(c){var d=c.getElementById("HP"); -if(d){var e=c.getElementById("HP1"); -c=c.getElementById("HP2"); -e.width=a; -c.width=b; -c.style.display=b?"":"none"; -e.src=tkHP/maxHP0){tkHP+=maxHP/(vrem*60);} -if(TimerOn!=-1)TimerOn=setTimeout(setHPlocal,delay*100) -} - diff --git a/js/ch2.91.js b/js/ch2.91.js deleted file mode 100644 index 43741bb..0000000 --- a/js/ch2.91.js +++ /dev/null @@ -1,97 +0,0 @@ -document.onmousedown = Down; -function Down() {top.CtrlPress = window.event.ctrlKey} - -// Разрешенные смайлики -var sm = new Array("horse",60,40, "hug",48,20, "laugh",15,15, "susel",70,34 , "fingal",22,15, "eek",15,15, "flowers",28,29, "smoke",20,20, "hi",31,28, "bye",15,15, -"king",21,22, "king2",28,24, "boks2",28,21, "boks",62,28, "gent",15,21, "lady",15,19, "tongue",15,15, "smil",16,16, "rotate",15,15, -"ponder",21,15, "bow",15,21, "smile",18,18, "angel",42,43, "angel2",26,25, "hello",25,27, "dont",26,26, "idea",26,27, "mol",27,22, "super",26,28, -"beer",15,15, "drink",19,17, "baby",15,18, "tongue2",15,15, "sword",49,18, "agree",37,15, -"loveya",27,15, "kiss",15,15, "kiss2",15,15, "kiss3",15,15, "kiss4",37,15, "rose",15,15, "love",27,28, -"love2", 55,24, "inv",80,20, -"confused",15,22, "yes",15,15, "no",15,15, "shuffle",15,20, "nono",22,19, "maniac",70,25, "privet",27,29, "ok",22,16, "ninja",15,15, -"pif",46,26, "smash",30,26, "alien",13,15, "pirate",23,19, "gun",40,18, "trup",20,20, -"mdr",56,15, "sneeze",15,20, "mad",15,15, "friday",57,28, "cry",16,16, "grust",15,15, "rupor",38,18, -"fie",15,15, "nnn",82,16, "row",36,15, "red",15,15, "lick",15,15, -"help",23,15, "wink",15,15, "jeer",26,16, "tease",33,19, "str", 35, 25, "kruger",34,27, "girl",37,26, "Knight1",69,37, "rev",40,25, "smile100",44,39, "smile118",25,25, -"smile149", 54,37, "smile166",46,29, "smile237",35,35, "smile245",50,30, "smile28",33,34, "smile289",46,31, "smile314",36,29, "smile36",50,46, "smile39",46,48, -"smile44",27,26, "smile70",50,32 -); - -function AddLogin() -{ var o = window.event.srcElement; - if (o.tagName == "SPAN") { - var login=o.innerText; - if (o.alt != null && o.alt.length>0) login=o.alt; - var i1,i2; - if ((i1 = login.indexOf('['))>=0 && (i2 = login.indexOf(']'))>0) login=login.substring(i1+1, i2); - if (o.className.substr(0,1) == "p") { top.AddToPrivate(login, false) } - else if (o.className == "s") {top.AddToSms(login, false) } - else { top.AddTo(login) } - } -} - -function ClipBoard(text) -{ - //var holdtext.innerText = text; - var Copied = text;//holdtext.createTextRange(); - Copied.execCommand("RemoveFormat"); - Copied.execCommand("Copy"); -} - -function OpenMenu(th) { - var el, x, y, login, login2; - el = document.all("oMenu"); - var o = window.event.srcElement; - if (o.tagName != "SPAN") return true; - x = window.event.clientX + document.documentElement.scrollLeft + document.body.scrollLeft - 3; - y = window.event.clientY + document.documentElement.scrollTop + document.body.scrollTop; - - if (window.event.clientY + 72 > document.body.clientHeight) { y-=68 } else { y-=2 } - login = o.innerText; - if (o.alt != null && o.alt.length>0) login = o.alt; - window.event.returnValue=false; - var i1, i2; - if ((i1 = login.indexOf('['))>=0 && (i2 = login.indexOf(']'))>0) login=login.substring(i1+1, i2); - var login2 = login; - login2 = login2.replace('%', '%25'); - while (login2.indexOf('+')>=0) login2 = login2.replace('+', '%2B'); - while (login2.indexOf('#')>=0) login2 = login2.replace('#', '%23'); - while (login2.indexOf('?')>=0) login2 = login2.replace('?', '%3F'); - - el.innerHTML = 'TO'+ - 'PRIVATE'+ - 'INFO'+ - 'COPY'; - - el.style.left = x + "px"; - el.style.top = y + "px"; - el.style.visibility = "visible"; -} - -function OpenInfo(login) { - var lar = login.split(/,/g); - for (i=0;i"; - if (klan) s+=""; - s+=""+name+" "; - if (level!=-1) s+="["+level+"]"; - if (id!=-1) s+="Инф. о "+name+""; - - document.write(s); -} diff --git a/js/dialog_030_ru.js b/js/dialog_030_ru.js deleted file mode 100644 index c20531e..0000000 --- a/js/dialog_030_ru.js +++ /dev/null @@ -1,346 +0,0 @@ -var Hint3Name = ''; - -step=0; -top.is_qlaunch = 0; -function errmess(s) -{ - messid.innerHTML=''+s+''; - highlight(); -} -function highlight() -{ - if (step) return(0); - step=10; - setTimeout(dohi,50); -} - -function dohi() -{ - var hx=new Array(0,1,2,3,4,5,6,7,8,9,"A","B","C","D","E","F"); - step--; - messid.style.color="#"+hx[Math.floor(15-step/2)]+((step&1)?"F":"8")+"0000"; - if (step>0) setTimeout(dohi,50); -} - -function fixspaces(s) -{ - while (s.substr(s.length-1,s.length)==" ") s=s.substr(0,s.length-1); - while (s.substr(0,1)==" ") s=s.substr(1,s.length); - return(s); -} - - -// Заголовок, название скрипта, имя поля с логином -function bank_open(ac_list, ac_def, skipz, name) { - var ac = ac_list.split(','); - var s; - var addon = ''; - var hint = 'Выберите счёт и введите пароль'; - var title = 'Счёт в банке'; - var opt = ''; - //alert (opt); - s=''+ - ''+ - ''+ - '' + - '' + - '
'+ hint + '
' + opt+ ' '+(addon?addon:'')+'
'; - s = crtmagic('', title, s,"",skipz); - if (!name) {name = "hint4"}; - - document.all(name).innerHTML = s; - document.all(name).style.visibility = "visible"; - if (!skipz) { - document.all(name).style.left = 100; - document.all(name).style.zIndex = 200; - document.all(name).style.top = document.body.scrollTop+50; - } - document.all('num').focus(); - Hint3Name = 'num'; - - - - for (var i=0; i'+ ac[i] + ''; - } - opt += ''; - -} - -function bank_info() { - alert('У Вас нет активных счетов. \n\n На правах рекламы: Вы можете открыть счёт в Банке БК,'+ - ' на Страшилкиной улице*\n\n* Мелким шрифтом: услуга платная.'); -} - -function bank_blocked(tm) { - var s = 'Ваши счета заблокированы (ещё '+ tm + ').'; - alert(s); -} - -function get_bank_pwd(){ - -} - -function b_confirm(script, txt, mtype, addon, need_defend) { - - if (need_defend && defend==false) { - defend=-1 -// errmess("Блок не выбран."); return false; - } - - if (need_defend) { - addon+=""; - addon+=""; - addon+=""; - } - - dialogconfirm('Подтверждение', '/battle.pl', '
'+txt+'
Использовать сейчас?
'+addon, mtype); -} - - -function dialogconfirm(title, script, text, mtype) { - var s; - - s='
'+ - text+'
'; - - s = crtmagic(mtype, title, s); - document.all("hint4").innerHTML = s; - - document.all("hint4").style.visibility = "visible"; - document.all("hint4").style.left = 100; - document.all("hint4").style.zIndex = 200; - document.all("hint4").style.top = document.body.scrollTop+50; - document.all("tmpname423").focus(); - Hint3Name = name; -} - -function dialogOK(title, text, mtype) { - var s; - - s='
'+ - text+'
'; - - s = crtmagic(mtype, title, s); - document.all("hint4").innerHTML = s; - document.all("hint4").style.visibility = "visible"; - document.all("hint4").style.left = 100; - document.all("hint4").style.zIndex = 200; - document.all("hint4").style.top = document.body.scrollTop+50; - Hint3Name = name; -} - - -function foundmagictype (mtypes) { - if (mtypes) { - mtypes=mtypes+""; - if (mtypes.indexOf(',') == -1) return parseInt(mtypes); - var s=mtypes.split(','); - var found=0; - var doubl=0; - var maxfound=0; - - for (i=0; i < s.length; i++) { - var k=parseInt(s[i]); - if (k > maxfound) { - found=i + 1; - maxfound=k; - doubl=0; - } else { - if (k == maxfound) {doubl=1;} - } - } - if (doubl) {return 0}; - - return found; - } - return 0; -} -// Для магии. Заголовок, название скрипта, название магии, номер вещицы в рюкзаке, логин по умолчанию, описание доп. поля -function magicklogin(title, script, magickname, n, defaultlogin, extparam, mtype) { - var s = ''; - if (extparam != null && extparam != '') { - s = s + ''; - } - s = s + '
'+ - 'Укажите логин персонажа:
(можно щелкнуть по логину в чате)
'+extparam+'
'; - s = crtmagic(mtype, title, s); - document.all("hint4").innerHTML = s; - document.all("hint4").style.visibility = "visible"; - document.all("hint4").style.left = 100; - document.all("hint4").style.zIndex = 200; - document.all("hint4").style.top = document.body.scrollTop+50; - document.all("param").focus(); - Hint3Name = 'param'; -} - -// Магия -function UseMagick(title, script, name, extparam, n, extparam2, mtype) { - var image = name; - var path = ('' + name).split('/'); - name = path[ path.length - 1 ]; - if ((extparam != null)&&(extparam != '')) { - - var t1='text',t2='text'; - - if (extparam.substr(0,1) == "!") - { - t1='password'; - extparam=extparam.substr(1,extparam.length); - } - - var s = ''; - if (extparam2 != null && extparam2 != '') { - if (extparam2.substr(0,1) == "!") - { - t2='password'; - extparam2=extparam2.substr(1,extparam2.length); - } - s = s + ''; - } - s += '
'+ - extparam + ':
'+extparam2+':
'; - s = crtmagic(mtype, title, s); - document.all("hint4").innerHTML = s; - document.all("hint4").style.visibility = "visible"; - document.all("hint4").style.left = 100; - document.all("hint4").style.zIndex = 200; - document.all("hint4").style.top = document.body.scrollTop+50; - document.all("param").focus(); - Hint3Name = 'param'; - } else { - dialogconfirm('Подтверждение', script, '
Использовать сейчас?
'+ - '', mtype); - } -} - -// Закрывает окно ввода логина -function closehint3() -{ - top.is_qlaunch = 0; - document.all("hint4").style.visibility="hidden"; - Hint3Name=''; -} - -// Для боевой магии. Заголовок, название магии, номер вещицы в рюкзаке -function Bmagicklogin (title, magickname, n, defaultlogin, extparam, mtype) { - if (defend==false) { - defend=-1; -// errmess("Блок не выбран."); return false; - } - - var s = ''; - if (extparam != null && extparam != '') { - s = s + ''; - } - s = s + '
'+ - 'Укажите логин персонажа:
(можно щелкнуть по логину в чате)
'+extparam+'
'; - s = crtmagic(mtype, title, s); - - document.all("hint4").innerHTML= s; - document.all("hint4").style.visibility = "visible"; - document.all("hint4").style.left = 100; - document.all("hint4").style.zIndex = 200; - document.all("hint4").style.top = 60; - document.all("param").focus(); - Hint3Name = 'param'; -} - -// Магия -function BUseMagick(name, extparam, n, mtype) { - if (defend==false) { - defend=-1; -// errmess("Блок не выбран."); return false; - } - - if ((extparam != null)&&(extparam != '')) { - var s = prompt(extparam+':', ''); - if ((s != null)&&(s != '')) { - re = /\%/g; s=s.replace(re, "%25"); - re = /\+/g; s=s.replace(re, "%2B"); - re = /\#/g; s=s.replace(re, "%23"); - re = /\?/g; s=s.replace(re, "%3F"); - re = /\&/g; s=s.replace(re, "%26"); - window.location.href='/battle.pl?use='+name+'¶m='+s+'&n='+n+'&mdefend='+defend+'&enemy='+enemy+'&myid='+myid; - } - } else { - dialogconfirm('Подтверждение', '/battle.pl', '
Использовать сейчас?
'+ - '', mtype); - } -} - - - -function crtmagic(mtype, title, body, subm, noclose) { - return crtmagic_full(mtype, title, body, subm, noclose, 270, 0); -} -function crtmagic_full(mtype, title, body, subm, noclose, dx, dy) { -//name, XYX, X1-X2-Y2, pad.LRU - mtype=foundmagictype(mtype); - -var names=new Array( -'neitral',17, 6, 14, 17, 14, 7,0,0, 3, -'fire', 57, 30, 33, 20, 21, 14, 11, 12, 0, -'water', 57, 30, 33, 20, 21, 14, 11, 12, 0, -'air', 57, 30, 33, 20, 21, 14, 11, 12, 0, -'earth', 57,30, 33, 20, 21, 14, 11, 12, 0, -'white', 51, 25, 46, 44, 44, 10, 5, 5, 0, -'gray', 51, 25, 46, 44, 44, 10, 5, 5, 0, -'black', 51, 25, 46, 44, 44, 10, 5, 5, 0); -var colors=new Array('B1A993','DDD5BF', 'ACA396','D3CEC8', '96B0C6', 'BDCDDB', 'AEC0C9', 'CFE1EA', 'AAA291', 'D5CDBC', 'BCBBB6', 'EFEEE9', '969592', 'DADADA', '72726B', 'A6A6A0'); - -while (body.indexOf('#IMGSRC#')>=0) body = body.replace('#IMGSRC#', 'http://img.combats.com/i/misc/dmagic/'+names[mtype*10]+'_30.gif'); -var s=''+ - ''+ - ''+ -''+ -'
'+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'+ - ''+ - ''+ - (names[mtype*10+7]?'':'')+ - ''+ - ''+ - ''+ - (names[mtype*10+8]?'':'')+ - ''+ - '
  '+ - ''+ - ''+ - ''+ - ''+ - '
'+ - '
'+title+ - ' 
'+ - '
'+body+ - '
  
'+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'; - - return s; -} - - diff --git a/js/gameEngine.js b/js/gameEngine.js deleted file mode 100644 index 40cb13b..0000000 --- a/js/gameEngine.js +++ /dev/null @@ -1,35 +0,0 @@ - -function qn_win(t,obr) { - $('#qsst').html( - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'+ - '
 '+ - ''+ - '
'+t+'
'+ - ''+ - '
 
' - ); - if(top.qst_sml == '') { - $('#qsst').css('display','block'); - }else{ - if(top.qst_sml != obr) { - $('#mini_qsst').html(''); - } - } - $('#qsst').center(); -} diff --git a/js/inf.0.104.js b/js/inf.0.104.js deleted file mode 100644 index f79fb6c..0000000 --- a/js/inf.0.104.js +++ /dev/null @@ -1,20 +0,0 @@ - -var CtrlPress=false,doc=document; -var rnd=Math.random(), -redHP=0.33, -yellowHP=0.66, -TimerOn=-1, -tkHP, -maxHP, -speed=100, -mspeed=100; -function setHP(a,b,c){ -tkHP=a; -maxHP=b; -vrem=c; -if(TimerOn>=0){ -clearTimeout(TimerOn);TimerOn=-1}setHPlocal()} - -function setHPlocal(){ -if(tkHP>maxHP){tkHP=maxHP;TimerOn=-1 -}else TimerOn=0;var a=Math.round(tkHP)+"/"+maxHP;a=120;var b=Math.round(a/maxHP*tkHP);a=a-b;if(doc.all("HP")){doc.HP1.width=b;doc.HP2.width=a;doc.HP2.display=a?"":"none";doc.HP1.src=tkHP/maxHP0){tkHP+=maxHP/(vrem*60);}if(TimerOn!=-1)TimerOn=setTimeout("setHPlocal()",delay*100)} diff --git a/js/inf.0.96.js b/js/inf.0.96.js deleted file mode 100644 index d120a55..0000000 --- a/js/inf.0.96.js +++ /dev/null @@ -1,119 +0,0 @@ -function NewErrorTrap() { return true; } -function errtrap(nick) -{ - var OldErrorTrap = window.onerror; - window.onerror = NewErrorTrap; - if (window.opener) { // && window.opener.top.delay) { - document.write('Приватное сообщение'); - } - if (document.log != null) { window.top.location="/index.htm"; } - window.onerror = OldErrorTrap; -} - -function fastshow (content) { - var el = document.getElementById("mmoves"); - var o = window.event.srcElement; - if (content!='' && el.style.visibility != "visible") {el.innerHTML = ''+content+'';} - var x = window.event.clientX + document.documentElement.scrollLeft + document.body.scrollLeft + 3; - var y = window.event.clientY + document.documentElement.scrollTop + document.body.scrollTop+5; - el.style.left = x + "px"; - el.style.top = y + "px"; - if (el.style.visibility != "visible") { - el.style.visibility = "visible"; - } -} - -var gift = new Array('','',''); // gift_from_before, gift_from_after, gift_from_anonym; - -function quoteString(str){ - str = str.replace(/\\/g,'\\\\'); - str = str.replace(/\'/g,'\\\''); - str = str.replace(/\"/g,'\\"'); - str = str.replace(/\n/g,'\\n'); - return "'" + str + "'"; -} - -function DrawGift(name, flag, title, text, from, uid, width, height){ - var s = ('');
-  if (text)s+=text+'; - document.writeln(s); -} - - -function DG1(name, flag, title, text, from, uid){ - DrawGift(name, flag, title, text, from, uid, 61, 60); -} - -function DG2(name, flag, title, text, from, uid){ - DrawGift(name, flag, title, text, from, uid, 80, 74); -} - -function DF(name, flag, title, text, from, uid){ - DrawGift(name, flag, title, text, from, uid, 60, 60); -} - -function quote_url(s){ - var from = Array('+', ' ', '#'); - var to = Array('%2B', '+', '%23'); - for(var i=0;i=0) s= s.replace(from[i],to[i]); - return s; -} - -function ShowGift(title, name, img, text, from, y, uid) { - - var el = document.getElementById("mgift"); - var o = window.event.srcElement; - var stitle = (img & 8)? - '' + title + '': - ((img & 2)?'' + title + '': - title); - if (el.style.visibility !='visible'){ - if (uid){ - if (parseInt(uid))from = gift[0] + '' + from + '' + gift[1]; - else from = gift[0] + from + gift[1]; - }else if (from) from = gift[0] + ((from == 'АНТИБК Online')?from:'' + from + '') + gift[1]; - if (!from) from = gift[2]; - document.getElementById("mgift_sign").innerHTML = '' + (text?text+'
':'') + from + '
'; - document.getElementById("mgift_title").innerHTML = '' + stitle + ''; - var eimg = document.getElementById("mgift_pict"); - if (!(img & 6)){ - eimg.innerHTML = '
'+title+'

'; - } else { - var s = ((img & 4)?'middle/':'big/3d'); - eimg.innerHTML = ''; - } - } - var x = 15; - // var y = y; # window.event.clientY + document.documentElement.scrollTop + document.body.scrollTop; - el.style.left = x + "px"; - el.style.top = y + "px"; - if (el.style.visibility != "visible") { - el.style.visibility = "visible"; - } -} - -function hideshow () { - document.getElementById("mmoves").style.visibility = 'hidden'; -} - -function HideGift () { - document.getElementById("mgift").style.visibility = 'hidden'; -} - -function drawDivs(){ - document.writeln(''); - document.writeln(''); - -} - diff --git a/js/jax_dialog.js b/js/jax_dialog.js deleted file mode 100644 index 2dc6e9f..0000000 --- a/js/jax_dialog.js +++ /dev/null @@ -1,138 +0,0 @@ -//------------------------------------ -function MagicInput(options, data, callback){ - this.data = data; - this.options = options; - this._callback = callback; -} - -MagicInput.prototype.toString = function(){ - return 'This is MagicInput object'; -} - -MagicInput.prototype.callback = function(){ - this._callback.apply(this, arguments); -} - -MagicInput.instance = function(el, data, callback){ -// var options = $(el).mapAttributes('mi-', true); - el = $(el); - var options = {}; - options['action'] = el.attr('mi-action'); - options['title'] = el.attr('mi-title'); - options['iface'] = el.attr('mi-iface'); - options['data'] = el.attr('mi-data'); - try{ - $.extend(data, options.data ? $.parseJSON(options.data) : {}); - delete options.data; - options.iface = 'mi' + options.iface.substring(0,1).toUpperCase() + options.iface.substring(1); - return input = new window[options.iface](options, data, callback); - }catch(e){ - console.log('MagicInput::instance ' + e); - throw e; - } -} -//------------------------------------ -function miNone(options, callback){ - miNote.superclass.constructor.apply(this, arguments); - this.callback(); -} -extend(miNone, MagicInput); - -miNone.prototype.toString = function(){ - return 'This is miNone object'; -} -//------------------------------------ -function miNote(options, callback){ - miNote.superclass.constructor.apply(this, arguments); - if(confirm('Eniieuciaaou "'+this.options.title+'" nae?an?')){ - this.callback() - } -} -extend(miNote, MagicInput); - -miNote.prototype.toString = function(){ - return 'This is miNote object'; -} -//------------------------------------ -function miDialog(options, data, callback, content, dialogOptions){ - miDialog.superclass.constructor.apply(this, arguments); - var mi = this; - this.dialog = content.dialog($.extend({},{ - title: this.options.title, - resizable: false, - minHeight: 20, - dialogClass: 'sand-style mi-container', - beforeClose: function(e, ui){ - var tmp = true; - if(1 * $(this).attr('submit')){ - mi._collect.call(mi); - if(tmp = mi._validation.call(mi)){ - return true; - } - } - $(this).attr('submit', 0); - return tmp; - }, - close: function(e, ui){ - if(1 * $(this).attr('submit')){ - mi.callback(); - } - mi.destroy(); - } - }, dialogOptions)) - .on('click','.dialog-submit',function(){ - $(this).closest('.ui-dialog-content').attr('submit', 1).dialog('close') - }) -} -extend(miDialog, MagicInput); - -miDialog.prototype.toString = function(){ - return 'This is ABSTRACT miDialog object'; -} - -miDialog.prototype.destroy = function(){ - this.dialog.dialog('destroy').remove(); -} - -miDialog._oneInput = function(p){ - var i = $('').attr('name',p.name); - if(p.grabber){ - h[p.grabber].set(i); - }else{ - i.select(); - } - return $('
') - .append('') - .append($('
').append(i)); -} - -miDialog.prototype._collect = function(){ - var mi = this; - this.dialog.find('[name]').each(function(){ - var el = $(this); - if(el.is('input[type="checkbox"]')){ - mi.data[el.attr('name')] = ~~el.is(':checked'); - return; - } - mi.data[el.attr('name')] = el.val(); - }) -} - -miDialog.prototype._validation = function(){ - return true; -} - -function miUser(options, data, callback){ - var mi = this; - miUser.superclass.constructor.call(this, options, data, callback, - $('
Укажите логин персонажа :
(можно кликнуть по логину в чате)
') - .append(miDialog._oneInput({name:'victim',grabber:'grabLogin'})), - {width: 250}); -} -extend(miUser, miDialog); - -miUser.prototype._validation = function(){ - this.data.victim = $.trim(this.data.victim); - return miUser.superclass._validation.apply(this) - && this.data.victim.length > 0; -} \ No newline at end of file diff --git a/js/kicke.js b/js/kicke.js deleted file mode 100644 index bf6df04..0000000 --- a/js/kicke.js +++ /dev/null @@ -1,56 +0,0 @@ -function Dialog(t){ - function e(t, e) { - var i = l.outerWidth(!0), n = l.outerHeight(!0), o = $(window).width(), c = $(window).height(); - switch(t) { - case"center": - if("t"==e) return c/2-n/2; - if("l"==e)return o/2-i/2; - break; - case"top": - case"left":return 0; - case"bottom":return c-n; - case"right":return o-i - } - } - - function i() { - var t = s.position.split(","), i = $.trim(t[0]), n = $.trim(t[1]); - l.css({position:"absolute", top:parseInt(i)?i:e(i, "t"), left:parseInt(n)?n:e(n, "l")}) - } - - function n() { - l.draggable({containment:"window", handle:".dialog-header"}) - } - - function o() { - $.each(s.buttons, function(t, e) { - e = $.isFunction(e)?{click:e, value:t}:e, e = $.extend({type:"button"}, e); - var i = e.click; - e.click = function() { - i.apply(this, r, l, arguments) - }, $("", e).appendTo(p) - }) - } - - function c(t) { - var e, i = ["", 0, null, void 0]; - for(e in i) - if(t == i[e])return!0; return!1 - } - if(!jQuery)return alert("Для работы диалогов требуется jQuery библиотека."), !1; - var r = this, a = {position:"center,center", style:{}, title:"", content:"", template:['
','
','','[x]',"
",'
','
',"
"], onopen:$.noop, onclose:$.noop, buttons:!1, autoopen:!0, draggable:!0}, s = $.extend(a, t), l = $(s.template.join("")), d = l.find(".dialog-header"), u = d.find(".dialog-title"), k = l.find(".dialog-content"), p = l.find(".dialog-buttons"), f = d.find(".dialog-close-button"); return 0 == u.length || 0 == d.length || 0 == k.length || 0 == p.length || 0 == f.length ? void alert("Error css classes: dialog-title, dialog-header, dialog-content, dialog-buttons, dialog-close-button not found!"):(this.open =!1, - this.set = function(t, e) { - switch(t) { - case"content": - s.content = e, k.html(e); - break; - case"title": - s.title=e, u.text(e); - break; - case"position": - s.position = e, this.rePosition(); - break; - case"onopen": - $.isFunction(e) && (s.onopen = e); - break; - case"onclose":$.isFunction(e)&&(s.onclose=e);break;case"draggable":"enable"==e?n():"disable"==e&&l.draggable("destroy");break;case"buttons":$.isPlainObject(e)&&!$.isEmptyObject(e)&&(p.show(),s.buttons=e,o())}},this.get=function(t){return s[t]||null},this.rePosition=function(){i()},this.close=function(){r.open=!1,s.onclose.call(r,l),l.hide()},this.show=function(){r.open=!0,s.onopen.call(r,l),l.show()},$("body").append(l),l.hide(),l.css(s.style),c(s.title)||u.html(s.title),f.click(function(){return r.close(),!1}),c(s.content)||k.html(s.content),($.isPlainObject(s.buttons)&&!$.isEmptyObject(s.buttons)||$.isArray(s.buttons)&&s.buttons.length>0)&&o(),$.isEmptyObject(s.buttons)&&p.hide(),i(),s.draggable&&void 0!==$.fn.draggable&&n(),void(s.autoopen&&this.show()))}jQuery&&($.extend({isEmpty:function(t){var e,i=["",0,null,void 0,!1,"null","undefined","false"];for(e in i)if(t==i[e])return!0;return!1},random:function(t,e){return void 0==t||void 0==e?Math.random():Math.ceil(Math.random()*(e-t))+t},isTrue:function(t){return t>$.random(0,1e4)/100},parseTime:function(t){var e=t.split("-");if(e.length>1){var i=e[0]<1?1:e[0],n=e[1]<1?1:e[1];return n=i>n?i+1:n,1e3*$.random(parseInt(i),parseInt(n))}return 1e3*parseInt(e[0]<1?1:e[0])},getButton:function(t,e,i){return e=e||document,i?i&&$(t,e).length>1?$(t,e).eq(i):!1:$(t,e)},getLink:function(t,e,i){return e=e||document,i?i&&$('a:contains("'+t+'")').length>1?$('a:contains("'+t+'")').eq(i):!1:$('a:contains("'+t+'")')}}),$.fn.findInput=function(t){var e=null;return this.each(function(){var i=$(this),n=i.val();-1!==n.search(t)&&(e=i)}),e});var Kicker=function(){function t(){return-1!=top.frames.main.document.location.href.search("battle")}function e(){var t=$("#"+x+"kick-r").is(":checked"),e=$("#"+x+"block-r").is(":checked"),n=0,o={},c=0,r={},a="",s=i($("#"+x+"waittime").val());t?o[0]="r":($("."+x+"kick:checked").each(function(){var t=$(this),e=t.attr("id").split("-").pop(),i=parseInt($("#"+x+"kick-perc-"+e).val());o[e]=i,n+=i}),n>=0&&100>n?a+='
'+m.err_low_perc_kick+"
":n>100&&(a+='
'+m.err_big_perc_kick+"
")),e?r[0]="r":($("."+x+"block:checked").each(function(){var t=$(this),e=t.attr("id").split("-").pop(),i=parseInt($("#"+x+"block-perc-"+e).val());r[e]=i,c+=i}),c>=0&&100>c?a+='
'+m.err_low_perc_block+"
":c>100&&(a+='
'+m.err_big_perc_block+"
")),$.isEmpty(s)&&(a+='
'+m.err_no_waittime+"
"),$.isEmpty(a)?(O.waittime=s,O.kick=o,O.block=r,O.ontimeout=$("#"+x+"ontimeout").val(),f[x+"setting"]=JSON.stringify(O),$("#"+x+"errors").show().html('
Настройки сохранены
').fadeOut(5e3)):$("#"+x+"errors").show().html(a).fadeOut(3e3)}function i(t){var e=t.split("-");if(e.length>1){var i=Math.ceil(e[0])||1,n=Math.ceil(e[1])||i+1;return n=i>=n?i+1:n,i+"-"+n}var i=Math.ceil(e[0])||1;return""+i}function n(){if($.isPlainObject(O.kick)&&!$.isEmpty(O.kick[0])&&($("#"+x+"kick-r").attr("checked",!0),$("."+x+"kick").attr("disabled",!0)),$.isPlainObject(O.block)&&!$.isEmpty(O.block[0])&&($("#"+x+"block-r").attr("checked",!0),$("."+x+"block").attr("disabled",!0)),$.isPlainObject(O.kick)&&!$.isEmptyObject(O.kick)&&$.isEmpty(O.kick[0])){$("#"+x+"kick-r").attr("checked",!1),$("."+x+"kick").attr("disabled",!1);for(var t in O.kick){var e=O.kick[t];$("#"+x+"kick-"+t).attr("checked",!0),$("#"+x+"kick-perc-"+t).val(e)}}if($.isPlainObject(O.block)&&!$.isEmptyObject(O.block)&&$.isEmpty(O.block[0])){$("#"+x+"block-r").attr("checked",!1),$("."+x+"block").attr("disabled",!1);for(var t in O.block){var e=O.block[t];$("#"+x+"block-"+t).attr("checked",!0),$("#"+x+"block-perc-"+t).val(e)}}$("#"+x+"ontimeout").val(O.ontimeout)}function o(){for(var t,e="off"==h.power?"red":"green",i='
',n='
',o="",c=0;c ",n+='
";for(t in w)o+='";var r=['
Состояние: '+m["stat_"+h.power]+"
",'
','
','
Время на удар: сек.
','
По тайму:
",'',"","","","","","","","","
УдарБлок
"+i+""+n+"
"];return r.join("")}function c(){if("off"==h.power)return void clearTimeout(_);var e=$(".m",top.frames.main.document).length;s=$(I,top.frames.main.document).findInput(y.KICK),l=$(I,top.frames.main.document).findInput(y.WIN),d=$(I,top.frames.main.document).findInput(y.DRAW),u=$(I,top.frames.main.document).findInput(y.EXIT),k=$(I,top.frames.main.document).findInput(y.REFRESH);var i=$.parseTime(O.waittime),n=Date.now(),o=n-E;if(t()&&0==e){if($.isEmpty(s))$.isEmpty(l)||"win"!=O.ontimeout?$.isEmpty(d)||"draw"!=O.ontimeout?!$.isEmpty(k)&&o>=i&&(k.click(),E=n):d.click():l.click();else if(o>=i){var p=r(),f=a();$("#A"+p,top.frames.main.document).attr("checked",!0),$("#D"+f,top.frames.main.document).attr("checked",!0),s.click(),E=n}$.isEmpty(u)||u.click()}_=setTimeout(function(){c()},1e3)}function r(){if($.isEmpty(O.kick[0])){var t=!1,e=null;for(var i in O.kick)$.isTrue(O.kick[i])&&(t=!0,e=i);return t?e:r()}return $.random(0,4)}function a(){if(!$.isEmpty(O.block[0]))return $.random(0,4);var t=!1,e=null;for(var i in O.block)$.isTrue(O.block[i])&&(t=!0,e=i);return t?e:a()}var s,l,d,u,k,p=this,f=localStorage,b=(top.frames.main,{myLogin:"",myClass:null,kickScheme:{},kick:{0:"r"},block:{0:"r"},waittime:"1-5",ontimeout:"win"}),h={version:"0.3",power:"off"},m={err_low_perc_kick:"Сумма % ударов меньше 100%.",err_big_perc_kick:"Сумма % ударов больше 100%.",err_low_perc_block:"Сумма % блоков меньше 100%.",err_big_perc_block:"Сумма % блоков больше 100%.",err_kick_len:"Вы не выбрали куда бить.",err_block_len:"Вы не выбрали места блоков.",err_no_waittime:"Вы не указали время на удар.",set_saved:"Настройки сохранены.",stat_on:"Включен",stat_off:"Выключен",status:"Состояние"},v=["в голову","в корпус","в пояс(пах)","по ногам"],g=["головы и корпуса","корпуса и пояса","пояса и ног","головы и ног"],w={"Победа":"win","Ничья":"draw","Ждать":"wait"},y={KICK:"Вперед",WIN:"Я победил",DRAW:"Ничья",EXIT:"Вернуться",REFRESH:"Обновить"},_=-1,E=0,I='input[type="button"], input[type="submit"]',x="kicker-",j=$.isEmpty(f[x+"setting"])?"":JSON.parse(f[x+"setting"]),O=$.extend({},b,j),T=new Dialog({position:"top,left",title:"Автоудар",content:"",onopen:function(){this.set("content",o()),n(),$("#"+x+"status").click(function(){switch(h.power){case"off":h.power="on",$("#"+x+"status").removeClass("red").addClass("green").text("Включен."),c();break;case"on":h.power="off",$("#"+x+"status").removeClass("green").addClass("red").text("Выключен."),clearTimeout(_)}}),$("#"+x+"kick-r").click(function(){$("."+x+"kick").attr("disabled",$(this).is(":checked"))}),$("#"+x+"block-r").click(function(){$("."+x+"block").attr("disabled",$(this).is(":checked"))})},autoopen:!1,buttons:{"Сохранить":function(){e()}}});return this.ShowDialog=function(){T.open||T.show()},p}; diff --git a/js/main_096_ru.js b/js/main_096_ru.js deleted file mode 100644 index f96647b..0000000 --- a/js/main_096_ru.js +++ /dev/null @@ -1,21 +0,0 @@ -function DrawBar(title, id, flags, link_text, link){ - // alert(title + document); - var s ='' + - ''; - s += ''; - if (link_text){ - s += ''; - } - s += '
'; - var sz = 11, num = 1; - var rnd = Math.random(); - s += ''; - if (flags & 1) { - s+= 'Скрыть'; - } else { - s+= 'Показать'; - } - s += '   '+title+':   '+link_text+' 
'; - // window.clipboardData.setData('Text', s); - document.writeln(s); -} diff --git a/js/recoverscroll.js b/js/recoverscroll.js deleted file mode 100644 index 256736a..0000000 --- a/js/recoverscroll.js +++ /dev/null @@ -1,122 +0,0 @@ -var RecoverScroll= -{ - - timer:null, x:0, y:0, actOnHash:false, cookieId:"RecoverScroll", expiry : "", dataCode:0, logged:0, - - start : function( pageIdent, days ) - { - this.installHandler=function(obj,evt,func) { - window.attachEvent ? obj.attachEvent(evt,func) : obj.addEventListener(evt.replace(/^on/i,""),func,false); - return func; - } - this.installHandler( window, 'onload', function(){ RecoverScroll.init( pageIdent, days ); } ); - }, - - init : function( pageName, days ) - { - var dt, duration; - - if( typeof window.pageXOffset != 'undefined' ) - this.dataCode = 1; - else - if( document.documentElement ) - this.dataCode = 3; - else - if( document.body && typeof document.body.scrollTop != 'undefined' ) - this.dataCode = 2; - - if( pageName ) - this.cookieId = pageName.replace( /[\s\=\;\,]/g, '_' ); - - if( days && ( duration = parseInt( days ) ) != NaN ) - { - dt = new Date(); - - dt.setDate( dt.getDate() + duration ); - - this.expiry = ";expires=" + dt.toUTCString(); - } - - this.installHandler( window, 'onscroll', function(){ RecoverScroll.reset() } ); - - this.go(); - }, - - go : function( ) - { - var sx, sy, offsetData; - - if( ( window.location.hash == "" || this.actOnHash ) -// && location.search.length == 0 - && ( offsetData = this.readCookie( this.cookieId )) != "" - && ( offsetData = offsetData.split('|') ).length == 4 - && !isNaN( sx = Number( offsetData[ 1 ] ) ) && !isNaN( sy = Number( offsetData[3] ) ) ) - { - - if(!!window.SoftScroll && SoftScroll.scrollTo) - { SoftScroll.init(); SoftScroll.scrollTo(sx, sy); } - else - window.scrollTo(sx, sy); - } - - this.record(); - }, - - sf : function( str ) - { - return unescape(str).replace(/(.)(.*)/, function(a,b,c){return c+b;}); - }, - - reset : function() - { - clearTimeout( this.timer ); - this.timer = setTimeout( function(){ RecoverScroll.record(); }, 50 ); - }, - - record : function() - { - var cStr; - - this.getScrollData(); - - this.setTempCookie( this.cookieId, cStr='x|'+this.x+'|y|'+this.y ); - }, - - setTempCookie : function(cName, cValue) - { - document.cookie = cName + "=" + cValue + this.expiry; - }, - - readCookie : function(cookieName) - { - var cValue=""; - - if(typeof document.cookie!='undefined') - cValue=(cValue=document.cookie.match(new RegExp("(^|;|\\s)"+cookieName+'=([^;]+);?'))) ? cValue[2] : ""; - - return cValue; - }, - - hash : function() - { - this.actOnHash = true; - }, - - getScrollData : function() - { - switch( this.dataCode ) - { - case 3 : this.x = Math.max(document.documentElement.scrollLeft, document.body.scrollLeft); - this.y = Math.max(document.documentElement.scrollTop, document.body.scrollTop); - break; - - case 2 : this.x = document.body.scrollLeft; - this.y = document.body.scrollTop; - break; - - case 1 : this.x = window.pageXOffset; this.y = window.pageYOffset; break; - } - }, - - installHandler : function(){}, -} diff --git a/js/win_add.js b/js/win_add.js deleted file mode 100644 index 2573537..0000000 --- a/js/win_add.js +++ /dev/null @@ -1,201 +0,0 @@ -isIE = document.all; -isNN = !document.all&&document.getElementById; -isN4 = document.layers; -isHot = false; -document.onmousedown = ddInit; -document.onmouseup = Function("ddEnabled=false"); - -function ddInit(e) { - topDog = isIE ? "BODY" : "HTML"; - whichDog = isIE ? document.all.theLayer : document.getElementById("theLayer"); - hotDog = isIE ? event.srcElement : e.target; - while(hotDog.id != "titleBar"&&hotDog.tagName != topDog) { - hotDog = isIE ? hotDog.parentElement : hotDog.parentNode; - } - if(hotDog.id == "titleBar") { - offsetx = isIE ? event.clientX : e.clientX; - offsety = isIE ? event.clientY : e.clientY; - nowX = parseInt(whichDog.style.left); - nowY = parseInt(whichDog.style.top); - ddEnabled = true; - document.onmousemove = dd; - } -} - -function dd(e) { - if(!ddEnabled) return; - whichDog.style.left = isIE ? nowX+event.clientX-offsetx : nowX+e.clientX-offsetx; - whichDog.style.top = isIE ? nowY+event.clientY-offsety : nowY+e.clientY-offsety; - return false; -} - -function mousePageXY(e) { - var x = 0, y = 0; - if(e.pageX || e.pageY) { - x = e.pageX; - y = e.pageY; - } else if (e.clientX || e.clientY) { - x = e.clientX + (document.documentElement.scrollLeft || document.body.scrollLeft) - document.documentElement.clientLeft; - y = e.clientY + (document.documentElement.scrollTop || document.body.scrollTop) - document.documentElement.clientTop; - } - return {"x":x, "y":y}; -} - -var win = { - winc:{}, - wsdr:null, - scor:{}, - openw:function(id, title, text, date, type, style) { - if($('#win_'+id).attr('id') == undefined) { - this.add(id, title, text, date, type, 1, ''); - } - }, - WstartDrag:function(id) { - $('#wupbox').css({'display':'block', 'cursor':'move'}); - this.wsdr = id; - $('.w1').css({'z-index':1102}); - $('#win_'+id).css({'z-index':1103}); - delete cm; - }, - WmoveDrag:function(e) { - var x = mousePageXY(e)['x'], y = mousePageXY(e)['y']; - if(this.scor.x == undefined) { - this.scor.x = x; - this.scor.y = y; - this.scor.x2 = unpx($('#win_'+this.wsdr).css('left')); - this.scor.y2 = unpx($('#win_'+this.wsdr).css('top')); - } - x = x-this.scor.x; - y = y-this.scor.y; - x += this.scor.x2; - y += this.scor.y2; - if(x < 9) { x = 9; } - if(x + $('#win_'+this.wsdr).width() > $(window).width() - 9) { - x = $(window).width() - 9 - $('#win_'+this.wsdr).width(); - } - if(y < 35) { y = 35; } - if(y + $('#win_'+this.wsdr).height() > $(window).height() - 35) { - y = $(window).height() - 35 - $('#win_'+this.wsdr).height(); - } - $('#win_'+this.wsdr).css({'top':y+'px','left':x+'px'}); - }, - WstopDrag:function() { - $('#wupbox').css({'display':'none', 'cursor':'move'}); - this.wsdr = null; - this.scor = {}; - }, - add:function(id, title, text, date, type, style, css) { - var nw = ''; - if($('#win_'+id).attr('id') == undefined) { - var acts = {}; - - if(date.usewin != undefined){ - acts[0] = 'onmouseup="'+date.usewin+'"'; - } - - if(date.n != undefined){ - text += '
'+date.n+'
'; - } - - var kyps = ['', '']; - - if(type == 0) { - nw = text; - } else if(type == 1) { - nw = text; - } else if(type == 2) { - nw = '
'+text+'

'; - kyps[0] = ''+date.a1+';win.closew(\\\''+id+'\\\');win.addaction(0,\\\'\\\');'; - } else if(type == 3) { - nw = '
'+text+'
'; - kyps[0] = ''+date.a1+';win.closew(\\\''+id+'\\\');win.addaction(0,\\\'\\\');'; - } else if(type == 4) { - nw = text[0]; - } - - if(date.d != undefined) { - nw = nw+date.d; - } - - nw = '
'+nw+'
'; - - if(title != '') { - nw = '
'+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'+title+'
'+ - '
'+nw; - } - - nw = ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - ''+ - '
'+nw+'
'; - - nw = '
'+nw+'
'; - - $('#windows').html($('#windows').html()+nw); - $('#win_'+id).center(); - if(type == 2 || type == 3) { - if(type == 2) { - $('#winyesbtnfox'+id).focus(); - } - } - } - delete nw; - }, - addaction:function(nm, vl) { - key_actions[nm] = vl; - if(nm != 2) { - key_actions[2] = 1; - } - }, - closew:function(id) { - $('#win_'+id).html(''); - $('#win_'+id).remove(); - } -} - -function hideMe() { - if (isIE||isNN) { - whichDog.style.visibility = "hidden"; - } else if (isN4) { - document.theLayer.visibility = "hide"; - } -} - -function showForm(title, text, input_name, input_value, hidden_name, hidden_value, action) { - document.getElementById('ftitle').innerHTML = title; - document.getElementById('ftext').innerHTML = text; - document.getElementById('finput').name = input_name; - document.getElementById('finput').value = input_value; - document.getElementById('fhinput').name = hidden_name; - document.getElementById('fhinput').value = hidden_value; - if(action != ""){ - document.getElementById('fuse').action = action; - } - - whichDog.style.left = (document.body.clientWidth - 240)/2; - if(isIE||isNN) { - whichDog.style.visibility = "visible"; - } else if (isN4) { - document.theLayer.visibility = "show"; - } - document.getElementById('finput').focus(); -} \ No newline at end of file diff --git a/kartabc.html b/kartabc.html deleted file mode 100644 index 14c7aec..0000000 --- a/kartabc.html +++ /dev/null @@ -1,1003 +0,0 @@ - -Карта Башни Смерти - - - - - - - -
- (цифры в скобках - - время задержки в комнате) -
-
Карта - Башни Смерти
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                 
       Восточная крыша (20) - - - - - - - -
 
 
 
Бойница (15)  Келья 3 (15) Келья 2 (15)   
        - - - - - -
   
    - - - - - -
   
  - - - - - -
   
   
       Западная крыша 2 (20) Келья 4 (15) - - - - - - - -
 
 
 
Келья 1 (15) - - - - - - - -
 
 
 
Служебная комната (25)   
        - - - - - -
  .
  - - - - - -
   
    - - - - - -
   
   
   Зал Отдыха 2 (20)   Западная крыша 1 (20) - - - - - - - -
 
 
 
Выход на крышу (20)  Зал Статуй 2 (30) - - - - - - - -
 
 
 
Храм (25) - - - - - - - -
 
 
 
Восточная комната (20) 
    - - - - - -
   
        - - - - - -
   
     
   Зал Отдыха 1 (20) Старый Зал 2 (25) - - - - - - - -
 
 
 
Старый Зал 1 (25) - - - - - - - -
 
 
 
Красный Зал 3 (35) - - - - - - - -
 
 
 
Зал Статуй 1 (35) - - - - - - - -
 
 
 
Зал Статуй 3 (35) - - - - - - - -
 
>
 
Трапезная 3 (15) 
    - - - - - -
   
  - - - - - -
   
    - - - - - -
   
  - - - - - -
   
    - - - - - -
   
 
 Трапезная 3 (15) Зал Ожиданий (20) Оружейная (25) Красный Зал - Окна (20) - - - - - - - -
 
 
 
Красный Зал (35) - - - - - - - -
 
 
 
Гостинная (40) - - - - - - - -
 
 
 
Трапезная 1 (15) Внутренний
Двор (20)
 
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
     
 Внутренний
Двор (20)
- - - - - - - -
 
 
 
Внутренний
Двор - Вход - (20)
 Желтый Коридор (20) - - - - - - - -
 
 
 
Мраморный
Зал 1 (35)
 Красный Зал 2 (40) - - - - - - - -
 
 
 
Библиотека 1 (35) - - - - - - - -
 
 
 
Трапезная 2 (15)   
  - - - - - -
   
    - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
     
 Проход Внутреннего Двора -(20) - - - - - - - -
 
<
 
Комната с Камином (20) - - - - - - - -
 
 
 
Библиотека 3 (35) Выход из Мраморного Зала -(20) Красный Зал - Корридор (20)  Лестница в Подвал 1 (15)     
  - - - - - -
   
    - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
     
 Южный Внутренний
Двор -(20)
- - - - - - - -
 
 
 
Трапезная 4 (15) - - - - - - - -
 
 
 
Мраморный
Зал 3 (40)
- - - - - - - -
 
 
 
Мраморный
Зал 2 (40)
- - - - - - - -
 
 
 
Картинная Галерея 1 (40) Лестница в Подвал 2 (15)     
  - - - - - -
   
    - - - - - -
   
  - - - - - -
   
  - - - - - -
   
  - - - - - -
   
     
 Проход Внутреннего Двора 2 - (20) - - - - - - - -
 
 
 
Внутренний Двор - Выход (20) - - - - - - - -
 
 
 
Библиотека 2 (35) - - - - - - - -
 
 
 
Картинная Галерея 3 (40) - - - - - - - -
 
 
 
Картинная Галерея 2 (40) Лестница в Подвал 3 (15)     
  - - - - - -
   
      - - - - - -
   
  - - - - - -
   
  - - - - - -
   
     
 Терраса (20)     Оранжерея (20) - - - - - - - -
 
 
 
Зал Ораторов (35) Лестница в Подвал 4 (15)     
  - - - - - -
   
           - - - - - -
   
     
 Темная
Комната (15)
       Винный погреб (20) - - - - - - - -
 
 
 
Комната в Подвале (20) - - - - - - - -
 
 
 
Подвал 1 (20)   
                 


- - -
- - diff --git a/lib/exp.html b/lib/exp.html deleted file mode 100644 index 8520d83..0000000 --- a/lib/exp.html +++ /dev/null @@ -1,1081 +0,0 @@ - - - - - - - - -
-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
000305
 12010
24511
37512
101103+1410
.
- .
- .
116010
221511
328012
435014
204103+1820
- .153010
267012
383014
495018
51100112
3013003+11630
- .1145011
2165015
31850110
42050115
52200120
4025005+12560
. -
, - .
- /.
- .
1290013
23350110
33800115
44200120
54600125
5050003+140120
 1600016
27000120
38000130
49000140
510000140
611000140
712000150
60125003+180180
- .11400019
215500125
317000145
419000145
521000145
623000155
727000145
70300005+190 300
- .

- - -.
16000011
2750001100
31500001150
4175000150
52000001100
6225000150
72500001100
8260000150
92800001100
803000005+1300450
-
\ No newline at end of file diff --git a/main.php b/main.php index f1bb172..b20c332 100644 --- a/main.php +++ b/main.php @@ -1483,8 +1483,7 @@ if (isset($_GET['edit'])) {
Уровень:
- Опыт: ()
+ Опыт: ()
Побед:
Поражений:
Ничьих:
diff --git a/pole.php b/pole.php index 582211f..950c30a 100644 --- a/pole.php +++ b/pole.php @@ -22,7 +22,6 @@ -
diff --git a/relikt.php b/relikt.php index 553da48..50b3049 100644 --- a/relikt.php +++ b/relikt.php @@ -270,7 +270,15 @@ if ($user['klan'] != '') {
- + query('SELECT `id`, `ekr` FROM `bank` WHERE `id` = ?i ', $id)->fetch_assoc(); + if (isset($bank['id'])) { + echo '
СчётБанковский счёт № {$id}
На счету ' . $bank['ekr'] . ' еврокредитов.
'; + } else { + echo 'У вас нет счета в банке.'; + } + ?>
diff --git a/stat_battle.php b/stat_battle.php index 9e4ebdf..f2f30d5 100644 --- a/stat_battle.php +++ b/stat_battle.php @@ -14,7 +14,6 @@ .b8 { font-weight: bold; color: #842B61; } .b9 { font-weight: bold; color: navy; } -

Статистика боя

diff --git a/tab.php b/tab.php deleted file mode 100644 index 3b403a4..0000000 --- a/tab.php +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - - - -





- -
-Цена 1 - 0
-Цена 2 - 0
-Цена 3 - 0
-
- - - - \ No newline at end of file diff --git a/tab.png b/tab.png deleted file mode 100644 index 1082dd9..0000000 Binary files a/tab.png and /dev/null differ diff --git a/towerin.php b/towerin.php index 76a8832..4987c7e 100644 --- a/towerin.php +++ b/towerin.php @@ -273,7 +273,6 @@ if($user['hp'] <= 0) { header('Location: tower.php'); die(); } - -