#1

Hi,
When i use cmd:ads there're menu opened like Next Generation Gaming Server but when i choose any thing from the menu, nothing happen i don't know why?
There're codes
PHP код:
CMD:ad(playeridparams[])
{
    
SendClientMessageEx(playeridCOLOR_WHITE"The /ad command has been removed - use /ads or /advertisements.");
    return 
1;
}
CMD:ads(playeridparams[]) {
    return 
cmd_advertisements(playeridparams);
}
CMD:advertisements(playeridparams[]) {
    if(
gPlayerLogged{playerid} == 0) {
        
SendClientMessageEx(playeridCOLOR_GREY"You're not logged in.");
    }
    else if(
GetPVarType(playerid"Injured")) {
        
SendClientMessageEx(playeridCOLOR_GREY"You can't use advertisements while injured.");
    }
    else if(
PlayerCuffed[playerid] != 0) {
        
SendClientMessageEx(playeridCOLOR_GREY"You can't use advertisements right now.");
    }
    else if(
PlayerInfo[playerid][pJailTime] > 0) {
        
SendClientMessageEx(playeridCOLOR_GREY"You can't use advertisements while in jail.");
    }
    else 
ShowPlayerDialog(playeridDIALOG_ADMAINDIALOG_STYLE_LIST"Advertisements""List Advertisements\nSearch Advertisements\nPlace Advertisement\nPlace Priority Advertisement""Select""Cancel");
    return 
1;

Reply
#2

You haven't declared anything regarding that dialogid, and no, that's certainly not a bug.
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    switch(dialogid)
    {
        case DIALOG_ADMAIN:
        {
            if(response)
            {
                switch(listitem)
                {
                    case 0: // do stuff here - List Advertisements
                    case 1: // Search Advertisements
                    case 2: // Place Advertisement
                    case 3: // Priority Advertisement
                    // etc..
                }
            }
        }      
    }
    return 1;
}
Reply
#3

Should i add this codes?
Reply
#4

Are you seriously asking or..?
Reply
#5

Quote:

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid)
{
case DIALOG_ADMAIN:
{
if(response)
{
switch(listitem)
{
case 0: // do stuff here - List Advertisements
case 1: // Search Advertisements
case 2: // Place Advertisement
case 3: // Priority Advertisement
// etc..
}
}
}
}
return 1;
}

I dont have this codes in my script but this list which appeared when any one use /ads
Quote:

{
case 0: // do stuff here - List Advertisements
case 1: // Search Advertisements
case 2: // Place Advertisement
case 3: // Priority Advertisement

Reply
#6

I'm sorry, if you can't understand the code above, I cannot help you further.
Reply
#7

Quote:

Are you seriously asking or..?

Listen i seriously asking because i don't know any thing about how to script :/
Just little bit..
Reply
#8

Go and study programming in general before trying to jump into a project which you can't handle, with all honesty.
Reply
#9

Quote:

Go and study programming in general before trying to jump into a project which you can't handle, with all honesty.

I Promise you that i will try to study them, but that's the only problem on my server so i want to fix you just define to me to how to add the lost codes., Please if you want i need help..
Reply
#10

Bump any one help me?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)