Download the PHP package pandaac/exporter without Composer
On this page you can find all versions of the php package pandaac/exporter. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package exporter
Exporter
The aim of the pandaac exporter is to provide a simple & quick interface to export data from the common XML files found within the data/ directory of your Open Tibia server.
It is strongly recommended that you cache the response rather than parsing it over and over again.
As of right now, this exporter assumes that you're using The Forgotten Server 1.1. I have no immediate plans to expand this to any other distrobutions until I expand the distrobution range for pandaac itself. However, if there's enough public pressure for a specific distrobution, I may reconsider.
Requirements
- PHP 5.6.4+
- PHP Extensions
- libxml
Install
Via Composer
Usage
Pass the absolute path to your Open Tibia server as the first argument of the Exporter
object and specify which parser you would like to use as the first argument of the parse
method of the Exporter
object.
The parse
method also accepts a second argument for additional attributes (depends on the parser), and a third argument for overriding the default filepath (or providing a specific parser with a filepath).
Settings
Optionally, you may pass through engine specific settings as the second argument of the \pandaac\Exporter\Exporter
object.
Available settings are as follows (the selected values are the default values):
Response
Each parser returns an Illuminate Collection object. Please refer to the Laravel documentation for details on how to utilise it.
Parsers
Parsers are what decides how to parse a certain file, and how to structure its response. It is important you use the correct parser for the correct file.
XML Parsers
-
Actions
-
Chat Channels
-
Commands
-
Creature Scripts
-
Events
-
Global Events
-
Groups
-
Items
-
Map Houses
You must specify the relative filename as the third argument.
-
Map Spawns
You must specify the relative filename as the third argument.
-
Monster
You must specify the relative filename as the third argument.
-
Monsters
You may also load the data from within each individual monster file by setting the
recursive
attribute totrue
. -
Mounts
-
Movements
-
NPC
You must specify the relative filename as the third argument.
-
Outfits
-
Quests
-
Raid
You must specify the relative filename as the third argument.
-
Raids
You may also load the data from within each individual raid file by setting the
recursive
attribute totrue
. -
Spells
-
Stages
-
TalkActions
-
Vocations
-
Weapons
- XMLSource
If you have a string containing XML, you may also parse that using the following setup.
OTBM Parsers
The OTBM engine has not yet been developed, and thus the following parsers are rendered obsolete for the time being.
- Towns
Contributing
Please refer to the PSR-2 guidelines and squash your commits together into one before submitting a pull request.
Thank you.
All versions of exporter with dependencies
ext-libxml Version *
tightenco/collect Version ~5.4
mdurrant/php-binary-reader Version ~1.0