Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*==============================================================================================================
- *M3SS4GE SYST3M BY GIR0UD12* -All About Messages/Chat-
- ================================================================================================================
- FEATURES:
- * Random Messages
- * Welcome Messages
- * Join Messages
- * Leave Messages
- * Enter Vehicle Messages
- * Exit Vehicle Messages
- * /credits /vpannounce /vpsay /mscmds /heal
- * VP mean Veteran Player.Veteran Player mean 1000+ score :)
- BONUS:
- Heal player with "TAICHI" anims and to stop the anim just press "ENTER".
- *You can turn on /heal command or turn off it by true/false
- INFO:
- * You can edit this script but please dont remove CREDITS!!
- * Feel free to +rep me at forum.sa-mp.com
- CREDITS:
- Script Date: 18/5/2013 Scripter: Giroud12 Script Version : v1.2
- ==================================================================================*/
- /*================================================================================*/
- #include <a_samp> /* THANKS TO SAMP TEAM */
- #include <zcmd> /* THANKS TO ZEEX */
- #include <sscanf> /* THANKS TO Y_LESS */
- /*================================================================================*/
- #define SERVERNAME YOURSERVERNAME /* CHANGE TO YOUR SERVER NAME */
- #define GMNAME YOURGMNAME /* CHANGE TO YOUR GM NAME */
- #define SERVEREOWNER SERVEROWNER /* CHANGE TO YOUR SERVER OWNER NAME */
- #define FORUMURL weburl.com /* CHANGE TO YOUR WEBSITE URL */
- #define VERSION v1.2 /*-------------------------------------*/
- #define DIALOG_CREDITS 0
- #define DIALOG_MSCMDS 1
- #define INFINITENO 9999999999
- #define HEALCMDS true
- /*================================================================================*/
- #define C_GREY 0xAFAFAFAA
- #define C_YELLOW 0xFFFF00AA
- #define C_RED 0xAA3333AA
- #define red "{E10000}"
- #define yellow "{F3FF02}"
- #define lightblue "{00C0FF}"
- #define white "{FFFFFF}"
- /*================================================================================*/
- new playersonline=0;
- /*================================================================================*/
- new RandomMSG[][] =
- {
- "*Welcome To Server : "#SERVERNAME" 0.3x*",
- "*Our Website : "#WEBURL"*",
- "*Server Owner : "#SERVEROWNER"*"
- /*Add More Messages*/
- /*Note: Last Messages Dont Put ,*/
- };
- /*================================================================================*/
- new VehicleNames[][] = {
- {"Landstalker"},{"Bravura"},{"Buffalo"},{"Linerunner"},{"Perrenial"},{"Sentinel"},{"Dumper"},
- {"Firetruck"},{"Trashmaster"},{"Stretch"},{"Manana"},{"Infernus"},{"Voodoo"},{"Pony"},{"Mule"},
- {"Cheetah"},{"Ambulance"},{"Leviathan"},{"Moonbeam"},{"Esperanto"},{"Taxi"},{"Washington"},
- {"Bobcat"},{"Mr Whoopee"},{"BF Injection"},{"Hunter"},{"Premier"},{"Enforcer"},{"Securicar"},
- {"Banshee"},{"Predator"},{"Bus"},{"Rhino"},{"Barracks"},{"Hotknife"},{"Trailer 1"},{"Previon"},
- {"Coach"},{"Cabbie"},{"Stallion"},{"Rumpo"},{"RC Bandit"},{"Romero"},{"Packer"},{"Monster"},
- {"Admiral"},{"Squalo"},{"Seasparrow"},{"Pizzaboy"},{"Tram"},{"Trailer 2"},{"Turismo"},
- {"Speeder"},{"Reefer"},{"Tropic"},{"Flatbed"},{"Yankee"},{"Caddy"},{"Solair"},{"Berkley's RC Van"},
- {"Skimmer"},{"PCJ-600"},{"Faggio"},{"Freeway"},{"RC Baron"},{"RC Raider"},{"Glendale"},{"Oceanic"},
- {"Sanchez"},{"Sparrow"},{"Patriot"},{"Quad"},{"Coastguard"},{"Dinghy"},{"Hermes"},{"Sabre"},
- {"Rustler"},{"ZR-350"},{"Walton"},{"Regina"},{"Comet"},{"BMX"},{"Burrito"},{"Camper"},{"Marquis"},
- {"Baggage"},{"Dozer"},{"Maverick"},{"News Chopper"},{"Rancher"},{"FBI Rancher"},{"Virgo"},{"Greenwood"},
- {"Jetmax"},{"Hotring"},{"Sandking"},{"Blista Compact"},{"Police Maverick"},{"Boxville"},{"Benson"},
- {"Mesa"},{"RC Goblin"},{"Hotring Racer A"},{"Hotring Racer B"},{"Bloodring Banger"},{"Rancher"},
- {"Super GT"},{"Elegant"},{"Journey"},{"Bike"},{"Mountain Bike"},{"Beagle"},{"Cropdust"},{"Stunt"},
- {"Tanker"}, {"Roadtrain"},{"Nebula"},{"Majestic"},{"Buccaneer"},{"Shamal"},{"Hydra"},{"FCR-900"},
- {"NRG-500"},{"HPV1000"},{"Cement Truck"},{"Tow Truck"},{"Fortune"},{"Cadrona"},{"FBI Truck"},
- {"Willard"},{"Forklift"},{"Tractor"},{"Combine"},{"Feltzer"},{"Remington"},{"Slamvan"},
- {"Blade"},{"Freight"},{"Streak"},{"Vortex"},{"Vincent"},{"Bullet"},{"Clover"},{"Sadler"},
- {"Firetruck LA"},{"Hustler"},{"Intruder"},{"Primo"},{"Cargobob"},{"Tampa"},{"Sunrise"},{"Merit"},
- {"Utility"},{"Nevada"},{"Yosemite"},{"Windsor"},{"Monster A"},{"Monster B"},{"Uranus"},{"Jester"},
- {"Sultan"},{"Stratum"},{"Elegy"},{"Raindance"},{"RC Tiger"},{"Flash"},{"Tahoma"},{"Savanna"},
- {"Bandito"},{"Freight Flat"},{"Streak Carriage"},{"Kart"},{"Mower"},{"Duneride"},{"Sweeper"},
- {"Broadway"},{"Tornado"},{"AT-400"},{"DFT-30"},{"Huntley"},{"Stafford"},{"BF-400"},{"Newsvan"},
- {"Tug"},{"Trailer 3"},{"Emperor"},{"Wayfarer"},{"Euros"},{"Hotdog"},{"Club"},{"Freight Carriage"},
- {"Trailer 3"},{"Andromada"},{"Dodo"},{"RC Cam"},{"Launch"},{"Police Car (LSPD)"},{"Police Car (SFPD)"},
- {"Police Car (LVPD)"},{"Police Ranger"},{"Picador"},{"S.W.A.T. Van"},{"Alpha"},{"Phoenix"},{"Glendale"},
- {"Sadler"},{"Luggage Trailer A"},{"Luggage Trailer B"},{"Stair Trailer"},{"Boxville"},{"Farm Plow"},
- {"Utility Trailer"}
- };
- /*================================================================================*/
- #if defined FILTERSCRIPT /* DEFINE IT FILTERSCRIPT */
- /*================================================================================*/
- /*================================================================================*/
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print("Loading...................");
- print("Messages System "#VERSION" BY GIROUD12 Loaded!");
- print("--------------------------------------\n");
- return 1;
- }
- /*================================================================================*/
- public OnFilterScriptExit()
- {
- print("\n--------------------------------------");
- print("Loading...................");
- print("Messages System "#VERSION" by GIROUD12 Unloaded!");
- print("--------------------------------------\n");
- return 1;
- }
- /*================================================================================*/
- #else
- /*================================================================================*/
- main()
- {
- print("\n----------------------------------");
- print(""#GAMEMODENAME"");
- print("----------------------------------\n");
- }
- #endif
- /*================================================================================*/
- public OnGameModeInit()
- {
- SetTimer("SendMSG", 60000, true);
- return 1;
- }
- /*================================================================================*/
- forward SendMSG();
- /*================================================================================*/
- public OnPlayerConnect(playerid)
- {
- SendClientMessage(playerid, C_YELLOW, "*Welcome To "#SERVERNAME"*");
- SendClientMessage(playerid, C_YELLOW, "*The best SAMP Server 0.3x*");
- playersonline++;
- new string[128];
- format(string, sizeof(string), "*There are currently %d playing on this server*", playersonline);
- SendClientMessageToAll(C_GREY, string);
- new name[MAX_PLAYER_NAME];
- new ConnectMessage[256];
- format(ConnectMessage,sizeof(ConnectMessage),"*%s [ID:%d] has joined the server*", name, playerid);
- SendClientMessageToAll(C_GREY,ConnectMessage);
- return 1;
- }
- /*================================================================================*/
- public OnPlayerDisconnect(playerid, reason)
- {
- new pname[MAX_PLAYER_NAME], string[39 + MAX_PLAYER_NAME];
- GetPlayerName(playerid, pname, sizeof(pname));
- switch(reason)
- {
- case 0: format(string, sizeof(string), "%s has left the server. (Lost Connection)", pname);
- case 1: format(string, sizeof(string), "%s has left the server. (Leaving)", pname);
- case 2: format(string, sizeof(string), "%s has left the server. (Kicked)", pname);
- }
- SendClientMessageToAll(C_GREY, string);
- return 1;
- }
- /*================================================================================*/
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
- {
- new string[150];
- new modelid = GetVehicleModel(vehicleid);
- new car = modelid-400;
- format(string, sizeof(string), "You entered ~r~%s", VehicleNames[car]);
- GameTextForPlayer(playerid,string,3000,3);
- return 1;
- }
- /*================================================================================*/
- public OnPlayerExitVehicle(playerid, vehicleid)
- {
- new string[150];
- new modelid = GetVehicleModel(vehicleid);
- new car = modelid-400;
- format(string, sizeof(string), "You exited ~r~%s ", VehicleNames[car]);
- GameTextForPlayer(playerid,string,3000,3);
- return 1;
- }
- /*================================================================================*/
- public SendMSG()
- {
- new randMSG = random(sizeof(RandomMSG));
- SendClientMessageToAll(C_YELLOW, RandomMSG[randMSG]);
- }
- /*================================================================================*/
- COMMAND:vpannounce(playerid, params[])
- {
- new msg[180];
- if(sscanf(params, "s", msg)) return SendClientMessage(playerid, C_YELLOW, "USAGE: /announce [MESSAGES]");
- if (GetPlayerScore(playerid) >= 1000 && GetPlayerScore(playerid) < INFINITENO)
- {
- new string[180];
- format(string, sizeof(string), "*[VP]:~r~%s*",msg);
- GameTextForAll(string, 5000, 3);
- } else SendClientMessage(playerid, C_RED, "ERROR: You need to have 1000+ score!");
- return 1;
- }
- /*================================================================================*/
- COMMAND:credits(playerid, params [])
- {
- ShowPlayerDialog(playerid,0,DIALOG_STYLE_MSGBOX,"Credits",""yellow"Messages System v1.1\n---------------\n"white"Credits to :\n"lightblue"GIR0UD12 aka Shadowz "white"create this "yellow"Filterscript\n"lightblue"Team SAMP "white"for "yellow"#include <a_samp> ","Ok","");
- return 1;
- }
- /*================================================================================*/
- COMMAND:mscmds(playerid, params [])
- {
- ShowPlayerDialog(playerid,1,DIALOG_STYLE_MSGBOX,"COMMANDS",""yellow"COMMANDS:\n---------------\n"white"Commands:\n"white"/vpsay : "red"only 1000+ score players !\n"white"/vpannounce : "red"only 1000+ score players !\n"white"/mscmds : "red"all system cmds !","Ok","");
- return 1;
- }
- /*================================================================================*/
- COMMAND:vpsay(playerid,params[])
- {
- new msg[180];
- if(sscanf(params, "s", msg)) return SendClientMessage(playerid, C_YELLOW, "USAGE: /vpsay [MESSAGES]");
- if (GetPlayerScore(playerid) >= 1000 && GetPlayerScore(playerid) < INFINITENO)
- {
- new string[180];
- format(string, sizeof(string), "*[VP]:~r~%s*",msg);
- SendClientMessageToAll(C_YELLOW, string);
- } else SendClientMessage(playerid, C_RED, "ERROR: You need to have 1000+ score!");
- return 1;
- }
- /*================================================================================*/
- #if HEALCMDS == false
- COMMAND:heal(playerid,params[])
- {
- ApplyAnimation(playerid,"PARK","Tai_Chi_Loop", 4.0, 1, 0, 0, 0, 0);
- SetPlayerHealth(playerid, 100.0);
- GivePlayerMoney(playerid, -500);
- SendClientMessage(playerid, C_YELLOW, "You just heal yourself and paid $500");
- return 1;
- }
- #endif
- /*================================================================================*/
Advertisement
Add Comment
Please, Sign In to add comment