PHP Code:
CMD:save(playerid, params[])
{
? ? new message[100];
? ? sscanf(params, "s[100]", message);
? ? format(PlayerInfo[playerid][pMessage], 100, message);
SaveMessage(playerid);
? ? return 1;
}
CMD:show(playerid, params[])
{
? ? new string[100];
? ? if (!strcmp(PlayerInfo[playerid][pMessage], "None", true))
? ? ? ? ?return SendClientMessage(playerid, COLOR_YELLOW, "No message");
? ? format(string, sizeof string, "%s", PlayerInfo[playerid][pMessage]);
? ? SendClientMessage(playerid, COLOR_WHITE, string);
? ? return 1;
}
SaveMessage(playerid)
{
new query[256];
mysql_format(dbCon, query, sizeof(query), "UPDATE `players` SET `MessageText` = '%e' WHERE `ID` = '%d'",
PlayerInfo[playerid][pMessage],
PlayerInfo[playerid][pSQLID]);
mysql_tquery(dbCon, query);
return 1;
}
/save {F60000}Message {FFFFFF}Message
But its only save Message?Message?
This is what I want