MUILI Dialog
#1

Can anyone help me. how to create a muli dialog.
Reply
#2

What do you mean? Do you have any screenshots or can you explain?
Reply
#3

Quote:
Originally Posted by AndreiWow
Посмотреть сообщение
What do you mean? Do you have any screenshots or can you explain?
It's like a control panel



I want this to be first in dialog. then it go on like Set Message then the next can be a message saying "Test".



Код:
  if(dialogid == 97)
    {
        if(response)
        {
            new string[128], query[128];
            format(string, sizeof(string), "You had set your message to: %s", inputtext);
            SendClientMessage(playerid, -1, string);
            format(PlayerInfo[playerid][personalmsg], 128, "%s", inputtext);
            //save player account
            mysql_format(mysql, query, sizeof(query), "UPDATE `accounts` SET `SCORE`= %i , `Admin` = '%i' , `personalmsg` = '%e' WHERE `ID` = '%d'", GetPlayerScore(playerid), PlayerInfo[playerid][pAdmin], PlayerInfo[playerid][personalmsg], PlayerInfo[playerid][ID]);
            mysql_query(mysql, query);
            print(query);
            return 1;
        }
    }
Код:
CMD:cp(playerid,params[])   cp = Control Panel
{
    ShowPlayerDialog(playerid,97,DIALOG_STYLE_INPUT,"Join Message","Enter the new join message you want to set","Set","Close");
    return 1;
}
Reply
#4

I guess you have already done what you want. just send this message when he connects, like
pawn Код:
enum p_data
{
    personalmsg[128]//make sure you've added this array which makes it a string later
};
new PlayerInfo[MAX_PLAYERS][p_data];
public OnPlayerConnect(playerid)
{
    new
        str[126];
    format(str, sizeof(str), "Your personal message is: %s", PlayerInfo[playerid][personalmsg]);
    SendClientMessage(playerid, -1, str);
//or show him a dialog if you want.
        ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_MSGBOX, "Personal Message", str, "Close", "");
    return true;
}
If I am wrong, please explain more. or show errors if there is any.
Reply
#5

Quote:
Originally Posted by SilentSoul
Посмотреть сообщение
I guess you have already done what you want. just send this message when he connects, like
pawn Код:
enum p_data
{
    personalmsg[128]//make sure you've added this array which makes it a string later
};
new PlayerInfo[MAX_PLAYERS][p_data];
public OnPlayerConnect(playerid)
{
    new
        str[126];
    format(str, sizeof(str), "Your personal message is: %s", PlayerInfo[playerid][personalmsg]);
    SendClientMessage(playerid, -1, str);
//or show him a dialog if you want.
        ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_MSGBOX, "Personal Message", str, "Close", "");
    return true;
}
If I am wrong, please explain more. or show errors if there is any.
No not Onplayerconnect. not a single dialog. i want a muli dialog. which i can do more inside of it . but it need to be in /cp command

It's like a weapon system. but togeter dialog
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)