This commit is contained in:
Gnieark 2015-12-18 21:28:38 +01:00
parent 273a493520
commit 5c9c007d4a

View File

@ -29,9 +29,10 @@ function fight(xd_check){
document.getElementById('logs').innerHTML = 'erreur' +xhr.responseText;
return;
}
var coords = strike['target'].split(",");
document.getElementById( 'bot' + strike['opponent'] + '-' + coords[1] + '-' + coords[0]).innerHTML = "X";
if( strike['target'] <> ''){
var coords = strike['target'].split(",");
document.getElementById( 'bot' + strike['opponent'] + '-' + coords[1] + '-' + coords[0]).innerHTML = "X";
}
var p=createElem("p");
p.innerHTML=strike['log'];
document.getElementById('logs').appendChild(p);