OTS_MonstersList __construct(
string
$path
)
|
|
Loads monsters mapping file.
Loads monsters mapping file.
Note: You pass directory path, not monsters.xml file name itself.
Parameters:
|
string |
$path: |
Monsters directory. |
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Throws: | DOMException On DOM operation error. |
| Since: | 0.1.0 |
Returns amount of monsters loaded.
Returns amount of monsters loaded.
API Tags:
| Return: | Count of monsters. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- Countable::count
Returns monster at current position in iterator.
Returns monster at current position in iterator.
API Tags:
| Return: | Monster. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Throws: | DOMException On DOM operation error. |
| Since: | 0.1.0 |
Implementation of:
- Iterator::current
Returns loaded data of given monster.
Returns loaded data of given monster.
Parameters:
|
string |
$name: |
Monster name. |
API Tags:
| Return: | Monster data. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.1.0 |
| Throws: | OutOfBoundsException If not exists. |
| Since: | 0.1.0 |
| Throws: | DOMException On DOM operation error. |
bool hasMonster(
string
$name
)
|
|
Checks if given monster ID exists on list.
Checks if given monster ID exists on list.
Parameters:
|
string |
$name: |
Monster name. |
API Tags:
| Return: | If monster is set then true. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.1.0 |
| Since: | 0.1.0 |
| Since: | 0.1.3 |
Returns name of current position.
Returns name of current position.
API Tags:
| Return: | Current position key. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- Iterator::key
Moves to next iterator monster.
Moves to next iterator monster.
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- Iterator::next
bool offsetExists(
string
$offset
)
|
|
Checks if given element exists.
Checks if given element exists.
Parameters:
|
string |
$offset: |
Array key. |
API Tags:
| Return: | True if it's set. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- ArrayAccess::offsetExists
Returns item from given position.
Returns item from given position.
Parameters:
|
string |
$offset: |
Array key. |
API Tags:
| Return: | Monster instance. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.1.0 |
| Throws: | DOMException On DOM operation error. |
| Since: | 0.1.0 |
Implementation of:
- ArrayAccess::offsetGet
void offsetSet(
string|int
$offset, mixed
$value
)
|
|
This method is implemented for ArrayAccess interface.
This method is implemented for ArrayAccess interface. In fact you can't write/append to monsters list. Any call to this method will cause E_OTS_ReadOnly raise.
Parameters:
|
string|int |
$offset: |
Array key. |
|
mixed |
$value: |
Field value. |
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Throws: | E_OTS_ReadOnly Always - this class is read-only. |
| Since: | 0.1.0 |
Implementation of:
- ArrayAccess::offsetSet
void offsetUnset(
string|int
$offset
)
|
|
This method is implemented for ArrayAccess interface.
This method is implemented for ArrayAccess interface. In fact you can't write/append to monsters list. Any call to this method will cause E_OTS_ReadOnly raise.
Parameters:
|
string|int |
$offset: |
Array key. |
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Throws: | E_OTS_ReadOnly Always - this class is read-only. |
| Since: | 0.1.0 |
Implementation of:
- ArrayAccess::offsetUnset
Resets iterator index.
Resets iterator index.
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- Iterator::rewind
Checks if there is anything more in interator.
Checks if there is anything more in interator.
API Tags:
| Return: | If iterator has anything more. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Implementation of:
- Iterator::valid
void __set_state(
array
$properties
)
|
|
Magic PHP5 method.
Magic PHP5 method.
Allows object importing from var_export().
Parameters:
|
array |
$properties: |
List of object properties. |
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Since: | 0.1.0 |
Returns string representation of object.
Returns string representation of object.
If any display driver is currently loaded then it uses it's method.
API Tags:
| Return: | String representation of object. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.1.0 |
| Since: | 0.1.0 |
| Since: | 0.1.3 |