aboutsummaryrefslogtreecommitdiffstats
path: root/doc/phpdoc/namespaces/default.html
diff options
context:
space:
mode:
Diffstat (limited to 'doc/phpdoc/namespaces/default.html')
-rw-r--r--doc/phpdoc/namespaces/default.html1656
1 files changed, 1656 insertions, 0 deletions
diff --git a/doc/phpdoc/namespaces/default.html b/doc/phpdoc/namespaces/default.html
new file mode 100644
index 0000000..fa3b993
--- /dev/null
+++ b/doc/phpdoc/namespaces/default.html
@@ -0,0 +1,1656 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
+ <meta charset="utf-8"/>
+ <title> &raquo; \
+</title>
+ <meta name="author" content=""/>
+ <meta name="description" content=""/>
+
+ <link href="../css/template.css" rel="stylesheet" media="all"/>
+
+ <!--[if lt IE 9]>
+ <script src="https://html5shim.googlecode.com/svn/trunk/html5.js" type="text/javascript"></script>
+ <![endif]-->
+ <script src="../js/jquery-1.7.1.min.js" type="text/javascript"></script>
+ <script src="../js/jquery-ui-1.8.2.custom.min.js" type="text/javascript"></script>
+ <script src="../js/jquery.mousewheel.min.js" type="text/javascript"></script>
+ <script src="../js/bootstrap.js" type="text/javascript"></script>
+ <script src="../js/template.js" type="text/javascript"></script>
+ <script src="../js/prettify/prettify.min.js" type="text/javascript"></script>
+
+ <link rel="shortcut icon" href="../img/favicon.ico"/>
+ <link rel="apple-touch-icon" href="../img/apple-touch-icon.png"/>
+ <link rel="apple-touch-icon" sizes="72x72" href="../img/apple-touch-icon-72x72.png"/>
+ <link rel="apple-touch-icon" sizes="114x114" href="../img/apple-touch-icon-114x114.png"/>
+ </head>
+<body>
+
+ <div class="navbar navbar-fixed-top">
+ <div class="navbar-inner">
+ <div class="container">
+ <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
+ <span class="icon-bar"></span> <span class="icon-bar"></span>
+ <span class="icon-bar"></span> </a>
+ <a class="brand" href="../index.html">API Documentation</a>
+
+ <div class="nav-collapse">
+ <ul class="nav">
+ <li class="dropdown">
+ <a href="#api" class="dropdown-toggle" data-toggle="dropdown">
+ API Documentation <b class="caret"></b>
+ </a>
+ <ul class="dropdown-menu">
+ </ul>
+ </li>
+ <li class="dropdown" id="charts-menu">
+ <a href="#charts" class="dropdown-toggle" data-toggle="dropdown">
+ Charts <b class="caret"></b>
+ </a>
+ <ul class="dropdown-menu">
+ <li>
+ <a href="../graph_class.html">
+ <i class="icon-list-alt"></i>&#160;Class hierarchy diagram
+ </a>
+ </li>
+ </ul>
+ </li>
+ <li class="dropdown" id="reports-menu">
+ <a href="#reports" class="dropdown-toggle" data-toggle="dropdown">
+ Reports <b class="caret"></b>
+ </a>
+ <ul class="dropdown-menu">
+ <li>
+ <a href="../errors.html">
+ <i class="icon-list-alt"></i>&#160;Errors
+ </a>
+ </li>
+ <li>
+ <a href="../markers.html">
+ <i class="icon-list-alt"></i>&#160;Markers
+ </a>
+ </li>
+ <li>
+ <a href="../deprecated.html">
+ <i class="icon-list-alt"></i>&#160;Deprecated
+ </a>
+ </li>
+ </ul>
+ </li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ <div class="go_to_top">
+ <a href="#___" style="color: inherit">Back to top&#160;&#160;<i class="icon-upload icon-white"></i></a>
+ </div>
+ </div>
+
+ <div id="___" class="container">
+ <noscript>
+ <div class="alert alert-warning">
+ Javascript is disabled; several features are only available if Javascript is enabled.
+ </div>
+ </noscript>
+
+
+
+ <div class="row">
+
+ <div class="span4">
+ <div class="btn-group view pull-right" data-toggle="buttons-radio">
+ <button class="btn details" title="Show descriptions and method names">
+ <i class="icon-list"></i></button><button class="btn simple" title="Show only method names">
+ <i class="icon-align-justify"></i>
+ </button>
+ </div>
+ <ul class="side-nav nav nav-list">
+ <li class="nav-header">
+ <i class="icon-map-marker"></i> Namespaces
+ </li>
+ <a href="../namespaces/default.html" title="\">
+ <i class="icon-th"></i> \
+ </a>
+ <ul class="nav nav-list nav-namespaces">
+
+
+ </ul>
+ </ul>
+ </div>
+
+ <div class="span8 namespace-contents">
+
+
+ <ul class="breadcrumb">
+ <li><a href="../index.html"><i class="icon-th"></i></a></li>
+
+
+ <li>
+ <span class="divider">\</span><a href="../namespaces/default.html">\</a>
+ </li>
+
+ </ul>
+
+ <div class="namespace-indent">
+ <h3><i class="icon-custom icon-function"></i> Functions</h3>
+ <div id="function_buildDungeon" class="element ajax clickable function" data-toggle="collapse" data-target="#function_buildDungeon .collapse">
+ <h1>buildDungeon<a href="../namespaces/default.html#function_buildDungeon">¶</a></h1>
+ <p class="short_description">Allows acces to the dungeon in the session and sends it to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Debits the dungeon's ticket cost from the player's gold.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_buildDungeon" class="more">« More »</a> </div>
+
+ <div id="function_buildShop" class="element ajax clickable function" data-toggle="collapse" data-target="#function_buildShop .collapse">
+ <h1>buildShop<a href="../namespaces/default.html#function_buildShop">¶</a></h1>
+ <p class="short_description">Creates the shop in the session and sends it to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Debits the shop's cost from the player's gold.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_buildShop" class="more">« More »</a> </div>
+
+ <div id="function_buyItem" class="element ajax clickable function" data-toggle="collapse" data-target="#function_buyItem .collapse">
+ <h1>buyItem<a href="../namespaces/default.html#function_buyItem">¶</a></h1>
+ <p class="short_description">Debits the item&#039;s cost specified as the item POST parameter, adds it to the Inventory and sends it to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_buyItem" class="more">« More »</a> </div>
+
+ <div id="function_createGuild" class="element ajax clickable function" data-toggle="collapse" data-target="#function_createGuild .collapse">
+ <h1>createGuild<a href="../namespaces/default.html#function_createGuild">¶</a></h1>
+ <p class="short_description">Create the miners guild in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Debits GUILD_COST from the player's gold.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\guild.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_createGuild" class="more">« More »</a> </div>
+
+ <div id="function_creditAccount" class="element ajax clickable function" data-toggle="collapse" data-target="#function_creditAccount .collapse">
+ <h1>creditAccount<a href="../namespaces/default.html#function_creditAccount">¶</a></h1>
+ <p class="short_description">Credits the account of a certain amount of gold.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\account.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$amount</h4>
+ <code>integer</code><p><p>amount to credit</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_creditAccount" class="more">« More »</a> </div>
+
+ <div id="function_debitAccount" class="element ajax clickable function" data-toggle="collapse" data-target="#function_debitAccount .collapse">
+ <h1>debitAccount<a href="../namespaces/default.html#function_debitAccount">¶</a></h1>
+ <p class="short_description">Debits the account of a certain amount of gold.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\account.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$amount</h4>
+ <code>integer</code><p><p>amount to debit</p></p>
+ </div>
+
+ <h3>Response</h3>
+ <code>boolean</code><p><p>true if player had enough gold, false otherwise</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_debitAccount" class="more">« More »</a> </div>
+
+ <div id="function_deleteSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_deleteSave .collapse">
+ <h1>deleteSave<a href="../namespaces/default.html#function_deleteSave">¶</a></h1>
+ <p class="short_description">Deletes a save file given as the filename POST parameter.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_deleteSave" class="more">« More »</a> </div>
+
+ <div id="function_downSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_downSave .collapse">
+ <h1>downSave<a href="../namespaces/default.html#function_downSave">¶</a></h1>
+ <p class="short_description">Sends the current game or a specific save file given by the filename GET parameter to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_downSave" class="more">« More »</a> </div>
+
+ <div id="function_exitDungeon" class="element ajax clickable function" data-toggle="collapse" data-target="#function_exitDungeon .collapse">
+ <h1>exitDungeon<a href="../namespaces/default.html#function_exitDungeon">¶</a></h1>
+ <p class="short_description">Marks the dungeon as not accessible in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_exitDungeon" class="more">« More »</a> </div>
+
+ <div id="function_generateMonster" class="element ajax clickable function" data-toggle="collapse" data-target="#function_generateMonster .collapse">
+ <h1>generateMonster<a href="../namespaces/default.html#function_generateMonster">¶</a></h1>
+ <p class="short_description">Loads all the dungeon&#039;s monsters from the XML file data/monsters.xml.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>array</code><p><p>contains all the Monster objects</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_generateMonster" class="more">« More »</a> </div>
+
+ <div id="function_genFilename" class="element ajax clickable function" data-toggle="collapse" data-target="#function_genFilename .collapse">
+ <h1>genFilename<a href="../namespaces/default.html#function_genFilename">¶</a></h1>
+ <p class="short_description">Generates the save file name using current date/time.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>The date function will use the server's timezone which could be inconsistent with the client timezone.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>string</code><p><p>the generated file name</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_genFilename" class="more">« More »</a> </div>
+
+ <div id="function_genSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_genSave .collapse">
+ <h1>genSave<a href="../namespaces/default.html#function_genSave">¶</a></h1>
+ <p class="short_description">Generates the XML save tree from the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_genSave" class="more">« More »</a> </div>
+
+ <div id="function_genXML" class="element ajax clickable function" data-toggle="collapse" data-target="#function_genXML .collapse">
+ <h1>genXML<a href="../namespaces/default.html#function_genXML">¶</a></h1>
+ <p class="short_description">Recursively generates an XML tree from an array.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>If objects are found, call addToXML() methods which should serialize the object as a child of the XML tree passed as parameter.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$table</h4>
+ <code>array</code><p><p>an array with mixed type elements to convert to XML</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$xml</h4>
+ <code>\SimpleXMLElement</code><p><p>root XML to add the elements to</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_genXML" class="more">« More »</a> </div>
+
+ <div id="function_getItem" class="element ajax clickable function" data-toggle="collapse" data-target="#function_getItem .collapse">
+ <h1>getItem<a href="../namespaces/default.html#function_getItem">¶</a></h1>
+ <p class="short_description">Gets an Item object from the shop from its name.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+ params
+ </th>
+ <td>
+
+ <p>string $name the name of the object to search for</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$name</h4>
+ <code></code><p></p>
+ </div>
+
+ <h3>Response</h3>
+ <code><a href="../classes/Item.html">\Item</a>|false</code><p><p>the Item object or false if the item was not found</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_getItem" class="more">« More »</a> </div>
+
+ <div id="function_hireMiner" class="element ajax clickable function" data-toggle="collapse" data-target="#function_hireMiner .collapse">
+ <h1>hireMiner<a href="../namespaces/default.html#function_hireMiner">¶</a></h1>
+ <p class="short_description">Hire one miner.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Debits MINER_COST from the player's gold.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\guild.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_hireMiner" class="more">« More »</a> </div>
+
+ <div id="function_increasePerso" class="element ajax clickable function" data-toggle="collapse" data-target="#function_increasePerso .collapse">
+ <h1>increasePerso<a href="../namespaces/default.html#function_increasePerso">¶</a></h1>
+ <p class="short_description">Increases a player&#039;s stat.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\perso.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$prop</h4>
+ <code>integer</code><p><p>stat to increase</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$num</h4>
+ <code></code><p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_increasePerso" class="more">« More »</a> </div>
+
+ <div id="function_initCraftMine" class="element ajax clickable function" data-toggle="collapse" data-target="#function_initCraftMine .collapse">
+ <h1>initCraftMine<a href="../namespaces/default.html#function_initCraftMine">¶</a></h1>
+ <p class="short_description">Initializes the gold amount and miners count in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\mine.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_initCraftMine" class="more">« More »</a> </div>
+
+ <div id="function_initDungeon" class="element ajax clickable function" data-toggle="collapse" data-target="#function_initDungeon .collapse">
+ <h1>initDungeon<a href="../namespaces/default.html#function_initDungeon">¶</a></h1>
+ <p class="short_description">Marks the dungeon as accessible in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_initDungeon" class="more">« More »</a> </div>
+
+ <div id="function_initPerso" class="element ajax clickable function" data-toggle="collapse" data-target="#function_initPerso .collapse">
+ <h1>initPerso<a href="../namespaces/default.html#function_initPerso">¶</a></h1>
+ <p class="short_description">Initializes the player&#039;s stats.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\perso.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_initPerso" class="more">« More »</a> </div>
+
+ <div id="function_initShop" class="element ajax clickable function" data-toggle="collapse" data-target="#function_initShop .collapse">
+ <h1>initShop<a href="../namespaces/default.html#function_initShop">¶</a></h1>
+ <p class="short_description">Marks the shop as created in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_initShop" class="more">« More »</a> </div>
+
+ <div id="function_launchDungeon" class="element ajax clickable function" data-toggle="collapse" data-target="#function_launchDungeon .collapse">
+ <h1>launchDungeon<a href="../namespaces/default.html#function_launchDungeon">¶</a></h1>
+ <p class="short_description">Sends monsters for a specific floor as specified by the floor POST parameter to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_launchDungeon" class="more">« More »</a> </div>
+
+ <div id="function_listSaves" class="element ajax clickable function" data-toggle="collapse" data-target="#function_listSaves .collapse">
+ <h1>listSaves<a href="../namespaces/default.html#function_listSaves">¶</a></h1>
+ <p class="short_description">Sends the list of available saves to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Warning: this function changes directory.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_listSaves" class="more">« More »</a> </div>
+
+ <div id="function_loadSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_loadSave .collapse">
+ <h1>loadSave<a href="../namespaces/default.html#function_loadSave">¶</a></h1>
+ <p class="short_description">Loads a save file given as the filename POST parameter to the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Empties the session beforehand.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_loadSave" class="more">« More »</a> </div>
+
+ <div id="function_loadShop" class="element ajax clickable function" data-toggle="collapse" data-target="#function_loadShop .collapse">
+ <h1>loadShop<a href="../namespaces/default.html#function_loadShop">¶</a></h1>
+ <p class="short_description">Loads all the shop&#039;s items from the XML file data/items.xml.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>array</code><p><p>contains all the Item objects</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_loadShop" class="more">« More »</a> </div>
+
+ <div id="function_parseSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_parseSave .collapse">
+ <h1>parseSave<a href="../namespaces/default.html#function_parseSave">¶</a></h1>
+ <p class="short_description">Reads an XML tree and deserializes it to an array.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$xml</h4>
+ <code>\SimpleXMLElement</code><p><p>root XML to read the elements from</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$table</h4>
+ <code>array</code><p><p>an empty array to stores the elements to, passed by reference</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_parseSave" class="more">« More »</a> </div>
+
+ <div id="function_reportBadRequest" class="element ajax clickable function" data-toggle="collapse" data-target="#function_reportBadRequest .collapse">
+ <h1>reportBadRequest<a href="../namespaces/default.html#function_reportBadRequest">¶</a></h1>
+ <p class="short_description">Indique au client une message requete.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>Default</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_reportBadRequest" class="more">« More »</a> </div>
+
+ <div id="function_saveGame" class="element ajax clickable function" data-toggle="collapse" data-target="#function_saveGame .collapse">
+ <h1>saveGame<a href="../namespaces/default.html#function_saveGame">¶</a></h1>
+ <p class="short_description">Save the XML save tree as an XML file named after the results of genFilename in SAVEDIR.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Fails and send an error the the client if permissions are incorrectly set. Watch for errors in PHP log.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_saveGame" class="more">« More »</a> </div>
+
+ <div id="function_sendCraftMine" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendCraftMine .collapse">
+ <h1>sendCraftMine<a href="../namespaces/default.html#function_sendCraftMine">¶</a></h1>
+ <p class="short_description">Sends all data from previous session on page load.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>All data from the different modules are packed in an array.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\craftmine.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendCraftMine" class="more">« More »</a> </div>
+
+ <div id="function_sendDungeon" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendDungeon .collapse">
+ <h1>sendDungeon<a href="../namespaces/default.html#function_sendDungeon">¶</a></h1>
+ <p class="short_description">Returns the dungeon array if it was created.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>array</code><p><p>dungeon array as created by generateMonster</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendDungeon" class="more">« More »</a> </div>
+
+ <div id="function_sendDungeonProgress" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendDungeonProgress .collapse">
+ <h1>sendDungeonProgress<a href="../namespaces/default.html#function_sendDungeonProgress">¶</a></h1>
+ <p class="short_description">Updates floor and monster number from the POST parameters in the session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\dungeon.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendDungeonProgress" class="more">« More »</a> </div>
+
+ <div id="function_sendError" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendError .collapse">
+ <h1>sendError<a href="../namespaces/default.html#function_sendError">¶</a></h1>
+ <p class="short_description">Sends an error message to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Simple wrapper calling sendMessage with &quot;error&quot; as $type.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\messages.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$msg</h4>
+ <code>string</code><p><p>message content</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$fmt</h4>
+ <code>string</code><p><p>optional parameters to apply when formating message string</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendError" class="more">« More »</a> </div>
+
+ <div id="function_sendInfo" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendInfo .collapse">
+ <h1>sendInfo<a href="../namespaces/default.html#function_sendInfo">¶</a></h1>
+ <p class="short_description">Sends an info message to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Simple wrapper calling sendMessage with &quot;info&quot; as $type.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\messages.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$msg</h4>
+ <code>string</code><p><p>message content</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$fmt</h4>
+ <code>string</code><p><p>optional parameters to apply when formating message string</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendInfo" class="more">« More »</a> </div>
+
+ <div id="function_sendMessage" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendMessage .collapse">
+ <h1>sendMessage<a href="../namespaces/default.html#function_sendMessage">¶</a></h1>
+ <p class="short_description">Sends a message to the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\messages.inc</p>
+ </td>
+ </tr>
+ </table>
+
+ <h3>Arguments</h3>
+ <div class="subelement argument">
+ <h4>$type</h4>
+ <code>string</code><p><p>message type, for example &quot;info&quot; or &quot;error&quot;</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$msg</h4>
+ <code>string</code><p><p>message content</p></p>
+ </div>
+ <div class="subelement argument">
+ <h4>$fmt</h4>
+ <code>string</code><p><p>optional parameters to apply when formating message string</p></p>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendMessage" class="more">« More »</a> </div>
+
+ <div id="function_sendMine" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendMine .collapse">
+ <h1>sendMine<a href="../namespaces/default.html#function_sendMine">¶</a></h1>
+ <p class="short_description">Returns the amount of gold currently owned by the player.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\mine.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>integer</code><p><p>amount of gold available</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendMine" class="more">« More »</a> </div>
+
+ <div id="function_sendMiners" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendMiners .collapse">
+ <h1>sendMiners<a href="../namespaces/default.html#function_sendMiners">¶</a></h1>
+ <p class="short_description">Returns the number of miners currently in the guild.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\guild.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>integer</code><p><p>number of miners in the guild</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendMiners" class="more">« More »</a> </div>
+
+ <div id="function_sendPerso" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendPerso .collapse">
+ <h1>sendPerso<a href="../namespaces/default.html#function_sendPerso">¶</a></h1>
+ <p class="short_description">Returns all player&#039;s stats after initializing them if needed.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\perso.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>array&lt;mixed,integer&gt;</code><p><p>arrays containing player's stats</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendPerso" class="more">« More »</a> </div>
+
+ <div id="function_sendShop" class="element ajax clickable function" data-toggle="collapse" data-target="#function_sendShop .collapse">
+ <h1>sendShop<a href="../namespaces/default.html#function_sendShop">¶</a></h1>
+ <p class="short_description">Returns the shop array if it was created.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ <h3>Response</h3>
+ <code>array</code><p><p>shop array as created by loadShop</p></p>
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_sendShop" class="more">« More »</a> </div>
+
+ <div id="function_updatePerso" class="element ajax clickable function" data-toggle="collapse" data-target="#function_updatePerso .collapse">
+ <h1>updatePerso<a href="../namespaces/default.html#function_updatePerso">¶</a></h1>
+ <p class="short_description">Copies stats given in POST request to session.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\perso.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_updatePerso" class="more">« More »</a> </div>
+
+ <div id="function_uploadSave" class="element ajax clickable function" data-toggle="collapse" data-target="#function_uploadSave .collapse">
+ <h1>uploadSave<a href="../namespaces/default.html#function_uploadSave">¶</a></h1>
+ <p class="short_description">Reads a save file sent by the client.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"><p>Parse the received file then generate it again to clean it for any unwanted
+and make sure that it is a valid XML save file.
+XML errors are simply ignored and an error is sent to the client if something wrong happens.</p></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\savegame.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_uploadSave" class="more">« More »</a> </div>
+
+ <div id="function_useItem" class="element ajax clickable function" data-toggle="collapse" data-target="#function_useItem .collapse">
+ <h1>useItem<a href="../namespaces/default.html#function_useItem">¶</a></h1>
+ <p class="short_description">Invoke useItem on an item passed as the item POST parameter, sends to the client the updated player stats and the item.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\shop.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_useItem" class="more">« More »</a> </div>
+
+ <div id="function_withdrawMine" class="element ajax clickable function" data-toggle="collapse" data-target="#function_withdrawMine .collapse">
+ <h1>withdrawMine<a href="../namespaces/default.html#function_withdrawMine">¶</a></h1>
+ <p class="short_description">Transfers all gold from the mine to the player&#039;s account.</p>
+ <div class="details collapse">
+
+ <div class="row collapse">
+ <div class="detail-description">
+ <div class="long_description"></div>
+
+ <table class="table">
+ <tr>
+ <th>
+ package
+ </th>
+ <td>
+
+ <p>inc\mine.inc</p>
+ </td>
+ </tr>
+ <tr>
+ <th>
+
+ </th>
+ <td>
+ </td>
+ </tr>
+ </table>
+
+
+ </div>
+ </div>
+ </div>
+ <a href="../namespaces/default.html#function_withdrawMine" class="more">« More »</a> </div>
+
+ </div>
+
+ <div class="namespace-indent">
+ <h3><i class="icon-custom icon-constant"></i> Constants</h3>
+ <div id="constant_SAVEDIR" class="element ajax clickable constant" data-toggle="collapse" data-target="#constant_SAVEDIR .collapse">
+ <h1>SAVEDIR<a href="../namespaces/default.html#constant_SAVEDIR">¶</a></h1>
+ <p class="short_description">Directory to save to and load from.</p>
+ <div class="details collapse">
+ <p>The PHP/Apache user must have write permission on this directory.
+Use the following commands to give write permissions to the http group:</p>
+<samp>
+sudo chown :http data/save
+sudo chmod g+w data/save
+</samp>
+ </div>
+ <a href="../namespaces/default.html#constant_SAVEDIR" class="more">« More »</a> </div>
+
+ <div id="constant_GUILD_COST" class="element ajax clickable constant" data-toggle="collapse" data-target="#constant_GUILD_COST .collapse">
+ <h1>GUILD_COST<a href="../namespaces/default.html#constant_GUILD_COST">¶</a></h1>
+ <p class="short_description">Amount of gold required to build the miners guild.</p>
+ <div class="details collapse">
+
+ </div>
+ <a href="../namespaces/default.html#constant_GUILD_COST" class="more">« More »</a> </div>
+
+ <div id="constant_MINER_COST" class="element ajax clickable constant" data-toggle="collapse" data-target="#constant_MINER_COST .collapse">
+ <h1>MINER_COST<a href="../namespaces/default.html#constant_MINER_COST">¶</a></h1>
+ <p class="short_description">Amount of gold required to hire a miner.</p>
+ <div class="details collapse">
+
+ </div>
+ <a href="../namespaces/default.html#constant_MINER_COST" class="more">« More »</a> </div>
+
+ </div>
+
+ <div class="namespace-indent">
+ <h3><i class="icon-custom icon-class"></i> Classes, interfaces and traits</h3>
+
+
+ <div id="class_Inventory" class="element ajax clickable class" data-toggle="collapse" data-target="#class_Inventory .collapse">
+ <h1>Inventory<a href="../classes/Inventory.html">¶</a></h1>
+ <p class="short_description">Represent the player&#039;s Inventory.</p>
+ <div class="details collapse">
+ <p>Implemented as a singleton in the session.</p>
+ </div>
+ <a href="../classes/Inventory.html" class="more">« More »</a> </div>
+
+ <div id="class_Item" class="element ajax clickable class" data-toggle="collapse" data-target="#class_Item .collapse">
+ <h1>Item<a href="../classes/Item.html">¶</a></h1>
+ <p class="short_description">Represent an Item in the shop or in the Inventory.</p>
+ <div class="details collapse">
+
+ </div>
+ <a href="../classes/Item.html" class="more">« More »</a> </div>
+
+ <div id="class_Monster" class="element ajax clickable class" data-toggle="collapse" data-target="#class_Monster .collapse">
+ <h1>Monster<a href="../classes/Monster.html">¶</a></h1>
+ <p class="short_description">Represent an Item in the shop or in the Inventory.</p>
+ <div class="details collapse">
+
+ </div>
+ <a href="../classes/Monster.html" class="more">« More »</a> </div>
+
+ </div>
+
+
+ </div>
+ </div>
+ </div>
+
+ <footer class="span12">
+ Template is built using <a href="http://twitter.github.com/bootstrap/">Twitter Bootstrap 2</a> and icons provided by
+ <a href="http://glyphicons.com/">Glyphicons</a>.<br/>
+ Documentation is powered by <a href="http://www.phpdoc.org/">phpDocumentor </a> and<br/>
+ generated on Sun, 08 May 2016 20:44:21 +0200.<br/>
+ </footer>
+ </body>
+</html>