When i type /createbiz Server Stopped
#1

Hello Guys When i type /createbiz Server stopped i try to fix it but cant can u help me ?


PHP код:
CMD:createbiz(playeridparams[])
{
    new 
typestring[128];
    if(!
IsPlayerConnected(playerid)) return SendClientMessage(playeridCOLOR_GREY"You need to login first before using any command.");
    if(
IsPlayerAdmin(playerid)) return SendClientMessage(playeridCOLOR_GREY"You are not authorized to use this command.");
//    if(!aDuty[playerid]) return SendClientMessage(playerid, COLOR_GREY, "You are not on admin duty.");
    
if(sscanf(params"i"type))
    {
        
SendClientMessage(playeridCOLOR_WHITE"USAGE: /createbiz [type]");
        
SendClientMessage(playeridCOLOR_GREY"TYPES: 1) 24/7 | 2) Clothes Shop | 3) Ammunation | 4) Club | 5) Advertisement Agency | 6) Fast Food | 7) Casino");
        return 
1;
    }
    if(
type || type 7) return SendClientMessage(playeridCOLOR_GREY"Businesses are between 1 and 7.");
    for(new 
idx=1idx<MAX_BIZidx++)
    {
        if(!
BizInfo[idx][bType])
        {
            
//g_bizRobber[idx] = -1;
            // Getting Business Setup
            
new Float:XFloat:YFloat:Z;
            
GetPlayerPos(playeridXYZ);
            
// Making Business
            
BizInfo[idx][bType] = type;
            
BizInfo[idx][bStatus] = 0;
            
format(BizInfo[idx][bOwner], 32"The State");
            
BizInfo[idx][bX] = X;
            
BizInfo[idx][bY] = Y;
            
BizInfo[idx][bZ] = Z;
            
BizInfo[idx][bMoney] = 1000;
            
BizInfo[idx][bProducts] = 0;
            
BizInfo[idx][bSold] = 0;
            
BizInfo[idx][bLevel] = 1;
            
BizInfo[idx][bPrice] = 99999999;
            if(
BizInfo[idx][bType] == 1)
            {
                 
BizInfo[idx][bPickup] = CreateDynamicPickup(12741XYZ0);
            }
            if(
BizInfo[idx][bType] == 2)
            {
                 
BizInfo[idx][bPickup] = CreateDynamicPickup(12751XYZ0);
            }
            if(
BizInfo[idx][bType] == 3)
            {
                 
BizInfo[idx][bPickup] = CreateDynamicPickup(12421XYZ0);
            }
            if(
BizInfo[idx][bType] == 4)
            {
                 
BizInfo[idx][bPickup] = CreateDynamicPickup(12721XYZ0);
            }
            if(
BizInfo[idx][bType] == 5)
            {
                 
BizInfo[idx][bPickup] = CreateDynamicPickup(12391XYZ0);
            }
            if(
BizInfo[idx][bType] == 6)
            {
                
BizInfo[idx][bPickup] = CreateDynamicPickup(12721XYZ0);
            }
             if(
BizInfo[idx][bType] == 7)
            {
                
BizInfo[idx][bPickup] = CreateDynamicPickup(12721XYZ0);
            }
            
format(stringsizeof(string), "{FC2B6A}[Business ID: %d]{FFFFFF}\nBusiness Type: %s\nBusiness Owner: %s\nStatus: For Sale\nPrice: $%d"idxRBT(idx), BizInfo[idx][bOwner], BizInfo[idx][bPrice]);
            
BizInfo[idx][bText] = CreateDynamic3DTextLabel(stringCOLOR_REDXYZ15);
            
format(stringsizeof(string), "AdmWarn: %s has created business ID %d."RPN(playerid), idx);
            
ABroadCast(COLOR_LIGHTREDstring2);
            
Log("logs/business.log"string);
            
idx MAX_BIZ;
            
SaveBiz();
        }
    }
    return 
1;

what happend ? Did this for im not make A Folder? At scirptfiles? there are biz.cfg i add its work when im create a biz
Reply


Messages In This Thread
When i type /createbiz Server Stopped - by RedRex - 28.05.2016, 14:42
Re: When i type /createbiz Server Stopped - by andrejc999 - 28.05.2016, 14:50
Re: When i type /createbiz Server Stopped - by Unrea1 - 28.05.2016, 14:51
Re: When i type /createbiz Server Stopped - by RedRex - 28.05.2016, 15:02
Re: When i type /createbiz Server Stopped - by CodeStyle175 - 28.05.2016, 16:04

Forum Jump:


Users browsing this thread: 1 Guest(s)