samp.directory
← Skrypty i biblioteki

dinhkhoi2298/Notify-TD

Brak opisu na GitHubie.

Biblioteka★ 5zaktualizowano paź 2020Brak licencjiPawn
Otwórz na GitHubie

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

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.

README.md

Screenshot

Installation

Include in your code and begin using the library:

#include <notify_td>

Usage

Function:

Notify_Send(const playerid, const text[], const time = 7000);

Test

#include <a_samp>
#include <notify_td>

public OnPlayerConnect(playerid) {
	new 
		str[128], name[24];
	
	GetPlayerName(playerid, name, 24);
	format(str, sizeof(str), "~g~%s~w~ da ket noi.", name);

	for(new i = 0; i < 1 + GetPlayerPoolSize(); i ++) {
		if(IsPlayerConnected(i)) {
			Notify_Send(i, str, 3000); 
		}
	}
	return 1;
}

public OnPlayerDisconnect(playerid, reason) {
	new 
		str[128], name[24];
	
	GetPlayerName(playerid, name, 24);
	format(str, sizeof(str), "~r~%s~w~ da ngat ket noi.", name);

	for(new i = 0; i < 1 + GetPlayerPoolSize(); i ++) {
		if(IsPlayerConnected(i)) {
			Notify_Send(i, str, 3000);
		}
	}
	return 1;
}

public OnPlayerSpawn(playerid) {
  Notify_Send(playerid, "Spawn UWU", 3000);
}

Credits

jav - rfogkid26

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

dinhkhoi2298/Notify-TD: Biblioteka SA-MP | samp.directory