aboutsummaryrefslogtreecommitdiffstats
path: root/inc/mine.inc
blob: 76c00551b2710a0f5c6fd1353fb3f5bb548a862f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?php

function initCraftMine() {
	$_SESSION["mine"] = array("mine" => 0, "gold" => 0, "miners" => 1);
}

function withdrawMine() {
	$mine = $_SESSION["mine"];
	$_SESSION["mine"]["gold"] += $mine["mine"];
	$_SESSION["mine"]["mine"] = 0;
}

function sendMine() {
	if(empty($_SESSION["mine"])) initMine();
	$mine = $_SESSION["mine"];
	echo $mine["gold"];
}


?>