Advertisement
KingOfTurkey38

Custom Private Messages with Social Spy By KingOfTurkey38

May 26th, 2019
403
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.64 KB | None | 0 0
  1. Private Messages with SocialSpy V0.0.6 by KingOfTurkey38 Discord: KingOfTurkey38#1377
  2.  
  3. HELP:
  4. ----------------------------------
  5. /pm (Shows the Private Message gui)
  6. /pm help (Private messages help)
  7. /pm socialspy add [Name] (Add a player to socialspy)
  8. /pm socialspy remove [Name] (remove a player from socialspy)
  9. /pm socialspy list (See all players in socialspy)
  10. /pm socialspy disable (Disables socialspy)
  11. /pm socialspy enable (Enables socialspy)
  12. ----------------------------------
  13.  
  14.  
  15.  
  16. CODE:
  17. ---------------------------------------------------
  18. cmd add pm %prefix% = \"§7[§bPrivate Messages§7]§r\"
  19. cmd add pm %status% = playerstatus(%p%)
  20. cmd add pm if %status%[\"op\"] != %true% then goto 11
  21. cmd add pm if (%args%[2] = \"enable\") or (%args%[2] = \"disable\") then goto 100
  22. cmd add pm if (%args%[1] = \"socialspy\") and (%args%[2] = \"add\") then goto 150
  23. cmd add pm if (%args%[1] = \"socialspy\") and (%args%[2] = \"remove\") then goto 170
  24. cmd add pm if (%args%[1] = \"socialspy\") and (%args%[2] = \"list\") then goto 190
  25. cmd add pm %usage% = \"§7[§bPrivate Messages§7] By KingOfTurkey38§r\\n§7-----------------------\\n§bpm socialspy add (Adds player to socialspy)\\npm socialspy remove (removes player from socialspy)\\npm socialspy list (see the list of socialspy)\\npm (Opens gui for private messages)\\npm socialspy enable (Enables socialspy for private messages)\\npm socialspy disable (Disables socialspy for private messages)\\npm help (Private message help)\\n§7-----------------------\"
  26. cmd add pm if %args%[1] = \"help\" then message %p% %usage%
  27. cmd add pm if %args%[1] = \"help\" then exit
  28. #GUI BY Link1147
  29. cmd add pm %gui%[\"type\"] = \"custom_form\"
  30. cmd add pm %gui%[\"title\"] = \"§cPrivate Message\"
  31. cmd add pm %drop%[\"type\"] = \"dropdown\"
  32. cmd add pm %drop%[\"text\"] = \"§cSelect a player:\"
  33. cmd add pm %options% = onlineplayers()
  34. cmd add pm %drop%[\"options\"] = %options%
  35. cmd add pm %input%[\"type\"] = \"input\"
  36. cmd add pm %input%[\"text\"] = \"§6Message:\"
  37. cmd add pm %input%[\"placeholder\"] = \"§4Message\"
  38. cmd add pm %content%[] = %drop%
  39. cmd add pm %content%[] = %input%
  40. cmd add pm %gui%[\"content\"] = %content%
  41. cmd add pm %output% = dialog(%p%, %gui%)
  42. cmd add pm if %output% = %false% then exit
  43. cmd add pm %players% = onlineplayers()
  44. cmd add pm %num% = %output%[0]
  45. cmd add pm %player% = %players%[%num%]
  46. cmd add pm %msg% = %output%[1]
  47. cmd add pm message %player% §7[§b%p%§7]§r§f:§b %msg%
  48. cmd add pm message %p% §bSuccessfully sended private message to §a%player% §7(§f%msg%§7)
  49. cmd add pm load %pm%
  50. cmd add pm if varset(%pm%) = %false% then %pm% = array(0) - array(0)
  51. cmd add pm if varset(%pm%[\"status\"]) = %false% then %pm%[\"status\"] = \"enabled\"
  52. cmd add pm if %pm%[\"status\"] = \"disabled\" then exit
  53. cmd add pm if (varset(%pm%[\"allowed\"]) = %false%) or (%pm%[\"allowed\"] = array(0) - array(0)) then exit
  54. cmd add pm %array% = array(0) - array(0)
  55. cmd add pm %num% = 0
  56. cmd add pm %members% = %pm%[\"allowed\"]
  57. cmd add pm if varset(%members%[%num%]) = %false% then goto 45
  58. cmd add pm %kmember% = %members%[%num%]
  59. cmd add pm if %kmember% in onlineplayers() then %array% = %array% + array(%kmember%)
  60. cmd add pm %num% = %num% + 1
  61. cmd add pm if %num% >= size(%members%) then goto 45
  62. cmd add pm goto 40
  63. cmd add pm message %array% §l§7(§bSocialSpy§7) §b%p% messaged to %player%: %msg%
  64. cmd add pm exit
  65.  
  66.  
  67.  
  68.  
  69. cmd edit pm 100 load %pm%
  70. cmd edit pm 101 if varset(%pm%) = %false% then %pm% = array(0) - array(0)
  71. cmd edit pm 102 if varset(%pm%[\"status\"]) = %false% then %pm%[\"status\"] = \"enabled\"
  72. cmd edit pm 110 if %args%[2] = \"enable\" then goto 130
  73. cmd edit pm 111 if %args%[2] = \"disabled\" then goto 115
  74. cmd edit pm 115 %pm%[\"status\"] = \"disabled\"
  75. cmd edit pm 116 message %p% §7§l(§bSocialSpy§7) §bDisabled
  76. cmd edit pm 120 save %pm%
  77. cmd edit pm 121 exit
  78. cmd edit pm 130 %pm%[\"status\"] = \"enabled\"
  79. cmd edit pm 131 save %pm%
  80. cmd edit pm 132 message %p% §7§l(§bSocialSpy§7) §benabled
  81. cmd edit pm 133 exit
  82. cmd edit pm 150 load %pm%
  83. cmd edit pm 151 if varset(%pm%) = %false% then %pm% = array(0) - array(0)
  84. cmd edit pm 152 if varset(%pm%[\"allowed\"]) = %false% then %pm%[\"allowed\"] = array(0) - array(0)
  85. cmd edit pm 153 %pl% = %args%[3]
  86. cmd edit pm 154 if (%pl% in %pm%[\"allowed\"]) or (varset(%pl%) = %false%) then message %p% %prefix% §b%pl% is already in SocialSpy!
  87. cmd edit pm 155 if (%pl% in %pm%[\"allowed\"]) or (varset(%pl%) = %false%) then exit
  88. cmd edit pm 164 %pm%[\"allowed\"] = %pm%[\"allowed\"] + array(%pl%)
  89. cmd edit pm 165 message %p% %prefix% §bSuccessfully added %pl% to SocialSpy!
  90. cmd edit pm 166 save %pm%
  91. cmd edit pm 167 exit
  92. cmd edit pm
  93. cmd edit pm 170 load %pm%
  94. cmd edit pm 171 if varset(%pm%) = %false% then %pm% = array(0) - array(0)
  95. cmd edit pm 172 if varset(%pm%[\"allowed\"]) = %false% then %pm%[\"allowed\"] = array(0) - array(0)
  96. cmd edit pm 173 %pl% = %args%[3]
  97. cmd edit pm 174 if (%pl% in %pm%[\"allowed\"]) or (varset(%pl%) = %false%) then message %p% %prefix% §b%pl% is not in SocialSpy!
  98. cmd edit pm 175 if (%pl% in %pm%[\"allowed\"]) or (varset(%pl%) = %false%) then exit
  99. cmd edit pm 174 %pm%[\"allowed\"] = %pm%[\"allowed\"] - array(%pl%)
  100. cmd edit pm 175 message %p% %prefix% §bSuccessfully removed %pl% from SocialSpy!
  101. cmd edit pm 176 save %pm%
  102. cmd edit pm 177 exit
  103. cmd edit pm
  104. cmd edit pm 190 load %pm%
  105. cmd edit pm 191 if varset(%pm%) = %false% then %pm% = array(0) - array(0)
  106. cmd edit pm 192 if varset(%pm%[\"allowed\"]) = %false% then %pm%[\"allowed\"] = array(0) - array(0)
  107. cmd edit pm 193 %list% = %pm%[\"allowed\"]
  108. cmd edit pm 194 message %p% %prefix% List: %list%
  109. cmd edit pm 195 exit
  110. ---------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement