aboutsummaryrefslogtreecommitdiffstats
path: root/inc/perso.inc
diff options
context:
space:
mode:
Diffstat (limited to 'inc/perso.inc')
-rw-r--r--inc/perso.inc17
1 files changed, 17 insertions, 0 deletions
diff --git a/inc/perso.inc b/inc/perso.inc
new file mode 100644
index 0000000..075f8ae
--- /dev/null
+++ b/inc/perso.inc
@@ -0,0 +1,17 @@
+<?php
+function sendPerso() {
+ if(!empty($_SESSION["perso"]))
+ return $_SESSION["perso"];
+ else return false;
+}
+
+function updatePerso(){
+ $hp = $_POST["hp"];
+ $xp = $_POST["xp"];
+ $lv = $_POST["lv"];
+ $_SESSION["perso"]["hp"] = $hp;
+ $_SESSION["perso"]["xp"] = $xp;
+ $_SESSION["perso"]["lv"] = $lv;
+}
+
+?>