Problem with dialog
#1

pawn Код:
returnFactionLockers(playerid, iFaction)
{
    new szDialog[1024], szGun[32];
    strcat(szDialog, "Badge (on/off-duty)\nKevlar Vest (100 armour)\nNew Uniform (100 health)\nX26 Tazer\nHandcuffs (x2)");
    for(new w = 0; w < MAX_FACTION_WEAPON; w++) {
        GetWeaponName(FactionInfo[iFaction][fI_Weapons][w], szGun, 32);
        if(FactionInfo[iFaction][fI_Weapons][w] != 0) {
            format(szDialog, sizeof(szDialog), "%s\n%s", szDialog, szGun);
        }
    }
    return ShowPlayerDialog(playerid, DIALOG_FACLOCKER, DIALOG_STYLE_LIST, "{42C2F5}["SERVER_NAME": {FFFFFF}Faction Locker{42C2F5}]", szDialog, "Take", "Close");
}
Okay I have this function which will appear when you do /locker, anyway; its the strcat thats the problem.

I have the vest, badge, cuffs, etc but when the dialog loads and I attempt to take one of those it doesn't do anything, whereas if I take a weapon it works fine.

(the weapon taking system works fine)

Dialog response code: http://pastebin.com/nHb2pW16

All help appreciated
Reply
#2

Nobody?
Reply
#3

Quote:
Originally Posted by MattSlater
Посмотреть сообщение
Nobody?
Standby

Quote:
Originally Posted by MattSlater
Посмотреть сообщение
Nobody?
Can i see the Dialog code Example #define your_dialog?

Can you tell me what works and what doesn't?
Reply
#4

pawn Код:
return FactionLockers(playerid, iFaction)
{
    new szDialog[1024], szGun[32];
    strcat(szDialog, "Badge (on/off-duty)\nKevlar Vest (100 armour)\nNew Uniform (100 health)\nX26 Tazer\nHandcuffs (x2)");
    for(new w = 0; w < MAX_FACTION_WEAPON; w++) {
        GetWeaponName(FactionInfo[iFaction][fI_Weapons][w], szGun, 32);
        if(FactionInfo[iFaction][fI_Weapons][w] != 0) {
            format(szDialog, sizeof(szDialog), "%s\n%s", szDialog, szGun);
        }
    }
    return ShowPlayerDialog(playerid, DIALOG_FACLOCKER, DIALOG_STYLE_LIST, "{42C2F5}SERVER_NAME"": {FFFFFF}Faction Locker{42C2F5}]", szDialog, "Take", "Close");
}
Reply
#5

That doesn't work since "returnFactionLockers" is a function, thank you anyway
Reply
#6

Bump
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)