2022-06-06 21:30:34 +00:00
|
|
|
|
<?
|
|
|
|
|
if(!defined('GAME'))
|
|
|
|
|
{
|
|
|
|
|
die();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($st['usefromfile']=='pirogi2' && $u->info['battle'] > 0 && $u->info['hpNow'] >= 1)
|
|
|
|
|
{
|
|
|
|
|
if($btl->info['team_win'] != -1 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$u->error = 'Использовать пирожки возможно только во время боя';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
}else{
|
|
|
|
|
$bu = mysql_fetch_array(mysql_query('SELECT * FROM `pirogi` WHERE `btl` = "'.$u->info['battle'].'" AND `uid` = "'.$u->info['id'].'" LIMIT 1'));
|
|
|
|
|
if(isset($bu['id'])) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$u->error = 'Нельзя использовать пирожки так часто! Осталось ходов: '.$bu['hod'].'';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
}else{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if( $itm['magic_inci'] == 446 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Живая Вода</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"10", "327", "invoke_kar3_lifew.gif", 22, "'.$u->info['id'].'", "Живая Вода", "atgm=30", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","25")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 449 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Сушеный Мухомор</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"5", "328", "invoke_kar3_mush.gif", 22, "'.$u->info['id'].'", "Сушеный Мухомор", "add_m10=25|add_m11=25", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","10")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 450 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Мешочек Пыли</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"5", "329", "invoke_kar3_dust.gif", 22, "'.$u->info['id'].'", "Мешочек Пыли", "add_m5=300|add_m4=300", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","10")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 451 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Отвар когтей ПГ</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"5", "330", "invoke_kar3_potpg.gif", 22, "'.$u->info['id'].'", "Отвар когтей ПГ", "add_za=200|add_zma=200", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","10")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 482 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Точильный Камень</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"10", "332", "invoke_kar3_mush.gif", 22, "'.$u->info['id'].'", "Точильный Камень", "add_m10=75", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","20")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 483 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Волшебный Эликсир</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"5", "333", "vampiric_potion.gif", 22, "'.$u->info['id'].'", "Волшебный Эликсир", "atgm=100", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","20")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 484 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Цепь Защитника</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"2", "334", "effcep.gif", 22, "'.$u->info['id'].'", "Цепь Защитника", "add_zaproc=100|add_zmproc=100", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","20")');
|
|
|
|
|
}
|
|
|
|
|
}elseif( $itm['magic_inci'] == 485 ) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = ' В результате персонаж "{u2}" был подвержен действию "<b>Эликсир Безумного Критовика</b>".';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
//
|
|
|
|
|
$txt = '';
|
|
|
|
|
if( isset($mgp['id']) ) {
|
|
|
|
|
$mgp['x']++;
|
|
|
|
|
$mgp['hod']++;
|
|
|
|
|
$txt = ' (x'.$mgp['x'].')';
|
|
|
|
|
}
|
|
|
|
|
if(isset($mgp['id'])) {
|
|
|
|
|
mysql_query('UPDATE `eff_users` SET `hod` = "'.$mgp['hod'].'", `x` = "'.$mgp['x'].'" WHERE `id` = "'.$mgp['id'].'" LIMIT 1');
|
|
|
|
|
}else{
|
|
|
|
|
mysql_query('INSERT INTO `eff_users` (
|
|
|
|
|
`hod`, `v2`, `img2`, `id_eff`, `uid`, `name`, `data`, `overType`, `timeUse`, `v1`, `user_use`
|
|
|
|
|
) VALUES (
|
2023-01-10 16:29:32 +00:00
|
|
|
|
"10", "335", "raaage.gif", 22, "'.$u->info['id'].'", "Эликсир Безумного Критовика", "add_m3=75", 0, "77", "priem", "'.$u->info['id'].'"
|
2022-06-06 21:30:34 +00:00
|
|
|
|
)');
|
|
|
|
|
mysql_query('INSERT INTO `pirogi` (`btl`,`uid`,`time`,`item_id`,`var`,`hod`) VALUES ("'.$u->info['battle'].'","'.$u->info['id'].'","'.time().'","'.$itm['item_id'].'","'.$itm['name'].'","20")');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if($u->info['sex']==1) {
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = '{u1} применила заклинание "<b>'.$itm['name'].'</b>". '.$txt.'';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
}else{
|
2023-01-10 16:29:32 +00:00
|
|
|
|
$txt = '{u1} применил заклинание "<b>'.$itm['name'].'</b>". '.$txt.'';
|
2022-06-06 21:30:34 +00:00
|
|
|
|
}
|
|
|
|
|
$lastHOD = mysql_fetch_array(mysql_query('SELECT * FROM `battle_logs` WHERE `battle` = "'.$u->info['battle'].'" ORDER BY `id_hod` DESC LIMIT 1'));
|
|
|
|
|
$id_hod = $lastHOD['id_hod'];
|
|
|
|
|
if($lastHOD['type']!=6) {
|
|
|
|
|
$id_hod++;
|
|
|
|
|
}
|
|
|
|
|
//
|
|
|
|
|
mysql_query('INSERT INTO `battle_logs` (`time`,`battle`,`id_hod`,`text`,`vars`,`zona1`,`zonb1`,`zona2`,`zonb2`,`type`) VALUES ("'.time().'","'.$u->info['battle'].'","'.($id_hod).'","{tm1} '.$txt.'","login1='.$u->info['login'].'||t1='.$u->info['team'].'||time1='.time().'||login2='.$u->info['login'].'||t2='.$u->info['team'].'||time2='.time().'","","","","","6")');
|
|
|
|
|
//
|
|
|
|
|
mysql_query('UPDATE `items_users` SET `iznosNow` = `iznosNow` + 1 WHERE `id` = "'.$itm['id'].'" LIMIT 1');
|
|
|
|
|
mysql_query('DELETE FROM `items_users` WHERE `iznosNOW` >= `iznosMAX` AND `id` = "'.$itm['id'].'" LIMIT 1');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
?>
|