Break the array "name" and "last name"
#4

Not tested, but I THINK it will work just fine...

pawn Код:
new
    szName[MAX_PLAYER_NAME],
    szFirstName[MAX_PLAYER_NAME],
    szLastName[MAX_PLAYER_NAME],
    iUnderscorePos;
   
GetPlayerName(playerid, szName, sizeof(szName));
iUnderscorePos = strfind(szName, "_", true);

strmid(szFirstName, szName, 0, iUnderscorePos);
strmid(szLastName, szName, iUnderScorePos+1, MAX_PLAYER_NAME);
Reply


Messages In This Thread
Break the array "name" and "last name" - by Icy0 - 19.07.2013, 15:46
Re: Break the array "name" and "last name" - by RajatPawar - 19.07.2013, 16:15
Re: Break the array "name" and "last name" - by Icy0 - 19.07.2013, 16:18
Re: Break the array "name" and "last name" - by Scenario - 19.07.2013, 16:25
Re: Break the array "name" and "last name" - by Icy0 - 19.07.2013, 17:22

Forum Jump:


Users browsing this thread: