29.12.2015, 11:45
You have a bracket after PlayerInfo[giveplayerid][pHeadValue] and you need to put a \ at the end of the line.
This is correct:
This is correct:
pawn Код:
CMD:profile(playerid, params[])
{
if(IsAHitman(playerid))
{
new string[128], giveplayerid;
if(sscanf(params, "u", giveplayerid)) return SendClientMessageEx(playerid, COLOR_GREY, "USAGE: /profile [player]");
if(IsPlayerConnected(giveplayerid))
{
format(string, sizeof(string), "Name: %s\n \
Date of Birth: %s\n \
Phone Number: %s\n \
Bounty: %s\n \
Bounty Reason: %s\n",
GetPlayerNameEx(giveplayerid),
PlayerInfo[giveplayerid][pBirthDate],
PlayerInfo[giveplayerid][pPnumber],
PlayerInfo[giveplayerid][pHeadValue],
PlayerInfo[giveplayerid][pContractDetail]);
ShowPlayerDialog(playerid, DIALOG_PROFILE,DIALOG_STYLE_MSGBOX,"Target Profile",string,"OK");
}
}
return 1;
}