Gathering variables
#10

You need to use format.

pawn Код:
new PlateString[MAX_PLAYERS][124]; // This is the license plate string.

CMD:setplate(playerid,params[])
{
    new string[124];
    if(isnull(params))
    {
        return SendClientMessage(playerid,-1,"USAGE: /setplate [platetext]");
    }
    else
    {
        new msgstring[124];
        PlateString[playerid] = string; // Sets the players plate string to what was typed.
        format(msgstring,sizeof(msgstring),"You have set your plate to %s",string); // Formats so you could see what was typed
        SendClientMessage(playerid,-1,msgstring); // Sends the formatted message.
        return 1;
    }
}
Reply


Messages In This Thread
Gathering variables - by falor - 01.03.2012, 22:40
Re: Gathering variables - by Walsh - 01.03.2012, 22:55
Re : Gathering variables - by falor - 02.03.2012, 00:27
Re: Gathering variables - by Walsh - 02.03.2012, 00:46
Re : Gathering variables - by falor - 02.03.2012, 00:49
Re: Gathering variables - by Walsh - 02.03.2012, 00:53
Re : Gathering variables - by falor - 02.03.2012, 00:56
Re: Gathering variables - by Walsh - 02.03.2012, 01:01
Re : Gathering variables - by falor - 02.03.2012, 01:08
Re: Gathering variables - by Walsh - 02.03.2012, 01:21

Forum Jump:


Users browsing this thread: 3 Guest(s)