diff --git a/src/arenas/Battleship/act.php b/src/arenas/Battleship/act.php index 1acd599..8febf92 100644 --- a/src/arenas/Battleship/act.php +++ b/src/arenas/Battleship/act.php @@ -242,10 +242,15 @@ switch ($_POST['act']){ break; case "fight": if($_POST['fullLogs'] == 'true'){ - $fullLogs = true; + $WantFullLogs = true; }else{ - $fullLogs = false; + $WantFullLogs = false; } + + if(!isset($fullLogs)){ + $fullLogs = ""; + } + if(count($_SESSION['strikes'][1]) == count($_SESSION['strikes'][2])){ //player 1 has to fight $currentPlayer=1; @@ -281,12 +286,12 @@ switch ($_POST['act']){ ); $anwserPlayer=get_IA_Response($currentBot['url'],$botParamsToSend); $anwserPlayerJson=$anwserPlayer['responseArr']; - if($fullLogs){ - $fullLogs='Arena send to '.$currentBot['name'].''.htmlentities($anwserPlayer['messageSend']).'
+ if($WantFullLogs){ + $fullLogs.='Arena send to '.$currentBot['name'].''.htmlentities($anwserPlayer['messageSend']).'
HTTP status: '.htmlentities($anwserPlayer['httpStatus']).'
Bot anwser: '.htmlentities($anwserPlayer['response']).'
'; }else{ - $fullLogs=""; + $fullLogs.=""; }