RRace...
#1

Hi, how i cand make a dialog to show all avabile races...i use RRace system...
i have somethink like this:
pawn Код:
CMD:realraces( PARAMS )
{
    new str[ 128 ], str2[ 1024 ];
   
    LoadRaceNames( );
    format( str2, sizeof( str2 ), "{FFFFFF}" );
    Loop( x, TotalRaces )
    {
        format(  str, 128, "%s\n", RaceNames[ x ] );
        strcat(  str2, str, 1024 );
    }
    ShowPlayerDialog(  playerid, CURSE_REALE, DIALOG_STYLE_LIST, "{FFFFFF}Avabile Races:", str, "Join", "Cancel" );
    return 1;
}
But it shows me just LV Race...

And a secound question is...:

How i can make a dialog response for that dialog?
Reply
#2

Change
Код:
ShowPlayerDialog(  playerid, CURSE_REALE, DIALOG_STYLE_LIST, "{FFFFFF}Avabile Races:", str, "Join", "Cancel" );
to
Код:
ShowPlayerDialog(  playerid, CURSE_REALE, DIALOG_STYLE_LIST, "{FFFFFF}Avabile Races:", str2, "Join", "Cancel" );
EDIT: And a response with what ? Use listitem ... Race[ listitem ][ Started ] ... something like this.
Reply
#3

Yeah thats work that you say there but on OnDialogResponse i type This:
pawn Код:
if ( dialogid == CURSE_REALE && response )
{
    LoadRace( playerid, listitem );
}
and it give me this error:
[pawn]
C:\Documents and Settings\user\My Documents\RAS&MAP&FS&SERVERS\RAS\gamemodes\RAS.pwn (7962) : error 035: argument type mismatch (argument 2)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)