[Ajuda] o Que tem de errado??
#1

PHP код:
#include <a_samp>
#define Click 789
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if (
dialogid == Click) {
            new 
string[256];
            if (
response == 1) {                 
                new 
nome[24];
                
GetPlayerName(playerid, nome, MAX_PLAYER_NAME);
                
format(string, sizeof(string), "{FFFF00}%s \n {33AA33}Ping: {FFFFFF}%d {33AA33}FPS: {FFFFFF}%d ", nome, GetPlayerPing(playerid), GetPlayerFPS(playerid));
                
ShowPlayerDialog(playerid, Click, DIALOG_STYLE_MSGBOX, "Informaзхes", string, "Refresh", "Cancelar");
            }
        }
    return 
1;
    }
public 
OnPlayerClickPlayer(playerid, clickedplayerid, source) {
        new 
string[256];
        
format(string, sizeof(string), "{33AA33}Ping: {FFFFFF}%d {33AA33}FPS: {FFFFFF}%d ", GetPlayerPing(playerid), GetPlayerFPS(playerid));
        
ShowPlayerDialog(playerid, Click, DIALOG_STYLE_MSGBOX, "Informaзхes", string, "Refresh", "Cancelar");
        return 
1;
    }
stock GetPlayerFPS(playerid) {
        
SetPVarInt(playerid, "DrunkL", GetPlayerDrunkLevel(playerid));
        if(
GetPVarInt(playerid, "DrunkL") < 100) SetPlayerDrunkLevel(playerid, 2000);
        else {
            if(
GetPVarInt(playerid, "LDrunkL") != GetPVarInt(playerid, "DrunkL")) {
                
SetPVarInt(playerid, "FPS", (GetPVarInt(playerid, "LDrunkL") - GetPVarInt(playerid, "DrunkL")));
                
SetPVarInt(playerid, "LDrunkL", GetPVarInt(playerid, "DrunkL"));
                if((
GetPVarInt(playerid, "FPS") > 0) && (GetPVarInt(playerid, "FPS") < 256)) {
                    return 
GetPVarInt(playerid, "FPS") - 1;
                }
            }
        }
        return 
0;
    } 
estou tentando colocar em FS, mais quando entro no servidor nгo da Load no FS
Reply
#2

Tente por isto no topo.

pawn Код:
#define FILTERSCRIPT
#if defined FILTERSCRIPT
#endif
Reply
#3

PHP код:
public OnPlayerClickPlayer(playerid, clickedplayerid, source) { 
        new 
string[256]; 
        
format(string, sizeof(string), "{33AA33}Ping: {FFFFFF}%d {33AA33}FPS: {FFFFFF}%d ", GetPlayerPing(playerid), GetPlayerFPS(playerid)); 
        
ShowPlayerDialog(playerid, Click, DIALOG_STYLE_MSGBOX, "Informaзхes", string, "Refresh", "Cancelar"); 
        return 
1; 
    } 
AKI em cima ^^ Seu codigo mostra o ping e o Fps seu, nгo o da pessoa que voce clickou.
PHP код:
public OnPlayerClickPlayer(playerid, clickedplayerid, source) { 
        new 
string[256]; 
        
format(string, sizeof(string), "{33AA33}Ping: {FFFFFF}%d {33AA33}FPS: {FFFFFF}%d ", GetPlayerPing(clickedplayerid), GetPlayerFPS(clickedplayerid)); 
        
ShowPlayerDialog(playerid, Click, DIALOG_STYLE_MSGBOX, "Informaзхes", string, "Refresh", "Cancelar"); 
        return 
1; 
    }
// certo 
Reply
#4

foi valeu, mais agora quando clica no "botгo Refresh" nгo atualiza, no gm que eu to fazendo funciona =S
Reply
#5

tipo bote "fechar" atualizar basta clickar dnovo'-
Reply
#6

no meu gm quando clica no "botгo" ele aparecia o dialog novamente, mais no fs nгo vai assim, nгo sei por que =S
Reply
#7

tipo voce colocou um response para akele dialog de clickar certo?

Mais na OnPlayerdialogresponse nгo tem Clickedplayerid.
apenas tire o response ou arrume ele .
para outra coisa.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)