From 64b1663e55544e1ed0e072c4f624688625691c9f Mon Sep 17 00:00:00 2001 From: alexichi Date: Sun, 1 May 2016 13:55:08 +0200 Subject: Add dungeon without fight system You can buy a "ticket" to access the dungeon If you exit you have to buy another ticket Problem when we update the page, the default sentence is displayed while it said that you can access the dungeon --- inc/dungeon.inc | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'inc/dungeon.inc') diff --git a/inc/dungeon.inc b/inc/dungeon.inc index b2277f0..8c26c92 100644 --- a/inc/dungeon.inc +++ b/inc/dungeon.inc @@ -36,4 +36,15 @@ function buildDungeon() { } } +function launchDungeon(){ + $dungeon=generateMonster(); + $opponent = $dungeon["monsters"]["floor1"]; + echo json_encode($opponent); +} + +function exitDungeon(){ + $_SESSION["dungeon"] = false; + echo json_encode(array("a" => 7));//Cette ligne ne sert qu'à contourner l'erreur créé à cause de sendRequest. A revoir. +} + ?> -- cgit v1.2.3-54-g00ecf