Update README.md
This commit is contained in:
21
README.md
21
README.md
@@ -1,3 +1,22 @@
|
|||||||
|

|
||||||
|
|
||||||
|
This plugin is a rewritten version of the FormConstructor plugin for Nukkit on PocketMine-MP API 5.0.0
|
||||||
|
|
||||||
|
[](LICENSE)
|
||||||
|
[](https://github.com/MEFRREEX/FormConstructor-PM/releases/tag/1.0.0)
|
||||||
|
|
||||||
|
🤔 Introduction
|
||||||
|
-------------
|
||||||
|
|
||||||
|
Library is designed to simplify the creation and handling of forms.
|
||||||
|
It has a few key advantages over other form libraries:
|
||||||
|
|
||||||
|
- Forms are handled using a callback function that is passed in when the form itself is created.
|
||||||
|
- For each button in SimpleForm we can set a callback function.
|
||||||
|
- In SimpleForm we get a button object as a response, where we can get its name and index.
|
||||||
|
- In CustomForm we can mark elements with an identifier to conveniently get this element in its handler. We can get element by id and its index.
|
||||||
|
- For each form we can set its closing handler.
|
||||||
|
|
||||||
🛠 Examples
|
🛠 Examples
|
||||||
-------------
|
-------------
|
||||||
|
|
||||||
@@ -111,4 +130,4 @@ public function onFormSend(PlayerFormSendEvent $event) {
|
|||||||
// Getting the form
|
// Getting the form
|
||||||
$form = $event->getForm();
|
$form = $event->getForm();
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user