From 9f28616dfd1cc425c5013937bab729217b7be2e6 Mon Sep 17 00:00:00 2001 From: piernov Date: Sun, 8 May 2016 20:45:40 +0200 Subject: Add build_doc.sh script + generated phpdoc --- doc/phpdoc/classes/Inventory.html | 625 ++++++++++++++++++++++++++++++++++++++ doc/phpdoc/classes/Item.html | 483 +++++++++++++++++++++++++++++ doc/phpdoc/classes/Monster.html | 410 +++++++++++++++++++++++++ 3 files changed, 1518 insertions(+) create mode 100644 doc/phpdoc/classes/Inventory.html create mode 100644 doc/phpdoc/classes/Item.html create mode 100644 doc/phpdoc/classes/Monster.html (limited to 'doc/phpdoc/classes') diff --git a/doc/phpdoc/classes/Inventory.html b/doc/phpdoc/classes/Inventory.html new file mode 100644 index 0000000..48730e5 --- /dev/null +++ b/doc/phpdoc/classes/Inventory.html @@ -0,0 +1,625 @@ + + + + + + API Documentation » \Inventory + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + +
+ + +
+
+

Inventory

+ + +

Represent the player's Inventory.

+
+
+

Implemented as a singleton in the session.

+
+ + + + + + + + + + + + + +
+ package + + +

inc\Inventory.inc

+
+ author + + +

Alexandre Renoux

+
+ author + + +

Pierre-Emmanuel Novac

+
+ +

Methods

+ +
+

Adds an Item object to the Inventory, incrementing the Item's count if it was already present.

+
_addItem(\Item $item) : array
+
+
+ + +
+
+
+ + +
+ +

Arguments

+
+

$item

+ \Item

Item to add to the Inventory

+
+ +

Response

+ array

Item and Item's count

+
+
+ +
+ +
+

_removeItem

+
_removeItem( $item) 
+
+
+ + +
+
+
+ + + + + + + + + + +
+ + +
+ + +
+ +

Arguments

+
+

$item

+

+
+ +
+
+ +
+ +
+

_useItem

+
_useItem( $item) 
+
+
+ + +
+
+
+ + + + + + + + + + +
+ + +
+ + +
+ +

Arguments

+
+

$item

+

+
+ +
+
+ +
+ +
+

Adds an Item object to the singleton's Inventory from session.

+
addItem(\Item $item) : array
+
+ static
+ + +
+
+
+ + +
+ +

Arguments

+
+

$item

+ \Item

Item to add to the Inventory

+
+ +

Response

+ array

Item and Item's count

+
+
+ +
+ +
+

addToXML

+
addToXML( $root) 
+
+
+ + +
+
+
+ + + + + + + + + + +
+ + +
+ + +
+ +

Arguments

+
+

$root

+

+
+ +
+
+ +
+ +
+

Checks if the Inventory was already created in the session

+
created() : boolean
+
+ static
+ + +
+
+
+ + + + + + +
+ + +
+ + +

Response

+ boolean

true if Inventory was already created, false otherwise

+
+
+ +
+ +
+

Returns the Inventory from the session.

+
get() : \Inventory
+
+ static
+ + +
+
+

Implements the singleton pattern.

+ + + + + + +
+ + +
+ + +

Response

+ \Inventory

the Inventory object

+
+
+ +
+ +
+

removeItem

+
removeItem( $item) 
+
+ static
+ + +
+
+
+ + + + + + + + + + +
+ + +
+ + +
+ +

Arguments

+
+

$item

+

+
+ +
+
+ +
+ +
+

Returns the Inventory's content from the session.

+
sendContent() : array
+
+ static
+ + +
+
+
+ + + + + + +
+ + +
+ + +

Response

+ array

array of Items and number

+
+
+ +
+ +
+

useItem

+
useItem( $item) 
+
+ static
+ + +
+
+
+ + + + + + + + + + +
+ + +
+ + +
+ +

Arguments

+
+

$item

+

+
+ +
+
+ +
+ + +

Properties

+ +
+

Arrays of array with Item and Item's count

+
items : 
+
+
+
+
+
+ + + + + + +
+ + +
+ +

Type(s)

+ +
+
+
+
+
+ + +
+
+ +
+ + + + diff --git a/doc/phpdoc/classes/Item.html b/doc/phpdoc/classes/Item.html new file mode 100644 index 0000000..9dbd580 --- /dev/null +++ b/doc/phpdoc/classes/Item.html @@ -0,0 +1,483 @@ + + + + + + API Documentation » \Item + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + +
+
+
+ + +
+
+ + + + +
+ + + + +
+ +
+
+

Item

+ + +

Represent an Item in the shop or in the Inventory.

+
+
+ +
+ + + + + + + + + + + + + +
+ package + + +

inc\Item.inc

