From 79cfbb29042fd60dfbc76a6810f75cce21d3ffe0 Mon Sep 17 00:00:00 2001 From: alexichi Date: Sat, 7 May 2016 12:08:36 +0200 Subject: add the use of the life bottle --- js/dungeon.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'js/dungeon.js') diff --git a/js/dungeon.js b/js/dungeon.js index 30808ff..982dcf6 100644 --- a/js/dungeon.js +++ b/js/dungeon.js @@ -55,6 +55,7 @@ function strike(ret,nb, f){ return; } else if(persoLife == 0){ + data.hp = 1; endBattle("mob",nb,f,ret); return; } @@ -100,7 +101,7 @@ function endBattle(v,nb, f, ret){ sendRequest("craftmine.php", "op=sendDungeonProgress&floor="+f+"&mob="+nb); } sendRequest("craftmine.php", "op=updatePerso&hp="+data.hp+"&xp="+data.xp+"&lv="+data.level, function(){ - displayPerso(data.hp,data.xp,data.level); + displayPerso(data.hp,parseInt(data.xp),data.level); }); } -- cgit v1.2.3-54-g00ecf