[Ajuda]Acho que e Bem simples[Erro]
#1

pawn Код:
C:\Documents and Settings\Administrador\Desktop\BNL\Gamemode NV\gamemodes\BNL.PWN(76366) : error 017: undefined symbol "cmd"
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


1 Error.
Linha :
pawn Код:
if(strcmp(cmd, "/cassino", true) == 0)
Continuaзao do comando cassino
Ja tentei algumas coisas mais nao tou conseguindo arrumar isto
pawn Код:
if(strcmp(cmd, "/cassino", true) == 0)
{
     if(PlayerToPoint(10.0, playerid,-2765,382,6))
     SetPlayerInterior(playerid, 1);
     SetPlayerPos(playerid,2233.7998046875,1713.7144775391,1011.7869262695);
     PlayerInfo[playerid][pInt] = 1;
    return 0;
}
Nao me critiquem estou aprendendo .

E se Puderem ajudar neste Nao tou conseguindo saber oque e Acredito que seja Includes
pawn Код:
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16633) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16633) : error 033: array must be indexed (variable "cmd")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16700) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16700) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16707) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(16707) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17010) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17010) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17020) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17020) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17022) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(17022) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18370) : error 017: undefined symbol "strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18370) : error 033: array must be indexed (variable "tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18378) : error 017: undefined symbol "strtoK
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18378) : error 033: array must be indexed (variable "
tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18468) : error 017: undefined symbol "
strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18468) : error 033: array must be indexed (variable "
tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18510) : error 017: undefined symbol "
strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18510) : error 033: array must be indexed (variable "
x_job")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18518) : error 017: undefined symbol "
strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18518) : error 033: array must be indexed (variable "
tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18613) : error 017: undefined symbol "
strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18613) : error 033: array must be indexed (variable "
tmp")
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18922) : error 017: undefined symbol "
strtok"
C:\Documents and Settings\Administrador\Desktop\BNC\Gamemode NV\gamemodes\BNC.pwn(18922) : error 033: array must be indexed (variable "
tmp")

Compilation aborted.Pawn compiler 3.2.3664          Copyright © 1997-2006, ITB CompuPhase


26 Errors.
1 das Linhas
pawn Код:
if (strcmp(cmd, "/ver", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (PlayerInfo[playerid][pAdmin] >= 1)
            {
                tmp = strtok(cmdtext, idx);
                if(!strlen(tmp))
                {
                    SendClientMessage(playerid, COLOR_GRAD1, "USE: /ver [ id ]");
                    return 1;
                }
                if(admtrampando[playerid] < 1)
                {
                SendClientMessage(playerid, COLOR_GRAD1, "Vocк nгo estб trabalhando! (/profadmin)");
                return 1;
                }
                //giveplayerid = strval(tmp);
                giveplayerid = ReturnUser(tmp);
                if(IsPlayerConnected(giveplayerid))
                {
                    if(giveplayerid != INVALID_PLAYER_ID)
                    {
                        ShowStats(playerid,giveplayerid);
                    }
                }
                else
                {
                    SendClientMessage(playerid, COLOR_GRAD1, "   No Such Player");
                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD1, "   Voce nгo e admin !!");
            }
        }
        return 1;
    }
Reply
#2

Coloque a linha
Код:
new cmd[256];
na public OnPlayerCommandText.

Reply
#3

pawn Код:
new cmd[128];
cmd = strtok(cmdtext,idx);
Reply
#4

Duvido que alguйm coloque um comando de 128 caracteres...
Reply
#5

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    OnConsoleSaveData(playerid, cmdtext); //Grava Comandos
    new string[256];
    new playerdinheiro;
    new giveplayer[MAX_PLAYER_NAME];
    new playername[MAX_PLAYER_NAME];
    new plname[MAX_PLAYER_NAME];
    new cmd[256];
    new tmp[256];
    new giveplayerid, moneys, idx;
    cmd = strtok(cmdtext, idx);
    #if defined CARSELL
    #endif
So tem essa
Reply
#6

tire o #endif e
Reply
#7

retira as linhas
pawn Код:
#if defined CARSELL
    #endif
Reply
#8

Retirei e continua a mesma coisa !

C:\Documents and Settings\Administrador\Desktop\BCF\Gamemode NV\gamemodes\BNL.PWN(76364) : error 017: undefined symbol "cmd"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
Linha
pawn Код:
if(strcmp(cmd, "/entrarcassino", true) == 0)
Reply
#9

pawn Код:
if(strcmp(cmdtext, "/entrarcassino", true) == 0)
usa cmdtext.
Reply
#10

Jonathan CMDTEXT DA A MESMA MERDA E O PIOR QUE E SO NESTE COMANDO

Comando :
PHP код:
      if(strcmp(cmd"/entrarcassino"true) == 0)
{
     if(
PlayerToPoint(10.0playerid,-2765,382,6))
     
SetPlayerInterior(playerid1);
     
SetPlayerPos(playerid,2233.7998046875,1713.7144775391,1011.7869262695);
     
PlayerInfo[playerid][pInt] = 1;
    return 
0;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)