Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yasslv/dynopm
Implementing Dyno for PocketMine-MP
https://github.com/yasslv/dynopm
dyno fast minecraft mysql php php72 pmmp pocketmine sockets
Last synced: 3 months ago
JSON representation
Implementing Dyno for PocketMine-MP
- Host: GitHub
- URL: https://github.com/yasslv/dynopm
- Owner: YassLV
- License: gpl-3.0
- Archived: true
- Created: 2018-06-16T21:42:42.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-02-24T15:32:03.000Z (almost 5 years ago)
- Last Synced: 2024-09-28T19:42:12.590Z (3 months ago)
- Topics: dyno, fast, minecraft, mysql, php, php72, pmmp, pocketmine, sockets
- Language: PHP
- Homepage:
- Size: 70.3 KB
- Stars: 8
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# DynoPM
Implementing Dyno for PocketMine-MP
## Description
Create a Network system for PocketMine easily without AsyncTask and MySQL !## Version
* __DynoPM Version__: 1.0
* __For PocketMine-MP__: 3.0.0
* __Current Protocol__: 1
* __Config Version__: 1.0## Where can i get latest .phar?
Download latest .phar here: [Github Release](https://github.com/MineBuilderFR/DynoPM/releases)
## Installation
> __DynoPM needs [Dyno](https://github.com/MineBuilderFR/Dyno) to work__Download latest .phar and moved it to the PocketMine plugins folder
## Plugin Example
* __DynoMail__ : [Demo plugin for send Mail to player](https://github.com/MineBuilderFR/DynoMail)
* __DynoNetworkCount__ : SOON## Documentation
Documentation Page: [Wiki](https://github.com/MineBuilderFR/DynoPM/wiki)
## Code Example
> You can see more example code on the documentation!
### Connection to Dyno
```php
public function onEnable()
{
DynoPM::getInstance()->addPluginSyncWithDynoDescription($this, $dynoDesc);
if (($this->dyno = DynoPM::getInstance()->getDynoByDescription($dynoDesc)) === null) {
$this->getServer()->getPluginManager()->disablePlugin($this);
return;
}
$this->getServer()->getLogger()->info("Plugin Started !");
}
```
### Creation Base and Table and Put Keys```php
$pk = new inputPacket();
$final = new inputPacketLib();
$final = $final
->createBase("Base Test", [
BaseOptionsInterface::ONLY_IF_BASE_NOT_EXIST
])
->createTable("Table Test", [
TableOptionsInterface::ONLY_IF_TABLE_NOT_EXIST
])
->getTable("Table Test")
->putBool("Bool !", true)
->putString("String !", "This is a string")
->finalInput();
$pk->input = $final;
$this->dyno->sendDataPacket($pk);
```## Configuration
### Plugin> Configuration in config.yml
enabled: Enable DynoPM plugin or not
```
dynos:
- enabled: Enabled Dyno Client
ip: IP Dyno
port: Port Dyno
description: Description of your dyno (Allows to identify the DynoPM)
password: Dyno Password
```## Frequently Asked Questions
### What plugins can I create with DynoPM?With DynoPM you can create any kind of plugin using MySQL/YML, there is no limitation .
### Why use Dyno instead of MySQL for PocketMine?
You do not have to use only dyno, you can use Mysql and Dyno. Dyno even has a function that automatically transfers the data sent to Dyno on Mysql and guarantees no lag on your PocketMine server.
### How does Dyno not create Lags?
This means that you can send multiple Information Packet per second without having to wait more than 2 seconds for an Asynchronous response.
### Developing with Dyno is easy?
You can look at the source of the example plugins.