17.09.2012, 18:23
pawn Код:
#include <a_samp>
public OnPlayerConnect(playerid)
{
new File:playerinfos, pntFinal[MAX_PLAYER_NAME+15+11], pntName[MAX_PLAYER_NAME], pntIp[15];
GetPlayerName(playerid,pntName,sizeof(pntName));
GetPlayerIp(playerid,pntIp,sizeof(pntIp));
format(pntFinal,sizeof(pntFinal),"Name: %s | IP: %s",pntName,pntIp);
playerinfos = fopen("playerinfos.txt",io_append);
if (playerinfos)
{
fwrite(playerinfos,pntFinal);
fclose(playerinfos);
}
return 1;
}