[Include] Multi Private Messages (v0.5) - Include (New Abilities)
#1

Multi Private Messages (v0.5) - Include (New Abilities)

First of all, Big thanks to ****** for sscnaf plugin - Amazing!
After two version of this system I converted this to include with new abilities.

Whats New?
[*] Fixed some bugs (like two ,, after name...)
[*] Stop using Split & Explode, converted to sscnaf
[*] Added new callback
[*] Converted to include from filterscript
[*] Added new abilities (like full control on the sending and errors)

ScreenShots
Here some screenshots from the system fully working on 0.3e server:







Download
PasteBin: http://pastebin.com/f4xNBRF9
MediaFire(Mirror): http://www.mediafire.com/?60cx3l6654grnhg
* Mirrors will be accepted *

CallBack
In the new version I added new CallBack that names "OnPlayerSendPrivate":
Код:
forward OnPlayerSendPrivate(playerid, text[], bool:recived, reciveid, reciving[], status); //Status 0 = error, 1 = error, 2 = send to recive, 3 = send to sender
Usage Is Simple as seen in "Test script".

Test script
Код:
public OnPlayerSendPrivate(playerid, text[], bool:recived, reciveid, reciving[], status)
{
 	printf("[PrivateMessage] %s(%d) -> %s(%d): %s [Status: %d]", GetName(playerid), playerid, reciving, reciveid, text, status);
	switch(status) {
	    case 0:
	        SendClientMessage(playerid, 0xFF0000FF, "Usage: /Pm [ID\\IDs] [Text]"); //send error message
	    case 1:
	        SendClientMessage(playerid, 0xFF0000FF, "Wrong ID\\IDs, /Help for help"); //send error message
	    case 2:
	        SendClientFormat(reciveid, 0xEAFF00FF, sttr, "[PM] %s(->To You): %s", GetName(playerid), text); //send formated message to players
	    case 3:
	        SendClientFormat(playerid, 0xFF00FFFF, sttr, "[PM] %s(->To %s): %s", GetName(playerid), reciving, text); //send formated message to sender
	}
	return 1;
}
Controlling
In the new version you can fully controll the message sending, accepting, error and more(as seen in the test script).
Just as a reminder: Status 0 = error, 1 = error, 2 = send to recive, 3 = send to sender

Bugs & Suggestions
No bugs known for this time, if you have find a bug write me a private message and I will fix it at the nex version!
Allso Suggestions will be accepted as well.

Enjoy!

Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)