+
+ author + + +

Alexandre Renoux

+
+ author + + +

Pierre-Emmanuel Novac

+
+ +

Methods

+ +
+

Item's constructor

+
__construct(string $name, integer $cost, string $icon, string $desc, array $feat) : void
+
+
+ + +
+
+
+ + +
+ +

Arguments

+
+

$name

+ string

Item's name

+
+
+

$cost

+ integer

Item's cost

+
+
+

$icon

+ string

Item's icon

+
+
+

$desc

+ string

Item's description

+
+
+

$feat

+ array

associative array of strings describing the Item's features

+
+ +
+
+ +
+ +
+

Generates an XML tree describing the Item

+
addToXML( $root, integer $count) : void
+
+
+ + +
+
+
+ + +
+ +

Arguments

+
+

$root

+

+
+
+

$count

+ integer

numbers of Items

+
+ +
+
+ +
+ +
+

Applies Item's features on the player.

+
consume() : void
+
+
+ + +
+
+
+ + + + + + +
+ + +
+ + +
+
+ +
+ +
+

Generates an Item object from an XML tree

+
fromXML(\SimpleXMLElement $xml) : void
+
+ static
+ + +
+
+
+ + +
+ +

Arguments

+
+

$xml

+ \SimpleXMLElement

root XML element representing the Item

+
+ +
+
+ +
+ + +

Properties

+ +
+

Name of the item.

+
name : string
+
+
+
+
+
+ + + + + + +
+ var + +

Name of the item.

+
+ +

Type(s)

+ string +
+
+
+ +
+

Item's cost.

+
cost : integer
+
+
+
+
+
+ + + + + + +
+ var + +

Item's cost.

+
+ +

Type(s)

+ integer +
+
+
+ +
+

Item's icon.

+
icon : string
+
+
+
+
+
+ + + + + + +
+ var + +

Item's icon.

+
+ +

Type(s)

+ string +
+
+
+ +
+

Item's description.

+
desc : string
+
+
+
+
+
+ + + + + + +
+ var + +

Item's description.

+
+ +

Type(s)

+ string +
+
+
+ +
+

Item's features as an associative array

+
feat : array
+
+
+
+
+
+ + + + + + +
+ var + +

Item's features as an associative array

+
+ +

Type(s)

+ array +
+
+
+
+
+ + +
+
+ +
+ + + + diff --git a/doc/phpdoc/classes/Monster.html b/doc/phpdoc/classes/Monster.html new file mode 100644 index 0000000..5f22810 --- /dev/null +++ b/doc/phpdoc/classes/Monster.html @@ -0,0 +1,410 @@ + + + + + + API Documentation » \Monster + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + +
+
+
+ + +
+
+ + + + +
+ + + + +
+ +
+
+

Monster

+ + +

Represent an Item in the shop or in the Inventory.

+
+
+ +
+ + + + + + + + + + + + + +
+ package + + +

inc\Monster.inc

+
+ author + + +

Alexandre Renoux

+
+ author + + +

Pierre-Emmanuel Novac

+
+ +

Methods

+ +
+

Monster's constructor

+
__construct(string $name, integer $level, integer $hp, integer $xp, string $icon) : void
+
+
+ + +
+
+
+ + +
+ +

Arguments

+
+

$name

+ string

Monster's name

+
+
+

$level

+ integer

Monster's level

+
+
+

$hp

+ integer

Monster's HP

+
+
+

$xp

+ integer

Exp given by the Monster

+
+
+

$icon

+ string

Item's icon

+
+ +
+
+ +
+ + +

Properties

+ +
+

Name of the Monster.

+
name : string
+
+
+
+
+
+ + + + + + +
+ var + +

Name of the Monster.

+
+ +

Type(s)

+ string +
+
+
+ +
+

Monster's icon.

+
icon : string
+
+
+
+
+
+ + + + + + +
+ var + +

Monster's icon.

+
+ +

Type(s)

+ string +
+
+
+ +
+

Monster's description.

+
desc : \desc
+
+
+
+
+
+ + + + + + +
+ var + +

Monster's description.

+
+ +

Type(s)

+ \desc +
+
+
+ +
+

HP of the Monster.

+
hp : integer
+
+
+
+
+
+ + + + + + +
+ var + +

HP of the Monster.

+
+ +

Type(s)

+ integer +
+
+
+ +
+

Exp given by this monster.

+
xp : integer
+
+
+
+
+
+ + + + + + +
+ var + +

Exp given by this monster.

+
+ +

Type(s)

+ integer +
+
+
+ +
+

Monster's level.

+
level : integer
+
+
+
+
+
+ + + + + + +
+ var + +

Monster's level.

+
+ +

Type(s)

+ integer +
+
+
+
+
+ + +
+
+ +
+ + + + -- cgit v1.2.3-70-g09d2