[Ajuda] Erro e warning
#1

pawn Код:
CMD:duelo(playerid, params[])
{
    new cmd[128];
    new idx;
    new id;
    new tmp[128];
    new string[128];
    tmp = otherplayerids(cmd, idx);
    id = strval(tmp);
    if(InvitedDuel[playerid] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк Jб Convidou alguйm,Aguarde Expirar o Convite");
    if(ArenaUsada == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No momento a Arena estб Sendo Usada");
    if(!strlen(tmp)) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк deve digitar os ID do Player seguindo a Maneira (/duelo-run [playerid])");
    if(id == playerid) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк nгo pode convidar a Si-Mesmo");
    if(InvitedDuel[id] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No Momento o Player estб em um Duelo, Aguarde..");
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "»»[DUELO]«« : %s esta lhe convidando  para um \n Duelo Leve (Clique Aceitar para Aceitar)",name);
    ShowPlayerDialog(id,DIALOG_DUELO,DIALOG_STYLE_MSGBOX,"»»[DUELO]«« :",string,"Aceitar", "Recusar");
    GameTextForPlayer(id,"~r~DUE~w~LO !", 2500, 3);
    InvitedDuel[id] = true;
    IdDuel[id] = playerid;
    SetTimerEx("LimparDuelo",15000,false,"ii",id,playerid);
}//LINHA 425
    return 1; //LINHA426
}
Creditos do comando Fek Drakins

E aqui esta o erro e warning

Код:
D:\GM\gamemodes\GM.pwn(4025) : warning 209: function "cmd_duelo" should return a value
D:\GM\gamemodes\GM.pwn(4026) : error 010: invalid function or declaration
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
LINHAS DOS ERROS E WARNING EM //
Reply
#2

pawn Код:
CMD:duelo(playerid, params[])
{
    new cmd[128];
    new idx;
    new id;
    new tmp[128];
    new string[128];
    tmp = otherplayerids(cmd, idx);
    id = strval(tmp);
    if(InvitedDuel[playerid] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк Jб Convidou alguйm,Aguarde Expirar o Convite");
    if(ArenaUsada == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No momento a Arena estб Sendo Usada");
    if(!strlen(tmp)) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк deve digitar os ID do Player seguindo a Maneira (/duelo-run [playerid])");
    if(id == playerid) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк nгo pode convidar a Si-Mesmo");
    if(InvitedDuel[id] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No Momento o Player estб em um Duelo, Aguarde..");
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "»»[DUELO]«« : %s esta lhe convidando  para um \n Duelo Leve (Clique Aceitar para Aceitar)",name);
    ShowPlayerDialog(id,DIALOG_DUELO,DIALOG_STYLE_MSGBOX,"»»[DUELO]«« :",string,"Aceitar", "Recusar");
    GameTextForPlayer(id,"~r~DUE~w~LO !", 2500, 3);
    InvitedDuel[id] = true;
    IdDuel[id] = playerid;
    SetTimerEx("LimparDuelo",15000,false,"ii",id,playerid);

    return 1;
}
Reply
#3

pawn Код:
CMD:duelo(playerid, params[])
{
    new cmd[128];
    new idx;
    new id;
    new tmp[128];
    new string[128];
    tmp = otherplayerids(cmd, idx);
    id = strval(tmp);
    if(InvitedDuel[playerid] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк Jб Convidou alguйm,Aguarde Expirar o Convite");
    if(ArenaUsada == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No momento a Arena estб Sendo Usada");
    if(!strlen(tmp)) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк deve digitar os ID do Player seguindo a Maneira (/duelo-run [playerid])");
    if(id == playerid) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : Vocк nгo pode convidar a Si-Mesmo");
    if(InvitedDuel[id] == true) return SendClientMessage(playerid,0xF41917AA,"»»[DUELO]«« : No Momento o Player estб em um Duelo, Aguarde..");
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, name, sizeof(name));
    format(string, sizeof(string), "»»[DUELO]«« : %s esta lhe convidando  para um \n Duelo Leve (Clique Aceitar para Aceitar)",name);
    ShowPlayerDialog(id,DIALOG_DUELO,DIALOG_STYLE_MSGBOX,"»»[DUELO]«« :",string,"Aceitar", "Recusar");
    GameTextForPlayer(id,"~r~DUE~w~LO !", 2500, 3);
    InvitedDuel[id] = true;
    IdDuel[id] = playerid;
    SetTimerEx("LimparDuelo",15000,false,"ii",id,playerid);
    return 1;
}
Para que uma chave a mais? *-*
Reply
#4

ai que burrice, vlws galera
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)