blob: 19f311daa117aa87cbad9837f7ab1793bdacb99f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
<?php
require_once("messages.inc");
function debitAccount($amount) {
if($_SESSION["mine"]["gold"] <= $amount) {
sendError("gold_insufficient");
return false;
}
$_SESSION["mine"]["gold"] -= $amount;
return true;
}
function creditAccount($amount) {
$_SESSION["mine"]["gold"] += $amount;
}
?>
|