I got another idea. Load messages from specified player:
and limit number of messages from one player or make time limit between messages (like 10 seconds, who really need to send spam?), and add level limit, because 'new chars' can spam informations about their 'new extra cool servers online' :thumbup:
EDIT:
@darkhaos
PHP:
local message = string.gsub(string.gsub(param[1], messageSenderSep, 'HAXOR'), messageSep, 'HAXOR')
Is it not needed?
PHP:
if getPlayerByNameWildcard(param[2]) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have received a new private message.")
As someone reported. It send both messages to
cid.
PHP:
if doPlayerAddMessage(param[2], param[1], cid) and playerExists(param[2]) then
Why do you check if player exist when function doPlayerAddMessage check it?