tibiasolutions/tibia-parser

Tibia.com parser informations

v1.1 2017-01-20 16:48 UTC

This package is not auto-updated.

Last update: 2024-10-26 20:58:43 UTC


README

Total Downloads License

A PHP crawler module to get tibia.com parsed data.

Installation

  1. Download Composer or update composer self-update.
  2. Run
php composer.phar require tibiasolutions/tibia-parser

If Composer is installed globally, run

composer require tibiasolutions/tibia-parser

Basic Usage

Player

require dirname(__DIR__) . '/vendor/autoload.php';

use TibiaParser\Player;

$player = new Player('Kharsek');
if ($player->exists) {
	var_dump($player);
} else {
	echo 'Character does not exist.';
}

World

require dirname(__DIR__) . '/vendor/autoload.php';

use TibiaParser\World;

$world = new World('Antica');
if ($world->error != NULL) {
	echo $world->error;
} else {
	var_dump($world->information);
	foreach ($world->players as $player) {
		var_dump($player);
	}
}

// Get all World Names
var_dump(World::getWorlds());