Este error
#1

Код:
CMD:comprar(playerid, params[])
{
	new choice[32];
	if(sscanf(params, "s[32]", choice))
	{
	SendClientMessage(playerid, COLOR_WHITE, "Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");
	return 1;
	}
	else if(strcmp(choice, "muebles", true) == 0)
	{
    if (PlayerToPoint(10, playerid,1328.0438,-1760.3077,13.5559)){
    ShowModelSelectionMenu(playerid, MueblesObj, "Muebles", 0x4A5A6BBB, 0x88888899, 0xFAFAFA);
	return 1;
    }
    else if(strcmp(choice, "productos", true) == 0)
    {
	if (PlayerToPoint(20, playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20, playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20, playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid)){
  	SafeDialogEx(playerid, STOREMENU, DIALOG_STYLE_LIST, "{00F70C}24/7", "Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000", "Comprar", "Cancelar");
    return 1;
	}
	else if(strcmp(choice, "electronicos", true) == 0)
    {
	if (PlayerToPoint(20, playerid,1006.0530,52.7181,55.3221)){
	SafeDialogEx(playerid, TIENDA_ELEC, DIALOG_STYLE_LIST, "{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750", "Comprar", "Salir");
	return 1;
    }
    return 1;
    }
Me tira 26 errores
Reply
#2

pawn Код:
CMD:comprar(playerid, params[])
{
    new choice[32];
   
    if(sscanf(params, "s[32]", choice)) return SendClientMessage(playerid, COLOR_WHITE, "Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");

    if(strcmp(choice, "muebles", true) == 0)
    {
        if (PlayerToPoint(10, playerid,1328.0438,-1760.3077,13.5559)){
        ShowModelSelectionMenu(playerid, MueblesObj, "Muebles", 0x4A5A6BBB, 0x88888899, 0xFAFAFA);
        return 1;
    }
    else if(strcmp(choice, "productos", true) == 0)
    {
        if (PlayerToPoint(20, playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20, playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20, playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid))
        {
            SafeDialogEx(playerid, STOREMENU, DIALOG_STYLE_LIST, "{00F70C}24/7", "Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000", "Comprar", "Cancelar");
            return 1;
        }
    }
    else if(strcmp(choice, "electronicos", true) == 0)
    {
        if (PlayerToPoint(20, playerid,1006.0530,52.7181,55.3221))
        {
            SafeDialogEx(playerid, TIENDA_ELEC, DIALOG_STYLE_LIST, "{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750", "Comprar", "Salir");
            return 1;
        }
    }
    return 1;
}
Reply
#3

Cuando te dб estos errores, significa que te has dejado una llave { }. Sуlo la debes poner en el lugar que corresponde y ya funcionarб.
Reply
#4

estб mal estructurado:
PHP код:
CMD:comprar(playeridparams[])
{
    new 
choice[32];
    if(
sscanf(params"s[32]"choice))
    {
        
SendClientMessage(playeridCOLOR_WHITE"Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");
        return 
1;
    }
    else if(
strcmp(choice"muebles"true) == 0)
    {
        if (
PlayerToPoint(10playerid,1328.0438,-1760.3077,13.5559))
        {
            
ShowModelSelectionMenu(playeridMueblesObj"Muebles"0x4A5A6BBB0x888888990xFAFAFA);
            return 
1;
        }
        else if(
strcmp(choice"productos"true) == 0// si falla PlayerToPoint pasa acб?. Mal.
        
{
            if (
PlayerToPoint(20playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid))
            {
                  
SafeDialogEx(playeridSTOREMENUDIALOG_STYLE_LIST"{00F70C}24/7""Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000""Comprar""Cancelar");
                return 
1;
            }
            else if(
strcmp(choice"electronicos"true) == 0)
            {
                if (
PlayerToPoint(20playerid,1006.0530,52.7181,55.3221))
                {
                    
SafeDialogEx(playeridTIENDA_ELECDIALOG_STYLE_LIST"{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750""Comprar""Salir");
                    return 
1;
                }
                return 
1;
            } 
Deberнa ser asн:
PHP код:
CMD:comprar(playeridparams[])
{
    new 
choice[16];
    if(
sscanf(params"s[16]"choice))
    {
        
SendClientMessage(playeridCOLOR_WHITE"Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");
        return 
1;
    }
    else if(
strcmp(choice"muebles"true) == 0)
    {
        if (
PlayerToPoint(10playerid,1328.0438,-1760.3077,13.5559))
        {
            
ShowModelSelectionMenu(playeridMueblesObj"Muebles"0x4A5A6BBB0x888888990xFAFAFA);
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de muebles");
    }
    else if(
strcmp(choice"productos"true) == 0
    {
        if (
PlayerToPoint(20playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid))
        {
              
SafeDialogEx(playeridSTOREMENUDIALOG_STYLE_LIST"{00F70C}24/7""Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000""Comprar""Cancelar");
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de productos");
    }
    else if(
strcmp(choice"electronicos"true) == 0)
    {
        if (
PlayerToPoint(20playerid,1006.0530,52.7181,55.3221))
        {
            
SafeDialogEx(playeridTIENDA_ELECDIALOG_STYLE_LIST"{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750""Comprar""Salir");
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de electronicos");
    }
    return 
1;

Reply
#5

Quote:
Originally Posted by jotajeda
Посмотреть сообщение
estб mal estructurado:
PHP код:
CMD:comprar(playeridparams[])
{
    new 
choice[32];
    if(
sscanf(params"s[32]"choice))
    {
        
SendClientMessage(playeridCOLOR_WHITE"Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");
        return 
1;
    }
    else if(
strcmp(choice"muebles"true) == 0)
    {
        if (
PlayerToPoint(10playerid,1328.0438,-1760.3077,13.5559))
        {
            
ShowModelSelectionMenu(playeridMueblesObj"Muebles"0x4A5A6BBB0x888888990xFAFAFA);
            return 
1;
        }
        else if(
strcmp(choice"productos"true) == 0// si falla PlayerToPoint pasa acб?. Mal.
        
{
            if (
PlayerToPoint(20playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid))
            {
                  
SafeDialogEx(playeridSTOREMENUDIALOG_STYLE_LIST"{00F70C}24/7""Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000""Comprar""Cancelar");
                return 
1;
            }
            else if(
strcmp(choice"electronicos"true) == 0)
            {
                if (
PlayerToPoint(20playerid,1006.0530,52.7181,55.3221))
                {
                    
SafeDialogEx(playeridTIENDA_ELECDIALOG_STYLE_LIST"{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750""Comprar""Salir");
                    return 
1;
                }
                return 
1;
            } 
Deberнa ser asн:
PHP код:
CMD:comprar(playeridparams[])
{
    new 
choice[16];
    if(
sscanf(params"s[16]"choice))
    {
        
SendClientMessage(playeridCOLOR_WHITE"Info: Uso correcto: /Comprar Muebles - Productos - Electronicos");
        return 
1;
    }
    else if(
strcmp(choice"muebles"true) == 0)
    {
        if (
PlayerToPoint(10playerid,1328.0438,-1760.3077,13.5559))
        {
            
ShowModelSelectionMenu(playeridMueblesObj"Muebles"0x4A5A6BBB0x888888990xFAFAFA);
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de muebles");
    }
    else if(
strcmp(choice"productos"true) == 0
    {
        if (
PlayerToPoint(20playerid,-22.3260,-138.6221,1003.5469)||PlayerToPoint(20playerid,-25.6448,-56.6718,1003.5469)||PlayerToPoint(20playerid,-29.3554,-28.8020,1003.5573)|| IsAt247(playerid))
        {
              
SafeDialogEx(playeridSTOREMENUDIALOG_STYLE_LIST"{00F70C}24/7""Loteria\t\t\t$10\nSpray\t\t\t$100\nCigarros\t\t$40\nEncendedor\t\t$20\nFlores\t\t\t$7\nSprunk\t\t\t$8\nSeguro Alarma\t\t$500\nSeguro Industrial\t$2000""Comprar""Cancelar");
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de productos");
    }
    else if(
strcmp(choice"electronicos"true) == 0)
    {
        if (
PlayerToPoint(20playerid,1006.0530,52.7181,55.3221))
        {
            
SafeDialogEx(playeridTIENDA_ELECDIALOG_STYLE_LIST"{00F70C}Tienda electronica","Telйfono\t\t$250\nAgenda\t\t$20\nCбmara\t\t\t$160\nRadio Portable\t\t$800\nIpodMusic\t\t$850\nBoombox\t\t$750""Comprar""Salir");
            return 
1;
        }else return 
SendClientMessage(playerid, -1"No estas en el lugar de compra de electronicos");
    }
    return 
1;

Muchas gracias 1+rep
Reply
#6

PHP код:
        if(!IsAtClothShop(playerid)) return SendClientMessageEx(playeridCOLOR_GRAD2"No estбs en una tienda de Ropa.");
        if(
IsPlayerConnected(playerid)){
            
ShowModelSelectionMenu(playeridskinlist"Selecciona Tu Nuevo Skin");
        }
        else 
SendClientMessageEx(playeridCOLOR_WHITE"No estбs conectado."); 
їCуmo lo puedo implementar ahн?
Reply
#7

?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)