Advertisement
Guest User

MakeMeDrunk v1.1

a guest
Aug 2nd, 2012
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 2.16 KB | None | 0 0
  1. #include <a_samp>
  2. #define FILTERSCRIPT
  3. #define blue 0x375FFFFF
  4. #define red 0xAA3333AA
  5.  
  6. public OnFilterScriptInIt()
  7. {
  8.     print("/n-------------------------------");
  9.     print(" NoahF's useful FilterScript has loaded successfully."); //Shows a message in Samp-Server.exe saying the FilterScript has loaded successfully.
  10.     print("-------------------------------/n");
  11.     return 1;
  12. }
  13. public OnFilterScriptExit()
  14. {
  15.     return 1;
  16. }
  17. public OnPlayerCommandText(playerid, cmdtext[])
  18. {
  19.     new pName[24];
  20.     new str[128];
  21.    
  22.     if(!strcmp(cmdtext, "/makemedrunk", true, 12))  //The command that turns on the drunk effects.
  23.     {
  24.         SetPlayerDrunkLevel (playerid, 50000);
  25.         GetPlayerName(playerid, pName, 24);
  26.         format(str, 128, "%s Has made themselves drunk with the /makemedrunk command! Be careful not to drink and drive a vehicle or it may result in an accident!");
  27.         SendClientMessage(playerid, blue, "You have made yourself drunk! Don't drink and drive ;)");
  28.         SendClientMessage(playerid, blue, "If you want to turn off the drunk effects, just type /notdrunk!");
  29.         SendClientMessageToAll(red, str);
  30.         ApplyAnimation(playerid,"PED","WALK_DRUNK",4.1,1,1,1,0,0,0);
  31.         ApplyAnimation(playerid,"RIOT","RIOT_FUKU",4.1,1,1,1,0,0,0);
  32.         return 1;
  33.     }
  34.  
  35.     if(!strcmp(cmdtext, "/notdrunk", true, 9))  //The command that turns off the drunk effects.
  36.     {
  37.         SetPlayerDrunkLevel (playerid, 0);
  38.         SendClientMessage(playerid, blue, "You have turned off the drunk effects! It is now safe to drive.");
  39.         SendClientMessageToAll(red, str);
  40.         ClearAnimations(playerid);
  41.         return 1;
  42.     }
  43.     return 0;
  44. }
  45.  
  46.    
  47. /*
  48. -----------------------------------------CREDITS----------------------------------------
  49. MakeMeDrunk FilterScript scripted/created by Noah Fallon (NoahF) on 7/31/12.
  50. Please do not remove these credits.
  51. Changing things are allowed but when you do please post the newly modified code in a reply to my SA-MP Forums topic on this FS.
  52. Thanks for using ;)
  53. Also, don't be afraid to put some constructive criticism in a reply to the topic! This is my first FS and I would like to know how I can improve on future scripts. :)
  54. -----------------------------------------END OF CREDITS---------------------------------
  55. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement