I think you're using the United Gaming RP II
For future reference, use ****** or read the entire topic on the forums because your question has been answered already!
You need to find the code:
pawn Код:
stock LoadLetters()
{
new query[128], field[256], DBResult:result;
result = db_query(MailDB, "SELECT * FROM `Letters`");
if (db_num_rows(result) != 0)
{
for (new i = 0, rows = db_num_rows(result); i < rows; i ++)
{
LetterInfo[i][LetterActive] = true;
db_get_field_assoc(result, "LetterUnread", field, sizeof(field));
LetterInfo[i][LetterUnread] = (strval(field) == 1) ? (true) : (false);
db_get_field_assoc(result, "LetterSent", field, sizeof(field));
LetterInfo[i][LetterSent] = (strval(field) == 1) ? (true) : (false);
db_get_field_assoc(result, "LetterAddress", field, sizeof(field));
format(LetterInfo[i][LetterAddress], 128, "%s", field);
db_get_field_assoc(result, "LetterSender", field, sizeof(field));
format(LetterInfo[i][LetterSender], 24, "%s", field);
db_get_field_assoc(result, "LetterRecipient", field, sizeof(field));
format(LetterInfo[i][LetterRecipient], 24, "%s", field);
db_get_field_assoc(result, "LetterMessage", field, sizeof(field));
format(LetterInfo[i][LetterMessage], 256, "%s", field);
LetterInfo[i][LetterSQL] = i;
db_next_row(result);
}
}
db_free_result(result);
return 1;
}
and change to:
pawn Код:
stock LoadLetters()
{
new field[256], DBResult:result;
result = db_query(MailDB, "SELECT * FROM `Letters`");
if (db_num_rows(result) != 0)
{
for (new i = 0, rows = db_num_rows(result); i < rows; i ++)
{
LetterInfo[i][LetterActive] = true;
db_get_field_assoc(result, "LetterUnread", field, sizeof(field));
LetterInfo[i][LetterUnread] = (strval(field) == 1) ? (true) : (false);
db_get_field_assoc(result, "LetterSent", field, sizeof(field));
LetterInfo[i][LetterSent] = (strval(field) == 1) ? (true) : (false);
db_get_field_assoc(result, "LetterAddress", field, sizeof(field));
format(LetterInfo[i][LetterAddress], 128, "%s", field);
db_get_field_assoc(result, "LetterSender", field, sizeof(field));
format(LetterInfo[i][LetterSender], 24, "%s", field);
db_get_field_assoc(result, "LetterRecipient", field, sizeof(field));
format(LetterInfo[i][LetterRecipient], 24, "%s", field);
db_get_field_assoc(result, "LetterMessage", field, sizeof(field));
format(LetterInfo[i][LetterMessage], 256, "%s", field);
LetterInfo[i][LetterSQL] = i;
db_next_row(result);
}
}
db_free_result(result);
return 1;
}