samp.directory
← Skrypty i biblioteki

denisbranisteanu/samp-dialog-handler

A dialog wrapper library meant to use dialogs very easy.

Biblioteka★ 1zaktualizowano mar 2022Brak licencjiPawnsampctl
Otwórz na GitHubie

To repozytorium nie ma pliku licencji. Jest publiczne do odczytu, ale samo to nie daje pozwolenia na ponowne użycie.

Zainstaluj za pomocą sampctl

sampctl package install denisbranisteanu/samp-dialog-handler

Uruchom to w folderze swojego projektu. sampctl pobiera pakiet i to, od czego zależy.

Wypróbuj w kompilatorze Pawn →

Dodaje jej pliki include, razem z bibliotekami, od których zależy, do kompilatora Pawn w twojej przeglądarce, gotowe do dołączenia w skrypcie.

Zależy od 2 pakietów

README.md

dialog-handler

Samp Dialog Handler is a wrapper meant to help you with the dialogs. See usage to learn more.

Installation

Simply install to your project:

sampctl package install GroWy/dialog-handler

Include in your code and begin using the library:

#include <dialog-handler>

Usage

Display dialog:

DisplayDialog(playerid, function[], style, caption[], info[], button1[], button2[] = "", more_parameters);

Hide dialog:

HideDialog(playerid);

Check if a player have a dialog displayed:

bool:IsDialogDisplayed(playerid);

Internal

In the source code there are some constants that can be modified.

  • DIALOG_HANDLER_MAX_INFO: used to limit the dialog's info length (4096 by default).
  • DIALOG_HANDLER_MAIN_ID: id of the dialog used by the library, by default the value is set very high so as not have problems with other dialogs.

You can simply add them before including the include:

#define DIALOG_HANDLER_MAIN_ID <value>
#define DIALOG_HANDLER_MAX_INFO <value>

Testing

To test, simply run the package:

sampctl package run

Ta strona jest zbudowana z tego, co GitHub publikuje o repozytorium. samp.directory nie hostuje kodu. Zgłoś problem z tym wpisem

denisbranisteanu/samp-dialog-handler: Biblioteka SA-MP | samp.directory