[Plugin] Discord Rich Presence (Client & Server)
#1

Discord Rich Presence
Versхes suportadas: 0.3.7-R1, 0.3.7-R2 & 0.3.DL-R1.
Cliente
Na primeira inicializaзгo, um arquivo chamado "samp-drp.ini" й criado onde o plugin estб localizado (Nesse caso, na pasta do jogo

Code:
[Settings]
ConnectToServer=1
Por padrгo, o plugin tentarб se conectar ao servidor. Se o servidor nгo usar o plugin ou se esta opзгo estiver desativada, o ID do aplicativo padrгo serб inicializado e o plugin funcionarб independentemente, mostrando estas informaзхes: Nome do jogador, ip do servidor, porta do servidor, se o servidor estб trancado, contagem de jogadores e mбximo de jogadores. Um exemplo:



Se conectado a um servidor, as informaзхes mostradas serгo diferentes e controladas por ele.
Servidor
Funзхes:
Code:
native DRP_InitializeDiscordPlugin(const application_id[], const details[], const drp_state[], const large_image[], const large_image_text[], const small_image[], const small_image_text[]);
native DRP_IsPlayerUsingClientPlugin(const playerid);
native DRP_GetPlayerDetails(const playerid, details[], const length);
native DRP_GetPlayerLargeImageKey(const playerid, large_imagekey[], const length);
native DRP_GetPlayerSmallImageKey(const playerid, small_imagekey[], const length);
native DRP_GetPlayerSmallImageText(const playerid, small_image_text[], const length);
native DRP_GetPlayerLargeImageText(const playerid, large_image_text[], const length);
native DRP_GetPlayerState(const playerid, drp_state[], const length);
native DRP_SetPlayerDetails(const playerid, const details[]);
native DRP_SetPlayerLargeImageKey(const playerid, const large_image_key[]);
native DRP_SetPlayerLargeImageText(const playerid, const large_image_text[]);
native DRP_SetPlayerSmallImageKey(const playerid, const small_image_key[]);
native DRP_SetPlayerSmallImageText(const playerid, const small_image_text[]);
native DRP_SetPlayerState(const playerid, const drp_state[]);
-A documentaзгo para as funзхes estarб disponнvel no wiki do repositуrio do plugin.
-Binбrios para linux em breve.

Github
Reply
#2

Muito bom!
Reply
#3

Parabens Bem Utill

Mapas fale comigo

__________________________________________________ ______




Reply
#4

Pq nгo posta tambйm em Plugin Development ?
Reply
#5

Muito bom.
Reply
#6

Boa, bem elaborado.
Reply
#7

essa dependкncia й muito agradбvel!
Reply
#8

bacana.
Reply
#9

Уtimo trabalho, Bruno! <3
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)