Dialog.
#1

I had this working fine, however I modified it for multiplayer use. When a project is created, a new table is created in the database for the "ranks" what i'm trying to do is this: When you click "Open Project" it shows any projects that have your name in that table, however, it don't work.



pawn Код:
if(listitem == 1)
            {
                new string[51];
                new string1[MAX_PROJECT_LENGTH];
                for(new i; i<MAX_PROJECTS; i++)
                {
                    new Query[500];
                    format(Query, sizeof(Query), "SELECT * FROM `PROJECT_%d_RANKS` WHERE `ID` = %d", i, PlayerInfo[pid][pID]);
                    mysql_query(Query);
                    mysql_store_result();
                    if(mysql_num_rows())
                    {
                        if(i != MAX_PROJECTS-1)
                        {
                            format(string, sizeof(string), "\n%d:\t%s", i, ProjectInfo[i][prName]);
                            strcat(string1, string);
                        }
                    }
                }
               
                ShowPlayerDialog(pid, Project_Dialog, DIALOG_STYLE_LIST, "Select a project", string1, "Okay", "Cancel");
                PlayerInfo[pid][pProjects] = string1;
            }
Reply


Messages In This Thread
Dialog. - by TakeiT - 19.07.2014, 20:26
Re: Dialog. - by sammp - 19.07.2014, 22:53
Re: Dialog. - by TakeiT - 20.07.2014, 00:50
Re: Dialog. - by sammp - 20.07.2014, 01:17
Re: Dialog. - by TakeiT - 20.07.2014, 13:11

Forum Jump:


Users browsing this thread: 1 Guest(s)