DarkScriptZEditors

Untitled

Jan 9th, 2019
333
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.22 KB | None | 0 0
  1. local adminname1 = script.Name
  2. script.Parent = game.ServerStorage
  3. --// SETTINGS
  4. local settinsgubications = game:GetService("ServerStorage")
  5. local setting1 = Instance.new("Folder", settinsgubications)
  6. setting1.Name = adminname1.."Settings"
  7. local admins1 = Instance.new("Folder", setting1)
  8. admins1.Name = adminname1.."AdminsList"
  9. local bans1 = Instance.new("Folder", setting1)
  10. bans1.Name = adminname1.."BansList"
  11. local admin = Instance.new("NumberValue", admins1)
  12. admin.Name = owner.Name
  13. admin.Value = owner.UserId
  14. local setupfinish1 = true
  15.  
  16. local prefix1 = "?"
  17.  
  18. --// ACTUAL PLAYERS FUNCTIONS
  19. for _,plr in pairs(game.Players:GetChildren()) do
  20. plr.Chatted:Connect(function(msg)
  21. if admins1:FindFirstChild(plr.Name) then --// ADMINS SCANS
  22. --// RANKS SCANS & COMMANDS
  23. if admins1[plr.Name].Value == plr.UserId then --// RANK SCAN START
  24. if msg:sub(1,6) == prefix1.."kill " then --// COMMANDS START
  25. local target1 = msg:sub(7)
  26. if target1:lower() == "me" then
  27. target1 = plr.Name
  28. end
  29. if game.Players:FindFirstChild(target1) then
  30. game.Players[target1].Character:BreakJoints()
  31. print(adminname1..":\n"..target1.." now its DEAD!")
  32. end
  33. for _,plrs in pairs(game.Players:GetChildren()) do
  34. if target1:lower() == "others" then
  35. if plrs.Name ~= plr.Name then
  36. plrs.Character:BreakJoints()
  37. print(adminname1..":\n"..plrs.Name.." now its DEAD!")
  38. end
  39. end
  40. if target1:lower() == "all" then
  41. plrs.Character:BreakJoints()
  42. print(adminname1..":\n"..plrs.Name.." now its DEAD!")
  43. end
  44. end
  45. end --// COMMAND END
  46. if msg:sub(1,6) == prefix1.."kick " then --// COMMANDS START
  47. local target1 = msg:sub(7)
  48. if target1:lower() == "me" then
  49. target1 = plr.Name
  50. end
  51. if game.Players:FindFirstChild(target1) and target1 ~= owner.Name then
  52. game.Players[target1]:Destroy()
  53. print(adminname1..":\n"..target1.." now its KICKED!")
  54. end
  55. for _,plrs in pairs(game.Players:GetChildren()) do
  56. if target1:lower() == "others" then
  57. if plrs.Name ~= plr.Name and plrs.Name ~= owner.Name then
  58. plrs.Character:Destroy()
  59. print(adminname1..":\n"..plrs.Name.." now its KICKED!")
  60. end
  61. end
  62. if target1:lower() == "all" then
  63. if plrs.Name ~= owner.Name then
  64. plrs.Character:Destroy()
  65. print(adminname1..":\n"..plrs.Name.." now its KICKED!")
  66. end
  67. end
  68. end
  69. end --// COMMAND END
  70. if msg:sub(1,3) == prefix1.."m " then --// COMMANDS START
  71. local target1 = msg:sub(4)
  72. local MEESSAGE1 = Instance.new("Message", workspace)
  73. MEESSAGE1.Text = "["..plr.Name.."]: "..target1
  74. wait(8)
  75. MEESSAGE1:Destroy()
  76. end --// COMMAND END
  77. if msg:sub(1,3) == prefix1.."h " then --// COMMANDS START
  78. local target1 = msg:sub(4)
  79. local MEESSAGE1 = Instance.new("Hint", workspace)
  80. MEESSAGE1.Text = "["..plr.Name.."]: "..target1
  81. wait(8)
  82. MEESSAGE1:Destroy()
  83. end --// COMMAND END
  84. if msg:sub(1,7) == prefix1.."admin " and admins1[plr.Name].Value == owner.UserId then --// COMMANDS START
  85. local target1 = msg:sub(8)
  86. if target1:lower() == "me" then
  87. target1 = plr.Name
  88. end
  89. if game.Players:FindFirstChild(target1) and not admins1:FindFirstChild(target1) then
  90. local nadmin1 = Instance.new("NumberValue", admins1)
  91. nadmin1.Name = target1
  92. nadmin1.Value = game.Players[target1].UserId
  93. print(adminname1..":\n"..target1.." now its ADMIN!")
  94. end
  95. for _,plrs in pairs(game.Players:GetChildren()) do
  96. if target1:lower() == "others" then
  97. if plrs.Name ~= plr.Name and not admins1:FindFirstChild(plrs.Name) then
  98. local nadmin1 = Instance.new("NumberValue", admins1)
  99. nadmin1.Name = plrs.Name
  100. nadmin1.Value = plrs.UserId
  101. print(adminname1..":\n"..plrs.Name.." now its ADMIN!")
  102. end
  103. end
  104. if target1:lower() == "all" and not admins1:FindFirstChild(plrs.Name) then
  105. local nadmin1 = Instance.new("NumberValue", admins1)
  106. nadmin1.Name = plrs.Name
  107. nadmin1.Value = plrs.UserId
  108. print(adminname1..":\n"..plrs.Name.." now its ADMIN!")
  109. end
  110. end
  111. end --// COMMAND END
  112. if msg:sub(1,9) == prefix1.."unadmin " and admins1[plr.Name].Value == owner.UserId then --// COMMANDS START
  113. local target1 = msg:sub(10)
  114. if target1:lower() == "me" then
  115. target1 = plr.Name
  116. end
  117. if admins1:FindFirstChild(target1) and target1 ~= plr.Name then
  118. admins1[target1]:Destroy()
  119. print(adminname1..":\n"..target1.." now its GUEST!")
  120. end
  121. for _,plrs in pairs(admins1:GetChildren()) do
  122. if target1:lower() == "others" then
  123. if plrs.Name ~= plr.Name then
  124. plrs:Destroy()
  125. print(adminname1..":\n"..plrs.Name.." now its GUEST!")
  126. end
  127. end
  128. end
  129. end --// COMMAND END
  130. if msg:sub(1,8) == prefix1.."prefix " then --// COMMANDS START
  131. local target1 = msg:sub(9)
  132. prefix1 = target1
  133. print(adminname1..":\n New prefix has set: "..prefix1)
  134. end --// COMMAND END
  135. ---------------------------
  136. if setupfinish1 == false then
  137. if msg:sub(1,4) == ">new" and plr.Name == owner.Name then
  138. local setting1 = Instance.new("Folder", settinsgubications)
  139. setting1.Name = adminname1.."Settings"
  140. local admins1 = Instance.new("Folder", setting1)
  141. admins1.Name = adminname1.."AdminsList"
  142. local bans1 = Instance.new("Folder", setting1)
  143. bans1.Name = adminname1.."BansList"
  144. local admin = Instance.new("NumberValue", admins1)
  145. admin.Name = owner.Name
  146. admin.Value = owner.UserId
  147. local setupfinish1 = true
  148. end
  149. end
  150. ---------------------------
  151. end --// RANK SCAN & COMMANDS END
  152. end
  153. end)
  154. end
  155.  
  156. --// NEW PLAYERS FUNCTIONS
  157. game.Players.PlayerAdded:Connect(function(plr)
  158. plr.Chatted:Connect(function(msg)
  159. if admins1:FindFirstChild(plr.Name) then --// ADMINS SCANS
  160. --// RANKS SCANS & COMMANDS
  161. if admins1[plr.Name].Value == plr.UserId then --// RANK SCAN START
  162. if msg:sub(1,6) == prefix1.."kill " then --// COMMANDS START
  163. local target1 = msg:sub(7)
  164. if target1:lower() == "me" then
  165. target1 = plr.Name
  166. end
  167. if game.Players:FindFirstChild(target1) then
  168. game.Players[target1].Character:BreakJoints()
  169. print(adminname1..":\n"..target1.." now its DEAD!")
  170. end
  171. for _,plrs in pairs(game.Players:GetChildren()) do
  172. if target1:lower() == "others" then
  173. if plrs.Name ~= plr.Name then
  174. plrs.Character:BreakJoints()
  175. print(adminname1..":\n"..plrs.Name.." now its DEAD!")
  176. end
  177. end
  178. if target1:lower() == "all" then
  179. plrs.Character:BreakJoints()
  180. print(adminname1..":\n"..plrs.Name.." now its DEAD!")
  181. end
  182. end
  183. end --// COMMAND END
  184. if msg:sub(1,6) == prefix1.."kick " then --// COMMANDS START
  185. local target1 = msg:sub(7)
  186. if target1:lower() == "me" then
  187. target1 = plr.Name
  188. end
  189. if game.Players:FindFirstChild(target1) and target1 ~= owner.Name then
  190. game.Players[target1]:Destroy()
  191. print(adminname1..":\n"..target1.." now its KICKED!")
  192. end
  193. for _,plrs in pairs(game.Players:GetChildren()) do
  194. if target1:lower() == "others" then
  195. if plrs.Name ~= plr.Name and plrs.Name ~= owner.Name then
  196. plrs.Character:Destroy()
  197. print(adminname1..":\n"..plrs.Name.." now its KICKED!")
  198. end
  199. end
  200. if target1:lower() == "all" then
  201. if plrs.Name ~= owner.Name then
  202. plrs.Character:Destroy()
  203. print(adminname1..":\n"..plrs.Name.." now its KICKED!")
  204. end
  205. end
  206. end
  207. end --// COMMAND END
  208. if msg:sub(1,3) == prefix1.."m " then --// COMMANDS START
  209. local target1 = msg:sub(4)
  210. local MEESSAGE1 = Instance.new("Message", workspace)
  211. MEESSAGE1.Text = "["..plr.Name.."]: "..target1
  212. wait(8)
  213. MEESSAGE1:Destroy()
  214. end --// COMMAND END
  215. if msg:sub(1,3) == prefix1.."h " then --// COMMANDS START
  216. local target1 = msg:sub(4)
  217. local MEESSAGE1 = Instance.new("Hint", workspace)
  218. MEESSAGE1.Text = "["..plr.Name.."]: "..target1
  219. wait(8)
  220. MEESSAGE1:Destroy()
  221. end --// COMMAND END
  222. if msg:sub(1,7) == prefix1.."admin " and admins1[plr.Name].Value == owner.UserId then --// COMMANDS START
  223. local target1 = msg:sub(8)
  224. if target1:lower() == "me" then
  225. target1 = plr.Name
  226. end
  227. if game.Players:FindFirstChild(target1) and not admins1:FindFirstChild(target1) then
  228. local nadmin1 = Instance.new("NumberValue", admins1)
  229. nadmin1.Name = target1
  230. nadmin1.Value = game.Players[target1].UserId
  231. print(adminname1..":\n"..target1.." now its ADMIN!")
  232. end
  233. for _,plrs in pairs(game.Players:GetChildren()) do
  234. if target1:lower() == "others" then
  235. if plrs.Name ~= plr.Name and not admins1:FindFirstChild(plrs.Name) then
  236. local nadmin1 = Instance.new("NumberValue", admins1)
  237. nadmin1.Name = plrs.Name
  238. nadmin1.Value = plrs.UserId
  239. print(adminname1..":\n"..plrs.Name.." now its ADMIN!")
  240. end
  241. end
  242. if target1:lower() == "all" and not admins1:FindFirstChild(plrs.Name) then
  243. local nadmin1 = Instance.new("NumberValue", admins1)
  244. nadmin1.Name = plrs.Name
  245. nadmin1.Value = plrs.UserId
  246. print(adminname1..":\n"..plrs.Name.." now its ADMIN!")
  247. end
  248. end
  249. end --// COMMAND END
  250. if msg:sub(1,9) == prefix1.."unadmin " and admins1[plr.Name].Value == owner.UserId then --// COMMANDS START
  251. local target1 = msg:sub(10)
  252. if target1:lower() == "me" then
  253. target1 = plr.Name
  254. end
  255. if admins1:FindFirstChild(target1) and target1 ~= plr.Name then
  256. admins1[target1]:Destroy()
  257. print(adminname1..":\n"..target1.." now its GUEST!")
  258. end
  259. for _,plrs in pairs(admins1:GetChildren()) do
  260. if target1:lower() == "others" then
  261. if plrs.Name ~= plr.Name then
  262. plrs:Destroy()
  263. print(adminname1..":\n"..plrs.Name.." now its GUEST!")
  264. end
  265. end
  266. end
  267. end --// COMMAND END
  268. if msg:sub(1,8) == prefix1.."prefix " then --// COMMANDS START
  269. local target1 = msg:sub(9)
  270. prefix1 = target1
  271. print(adminname1..":\n New prefix has set: "..prefix1)
  272. end --// COMMAND END
  273. ---------------------------
  274. if setupfinish1 == false then
  275. if msg:sub(1,4) == ">new" and plr.Name == owner.Name then
  276. local setting1 = Instance.new("Folder", settinsgubications)
  277. setting1.Name = adminname1.."Settings"
  278. local admins1 = Instance.new("Folder", setting1)
  279. admins1.Name = adminname1.."AdminsList"
  280. local bans1 = Instance.new("Folder", setting1)
  281. bans1.Name = adminname1.."BansList"
  282. local admin = Instance.new("NumberValue", admins1)
  283. admin.Name = owner.Name
  284. admin.Value = owner.UserId
  285. local setupfinish1 = true
  286. end
  287. end
  288. ---------------------------
  289. end --// RANK SCAN & COMMANDS END
  290. end
  291. end)
  292. end)
  293.  
  294. --// SMART SCANNER
  295. settinsgubications.ChildRemoved:Connect(function(obj)
  296. if obj.Name == adminname1.."Settings" then
  297. setupfinish1 = false
  298. warn(adminname1..":\nPleas type '>new' in the chat.")
  299. end
  300. end)
Add Comment
Please, Sign In to add comment