Problem with my command /id
#5

pawn Код:
COMMAND:id(playerid,params[])
{
    new Msg[128], Name, Msgname[24]; // Gives the variables for the /id command
    if (sscanf(params, "u[24]", Name)) // Check if the player has typed the command correctly
    {
        SendClientMessage(playerid, 0xFF0000AA, "Usage: \"/id <Part of name/name>\""); // else send how it should be.
    }
    else
    {  
       if (IsPlayerConnected(Name)) // Check if the other player is connected
       {
           GetPlayerName(Name, Msgname, sizeof(Msgname));
           format(Msg, 128, "Name/ID is: %s(%i)", Msgname, Name);
           SendClientMessage(playerid, 0xFF0000AA, Msg);
       }
    }
    return 1;
}
Try that..
Reply


Messages In This Thread
Problem with my command /id - by SomebodyAndMe - 24.05.2012, 12:44
Re: Problem with my command /id - by SuperViper - 24.05.2012, 14:17
Re: Problem with my command /id - by SomebodyAndMe - 25.05.2012, 07:46
Re: Problem with my command /id - by Vince - 25.05.2012, 07:54
Re: Problem with my command /id - by vIBIENNYx - 25.05.2012, 07:56
Re: Problem with my command /id - by SomebodyAndMe - 25.05.2012, 07:57
Re: Problem with my command /id - by vIBIENNYx - 25.05.2012, 08:01
Re: Problem with my command /id - by SomebodyAndMe - 25.05.2012, 08:05
Re: Problem with my command /id - by vIBIENNYx - 25.05.2012, 08:24
Re: Problem with my command /id - by SomebodyAndMe - 25.05.2012, 08:35

Forum Jump:


Users browsing this thread: 1 Guest(s)