aboutsummaryrefslogtreecommitdiffstats
path: root/craftmine.php
diff options
context:
space:
mode:
authorpiernov <piernov@piernov.org>2016-04-24 22:30:43 +0200
committerpiernov <piernov@piernov.org>2016-04-24 22:30:43 +0200
commit64e92bb7b10bf521aa2992d20c243c41573e0ee8 (patch)
tree81eeb7a7502ed3e8e40cd2e434a462d5d13581f1 /craftmine.php
parenta7d9febaba01a5f32ff77dade8f4fa1e97870354 (diff)
parentbc8e1117591e22a2ec850ce34358abadf950d87e (diff)
downloadcandybox-64e92bb7b10bf521aa2992d20c243c41573e0ee8.tar.gz
candybox-64e92bb7b10bf521aa2992d20c243c41573e0ee8.tar.bz2
candybox-64e92bb7b10bf521aa2992d20c243c41573e0ee8.tar.xz
candybox-64e92bb7b10bf521aa2992d20c243c41573e0ee8.zip
Merge branch 'feat/shop' into piernov
Diffstat (limited to 'craftmine.php')
-rw-r--r--craftmine.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/craftmine.php b/craftmine.php
index 5df926f..869c83a 100644
--- a/craftmine.php
+++ b/craftmine.php
@@ -1,7 +1,10 @@
<?php
-session_start();
require_once("inc/mine.inc");
+require_once("inc/shop.inc");
+
+session_start(); // Must be placed *BEFORE* $_SESSION is actually used and *AFTER* all classes are imported
+
/**
* Indique au client une message requete.
*/
@@ -32,7 +35,9 @@ if (!isset($_POST["op"])) {
$op = $_POST["op"];
switch($op) {
case "withdrawMine": withdrawMine(); break;
- case "getCraftMine": sendMine(); break;
+ case "getCraftMine": sendCraftMine(); break;
+ case "buildShop": buildShop(); break;
+ case "buyItem": buyItem(); break;
default: reportBadRequest();
}