SERVER: Unknown command
#1

This is the second command that I'm creating as I had never created any command and CMD, hope not to bother and if they can help me since I have upset many friends.

I do not speak English and I'm using the ****** translator, a thousand apologies.

PHP код:
CMD:comprarcasa(playeridparams[]) 

    new 
houseid = -1
    for(new 
0MAX_CASASi++) 
    { 
        if(
IsPlayerInRangeOfPoint(playerid2.5CasaInfo[i][cPosX], CasaInfo[i][cPosY], CasaInfo[i][cPosZ])) 
        { 
            if(
CasaInfo[houseid][cPropietario] != 0) return SendClientMessage(playeridCOLOR_ROJO"ERROR: {C7C7C7}Esta casa no estб en venta."); 
            if(
CasaInfo[houseid][cPrecio] > PlayerInfo[playerid][Dinero]) return SendClientMessage(playeridCOLOR_ROJO"ERROR: {C7C7C7}No tienes el dinero suficiente para adquirir estб casa."); 
            
CasaInfo[i][cPropietario] = PlayerInfo[playerid][ID]; 
            
ActualizarCasas(houseid); 
            
GuardarCasas(houseid); 
            
GivePlayerMoney(playerid, -CasaInfo[i][cPrecio]); 
            
SendClientMessageEx(playeridCOLOR_VERDE_1"INFORMACIУN: {C7C7C7}Has adquirido una nueva casa por %s."FormatoCantidad(CasaInfo[i][cPrecio])); 
        } 
        else return 
SendClientMessage(playeridCOLOR_ROJO"ERROR: {C7C7C7}No estбs cerca de una casa para utilizar el comando."); 
    } 
    return 
1



This happens when I create a second home, the error only happens with ID 1 House the other houses not

Reply


Messages In This Thread
SERVER: Unknown command - by wharlos - 13.05.2016, 00:50
Re: SERVER: Unknown command - by KevinReinke - 13.05.2016, 01:13

Forum Jump:


Users browsing this thread: 1 Guest(s)