printf
#5

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
It must be inside the callback.
pawn Код:
public OnPlayerCommandPerformed( playerid, cmdtext[ ], success )
{
    new
        msg_[ 64 ],
        name_[ MAX_PLAYER_NAME ]
    ;
    GetPlayerName( playerid, name_, MAX_PLAYER_NAME );
    format( msg_, sizeof( msg_ ), "(CMD) %s: %s", name_, cmdtext );
    print( msg_ );

    for(new i = 0; i < MAX_PLAYERS; i++ )
    {
        if( !IsPlayerConnected( i ) || !IsPlayerAdmin( i ) ) continue;
       
        SendClientMessage( i, 0x754829AA, msg_ );
    }

    if( !success ) return 0;
    return 1;
}
You've already format it, just print it! No need to use printf.
sorry but can u help me with this code i want when i do clearchat i got message "Admin blalala has cleared the chat"
and sorry again for my suck english :/

Код:
CMD:clearchat(playerid,params[])
{
   if(!IsPlayerAdmin( playerid ) )return SCM( playerid, RED, "Unknown Command! Type /help" );
   
   for(new i = 0; i < 100; i++) SCMA(-1 ," ");
   
   return 1;
}
Reply


Messages In This Thread
printf - by Another1 - 15.10.2013, 16:26
Re: printf - by Konstantinos - 15.10.2013, 16:29
AW: printf - by BigETI - 15.10.2013, 16:29
Re: printf - by Another1 - 15.10.2013, 17:30
Re: printf - by Another1 - 15.10.2013, 17:34
Re: printf - by Patrick - 15.10.2013, 17:38
Re: printf - by Konstantinos - 15.10.2013, 17:39
Re: printf - by Djole1337 - 15.10.2013, 17:48
Re: printf - by Konstantinos - 15.10.2013, 17:53
Re: printf - by Another1 - 15.10.2013, 19:17

Forum Jump:


Users browsing this thread: 2 Guest(s)