PHPackages                             luminoray/role-php - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. luminoray/role-php

ActiveLibrary[Framework](/categories/framework)

luminoray/role-php
==================

A simple RPG framework for PHP.

0.1(9y ago)226MITPHP

Since Jul 12Pushed 9y ago1 watchersCompare

[ Source](https://github.com/luminoray/RolePHP)[ Packagist](https://packagist.org/packages/luminoray/role-php)[ RSS](/packages/luminoray-role-php/feed)WikiDiscussions master Synced yesterday

READMEChangelog (1)Dependencies (1)Versions (4)Used By (0)

RolePHP
=======

[](#rolephp)

Welcome to RolePHP, a simple PHP library for creating your own browser RPG. This project is still under very early development.

Installation
------------

[](#installation)

RolePHP is available via [Composer](https://getcomposer.org/), so there are a few options for installation (assuming composer is installed, if not, please refer to [Composer Installation](https://getcomposer.org/download/)):

#### Terminal

[](#terminal)

Navigate to your project folder and execute the following command:

```
php composer.phar require luminoray/role-php

```

#### Dependency definition

[](#dependency-definition)

This method is useful if you intend your project to depend on more packages other than RolePHP. Create a file on your project's root named *composer.json* with the following contents:

```
{
	"require": {
		"luminoray/role-php" : "dev-master"
	},
	"minimum-stability" : "dev"
}

```

The *dev-master* version defined refers to the current status of the master branch in this github project. As development goes on, this should be changed to RolePHP's current version (*v1.0*, for example). Since RolePHP is still under development, the minimum stability at the moment of updating this README file must be set to *dev*.

Once the file has been created, navigate to your project folder and execute the following command:

```
php composer.phar install

```

Updating
--------

[](#updating)

In order to update your installation of RolePHP, you just need to navigate to your project folder and execute the following command:

```
php composer.phar update

```

This will fetch the latest matching version according to your *composer.json* file. Please refer to [Composer Basic Usage](https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file) for more information.

Basic usage
-----------

[](#basic-usage)

RolePHP provides a framework for creating your own PHP-based browser RPG. As such, RolePHP is not immediately useable, as it allows the developer to create their own damage formulas.

Once RolePHP has been installed, you must include the *autoload.php* file, located in the *vendor* folder:

```
