Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 45.21 KB | None | 0 0
  1. startTime = tick()
  2. Core = {
  3. sBan={};
  4. injectList={
  5. "Dio";
  6. "Mortis";
  7. "Madara";
  8. "Zelphiros";
  9. "Sinister";
  10. "Nebula";
  11. "Infected";
  12. "Possesion";
  13. "Odin";
  14. "Divine";
  15. "Hollow";
  16. "Osu";
  17. "wanderer";
  18. "Sin";
  19. "Scammer";
  20. "Maid";
  21. "Goku";
  22. "Knives";
  23. "Saiyan";
  24. "Vis";
  25. "Warrior";
  26. "Rpg";
  27. "ls";
  28. },
  29. loopKill ={},
  30. Players={},
  31. coreFunctions = {
  32. FindPlayer=function(Name)
  33. local Len = string.len(Name)
  34. local Player=tostring(Name);
  35. for i,v in pairs(game.Players:GetPlayers()) do
  36. local Names=string.sub(string.lower(v.Name),1,Len);
  37. local PCalled=string.lower(Name)
  38. if Names == PCalled then
  39. return v
  40. end
  41. end
  42. end,
  43. trim = function(str)
  44. return (str:gsub("^%s*(.-)%s*$", "%1"))
  45. end,
  46. getArrInfo=function(arr,name)
  47. if #arr>Core.Settings.recrlimit and Core.Settings.inarray then
  48. return
  49. end
  50. for i,v in next,arr do
  51. if type(v)=="table" then
  52. if string.lower(name) == string.lower(tostring(i)) then
  53. return v
  54. end
  55. Core.Settings.inarray=true
  56. Core.Settings.rep=Core.Settings.rep+1
  57. Core.coreFunctions.getArrInfo(v,name)
  58. else
  59. if string.lower(name) == string.lower(tostring(i)) then
  60. return v
  61. end
  62. end
  63. end
  64. if Core.Settings.inarray then
  65. Core.Settings.rep=Core.Settings.rep-1
  66. Core.Settings.inarray=false
  67. end
  68. end,
  69. split=function(s, delimiter)
  70. local result = {}
  71. for match in (s..delimiter):gmatch("(.-)"..delimiter) do
  72. table.insert(result, match)
  73. end
  74. return result
  75. end;
  76. CallOnChildren=function(Instance, FunctionToCall)
  77. FunctionToCall(Instance)
  78.  
  79. for _, Child in next, Instance:GetChildren() do
  80. Core.coreFunctions.CallOnChildren(Child, FunctionToCall)
  81. end
  82. end;
  83. DeleteChildrenItem=function(Instance,className)
  84. Core.coreFunctions.CallOnChildren(Instance,function(Item)
  85. if Item.ClassName == className then
  86. Item:remove()
  87. end
  88. end)
  89. end;
  90. getPlayerRank=function(player)
  91. local id = player.UserId
  92. local url = Core.Settings.baseUrl.."getPlrData"
  93. local json = Core.Services.Http:PostAsync(url,id)
  94. local returnTable = Core.Services.JSONDecode(json)
  95. return returnTable.rank
  96. end;
  97. getPlayerColor=function(player)
  98. local id = player.UserId
  99. local url = Core.Settings.baseUrl.."getPlrData"
  100. local json = Core.Services.Http:PostAsync(url,id)
  101. local returnTable = Core.Services.JSONDecode(json)
  102. return returnTable.color
  103. end;
  104. getPlayerTable=function(player)
  105. local id = player.UserId
  106. local url = Core.Settings.baseUrl.."getPlrData"
  107. local json = Core.Services.Http:PostAsync(url,id)
  108. local returnTable = Core.Services.JSONDecode(json)
  109. return returnTable
  110. end;
  111. setPlayerTable=function(tble)
  112. local url = Core.Settings.baseUrl.."setPlrData"
  113. local json = Core.Services.JSONEncode(tble)
  114. Core.Services.Http:PostAsync(url,json)
  115. end;
  116. setPlayerRank=function(player,rank)
  117. local url = Core.Settings.baseUrl.."setPlrData"
  118. local tble = Core.coreFunctions.getPlayerTable(player)
  119. local http = Core.Services.Http
  120. tble.rank = rank
  121. local json = Core.Services.JSONEncode(tble)
  122. http:PostAsync(url,json)
  123. end;
  124. injectClient=function(plr)
  125. local cl = script.Client:Clone()
  126. cl.Parent = plr.Backpack
  127. cl.Disabled = false
  128. end;
  129. setPlayerColor=function(player,color)
  130. local url = Core.Settings.baseUrl.."setPlrData"
  131. local tble = Core.coreFunctions.getPlayerTable(player)
  132. local http = Core.Services.Http
  133. tble.color = color
  134. local json = Core.Services.JSONEncode(tble)
  135. http:PostAsync(url,json)
  136. end;
  137. addPlayer=function(tble)
  138. local url = Core.Settings.baseUrl.."insertPlrData"
  139. local http = Core.Services.Http
  140. local json = Core.Services.JSONEncode(tble)
  141. http:PostAsync(url,json)
  142. end;
  143. checkPlayer=function(player)
  144. local url = Core.Settings.baseUrl.."getPlrData"
  145. local http = Core.Services.Http
  146. local id = player.UserId
  147. local returnedMessage = http:PostAsync(url,id)
  148. print(returnedMessage)
  149. if returnedMessage == "error" or returnedMessage == "{}" then
  150. return false
  151. else
  152. return true
  153. end
  154. end;
  155. sendMessage = function(msg)
  156.  
  157. end
  158. },
  159. Services={
  160. Players = game:GetService("Players");
  161. Http = game:GetService("HttpService");
  162. RunService = game:GetService("RunService");
  163. ChatService = nil;
  164. Run = game:GetService("RunService");
  165. Post=function(link,data) local Return=Core.Services.Http:PostAsync(tostring(link),data) return Return end;
  166. Get=function(link,cache) local Return=Core.Services.Http:GetAsync(tostring(link),cache) return Return end;
  167. JSONEncode=function(data) return Core.Services.Http:JSONEncode(data) end;
  168. JSONDecode=function(data) return Core.Services.Http:JSONDecode(data) end;
  169. },
  170. Settings={
  171. rClient = script;
  172. rFunctions = nil;
  173. playing = nil;
  174. folder = Instance.new("Folder",workspace.Terrain);
  175. baseUrl = "https://spectrum-roblox.herokuapp.com/";
  176. messageType = "ChatService";
  177. },
  178. Commands={}
  179. }
  180. int=function()
  181. Core.Settings.rFunctions = Instance.new("Folder",game.ServerStorage)
  182. Core.Settings.rFunctions.Name = "Functions"
  183. Core.Settings.folder.Name = "Parts"
  184. Core.Settings.rClient.Parent = workspace.Terrain
  185. local success,message = pcall(function() Core.Services.ChatService = require(game.ServerScriptService.ChatServiceRunner.ChatService) end);
  186. if success then
  187. Core.coreFunctions.sendMessage = function(msg)
  188. Core.Settings.speaker:SayMessage(msg,"All")
  189. end
  190. Core.Settings.speaker = Core.Services.ChatService:AddSpeaker("Spectrum")
  191. Core.Settings.speaker:JoinChannel("All")
  192. Core.Settings.speaker:SetExtraData("NameColor", Color3.new(
  193. 66/255.0,
  194. 182.0/255.0,
  195. 244.0/255.0))
  196. Core.Settings.speaker:SetExtraData("ChatColor", Color3.new(
  197. 211.0/255.0,
  198. 211.0/255.0,
  199. 211.0/255.0))
  200. Core.Settings.speaker:SetExtraData("Font","SourceSansLight")
  201. Core.Settings.messageType = "ChatService";
  202. else
  203. Core.coreFunctions.sendMessage = function(msg,plr)
  204. if string.lower(plr) == "all" then
  205. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  206. Core.Settings.rClient:InvokeClient(v,"sendmessage",msg)
  207. end
  208. else
  209. Core.Settings.rClient:InvokeClient(plr,"sendmessage",msg)
  210. end
  211. end
  212. Core.Settings.messageType = "SetCore";
  213. end
  214. end
  215. int()
  216.  
  217. OnChatted=function(Message,Player)
  218. if not Message or type(Message) ~= "string" then return end
  219. --if not Player or type(Player) ~= "userdata" then return end
  220. local base = Core.coreFunctions.getPlayerTable(Player)
  221. local betaKey = base.betaKey
  222. Message = Message:gsub("^/e ",betaKey)
  223. local check = (Message:sub(1,string.len(betaKey)) == betaKey)
  224. if check then
  225. Message = Message:sub(string.len(betaKey)+1)
  226. local MFind = Message:find(" ")
  227. local substr,subaft
  228. pcall(function()
  229. substr = Message:sub(1,MFind-1)
  230. subaft = Message:sub(MFind+1)
  231. end)
  232. if not substr then
  233. substr = Message
  234. end
  235. if not subaft then
  236. subaft = ""
  237. end
  238. local UserProfile
  239. for i,v in pairs(Core.Players) do
  240. if v.Name == Player.Name then
  241. UserProfile = v
  242. end
  243. end
  244. for i,v in pairs(Core.Commands) do
  245. for index,object in pairs(v.Calls) do
  246. if substr == object and UserProfile then
  247. local base = Core.coreFunctions.getPlayerTable(Player)
  248. local rank = base.rank
  249. if v.Context <= rank then
  250. DestroyTablets(Player)
  251. local newthread = coroutine.create(v.Function)
  252. local Check,Error = coroutine.resume(newthread,subaft,Player)
  253. if not Check then
  254. AddPart("[Error]:"..tostring(Error),"Really red",Player)
  255. end
  256. return true
  257. else
  258. AddPart("Your rank is too low!","Really red",Player,nil);
  259. end
  260. end
  261. end
  262. end
  263. end
  264. end
  265.  
  266. function DestroyTablets(Player)
  267. --if not Player then return end
  268. if type(Player) == "userdata" then Player = Player.Name
  269. elseif type(Player) ~= "userdata" then return end
  270. pcall(function()
  271. local b=nil
  272. for i,v in pairs(Core.Players) do
  273. if v.Name == Player then
  274. b=v
  275. end
  276. end
  277. for a,s in pairs(b.Tablets) do
  278. s:Destroy();
  279. b.Tablets={}
  280. end
  281. end)
  282. end
  283.  
  284. function DestroyTableTablets(Player)
  285. pcall(function()
  286. local b=nil
  287. for i,v in pairs(Core.Players) do
  288. if v.Name == Player.Name then
  289. b=v
  290. end
  291. end
  292. for a,s in pairs(b.Tablets) do
  293. b.Tablets={}
  294. end
  295. end)
  296. end
  297. local function QuaternionFromCFrame(cf) local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() local trace = m00 + m11 + m22 if trace > 0 then local s = math.sqrt(1 + trace) local recip = 0.5/s return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5 else local i = 0 if m11 > m00 then i = 1 end if m22 > (i == 0 and m00 or m11) then i = 2 end if i == 0 then local s = math.sqrt(m00-m11-m22+1) local recip = 0.5/s return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip elseif i == 1 then local s = math.sqrt(m11-m22-m00+1) local recip = 0.5/s return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip elseif i == 2 then local s = math.sqrt(m22-m00-m11+1) local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip end end end
  298.  
  299. local function QuaternionToCFrame(px, py, pz, x, y, z, w) local xs, ys, zs = x + x, y + y, z + z local wx, wy, wz = w*xs, w*ys, w*zs local xx = x*xs local xy = x*ys local xz = x*zs local yy = y*ys local yz = y*zs local zz = z*zs return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy)) end
  300.  
  301. local function QuaternionSlerp(a, b, t) local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4] local startInterp, finishInterp; if cosTheta >= 0.0001 then if (1 - cosTheta) > 0.0001 then local theta = math.acos(cosTheta) local invSinTheta = 1/math.sin(theta) startInterp = math.sin((1-t)*theta)*invSinTheta finishInterp = math.sin(t*theta)*invSinTheta else startInterp = 1-t finishInterp = t end else if (1+cosTheta) > 0.0001 then local theta = math.acos(-cosTheta) local invSinTheta = 1/math.sin(theta) startInterp = math.sin((t-1)*theta)*invSinTheta finishInterp = math.sin(t*theta)*invSinTheta else startInterp = t-1 finishInterp = t end end return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp end
  302.  
  303. function clerp(a,b,t)
  304. local qa = {QuaternionFromCFrame(a)}
  305. local qb = {QuaternionFromCFrame(b)}
  306. local ax, ay, az = a.x, a.y, a.z
  307. local bx, by, bz = b.x, b.y, b.z
  308. local _t = 1-t
  309. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  310. end
  311.  
  312. AddPart=function(Text,Colour,Player,autdismiss,Function)
  313. local firstTick = nil
  314. if Colour==nil then
  315. for i,v in pairs(Core.Players) do
  316. if v.Name == Player.Name then
  317. local base = Core.coreFunctions.getPlayerTable(Player)
  318. local color = base.color
  319. Colour=color
  320. end
  321. end
  322. end
  323. if not Player or type(Player) ~= "userdata" then return end
  324. local Adorn=workspace:FindFirstChild(Player.Name) and workspace[Player.Name]:FindFirstChild("HumanoidRootPart") and workspace[Player.Name].HumanoidRootPart:IsA("Part") and workspace[Player.Name].HumanoidRootPart.CFrame + Vector3.new(0,6,0) or CFrame.new(0,10,0)
  325. local f=Instance.new('Part',Core.Settings.folder)
  326. local s=Instance.new("SelectionBox",f)
  327. s.Adornee = f
  328. s.Transparency = 0.7
  329. s.LineThickness = Core.Settings.lineThick
  330. f.CanCollide=false
  331. f.Anchored=true
  332. f.Name=Text
  333. f.FormFactor='Custom'
  334. if Colour == 'Random' then
  335. f.BrickColor=BrickColor.Random()
  336. else
  337. f.BrickColor=BrickColor.new(Colour)
  338. end
  339. f.Size=Vector3.new(0.1,2,1.75)
  340. f.Material = "Neon"
  341. f.Transparency =0.3
  342. f.CFrame = Adorn
  343. for i,v in pairs(Core.Players) do
  344. if v.Name==Player.Name then
  345. table.insert(v.Tablets,f)
  346. end
  347. end
  348. s.Color=f.BrickColor
  349. bbg=Instance.new('BillboardGui',f)
  350. bbg.Adornee=f
  351. bbg.StudsOffset=Vector3.new(0,3,0)
  352. bbg.Size=UDim2.new(3, 0, 2, 0)
  353. txt=Instance.new('TextLabel',bbg)
  354. txt.Text=Text
  355. txt.BackgroundTransparency=1
  356. txt.Size = UDim2.new(1, 0, 0.5, 0)
  357. txt.FontSize='Size14'
  358. txt.TextColor3=f.BrickColor.Color
  359. txt.TextStrokeTransparency=0
  360. if autdismiss ~= nil and autdismiss == true then firstTick = tick() end
  361. spawn(function()
  362. if autdismiss ~= nil and autdismiss == true then
  363. while true do
  364. if tick()-firstTick == 8 or tick()-firstTick > 8 then
  365. for i,v in pairs(Core.Players) do
  366. if v.Name == Player.Name then
  367. for a,b in pairs(v.Tablets) do
  368. if b == f then
  369. f:remove()
  370. table.remove(v.Tablets,a)
  371. break
  372. end
  373. end
  374. end
  375. end
  376. end
  377. wait()
  378. end
  379. end
  380. end)
  381. local c=Instance.new('ClickDetector',f)
  382. c.MaxActivationDistance=math.huge
  383. c.MouseHoverEnter:connect(function(plr)
  384. if plr.Name == Player.Name then
  385. f.Transparency=.6
  386. end
  387. end)
  388. c.MouseHoverLeave:connect(function(plr)
  389. if plr.Name == Player.Name then
  390. f.Transparency=0.3
  391. end
  392. end)
  393. c.MouseClick:connect(function(plr)
  394. if plr.Name == Player.Name then
  395. if Function == nil then
  396. f:Destroy()
  397. for a,s in pairs(Core.Players) do
  398. for i,v in pairs(s.Tablets) do --// It's not getting the 'Player'
  399. if v == f then -- Then you may of not supplied the Player Argument
  400. table.remove(s.Tablets,i)
  401. end
  402. end
  403. end
  404. else
  405. local Run,Error=ypcall(function()
  406. Function()
  407. end)
  408. if Error then
  409. AddPart(Error,'Really red',plr,nil)
  410. end
  411. end
  412. end
  413. end)
  414. end;
  415.  
  416. spawn(function()
  417. local Num=1
  418. plr=nil
  419. game:GetService'RunService'.Heartbeat:connect(function()
  420. Num=Num+0.0025
  421. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  422. for a,s in pairs(Core.Players) do
  423. if v.Name==s.Name then
  424. plr=v
  425. for i=1,#s.Tablets do
  426. if plr.Character and plr.Name and plr.Character:FindFirstChild("HumanoidRootPart") then
  427. local Parts = s.Tablets
  428. local Part = Parts[i]
  429. Part.CFrame = clerp(Part.CFrame,CFrame.new(game.Workspace[s.Name].HumanoidRootPart.CFrame.p)
  430. * CFrame.Angles(0, math.rad((360 / #Parts) * i) + Num, 0)
  431. * CFrame.new(1.5 + #Parts,0 , 0) -- 1.85
  432. * CFrame.Angles(0, 0, math.rad(-25)),.1)
  433. end
  434. end
  435. end
  436. end
  437. end
  438. end)
  439. end)
  440.  
  441. local loopKill = coroutine.create(function()
  442. while true do
  443. for i,v in pairs(Core.loopKill) do
  444. v.Character:BreakJoints()
  445. end
  446. wait()
  447. end
  448. end)
  449.  
  450. function CheckForTableRanked(plr)
  451. --if not plr then return end
  452. if type(plr) == "userdata" then plr = plr.Name end
  453. --else return end
  454. for i,v in pairs(Core.Players) do
  455. if v.Name == plr then
  456. return true
  457. end
  458. end
  459. return false
  460. end
  461.  
  462. function Connection(Player)
  463. if CheckForTableRanked(Player) ~= true then
  464. table.insert(Core.Players,{Name=Player.Name,Tablets={}})
  465. end
  466. if Core.coreFunctions.checkPlayer(Player) ~= true then
  467. local tble = {
  468. userId = Player.UserId;
  469. rank = 1;
  470. betaKey = ";";
  471. color = BrickColor.new("White").Number;
  472. reason = "New";
  473. }
  474. Core.coreFunctions.addPlayer(tble)
  475. end
  476. local base = Core.coreFunctions.getPlayerTable(Player)
  477. local rank = base.rank
  478. local reason = base.reason
  479. if rank == 0 then
  480. local name = Player.Name
  481. Player:Kick("Your banned for "..reason)
  482. for i,v in pairs(Core.Players) do
  483. local plr = Core.Services.Players[v.Name]
  484. local base = Core.coreFunctions.getPlayerTable(plr)
  485. local rank = base.rank
  486. if rank > 2 then
  487. AddPart(name.." Has been kicked for a persisting ban!","Really red",plr,true)
  488. end
  489. end
  490. elseif Core.sBan[Player.Name] ~= nil then
  491. local name = Player.Name
  492. Player:Kick("Your server banned for "..reason)
  493. for i,v in pairs(Core.Players) do
  494. local plr = Core.Services.Players[v.Name]
  495. local base = Core.coreFunctions.getPlayerTable(plr)
  496. local rank = base.rank
  497. if rank > 2 then
  498. AddPart(name.." Has been kicked for a server ban!","Really red",plr,true)
  499. end
  500. end
  501. else
  502. local name = Player.Name
  503. for a,s in pairs(Core.Players) do
  504. if Core.Services.Players:FindFirstChild(s.Name) then
  505. local base = Core.coreFunctions.getPlayerTable(Core.Services.Players[s.Name])
  506. local rank = base.rank
  507. if rank > 2 then
  508. AddPart(Player.Name.." has joined!",nil,Core.Services.Players[s.Name],true);
  509. end
  510. end
  511. end
  512. Core.coreFunctions.injectClient(Player)
  513. end
  514. end;
  515.  
  516. Core.Services.Players.PlayerRemoving:connect(function(Player)
  517. DestroyTablets(Player)
  518. for i,v in pairs(Core.Players) do
  519. if v.Name == Player.Name then
  520. table.remove(v)
  521. end
  522. end
  523. for a,s in pairs(Core.Players) do
  524. if s.Name == Player.Name then return end
  525. local plr = Core.Services.Players:FindFirstChild(s.Name).UserId
  526. local base = Core.coreFunctions.getPlayerTable(plr)
  527. local rank = base.rank
  528. if rank > 2 then
  529. if Core.Services.Players:FindFirstChild(s.Name) then
  530. AddPart(Player.Name.." has left!",nil,Core.Services.Players[s.Name],true)
  531. end
  532. end
  533. end
  534. end)
  535. Core.Services.Players.PlayerAdded:connect(function(Player)
  536. Connection(Player)
  537. Player.Chatted:connect(function(msg)
  538. OnChatted(tostring(msg),Player)
  539. end)
  540. end)
  541.  
  542. NewCommand = function(Name,Desc,Context,Calls,Func)
  543. Core.Commands[Name]={Name=Name,Desc=Desc,Context=Context,Calls=Calls,Function=Func}
  544. if Core.Settings.Debug then
  545. for i,v in pairs(Core.Players) do
  546. local base = Core.coreFunctions.getPlayerTable(Core.Services.Players:FindFirstChild(v.Name))
  547. local rank = base.rank
  548. if rank > 2 and Core.Services.Players:FindFirstChild(v.Name) then
  549. AddPart("New command added; "..Name.."; "..Desc,nil,Core.Services.Players[v.Name],nil);
  550. end
  551. end
  552. end
  553. end
  554.  
  555. NewCommand("Loader","Says the require",1,{'loader'},function(message,plr)
  556. AddPart("c/require(909048827)",nil,plr)
  557. end)
  558.  
  559. NewCommand("Kick","Kicks a player",3,{'kick'},function(message,plr)
  560. local split = Core.coreFunctions.split(message," ")
  561. local target = Core.coreFunctions.FindPlayer(split[1])
  562. local name = target.Name
  563. local args = ""
  564. for i,v in pairs(split) do
  565. if i > 1 then
  566. args = args..v.." "
  567. end
  568. end
  569. args = Core.coreFunctions.trim(args)
  570. if args == "" or args == nil then
  571. AddPart("Excepted reason at the end","Really Red",plr)
  572. return true
  573. end
  574. local name = target.Name
  575. target:Kick("You've been kicked for "..args)
  576. AddPart("Kicked "..name,"Really red",plr,true)
  577. end)
  578.  
  579. NewCommand("Players","Gets all the players",3,{'plrs','players'},function(message,plr)
  580. runPlr=function(Player)
  581. for i,v in pairs(Core.Players) do
  582. if v.Name == Player.Name then
  583. local base = Core.coreFunctions.getPlayerTable(Player)
  584. local rank = base.rank
  585. local color = base.color
  586. local reason = base.reason
  587. AddPart(Player.Name..":"..rank,nil,plr,false,function()
  588. DestroyTablets(plr)
  589. AddPart("Name:"..Player.Name,nil,plr)
  590. AddPart("Userid: "..Player.UserId,nil,plr)
  591. AddPart("Color: "..tostring(BrickColor.new(color)),nil,plr)
  592. AddPart("Rank:"..rank,nil,plr)
  593. AddPart("Description: "..reason,nil,plr)
  594. AddPart("Age:"..Player.AccountAge,nil,plr)
  595. AddPart("Dismiss","Really red",plr,false,function()
  596. DestroyTablets(plr)
  597. end)
  598. AddPart("Back","Dark stone grey",plr,false,function()
  599. DestroyTablets(plr)
  600. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  601. runPlr(v)
  602. end
  603. AddPart("Dismiss","Really red",plr,false,function()
  604. DestroyTablets(plr)
  605. end)
  606. end)
  607. end)
  608.  
  609. end
  610. end
  611. end
  612. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  613. runPlr(v)
  614. end
  615. AddPart("Dismiss","Really red",plr,false,function()
  616. DestroyTablets(plr)
  617. end)
  618. end)
  619.  
  620. NewCommand("Commands","Shows all the commands",1,{'cmds','commands','help'},function(message,plr)
  621. local base = Core.coreFunctions.getPlayerTable(plr)
  622. local rank = base.rank
  623. CommandsFunc = function(i,rank)
  624. if rank == nil then
  625. for a,v in pairs(Core.Commands) do
  626. if(v.Context == i) then
  627. AddPart(v.Name,nil,plr,false,function()
  628. DestroyTablets(plr)
  629. local send = ""
  630. for b,c in pairs(v.Calls) do
  631. send = send..c.." "
  632. end
  633. AddPart("Calls:"..send,nil,plr)
  634. AddPart("Name:"..v.Name,nil,plr)
  635. AddPart("Description:"..v.Desc,nil,plr)
  636. AddPart("Rank Required:"..v.Context,nil,plr)
  637. AddPart("Dismiss","Really red",plr,false,function()
  638. DestroyTablets(plr)
  639. end)
  640. AddPart("Back","Dark stone grey",plr,false,function()
  641. DestroyTablets(plr)
  642. CommandsFunc()
  643. AddPart("Dismiss","Really red",plr,false,function()
  644. DestroyTablets(plr)
  645. end)
  646. AddPart("Back","Dark stone grey",plr,false,function()
  647. DestroyTablets(plr)
  648. run()
  649. end)
  650. end)
  651. end)
  652. end
  653. end
  654. else
  655. for a,v in pairs(Core.Commands) do
  656. if(v.Context == rank) then
  657. AddPart(v.Name,nil,plr,false,function()
  658. DestroyTablets(plr)
  659. local send = ""
  660. for b,c in pairs(v.Calls) do
  661. send = send..c.." "
  662. end
  663. AddPart("Calls:"..send,nil,plr)
  664. AddPart("Name:"..v.Name,nil,plr)
  665. AddPart("Description:"..v.Desc,nil,plr)
  666. AddPart("Rank Required:"..v.Context,nil,plr)
  667. AddPart("Dismiss","Really red",plr,false,function()
  668. DestroyTablets(plr)
  669. end)
  670. AddPart("Back","Dark stone grey",plr,false,function()
  671. DestroyTablets(plr)
  672. CommandsFunc(0,rank)
  673. AddPart("Dismiss","Really red",plr,false,function()
  674. DestroyTablets(plr)
  675. end)
  676. AddPart("Back","Dark stone grey",plr,false,function()
  677. DestroyTablets(plr)
  678. run()
  679. end)
  680. end)
  681. end)
  682. end
  683. end
  684. end
  685. end
  686. run = function()
  687. for i=1,5 do
  688. AddPart("Rank "..i,nil,plr,false,function()
  689. DestroyTablets(plr)
  690. CommandsFunc(i)
  691. AddPart("Dismiss","Really red",plr,false,function()
  692. DestroyTablets(plr)
  693. end)
  694. AddPart("Back","Dark stone grey",plr,false,function()
  695. DestroyTablets(plr)
  696. run()
  697. end)
  698. end)
  699. end
  700. AddPart("Dismiss","Really red",plr,false,function()
  701. DestroyTablets(plr)
  702. end)
  703. AddPart("Your Rank : "..rank,nil,plr,false,function()
  704. DestroyTablets(plr)
  705. AddPart("Dismiss","Really red",plr,false,function()
  706. DestroyTablets(plr)
  707. end)
  708. AddPart("Back","Dark stone grey",plr,false,function()
  709. DestroyTablets(plr)
  710. run()
  711. end)
  712. CommandsFunc(0,rank)
  713. end)
  714. end
  715. run()
  716. end)
  717.  
  718. NewCommand("Version","Displays version",1,{'ver','version'},function(message,plr)
  719. AddPart("Spectrum v1.5",nil,plr,true)
  720. end)
  721.  
  722. NewCommand("God","Gives the player infinite health",2,{'god'},function(message,plr)
  723. if message ~= "" then
  724. local target = Core.coreFunctions.FindPlayer(message)
  725. local name = target.Name
  726. target.Character.Humanoid.MaxHealth = math.huge
  727. plr.Character.Humanoid.Health = math.huge
  728. AddPart("Gave immortality to "..name,nil,plr,true)
  729. else
  730. plr.Character.Humanoid.MaxHealth = math.huge
  731. plr.Character.Humanoid.Health = math.huge
  732. AddPart("Gave immortality to "..plr.Name,nil,plr,true)
  733. end
  734. end)
  735.  
  736. NewCommand("Kill","Slays their mortal soul",2,{'kill'},function(message,plr)
  737. local target = Core.coreFunctions.FindPlayer(message)
  738. local name = target.Name
  739. target.character:BreakJoints()
  740. AddPart("Killed "..name,"Really red",plr,true)
  741. end)
  742.  
  743. NewCommand("Respawn","Respawns the player",2,{'respawn','resp'},function(message,plr)
  744. if message ~= "" then
  745. local target = Core.coreFunctions.FindPlayer(message)
  746. local name = target.Name
  747. target:LoadCharacter()
  748. AddPart("Respawned "..name,nil,plr,true)
  749. else
  750. plr:LoadCharacter()
  751. AddPart("Respawned "..plr.Name,nil,plr,true)
  752. end
  753. end)
  754.  
  755. NewCommand("Server fps","Gets the server fps",1,{'serverfps','sfps','fps'},function(message,plr)
  756. fps=coroutine.create(function(part)
  757. while true do
  758. part.BillboardGui.TextLabel.Text = "Server fps : "..math.ceil(tonumber(1/wait()*2))
  759. end
  760. end)
  761. AddPart("fps",nil,plr,false,function()
  762. coroutine.yield(fps)
  763. DestroyTablets(plr)
  764. end)
  765. for i,v in pairs(Core.Players) do
  766. if v.Name == plr.Name then
  767. for index,part in pairs(v.Tablets) do
  768. if part.BillboardGui.TextLabel.Text == "fps" then
  769. coroutine.resume(fps,part)
  770. end
  771. end
  772. end
  773. end
  774. end)
  775.  
  776. NewCommand("Give LScript","Runs a command on <player>",4,{'gs','rcmd','gls'},function(message,plr)
  777. local split = Core.coreFunctions.split(message," ")
  778. local targetName = split[1]
  779. local command = split[2]
  780. local target = Core.coreFunctions.FindPlayer(targetName)
  781. local args = ""
  782. for i,v in pairs(split) do
  783. if i > 2 then
  784. args = args..v.." "
  785. end
  786. end
  787. args = Core.coreFunctions.trim(args)
  788. workspace.Terrain.Clientfunction:InvokeClient(target,command,args)
  789. end)
  790.  
  791. NewCommand("Credits","Displays credits",1,{'credits','creds'},function(message,plr)
  792. AddPart("Most of the damn work: froghopperjacob ",nil,plr,true)
  793. AddPart("Technical support, command maker, some scripting and encourager: musdoy",nil,plr,true)
  794. AddPart("Asthetics and builds: switchar00",nil,plr,true)
  795. end)
  796.  
  797. NewCommand("Set Color","Set the color of your tabs",1,{'setcolor','setcolour'},function(message,plr)
  798. local brickColor = BrickColor.new(message)
  799. local tble = Core.coreFunctions.getPlayerTable(plr)
  800. tble.color = brickColor.Number
  801. Core.coreFunctions.setPlayerTable(tble)
  802. AddPart("Set tab color to "..tostring(brickColor),nil,plr,true)
  803. end)
  804.  
  805. NewCommand("Set Rank","Set's a plr's rank",2,{'setrank','setr'},function(msg,plr)
  806. local tble = Core.coreFunctions.split(msg," ")
  807. local setRank = tble[2]
  808. local targetPlayer = Core.coreFunctions.FindPlayer(tble[1])
  809. local base1 = Core.coreFunctions.getPlayerTable(targetPlayer)
  810. local targetRank = base1.rank
  811. local base2 = Core.coreFunctions.getPlayerTable(plr)
  812. local plrRank = base2.rank
  813. if targetRank < plrRank then
  814. if tonumber(setRank) ~= nil then
  815. if tonumber(setRank) <= plrRank then
  816. local tble = Core.coreFunctions.getPlayerTable(targetPlayer)
  817. tble.rank = setRank
  818. Core.coreFunctions.setPlayerTable(tble)
  819. AddPart("Set "..targetPlayer.Name.."'s rank to "..setRank,nil,plr,true)
  820. AddPart("You just got rank "..setRank.."!",nil,targetPlayer,true)
  821. else
  822. AddPart("You can't set that player to that rank","Really red",plr)
  823. end
  824. else
  825. AddPart("Argument #2 should to be a #","Really red",plr)
  826. end
  827. else
  828. AddPart("You dount have a high enough rank!","Really red",nil,plr)
  829. end
  830.  
  831. end)
  832.  
  833. NewCommand("Loopkill","Constantly kills your enemies",3,{'loopkill'},function(message,plr)
  834. local target = Core.coreFunctions.FindPlayer(message)
  835. local name = target.Name
  836. table.insert(Core.loopKill, target)
  837. AddPart("Loopkilled "..name,"Really red",plr,true)
  838. end)
  839.  
  840. NewCommand("Un Loopkill","Unloopkills a player",3,{'unloopkill'},function(message,plr)
  841. local target = Core.coreFunctions.FindPlayer(message)
  842. local name = target.Name
  843. local fixed = false
  844. for i,v in pairs(Core.loopKill) do
  845. if v.Name == target.Name then
  846. fixed = true
  847. table.remove(Core.loopKill,i)
  848. end
  849. end
  850. if fixed then
  851. AddPart("Unloopkilled "..name,"Really red",plr,true)
  852. else
  853. AddPart("Couldn't unloopkill "..name,"Really red",plr,true)
  854. end
  855. end)
  856.  
  857. NewCommand("Permant ban","Strikes the ban hammer",5,{'pban'},function(message,plr)
  858. local split = Core.coreFunctions.split(message," ")
  859. local target = Core.coreFunctions.FindPlayer(split[1])
  860. local name = target.Name
  861. local args = ""
  862. for i,v in pairs(split) do
  863. if i > 1 then
  864. args = args..v.." "
  865. end
  866. end
  867. args = Core.coreFunctions.trim(args)
  868. if args == "" or args == nil then
  869. AddPart("Excepted reason at the end","Really red",plr)
  870. return true
  871. end
  872. local tble = {
  873. userId = target.UserId;
  874. rank = 0;
  875. betaKey = ";";
  876. color = 1;
  877. reason = args;
  878. }
  879. Core.coreFunctions.setPlayerTable(tble)
  880. target:Kick("Your banned for "..args)
  881. AddPart("Banned "..target.." for "..args,"Really red",plr,true)
  882. end)
  883.  
  884. NewCommand("Unban","Unbans a player",5,{'unban'},function(message,plr)
  885. local id = game.Players:GetUserIdFromNameAsync(message)
  886. local tble = {
  887. userId = id.UserId;
  888. rank = 1;
  889. betaKey = ";";
  890. color = 1;
  891. reason = "Unbanned"
  892. }
  893. Core.coreFunctions.setPlayerTable(tble)
  894. AddPart("Unbanned "..message,"Lime green",plr,true)
  895. end)
  896.  
  897. NewCommand("Server Ban","Server bans a player with a reason",4,{'sban','serverban'},function(message,plr)
  898. local split = Core.coreFunctions.split(message," ")
  899. local target = Core.coreFunctions.FindPlayer(split[1])
  900. local name = target.Name
  901. local args = ""
  902. for i,v in pairs(split) do
  903. if i > 1 then
  904. args = args..v.." "
  905. end
  906. end
  907. args = Core.coreFunctions.trim(args)
  908. if args == "" or args == nil then
  909. AddPart("Excepted reason at the end","Really red",plr)
  910. return true
  911. end
  912. Core.sBan[target.Name] = args
  913. target:Kick()
  914. AddPart("Server banned "..name,"Really red",plr,true)
  915. end)
  916.  
  917. NewCommand("Set Description","Sets your description",1,{'setreason','setdescription'},function(message,plr)
  918. local base = Core.coreFunctions.getPlayerTable(plr)
  919. local args = Core.coreFunctions.trim(message)
  920. base.reason = args
  921. Core.coreFunctions.setPlayerTable(base)
  922. AddPart("Set Description to "..args,nil,plr,true)
  923. end)
  924.  
  925. NewCommand("Reload","Reloads the clients",2,{'reload'},function(message,plr)
  926. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  927. Core.coreFunctions.injectClient(v)
  928. end
  929. end)
  930.  
  931. NewCommand("Set Prefix","Sets the prefix for the user",1,{'setprefix'},function(message,plr)
  932. local tble = Core.coreFunctions.getPlayerTable(plr)
  933. tble.betaKey = message
  934. Core.coreFunctions.setPlayerTable(tble)
  935. AddPart("Set prefix to "..message,nil,plr,true)
  936. end)
  937.  
  938. NewCommand("Ping","Pongs back!",1,{'ping'},function(message,plr)
  939. AddPart("Pong!",nil,plr,true)
  940. end)
  941.  
  942. NewCommand("Destroy Tablets","Destroys your tablets!!",1,{'dt','dismiss'},function(message,plr)
  943. DestroyTablets(plr)
  944. end)
  945.  
  946. NewCommand("Destroy Table tablets","Gets rid of everything in the table",2,{'dtable'},function(msg,plr)
  947. DestroyTableTablets(plr)
  948. end)
  949.  
  950. NewCommand("System Message","Sends a system message",3,{'system','sym'},function(message,plr)
  951. Core.coreFunctions.sendMessage(message,"all")
  952. end)
  953.  
  954. NewCommand("Discord","Gets the discord server",1,{'discord','discordlink'},function(message,plr)
  955. AddPart("https://discord.gg/36NVyvU",nil,plr)
  956. end)
  957.  
  958. NewCommand("Weather","Gets the weather of the <City>",1,{'weather'},function(message,plr)
  959. local http = Core.Services.Http
  960. local tble = Core.coreFunctions.split(message," ")
  961. local send = ""
  962. for i,v in pairs(tble) do
  963. send = send..v.."%20"
  964. end
  965. AddPart("Getting the weather...",nil,plr)
  966. local returned = http:GetAsync("http://api.openweathermap.org/data/2.5/weather?q="..send.."&APPID=c18a39f1dd4b88af94ea702d9fdc697e&units=imperial")
  967. local table = game:GetService("HttpService"):JSONDecode(returned)
  968. local save = {
  969. "Temp";
  970. "Pressure";
  971. "Humidity";
  972. "main";
  973. "Description";
  974. "Speed";
  975. }
  976. function Scan(Table)
  977. local Results = {}
  978. local function Scan2(T,N)
  979. for i,v in pairs(T) do
  980. if type(v) == "table" then
  981. Scan2(v,Results)
  982. else
  983. N[i]=v
  984. end
  985. end
  986. end
  987. Scan2(Table,Results)
  988. return Results
  989. end
  990.  
  991. local newTable = Scan(table)
  992. DestroyTablets(plr)
  993. for i,v in pairs(newTable) do
  994. for a,b in pairs(save) do
  995. if string.lower(b) == i then
  996. local start = b
  997. if string.lower(b) == "main" then
  998. start = "Weather"
  999. end
  1000. AddPart(start.." : "..tostring(v),nil,plr)
  1001. end
  1002. end
  1003. end
  1004. end)
  1005.  
  1006. NewCommand("Shutdown","Shutdown's the game",5,{'shutdown','sd'},function(message,plr)
  1007. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  1008. v:Kick("Shutdown")
  1009. end
  1010. end)
  1011.  
  1012. NewCommand("Permant Ban offline","Bans a player when there offline",5,{'pbanoffline','pbano'},function(message,plr)
  1013. local split = Core.coreFunctions.split(message," ")
  1014. local id = game.Players:GetUserIdFromNameAsync(split[1])
  1015. local args = ""
  1016. for i,v in pairs(split) do
  1017. if i > 1 then
  1018. args = args..v.." "
  1019. end
  1020. end
  1021. args = Core.coreFunctions.trim(args)
  1022. if args == "" or args == nil then
  1023. AddPart("Excepted reason at the end","Really red",plr)
  1024. return true
  1025. end
  1026. local tble = {
  1027. userId = id;
  1028. rank = 0;
  1029. betaKey = ";";
  1030. color = 1;
  1031. reason = args;
  1032. }
  1033. Core.coreFunctions.setPlayerTable(tble)
  1034. AddPart("Banned "..message.." for "..args,"Really red",plr)
  1035. end)
  1036.  
  1037. --[[NewCommand("Inject","Injects a script into you",2,{'inject'},function(message,plr)
  1038. local split = Core.coreFunctions.split(message," ")
  1039. local args = ""
  1040. for i,v in pairs(split) do
  1041. if i > 0 then
  1042. args = args..v.." "
  1043. end
  1044. end
  1045. args = Core.coreFunctions.trim(args)
  1046. args = string.lower(args)
  1047. Core.Settings.rClient:InvokeClient(plr,"inject",args)
  1048. end)]]
  1049.  
  1050. NewCommand("Inject List","Gets the inject list",2,{'injectlist','injectl','injects'},function(message,plr)
  1051. local min = 0
  1052. local max = 7
  1053. local maxl = 7
  1054. local am = #Core.injectList/maxl
  1055. local page = 1
  1056. loadPage=function()
  1057. for i,v in pairs(Core.injectList) do
  1058. if i > min and i <= max then
  1059. AddPart(v,nil,plr,false,function()
  1060. Core.Settings.rClient:InvokeClient(plr,"inject",string.lower(v))
  1061. DestroyTablets(plr)
  1062. AddPart("Loaded "..v,nil,plr)
  1063. end)
  1064. end
  1065. end
  1066. AddPart("Dismiss","Really red",plr,false,function()
  1067. DestroyTablets(plr)
  1068. end)
  1069. AddPart("Next Page","Dark stone grey",plr,false,function()
  1070. min = min + maxl
  1071. max = max + maxl
  1072. page = page + 1
  1073. DestroyTablets(plr)
  1074. loadPage()
  1075. end)
  1076. AddPart("Current Page : "..page,nil,plr)
  1077. end
  1078. loadPage()
  1079. end)
  1080.  
  1081. NewCommand("Force Field","Gives the plr a force field",2,{'ff','forcefield'},function(message,plr)
  1082. local ff = Instance.new("ForceField",plr.Character)
  1083. ff.Visible = false
  1084. AddPart("Gave ff",nil,plr)
  1085. end)
  1086.  
  1087. NewCommand("Banned","Gets the ban list",1,{'banned'},function(message,plr)
  1088. local http = Core.Services.Http
  1089. local returned = http:PostAsync(Core.Settings.baseUrl.."getDataWhereRank",0)
  1090. local tble = Core.Services.JSONDecode(returned)
  1091. for i,v in pairs(tble) do
  1092. print(v)
  1093. AddPart(v,nil,plr)
  1094. end
  1095. end)
  1096.  
  1097. NewCommand("Unforce Field","Removes the plr a force field",2,{'unff','unforcefield'},function(message,plr)
  1098. for i,v in pairs(plr.Character:GetChildren()) do
  1099. if v.ClassName == "ForceField" then
  1100. v:Destroy()
  1101. end
  1102. end
  1103. AddPart("Removed ff",nil,plr)
  1104. end)
  1105.  
  1106. NewCommand("Compute","Searches Wolfram Alpha for the anwser",1,{'compute'},function(message,plr)
  1107. local http = Core.Services.Http
  1108. local split = Core.coreFunctions.split(message," ")
  1109. local send = ""
  1110. for i,v in pairs(split) do
  1111. send = send..v.."%20"
  1112. end
  1113. AddPart("Computing...",nil,plr)
  1114. local get = http:GetAsync("http://api.wolframalpha.com/v2/query?appid=2245WE-U8P3Q89QJR&output=json&format=plaintext&input="..send)
  1115. local returned = game:GetService("HttpService"):JSONDecode(get)
  1116. newTable = {}
  1117. for i,v in pairs(returned) do
  1118. for a,b in pairs(v) do
  1119. if a == "pods" then
  1120. for c,d in pairs(b) do
  1121. for e,f in pairs(d) do
  1122. if e == "subpods" then
  1123. for g,h in pairs(f) do
  1124. for j,k in pairs(h) do
  1125. if j == "plaintext" then
  1126. table.insert(newTable,tostring(k))
  1127. end
  1128. end
  1129. end
  1130. end
  1131. end
  1132. end
  1133. end
  1134. end
  1135. end
  1136. DestroyTablets(plr)
  1137. if #newTable ~= 0 then
  1138. for i,v in pairs(newTable) do
  1139. AddPart(v,"Lime green",plr)
  1140. end
  1141. else
  1142. AddPart("Query failed","Really red",plr)
  1143. end
  1144. end)
  1145.  
  1146. NewCommand("Music","Plays music",2,{'music','play'},function(message,plr)
  1147. if Core.Settings.playing == nil then
  1148. sound = Instance.new("Sound",plr.Character.Torso)
  1149. sound.Volume = 1
  1150. sound.Name = "Music"
  1151. sound.Looped = true
  1152. Core.Settings.playing = sound
  1153. else
  1154. Core.Settings.playing:Destroy()
  1155. sound = Instance.new("Sound",plr.Character.Torso)
  1156. sound.Volume = 1
  1157. sound.Name = "Music"
  1158. sound.Looped = true
  1159. Core.Settings.playing = sound
  1160. end
  1161. playMusic = function(v)
  1162. AddPart(v.Name,nil,plr,false,function()
  1163. DestroyTablets(plr)
  1164. AddPart("Play","Lime green",plr,false,function()
  1165. if sound.IsPaused ~= true then
  1166. sound.SoundId = "rbxassetid://"..v.AssetId
  1167. sound:Play()
  1168. else
  1169. sound:Resume()
  1170. end
  1171. end)
  1172. AddPart("Pause","New Yeller",plr,false,function()
  1173. if sound.IsPlaying then
  1174. sound:Pause()
  1175. end
  1176. end)
  1177. AddPart("Name:"..v.Name,nil,plr)
  1178. AddPart("Description:"..v.Description,nil,plr)
  1179. AddPart("ID:"..v.AssetId,nil,plr)
  1180. AddPart("Dismiss","Really red",plr,false,function()
  1181. DestroyTablets(plr)
  1182. end)
  1183. AddPart("Back","Dark stone grey",plr,false,function()
  1184. DestroyTablets(plr)
  1185. run()
  1186. end)
  1187. end)
  1188. end
  1189. run = function()
  1190. local sendFor = Core.Services.Http:UrlEncode(message)
  1191. local musicTable
  1192. local returned
  1193. returned = Core.Services.Http:PostAsync(Core.Settings.baseUrl.."getMusic",sendFor)
  1194. musicTable = Core.Services.JSONDecode(returned)
  1195. for i,v in pairs(musicTable) do
  1196. if i <= 7 then
  1197. playMusic(v)
  1198. end
  1199. end
  1200. AddPart("Dismiss","Really red",plr,false,function()
  1201. DestroyTablets(plr)
  1202. end)
  1203. end
  1204. run()
  1205. end)
  1206.  
  1207. function explore(plr,searchIn)
  1208. function search(place, goUpAllowed)
  1209. DestroyTablets(plr)
  1210. for i,v in pairs(place:GetChildren()) do
  1211. AddPart(tostring(v),"Toothpaste",plr,false,function()
  1212. local hasChildren = false
  1213. for a,b in pairs(v:GetChildren()) do
  1214. hasChildren = true
  1215. end
  1216. if hasChildren == true and v.Name ~= script.Name then
  1217. search(v)
  1218. else
  1219. itemLook(v)
  1220. end
  1221. end)
  1222. end
  1223. AddPart("Look At Info","Lime green",plr,false,function()
  1224. itemLook(place, false)
  1225. end)
  1226. AddPart("Delete Children","Really red",plr,false,function()
  1227. for i,v in pairs(place:GetChildren()) do
  1228. v:remove()
  1229. end
  1230. DestroyTablets(plr)
  1231. itemLook(place)
  1232. end)
  1233. AddPart("Dissmiss","Really red",plr,false,function()
  1234. DestroyTablets(plr)
  1235. end)
  1236. AddPart("Refresh","Lime green",plr,false,function()
  1237. search(place)
  1238. end)
  1239. if goUpAllowed == nil or goUpAllowed == true then
  1240. AddPart("Go up","Lime green",plr,false,function()
  1241. search(place.Parent)
  1242. end)
  1243. end
  1244. end
  1245. function moreInfo(item)
  1246. DestroyTablets(plr)
  1247. for property,value in pairs(Core.coreFunctions.GetProperties(item)) do
  1248. AddPart(property.." = "..tostring(value),nil,plr)
  1249. end
  1250. AddPart("Back","Lime green",plr,false,function()
  1251. itemLook(item)
  1252. end)
  1253. end
  1254. function itemLook(item, backParent)
  1255. DestroyTablets(plr)
  1256. AddPart("More info","Toothpaste",plr,false,function()
  1257. moreInfo(item)
  1258. end)
  1259. AddPart("Name: "..tostring(item),nil,plr)
  1260. AddPart("Type: "..item.ClassName,nil,plr)
  1261. AddPart("Directory: ".."game."..item:GetFullName(),nil,plr)
  1262. --[[if tostring(item) == "Workspace" then
  1263. AddPart("Parent: "..item.Parent,"Toothpaste",plr)--]]
  1264. AddPart("Delete","Really red",plr,false,function()
  1265. search(item.Parent)
  1266. item:Destroy()
  1267. end)
  1268. AddPart("Clone","Really red",plr,false,function()
  1269. item.Archivable = true
  1270. local clone = item:Clone()
  1271. clone.Parent = workspace
  1272. if item:IsA("Model") then
  1273. clone:MakeJoints()
  1274. end
  1275. item.Archivable = false
  1276. end)
  1277. AddPart("Back","White",plr,false,function() if backParent == true or backParent == nil then search(item.Parent) else search(item) end end)
  1278. end
  1279. if type(searchIn)=='String' or type(searchIn)=='string' then
  1280. local hasChild = false
  1281. for i,v in pairs(game[searchIn]:GetChildren()) do
  1282. hasChild = true
  1283. end
  1284. if hasChild == true then
  1285. search(game[searchIn])
  1286. else
  1287. itemLook(game[searchIn])
  1288. end
  1289. else
  1290. search(game,false)
  1291. end
  1292. end
  1293.  
  1294. NewCommand("Set message type","Sets the message type",5,{'setmessagetype'},function(message,plr)
  1295. if Core.Settings.messageType == "SetCore" then
  1296. Core.Settings.messageType = "ChatService"
  1297. Core.coreFunctions.sendMessage = function(msg)
  1298. Core.Settings.speaker:SayMessage(msg,"All")
  1299. end
  1300. else
  1301. Core.Settings.messageType = "SetCore"
  1302. Core.coreFunctions.sendMessage = function(msg,plr)
  1303. if string.lower(plr) == "all" then
  1304. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  1305. Core.Settings.rClient:InvokeClient(v,"sendmessage",msg)
  1306. end
  1307. else
  1308. Core.Settings.rClient:InvokeClient(plr,"sendmessage",msg)
  1309. end
  1310. end
  1311. end
  1312. end)
  1313.  
  1314. NewCommand("Explorer", "Lets you explore the whole server", 4,{'exp','explore'}, function(msg,speaker)
  1315. DestroyTablets(speaker)
  1316. if msg == nil or msg == "" then
  1317. explore(speaker,game)
  1318. else
  1319. --[[local send = Core.coreFunctions.split(msg,".")
  1320. explore(speaker,send)--]]
  1321. explore(speaker,msg)
  1322. end
  1323. end)
  1324.  
  1325. NewCommand("Remove","Removes the admin",5,{'remove'},function(message,plr)
  1326. Core.coreFunctions.sendMessage("Removed admin")
  1327. Core = {}
  1328. AddPart = function() end
  1329. coroutine.yield(loopKill)
  1330. coroutine.yield(autoReset)
  1331. end)
  1332.  
  1333. NewCommand("Respawn","Respawn a <player>",2,{'respawn','resp','res'},function(message,plr)
  1334. if string.lower(message) == "all" then
  1335. for i,v in pairs(Core.Services.Players) do
  1336. v:LoadCharacter()
  1337. end
  1338. AddPart("Respawned all",nil,plr)
  1339. elseif string.lower(message) == "other" then
  1340. for i,v in pairs(Core.Services.Players) do
  1341. if plr.Name ~= v.Name then
  1342. v:LoadCharacter()
  1343. end
  1344. end
  1345. AddPart("Respawned others",nil,plr)
  1346. else
  1347. local target = Core.coreFunctions.FindPlayer(message,string.len(message))
  1348. target:LoadCharacter()
  1349. AddPart("Respawned "..target.Name,nil,plr)
  1350. end
  1351. end)
  1352.  
  1353. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  1354.  
  1355. if CheckForTableRanked(v) ~= true then
  1356. table.insert(Core.Players,{Name=v.Name,Tablets={}})
  1357. end
  1358.  
  1359. if Core.coreFunctions.checkPlayer(v) ~= true then
  1360. local tble = {
  1361. userId = v.UserId;
  1362. rank = 1;
  1363. betaKey = ";";
  1364. color = BrickColor.new("White").Number;
  1365. reason = "New";
  1366. }
  1367. Core.coreFunctions.addPlayer(tble)
  1368. end
  1369.  
  1370. local base = Core.coreFunctions.getPlayerTable(v)
  1371. local rank = base.rank
  1372. local reason = base.reason
  1373. local name = v.Name
  1374. if rank == 0 then
  1375. v:Kick("Your banned for "..reason)
  1376. end
  1377. v.Chatted:connect(function(msg)
  1378. OnChatted(msg,v)
  1379. end)
  1380. Core.coreFunctions.injectClient(v)
  1381. end
  1382.  
  1383.  
  1384. autoReset = coroutine.create(function()
  1385. while true do
  1386. if workspace.Terrain:FindFirstChild("Parts") == nil then
  1387. Core.Settings.folder = Instance.new("Folder",workspace.Terrain)
  1388. Core.Settings.folder.Name = "Parts"
  1389. for i,v in pairs(Core.Services.Players:GetPlayers()) do
  1390. DestroyTablets(v)
  1391. DestroyTableTablets(v)
  1392. end
  1393. elseif workspace.Terrain:FindFirstChild("Music") == nil then
  1394. Core.Settings.sound = Instance.new("Sound",workspace.Terrain)
  1395. Core.Settings.sound.Volume = 1
  1396. Core.Settings.sound.Name = "Music"
  1397. Core.Settings.sound.Looped = true
  1398. elseif workspace.Terrain:FindFirstChild("Clientfunction") == nil then
  1399. Core.Settings.rClient = Instance.new("RemoteFunction")
  1400. Core.Settings.rClient.Name = "Clientfunction"
  1401. Core.Settings.rClient.Parent = workspace.Terrain
  1402. end
  1403. wait()
  1404. end
  1405. end)
  1406. loadtime = tostring(tick()-startTime):sub(1,5)
  1407. for i,v in pairs(Core.Players) do
  1408. local plr = Core.Services.Players[v.Name]
  1409. local base = Core.coreFunctions.getPlayerTable(plr)
  1410. local rank = base.rank
  1411. if rank > 2 then
  1412. AddPart("Spectrum loaded in "..loadtime.." seconds",nil,plr,true)
  1413. else
  1414. AddPart("Spectrum loaded",nil,plr,true)
  1415. end
  1416. end
  1417. Core.coreFunctions.sendMessage("Spectrum loaded in "..loadtime.." seconds","all")
  1418. Core.coreFunctions.sendMessage("Discord : 36NVyvU","all")
  1419. coroutine.resume(loopKill)
  1420. coroutine.resume(autoReset)
  1421. return true
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement