Problem with name's
#1

Код:
If i connect to my server there stands:
Player logged in (level: [level])
So there stands nothing after Player!
no name or something!
this is the Code:
[pawn]format(string, sizeof(string), "** Player %s has been logged in (level: %d) **", PlayerName[playerid], PlayerInfo[playerid][pLevel]);
the same with:
pawn Код:
format(string, sizeof(string), "** Welcome %s(%d) to: BadCrime - Streets of San Andreas **", PlayerName[playerid], playerid);
but the biggest problem is with the login/register system!
the filename is nothing!
Reply
#2

where is this line:

[pawn]format(string, sizeof(string), "** Player %s has been logged in (level: %d) **", PlayerName[playerid], PlayerInfo[playerid][pLevel]);

probably somewhere where "playerid" isn't defined... ?
Reply
#3

PlayerName[] has to be given a string for it to return a string.

under OnPlayerConnect, add

pawn Код:
public OnPlayerConnect(playerid)
{
  GetPlayerName(playerid,PlayerName[playerid],MAX_PLAYER_NAME);
  //Your code here
}
Reply
#4

Thanks joe,
i forget to do that!
Reply
#5

hehe
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)