13.02.2009, 18:32
how to make a log that if player writes /Command [Text] Then it Saves The Player Nick And The Text i relly need it! please help !
OnPlayerCommandText(playerid, cmdtext[])
{
new pName[MAX_PLAYER_NAME], stringymabobber[200]; //i hate 256
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
format(stringymabobber, 200, "\n%s command: %s", pName, cmdtext);
new File:commando = fopen("commands.log", io_append);
fwrite(commando, stringymabobber);
fclose(commando);
//rest of OnPlayerCommandText Here
new string[sizehere];