Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/falkirks/simplewarp

The original warp plugin for PocketMine-MP
https://github.com/falkirks/simplewarp

php pocketmine-mp pocketmine-plugins

Last synced: about 18 hours ago
JSON representation

The original warp plugin for PocketMine-MP

Awesome Lists containing this project

README

        

![SimpleWarp](/meta/simplewarp-2.png)

![Poggit](https://poggit.pmmp.io/ci.shield/Falkirks/SimpleWarp/SimpleWarp)
[![Average time to resolve an issue](http://isitmaintained.com/badge/resolution/Falkirks/SimpleWarp.svg)](http://isitmaintained.com/project/Falkirks/SimpleWarp "Average time to resolve an issue")
![Total downloads](https://img.shields.io/github/downloads/Falkirks/SimpleWarp/total.svg)

SimpleWarp is the original warp plugin for PocketMine-MP. It allows players to move from point **A** to **B** with ease. At the core of SimpleWarp is simplicity and extensibility. Although very easy on the end user, it exposes a powerful backend for developers to hack around with.

**SimpleWarp 2.0 is not compatible with older SimpleWarp and PocketMine versions.**

## Commands
| Command | Usage | Description |
| ------- | ----- | ----------- |
| `/warp` | `/warp [player]` | Warps you or another player to a specified warp. |
| `/addwarp` | `/addwarp [ \| \|]` | Creates a new warp at a set location. |
| `/delwarp` | `/delwarp ` | Deletes specified warp. |
| `/listwarps` | `/listwarps` | Prints out list of warps. |
| `/openwarp` | `/openwarp ` | Allows any player to access specified warp. |
| `/closewarp` | `/closewarp ` | Restricts specfied so that only players with correct permission node can use it |
| `/warpreport` | `/warpreport [title]` | Run from console to generate a new GitHub issue for SimpleWarp |

## Permissions
```yaml
simplewarp:
default: op
children:
simplewarp.command:
default: op
children:
simplewarp.command.list:
default: true
children:
simplewarp.command.list.xyz:
default: op
simplewarp.command.list.visual:
default: op
simplewarp.command.addwarp:
default: op
simplewarp.command.delwarp:
default: op
simplewarp.command.warp:
default: true
children:
simplewarp.command.warp.other:
default: op
simplewarp.command.openwarp:
default: op
simplewarp.command.closewarp:
default: op
simplewarp.command.closewarp:
default: op
simplewarp.essentials.notice:
default: op
description: Recieve messages when their is warp conflict in Essentials
simplewarp.warp:
default: op
description: Allows usage of all warps
```

## API
What good is a plugin without an API? SimpleWarp has an API which is used by it's own core components.

### Getting access
Make sure to add the following to your `plugin.yml`

```yaml
depend: ["SimpleWarp"]
```
**Note:** If you use `softdepend` you will need to check if SimpleWarp is installed.

Now you can a copy of the API in your `onEnable` method

```php
$api = SimpleWarpAPI::getInstance($this); // This only works inside a PluginBase
```

If you want to get the instance outside your main class, you can do

```php
$api = $server->getPluginManager()->getPlugin("SimpleWarp")->getApi(); // $server is an instance of \pocketmine\Server
```