new
string[ 128 ],
Age = PlayerInfo[ playerid ][ pAge ],
Money = GetPlayerCash( playerid )
;
new Sex[20];
if(PlayerInfo[ playerid ][ pSex ] == 1) { Sex = "Male"; }
else if(PlayerInfo[ playerid ][ pSex ] == 2) { Sex = "Female"; }
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_________________________STATISTICS OF %s_________________________, pName");
SendClientMessage(playerid, -1, "");
format(string, sizeof(string), "Name: {FFFFFF}%s {6FDD96}| Money: {FFFFFF}%d {6FDD96}| Age: {FFFFFF}%d {6FDD96}| Sex: {FFFFFF}%s", pName, Money, Age, Sex);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
SendClientMessage(playerid, -1, "");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"____________________________________________________________________");
SendClientMessage(playerid, -1, "");
print("DEBUG: CMDSTART");
new
string[ 128 ],
Age = PlayerInfo[ playerid ][ pAge ],
Money = GetPlayerCash( playerid )
;
print("DEBUG: 1");
new Sex[20];
if(PlayerInfo[ playerid ][ pSex ] == 1) { Sex = "Male"; }
else if(PlayerInfo[ playerid ][ pSex ] == 2) { Sex = "Female"; }
print("DEBUG: 2");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_________________________STATISTICS OF %s_________________________, pName");
SendClientMessage(playerid, -1, "");
format(string, sizeof(string), "Name: {FFFFFF}%s {6FDD96}| Money: {FFFFFF}%d {6FDD96}| Age: {FFFFFF}%d {6FDD96}| Sex: {FFFFFF}%s", pName, Money, Age, Sex);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
SendClientMessage(playerid, -1, "");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"____________________________________________________________________");
print("DEBUG:3");
idk try remove
Код:
SendClientMessage(playerid, -1, ""); |
[09:24:21] DEBUG: CMDSTART [09:24:21] DEBUG: 1 [09:24:21] DEBUG: 2 [09:24:21] [debug] Server crashed while executing saonline.amx [09:24:21] [debug] AMX backtrace: [09:24:21] [debug] #0 native SendClientMessage () [004703a0] from samp-server.exe [09:24:21] [debug] #1 0001a904 in public cmd_stats (0x00000000, 0x01025ec8) from saonline.amx [09:24:21] [debug] #2 native CallLocalFunction () [00472ad0] from samp-server.exe [09:24:21] [debug] #3 000009c4 in public OnPlayerCommandText (0x00000000, 0x01025eac) from saonline.amx [09:24:21] [debug] Native backtrace: [09:24:21] [debug] #0 004989ec in ?? () from samp-server.exe [09:24:21] [debug] #1 747a6977 in ?? () from samp-server.exe [09:24:21] [debug] #2 770b3ca4 in ?? () from C:\Windows\SysWOW64\ntdll.dll [09:24:21] [debug] #3 770b3cfe in ?? () from C:\Windows\SysWOW64\ntdll.dll [09:24:21] [debug] #4 770b3ca4 in ?? () from C:\Windows\SysWOW64\ntdll.dll [09:24:21] [debug] #5 0045a965 in ?? () from samp-server.exe [09:24:21] [debug] #6 770b3ca4 in ?? () from C:\Windows\SysWOW64\ntdll.dll
CMD:stats(playerid, params[])
{
GetPlayerName(playerid, pName, sizeof(pName));
if(IsPlayerConnected(playerid))
{
print("DEBUG: CMDSTART");
new
string[ 128 ],
Age = PlayerInfo[ playerid ][ pAge ],
Money = GetPlayerCash( playerid )
;
print("DEBUG: 1");
new Sex[20];
if(PlayerInfo[ playerid ][ pSex ] == 1) { Sex = "Male"; }
else if(PlayerInfo[ playerid ][ pSex ] == 2) { Sex = "Female"; }
print("DEBUG: 2");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_________________________STATISTICS OF %s_________________________, pName");
SendClientMessage(playerid, -1, "");
format(string, sizeof(string), "Name: {FFFFFF}%s {6FDD96}| Money: {FFFFFF}%d {6FDD96}| Age: {FFFFFF}%d {6FDD96}| Sex: {FFFFFF}%s", pName, Money, Age, Sex);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
SendClientMessage(playerid, -1, "");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"____________________________________________________________________");
print("DEBUG:3");
}
return 1;
}
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_________________________STATISTICS OF %s_________________________, pName");
format(string, sizeof(string), "_________________________STATISTICS OF %s_________________________",pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
CMD:stats(playerid, params[])
{
GetPlayerName(playerid, pName, sizeof(pName));
if(IsPlayerConnected(playerid))
{
print("DEBUG: CMDSTART");
new
string[ 128 ],
Age = PlayerInfo[ playerid ][ pAge ],
Money = GetPlayerCash( playerid )
;
print("DEBUG: 1");
new Sex[20];
if(PlayerInfo[ playerid ][ pSex ] == 1) { Sex = "Male"; }
else if(PlayerInfo[ playerid ][ pSex ] == 2) { Sex = "Female"; }
print("DEBUG: 2");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_________________________STATISTICS OF %s_________________________, pName");
print("DEBUG: 2.1");
SendClientMessage(playerid, -1, "");
print("DEBUG: 2.2");
format(string, sizeof(string), "Name: {FFFFFF}%s {6FDD96}| Money: {FFFFFF}%d {6FDD96}| Age: {FFFFFF}%d {6FDD96}| Sex: {FFFFFF}%s", pName, Money, Age, Sex);
print("DEBUG: 2.3");
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
print("DEBUG: 2.4");
SendClientMessage(playerid, -1, "");
print("DEBUG: 2.5");
SendClientMessage(playerid, COLOR_LIGHTBLUE,"____________________________________________________________________");
print("DEBUG:3");
}
return 1;
}
do not use %s in SendClientMessage
pawn Код:
just do it like this pawn Код:
|