SA-MP Forums Archive
argument type mismatch (argument 2) - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Español/Spanish (https://sampforum.blast.hk/forumdisplay.php?fid=29)
+---- Thread: argument type mismatch (argument 2) (/showthread.php?tid=353670)



argument type mismatch (argument 2) - Rhino - 24.06.2012

Hola... nesesito una ayudita porfavor...

Resulta que tengo esta linea

SendCopMessage(PlayerInfo[playerid][pFac], COLOR_FCHAT, string);

y resulta que me da error con eso de error argument type mismatch (argument 2)

їAlguien sabe? porque yo eh intentado con todo y nada...


Respuesta: argument type mismatch (argument 2) - Parka - 24.06.2012

Eso Quiere Decir Que El Argumento no coincide con la fusion

pawn Код:
SendCopMessage(PlayerInfo[playerid][pFac], -1, string);//prueba asi
o

pawn Код:
SendCopMessage(playerid,  COLOR_FCHAT, string);// asi



Respuesta: argument type mismatch (argument 2) - OTACON - 24.06.2012

el problema esta en PlayerInfo[playerid][pFac], pero pasa el SendCopMessage, no se como lo tengas.

o prueba asi:
pawn Код:
SendCopMessage(COLOR_FCHAT, string);
EDIT:

si es asi, es como te dije arriba:

pawn Код:
SendCopMessage(color, text[]) {
    for(new i = 0; i < MAX_PLAYERS; i ++) {
        if(IsPlayerConnected(i)) {
            if (PlayerInfo[i] == pFac)
               {
                SendClientMessage(i, color, text);
            }
        }
    }
}