2023-03-31 18:42:06 +00:00
< ? php
2022-06-06 21:30:34 +00:00
if ( ! defined ( 'GAME' )) {
die ();
}
/*
2023-01-10 16:29:32 +00:00
Прием : Заряд : Шок
2022-06-06 21:30:34 +00:00
*/
$pvr = array ();
//$pvr['mg'] = mysql_fetch_array(mysql_query('SELECT * FROM `eff_users` WHERE `uid` = "'.$btl->users[$btl->uids[$this->ue['id']]]['id'].'" AND `v2` = "260" AND `user_use` = "'.$u->info['id'].'" ORDER BY `id` DESC LIMIT 1'));
$pvr [ 'mg' ] = mysql_fetch_array ( mysql_query ( 'SELECT * FROM `eff_users` WHERE `uid` = "' . $btl -> users [ $btl -> uids [ $this -> ue [ 'id' ]]][ 'id' ] . '" AND `v2` = "260" ORDER BY `id` DESC LIMIT 1' ));
if ( isset ( $pvr [ 'mg' ][ 'id' ]) ) {
2023-01-10 16:29:32 +00:00
//Действие при клике
2022-06-06 21:30:34 +00:00
//$pvr['hp'] = floor(144/3*$pvr['mg']['x']);
/*$pvr['hp'] = 1;*/
//
$pvr [ 'data' ] = $this -> lookStatsArray ( $pvr [ 'mg' ][ 'data' ]);
//
/**/
if ( $pvr [ 'data' ][ 'add_mg2static_points' ][ 0 ] < 1 ) {
2023-01-10 16:29:32 +00:00
echo '<font color=red><b>Статика не собрала достаточного количества зарядов</b></font>' ;
2022-06-06 21:30:34 +00:00
$cup = true ;
} else {
$prv [ 'text' ] = $btl -> addlt ( 1 , 21 , $btl -> users [ $btl -> uids [ $u -> info [ 'id' ]]][ 'sex' ] , NULL );
2023-01-10 16:29:32 +00:00
//Цвет приемаы
2022-06-06 21:30:34 +00:00
if ( $pvr [ 'promah' ] == false ) {
if ( $pvr [ 'krit' ] == false ) {
$prv [ 'color2' ] = '006699' ;
2023-01-10 16:29:32 +00:00
if ( isset ( $btl -> mcolor [ $btl -> mname [ 'воздух' ]])) {
$prv [ 'color2' ] = $btl -> mcolor [ $btl -> mname [ 'воздух' ]];
2022-06-06 21:30:34 +00:00
}
$prv [ 'color' ] = '000000' ;
2023-01-10 16:29:32 +00:00
if ( isset ( $btl -> mncolor [ $btl -> mname [ 'воздух' ]])) {
$prv [ 'color' ] = $btl -> mncolor [ $btl -> mname [ 'воздух' ]];
2022-06-06 21:30:34 +00:00
}
} else {
$prv [ 'color2' ] = 'FF0000' ;
$prv [ 'color' ] = 'FF0000' ;
}
} else {
$prv [ 'color2' ] = '909090' ;
$prv [ 'color' ] = '909090' ;
}
2023-01-10 16:29:32 +00:00
//Запрещаем юзать прошлый прием кол-во ходов равно уровню заряда
$this -> addPriem ( $this -> ue [ 'id' ], 264 , 'add_notuse_last_pr=' . ( $this -> ue [ 'last_pr' ]) . '' , 0 , 77 , $pvr [ 'data' ][ 'add_mg2static_points' ][ 0 ], $u -> info [ 'id' ], 1 , 'зарядшок' , 0 , 0 , 1 );
2022-06-06 21:30:34 +00:00
2023-01-10 16:29:32 +00:00
//Удаляем 1 негативный эффект
2022-06-06 21:30:34 +00:00
$pvr [ 'no' ] = ' AND `a`.`v2` != 201 AND `a`.`overType` != 100 AND `a`.`overType` != 101 AND `a`.`overType` != 105' ;
$pvr [ 'sp' ] = mysql_query ( 'SELECT `a`.* FROM `eff_users` AS `a` LEFT JOIN `priems` AS `b` ON `b`.`id` = `a`.`v2` WHERE `a`.`uid` = "' . $this -> ue [ 'id' ] . '" AND `a`.`delete` = 0 AND `a`.`v1` = "priem" ' . $pvr [ 'no' ] . ' AND `b`.`neg` = 0 LIMIT 1' );
$pvr [ 'pl' ] = mysql_fetch_array ( $pvr [ 'sp' ]);
$pvr [ 'pl' ][ 'priem' ] = mysql_fetch_array ( mysql_query ( 'SELECT * FROM `priems` WHERE `id` = "' . $pvr [ 'pl' ][ 'v2' ] . '" LIMIT 1' ));
if ( isset ( $pvr [ 'pl' ][ 'priem' ]) ) {
$btl -> delPriem ( $pvr [ 'pl' ], $btl -> users [ $btl -> uids [ $this -> ue [ 'id' ]]], 100 );
}
2023-01-10 16:29:32 +00:00
$prv [ 'text2' ] = '{tm1} ' . $prv [ 'text' ] . ' на {u2}.' ;
2022-06-06 21:30:34 +00:00
$btl -> priemAddLog ( $id , 1 , 2 , $u -> info [ 'id' ], $this -> ue [ 'id' ],
2023-01-10 16:29:32 +00:00
'<font color^^^^#' . $prv [ 'color2' ] . '>Заряд: Шок</font>' ,
2022-06-06 21:30:34 +00:00
$prv [ 'text2' ],
( $btl -> hodID + 1 )
);
2023-01-10 16:29:32 +00:00
//Добавляем прием
2022-06-06 21:30:34 +00:00
//$this->addEffPr($pl,$id);
2023-01-10 16:29:32 +00:00
//$this->addPriem($this->ue['id'],$pl['id'],'atgm='.($pvr['hp']/16).'',2,77,4,$u->info['id'],3,'оледенение',0,0,1);
2022-06-06 21:30:34 +00:00
2023-01-10 16:29:32 +00:00
//Удаляем оледенение
2022-06-06 21:30:34 +00:00
$pvr [ 'mg' ][ 'priem' ][ 'id' ] = $pvr [ 'mg' ][ 'id' ];
//$btl->delPriem($pvr['mg'],$btl->users[$btl->uids[$this->ue['id']]],2);
$pvr [ 'edt' ] = $u -> lookStats ( $pvr [ 'mg' ][ 'data' ]);
$pvr [ 'edt' ][ 'add_zm2proc' ] = 0 ;
$pvr [ 'edt' ][ 'add_mg2static_points' ] = 0 ;
$pvr [ 'edt' ] = $u -> impStats ( $pvr [ 'edt' ]);
mysql_query ( 'UPDATE `eff_users` SET `x` = 1, `data` = "' . $pvr [ 'edt' ] . '" WHERE `id` = "' . $pvr [ 'mg' ][ 'id' ] . '" LIMIT 1' );
2023-01-10 16:29:32 +00:00
//Отнимаем тактики
2022-06-06 21:30:34 +00:00
$this -> mintr ( $pl );
}
} else {
2023-01-10 16:29:32 +00:00
echo '<font color=red><b>Н а персонаже нет Статики (Вашего заклятия)</b></font>' ;
2022-06-06 21:30:34 +00:00
$cup = true ;
}
unset ( $pvr );
?>