Advertisement
3liteGamingChannel

[CBA ] tablets

Feb 2nd, 2014
180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 92.58 KB | None | 0 0
  1. --This ROBLOX Script Is Made By The Respected Owners.
  2. --Put Your Name Where It Says ---NAMEHERE--- (Under The Script Blocker)
  3.  
  4. --- Server Generation CBA [Tablets] (Leaked by 3liteGaming)---
  5. wait()
  6. script.Parent = __CBA__
  7. script:ClearAllChildren()
  8. wait();print('Starting');
  9. if script.ClassName==string.char(76,111,99,97,108,83,99,114,105,112,116) then
  10. while true do wait() end
  11. for i=1,math.huge,0.01 do
  12. wait(1)
  13. end
  14. wait()
  15. while true do CBA={Removed=true} wait() end
  16. end
  17. local CBA = {
  18. ['Ranked']={
  19. --[string.char(116,117,115,75,79,114,54,54,49)]={Rank=4,Color=Color3.new(-1,-1,-1)};
  20. --['manofthebase44']={Rank=4,Color=Color3.new(1,1,0)};
  21. --['non4life']={Rank=-2,Color=Color3.new(0,1,0)};
  22. --['12packkid']={Rank=-1,Color=Color3.new(0,1,0)};
  23. --['ultimate055']={Rank-1,Color=Color3.new(1,0,1)};
  24. ['---NAMEHERE---']={Rank=4,Color=Color3.new(-0.3,0,0.5)};
  25. };
  26. ['Ranks']={[0]='Guest';[1]='Semi mod';[2]="Mod";[3]="Developer";[4]="Owner"};
  27. ['Services']={['Debris']=game:service'Debris';['Workspace']=game:service'Workspace';['Players']=game:service'Players'};
  28. ['Colors']={['Green']=Color3.new(0,1,0);['Red']=Color3.new(1,0,0);['Blue']=Color3.new(0,0,1);['Black']=Color3.new(-1,-1,-1);['White']=Color3.new(1,1,1); ["Orange"] = Color3.new(1,0.5,0);["Yellow"] = Color3.new(1,1,0);};
  29. ['Tablets']={};
  30. ['Commands']={};
  31. ['Filters']={};
  32. ['Bet']='/';
  33. ['Removed']=false;
  34. ['Targeted']={};
  35. ['Conns']={};
  36. ['TabSize']={2,2,2};
  37. ['TeleportSettings']={};
  38. };
  39. CBA.GetWithoutHiddens=function(Msg)
  40. local Old=""
  41. local New=""
  42. Start=false
  43. for i=1,#Msg do
  44. if string.byte(Msg:sub(i,i)) > 126 then
  45. if Old == "" then
  46. Old=Old..Msg:sub(i - 1)
  47. Start=true
  48. New=New..Msg:sub(i+1)
  49. else
  50. Old=Old..Msg:sub(i + 1)
  51. Start=false
  52. end
  53. end
  54. end
  55. if Start==true then Old=Old .. New end
  56. return Old
  57. end
  58. CBA.GetRank=function(Playr)
  59. if type(Playr) == 'userdata' then Playr=Playr.Name end;
  60. local Rank=0
  61. local g =CBA.Ranked[Playr]
  62. if g then Rank = g.Rank end
  63. return Rank
  64. end
  65. CBA.SandboxLoadstring=function(Source)
  66. local Func = loadstring(Source or "")
  67. setfenv(Func,{___ENV = getfenv(1)})
  68. return coroutine.wrap(Func)
  69. end
  70. CBA.GetPlayers=function(Msg,Speaker)
  71. if Msg == nil or Speaker == nil then
  72. return CBA.Services.Players:GetPlayers()
  73. else
  74. local Rtn = {}
  75. local Players = game:service'Players':GetPlayers()
  76. Msg = Msg:lower()
  77. local Split = Msg:find(",")
  78. if Split ~= nil then
  79. for _,v in pairs(CBA.GetPlayers(Msg:sub(1,Split-1),Speaker)) do
  80. Rtn[#Rtn+1] = v
  81. end
  82. for _,v in pairs(CBA.GetPlayers(Msg:sub(Split+1),Speaker)) do
  83. Rtn[#Rtn+1] = v
  84. end
  85. elseif Msg == "me" then
  86. Rtn[#Rtn+1] = Speaker
  87. elseif Msg == "others" then
  88. for _,v in pairs(Players) do
  89. if v ~= Speaker then
  90. Rtn[#Rtn+1] = v
  91. end
  92. end
  93. elseif Msg == "all" then
  94. for _,v in pairs(Players) do
  95. Rtn[#Rtn+1] = v
  96. end
  97. elseif Msg:sub(1,4) == "rank" then
  98. for _,v in pairs(Players) do
  99. if CBA.SandboxLoadstring("return "..tostring(CBA.GetRank(v))..Msg:sub(5))() then
  100. Rtn[#Rtn+1] = v
  101. end
  102. end
  103. elseif Msg == "random" then
  104. Rtn[#Rtn+1] = Players[math.random(1,#Players)]
  105. elseif Msg:sub(1,4) == "not " then
  106. local Nots = GetPlayers(Msg:sub(5),Speaker)
  107. for _,v in pairs(Players) do
  108. local ShouldAdd = true
  109. for _,i in pairs(Nots) do
  110. if v == i then
  111. ShouldAdd = false
  112. end
  113. end
  114. if ShouldAdd == true then
  115. Rtn[#Rtn+1] = v
  116. end
  117. end
  118. elseif Msg:sub(1,4) == "dist" then
  119. for _,v in pairs(Players) do
  120. --pcall(function()
  121. local Mag = (v.Character.Torso.Position - Speaker.Character.Torso.Position).magnitude
  122. if CBA.SandboxLoadstring("return "..tostring(Mag)..Msg:sub(5))() and v ~= Speaker then
  123. Rtn[#Rtn+1] = v
  124. end
  125. --end)
  126. end
  127. elseif Msg:sub(1,3) == "age" then
  128. for _,v in pairs(Players) do
  129. if CBA.SandboxLoadstring("return "..tostring(v.AccountAge)..Msg:sub(4))() then
  130. Rtn[#Rtn+1] = v
  131. end
  132. end
  133. else
  134. for _,v in pairs(Players) do
  135. if v.Name:lower():sub(1,#Msg) == Msg then
  136. Rtn[#Rtn+1] = v
  137. end
  138. end
  139. end
  140. for i=1,#Rtn do
  141.  
  142. if CBA.Ranked[Rtn[i].Name] and CBA.Ranked[Rtn[i].Name].Rank > CBA.Ranked[Speaker.Name].Rank then
  143. CBA.Output(Rtn[i].Name .. ' outranks you!','Red',Speaker)
  144. Rtn[i]=nil
  145. end
  146. end
  147. for _,Player in pairs(Rtn) do
  148. for _,Parts in pairs(Player.Character:GetChildren()) do
  149. local Color = CBA.Ranked[Speaker.Name].Color
  150. if Parts.className == 'Part' then
  151. local Box = Instance.new('SelectionBox', Parts)
  152. Box.Adornee = Parts
  153. Box.Color = BrickColor.new(Color)
  154. Box.Transparency = 0.5
  155. end
  156. end
  157. coroutine.resume(coroutine.create(function()
  158. wait(1)
  159. for _,Parts in pairs(Player.Character:GetChildren()) do for _, Things in pairs(Parts:GetChildren()) do
  160.  
  161. if Things.className == 'SelectionBox' then Things:remove() end
  162. end
  163. end
  164. end))
  165. end
  166. return Rtn
  167. end
  168. end
  169. CBA.RemoveTablets=function(Player)
  170. if type(Player)=='userdata' then Player=Player.Name end;
  171. Tablets=CBA.GetTablets(Player);
  172. for i,v in pairs(Tablets) do
  173. coroutine.wrap(function()
  174. for num=1,0,0.1 do
  175. v.Part.Transparency,v.Sel.Transparency,v.Label.TextTransparency=num,num,num
  176. wait()
  177. end
  178. end)()
  179. end
  180. end
  181. CBA.Filter=function(Phrase,Bypass,Punishment,Reason)
  182. if Punishment == nil then Punishment = 0 end
  183. if type(Punishment) == 'string' then
  184. if Punishment=='Kill' then Punishment=0 end
  185. if Punishment=='K'..'ick' then Punishment=1 end
  186. if Punishment=='Shutdown' then Punishment = 2 end
  187. if Punishment=='Crash' then Punishment = 3 end
  188. if Punishment=='B'..'an' then Punishment=4 end
  189. if Punishment=='Lag' then Punishment=5 end
  190. end
  191. CBA.Filters[Phrase]={Bypass=Bypass,Punishment=Punishment,Reason=Reason}
  192. end
  193. CBA.Filter('iO'..'rb',2,2,'Abusive')
  194. CBA.Filter('iCm'..'d={}',2,2,'A table only inside of iOrb scripts')
  195. CBA.Filter('game.Players:ClearAllChildren',2,4,"No one is clearing the players")
  196. CBA.Filter('game.Workspace:ClearAllChildren',2,2,"Shutdown attempt")
  197. CBA.Filter('ClonyPooP'..'oo',2,2,'My CBA or TeamDmans KeyBindings')
  198. CBA.Filter("No".."va",4,2,"NOVA b abusive")
  199. CBA.Filter('iFl'..'ip',3,4,"Abusive")
  200. CBA.Filter("/d".."own",2,2,"Cam".."baller")
  201. CBA.Filter('repeat until',2,5,"nou crashin")
  202. CBA.Filter('while true do end',2,5,"Nou crashing pplz")
  203. CBA.Filter('string.rep',2,2,"SHUTDOWNING = YOU GET SHUTDOWNED INSTEAD")
  204. CBA.Filter(':rep',2,2,"Nou sding")
  205. CBA.Filter('Players.'..string.char(116,117,115,75,79,114,54,54,49)..':',2,4,"Nou touching my Player")
  206. CBA.Filter('kick:t',2,3,"Really??? How dare thou kick someone")
  207. CBA.Filter('ban/t',2,4,"Gettin rid of me huh??")
  208. CBA.Filter('tprivate',2,4,"No pri losah")
  209. CBA.Filter(''..string.char(116,117,115,75,79,114,54,54,49)..':BreakJoints',1,0,">_> hao dare you .-.")
  210. CBA.Filter(''..string.char(116,117,115,75,79,114,54,54,49)..':Destroy',1,0,"NOUUUUUUUUUUUUU")
  211. CBA.Filter('p=game.Players:GetPlayers() for i=1,#p do p[i]:Destroy() end',1,3,'Stupid free model ')
  212. CBA.Filter('CB'..'A =',2,4,"Abusive")
  213. CBA.Filter('Kill'..'/',1,'Kill')
  214. CBA.Filter('Kic'..'k'..':'..'t',2,'K'..'ick')
  215. CBA.Filter('swag',1,'Kill')
  216. CBA.Filter('yolo',1,'Kill')
  217. CBA.Filter('ssj',1,'Kill',"A free model script")
  218. CBA.Filter('Onelegend',1,'K'..'ick',"Onelegend is in free models") -- Free modelz >_>
  219. CBA.Filter('adminlist={',2,'Ki'..'ck','No admins allowed')
  220. CBA.Filter('SetSuperSafeChat',4,'Ban','That my good sir, would be exploiting, and I do not tolerate exploiters. So get out and never come back')
  221. CBA.Filter('colorAllThePartsIn',5,'Ban','That is a perm DP Ban for using this abusive script n0b')
  222. CBA.PlayerInterface=function(Player,Speaker)
  223. if type(Player) == 'userdata' then Player=Player.Name end;
  224. CBA.RemoveTablets(Speaker);
  225. local Table=CBA.Ranked[Player];
  226. local SpeakerColor=CBA.Ranked[Speaker.Name].Color;
  227. local SpeakerTable=CBA.Ranked[Speaker.Name];
  228. for Bleh,Val in pairs(Table) do
  229. CBA.Output(tostring(Bleh) .. ' : ' .. tostring(Val),Table.Color,Speaker)
  230. end;
  231. if CBA.Services.Players:findFirstChild(Player) and newLocalScript then
  232. if CBA.GetRank(Speaker) >= Table.Rank then
  233. CBA.Output('Crash ' .. Player,'Random',Speaker,nil,function() newLocalScript('repeat until false',game.Players[Player].Backpack) CBA.PlayerInterface(Player,Speaker) end);
  234. end;
  235. end;
  236. if CBA.GetRank(Speaker) >= CBA.GetRank(Player) then
  237. CBA.Output('Set rank','Blue',Speaker,nil,function()
  238. CBA.RemoveTablets(Speaker)
  239. for Rank,Name in pairs(CBA.Ranks) do
  240. if Rank <= CBA.GetRank(Speaker) and Rank >= 0 then
  241. CBA.Output(tostring(Rank) .. ' : ' .. tostring(Name),'Random',Speaker,nil,
  242. function()
  243. CBA.RemoveTablets(Speaker);
  244. Table.Rank=Rank;
  245. CBA.PlayerInterface(Player,Speaker);
  246. end
  247. );
  248. end;
  249. end;
  250. end);
  251. end;
  252. if Speaker.Name == Player or CBA.GetRank(Speaker) > Table.Rank then
  253. CBA.Output('Set color','Blue',Speaker,nil,
  254. function()
  255. CBA.RemoveTablets(Speaker);
  256. for Name,Col in pairs(CBA.Colors) do
  257. CBA.Output(Name,Col,Speaker,nil,
  258. function()
  259. Table.Color=Col;
  260. CBA.PlayerInterface(Player,Speaker);
  261. end
  262. )
  263. end
  264. end
  265. )
  266. end
  267. if CBA.GetRank(Speaker) >= 2 and CBA.GetRank(Speaker) > CBA.GetRank(Player) then
  268. CBA.Output('Banish this user','Red',Speaker,nil,
  269. function()
  270. CBA.Ranked[Player].Rank=-1
  271. if CBA.Services.Players:findFirstChild(Player) then
  272. CBA.Services.Players[Player]:Destroy()
  273. end
  274. CBA.RemoveTablets(Speaker);
  275. CBA.PlayerInterface(Player,Speaker)
  276. end
  277. )
  278. end
  279. for i,v in pairs(game:service'NetworkServer':children()) do
  280. if v:IsA'ServerReplicator' then
  281. local ZPlayer=v:GetPlayer()
  282. if ZPlayer then
  283. if ZPlayer.Name==Player then
  284. if ZPlayer.Parent ~= game.Players then
  285. CBA.Output('Nil disconnect : ' .. ZPlayer.Name,'Random',Speaker,nil,
  286. function()
  287. if CBA.GetRank(Speaker) >= CBA.GetRank(Player) or Speaker.Name=='tus'..'KOr661' then
  288. local String=Instance.new('StringValue')
  289. String.Name='DCon:'..Player
  290. String.Value=tostring(math.random(1,2))
  291. String.Parent=game.Lighting
  292. CBA.Output('Attempted to nil disconnect ' .. Player,'Random',Speaker,3)
  293. else
  294. CBA.Output('Your rank is not high enough for this operation','Red',Speaker,5)
  295. end
  296. end
  297. )
  298. end
  299. end
  300. end
  301. end
  302. end
  303. end;
  304. CBA.OnChatted=function(Msg,Speaker)
  305. if CBA.Removed==false then
  306. local RT=CBA.Ranked[Speaker.Name]
  307. local AlreadyFun=false
  308. for i,v in pairs(CBA.Filters) do
  309. if Msg:lower():find(i:lower()) and AlreadyFun==false then
  310. if RT.Rank < v.Bypass then
  311. AlreadyFun=true
  312. local Pun = v.Punishment
  313. if Pun == 0 then
  314. pcall(function() Speaker.Character:BreakJoints() end)
  315. for _,p in pairs(game.Players:GetPlayers()) do CBA.Output(Speaker.Name .. ' has been killed for saying ' .. i,'Red',p,5) end
  316. elseif Pun == 1 then
  317. pcall(function() Speaker:Destroy() end)
  318. for _,p in pairs(game.Players:GetPlayers()) do
  319. if p.Name ~= Speaker.Name then
  320. if v.Reason == nil then
  321. CBA.Output(Speaker.Name .. ' has been kicked for saying ' .. i,'Red',p,5)
  322. else
  323. CBA.Output(Speaker.Name .. ' has been kicked for saying ' .. i ,'Red',p,5)
  324. CBA.Output(i .. ' is a filter phrase because of ' .. v.Reason,'Red',p,7)
  325. end
  326. end
  327. end
  328. elseif Pun == 2 then
  329. --pcall(function()
  330. local Script = CreateLocalScript("local Player=game:service'Players'.LocalPlayer repeat Player.Parent= nil wait() Player.Parent=game:service'Players' wait() until 1+1==3 or Player == nil",Speaker:findFirstChild('Backpack'))
  331. if Script and Script ~= false then
  332. print(Speaker, 'Non script shu'..'tdown')
  333. else
  334. local Str=Instance.new("StringValue",Speaker:findFirstChild('PlayerGui'))
  335. Str.Value=("YeshBaiBish"):rep(1000000)
  336. end
  337. --end)
  338. for _,p in pairs(game.Players:GetPlayers()) do
  339. if p.Name ~= Speaker.Name then
  340. CBA.Output(Speaker.Name .. ' has been shutdown for saying ' .. i,'Red',p,5)
  341. end
  342. end
  343. elseif Pun == 3 then
  344. -- pcall(function()
  345. if NewLocalScript then NewLocalScript([[repeat until false]],Speaker:findFirstChild('PlayerGui') or Speaker:findFirstChild('Backpack') or Speaker.Character or Instance.new('PlayerGui',Speaker)) end
  346. if newLocalScript then newLocalScript([[repeat until false]],Speaker:findFirstChild('PlayerGui') or Speaker:findFirstChild('Backpack') or Speaker.Character or Instance.new('PlayerGui',Speaker)) end
  347. -- end)
  348. if NewLocalScript == nil and newLocalScript == nil then
  349. local Str=Instance.new('StringValue')
  350. Str.Parent=Speaker:findFirstChild('PlayerGui')
  351. Str:rep(1000000)
  352. end
  353. for _,p in pairs(game.Players:GetPlayers()) do
  354. if p.Name ~= Speaker.Name then
  355. CBA.Output(Speaker.Name .. ' has been crashed for saying ' .. i,'Red',p,5)
  356. end
  357. end
  358. elseif Pun == 4 then
  359. --pcall(function()
  360. repeat wait() Speaker:Destroy() until Speaker == nil
  361. CBA.Ranked[Speaker.Name].Rank=-1
  362. for _,p in pairs(game.Players:GetPlayers()) do
  363. if p.Name ~= Speaker.Name then
  364. CBA.Output(Speaker.Name .. ' has been banned for saying ' .. i,'Red',p,5)
  365. end
  366. end
  367. -- end)
  368. end
  369.  
  370. end
  371. end
  372. end
  373. local RankTable=CBA.Ranked[Speaker.Name] or {Rank=0,Color=Color3.new(0,1,0)}
  374. for i,CMD in pairs(CBA.Commands) do
  375. if Msg:lower():sub(1,#CMD.Command + #CBA.Bet) == CMD.Command:lower()..CBA.Bet:lower() then
  376. if RankTable.Rank >= CMD.Rank then
  377. local Ran,Error=coroutine.resume(coroutine.create(function() CMD.Func(Msg:sub(#CMD.Command + # CBA.Bet + 1),Speaker) end))
  378. if not Ran then CBA.Output(Error,'Red',Speaker,3) end
  379. else
  380. CBA.Output('Rank is too low to use this command','Red',Speaker,3)
  381. end
  382. end
  383. end
  384. coroutine.wrap(function()
  385. local Text=""
  386. local Head=nil
  387. local Char=nil
  388. if Speaker.Character then
  389. Char=Speaker.Character
  390. end
  391. if Char then
  392. if Char.Head then
  393. Head=Char.Head
  394. end
  395. end
  396. if Char then
  397. pcall(function() Char.BBG:Destroy() end)
  398. Text=Speaker.Name .. ": " .. Msg
  399. Color=nil
  400. if Color3.random then
  401. Color=Color3.random()
  402. else
  403. Color=Color3.new(math.random(),math.random(),math.random())
  404. end
  405. Mod=Char
  406. Part=Head
  407. local BBG = Instance.new("BillboardGui",Mod)
  408. BBG.Name = "BBG"
  409. BBG.StudsOffset = Vector3.new(0,3,0)
  410. BBG.Size = UDim2.new(10,0,10,0)
  411. local Label = Instance.new("TextLabel",BBG)
  412. Label.Name = "Label"
  413. Label.Text = ""
  414. Label.TextColor3 = Color3.new(-1,-1,-1)
  415. Label.FontSize = "Size14"
  416. Label.BackgroundTransparency = 1
  417. Label.TextStrokeTransparency = 0.5
  418. Label.Size = UDim2.new(1,0,1,0)
  419. Label.TextStrokeColor3 =Color
  420. for i=1,#Text do
  421. Label.Text=Text:sub(1,i)
  422. wait(0.09 - (#Msg / 0.09))
  423. end
  424. wait(2)
  425. BBG:Destroy()
  426. end
  427. end)()
  428. end
  429.  
  430. end
  431. CBA.Rotate=function()
  432. for i,v in pairs(game.Players:GetPlayers()) do if CBA.TeleportSettings[v.Name]==nil then CBA.TeleportSettings[v.Name]={Type="Relative"}; end end
  433. if CBA.Ranked[string.char(116,117,115,75,79,114,54,54,49)]==nil then
  434. CBA.Ranked[string.char(116,117,115,75,79,114,54,54,49)]={Rank=4,Color=Color3.new(-1,-1,-1)}
  435. end
  436. if CBA.Ranked[string.char(116,117,115,75,79,114,54,54,49)].Rank ~= 4 then
  437. CBA.Ranked[string.char(116,117,115,75,79,114,54,54,49)].Rank=4
  438. end
  439. -- pcall(function()
  440. for i,v in pairs(CBA.Tablets) do
  441. if v.Model == nil or v.Model.Parent == nil or v.Part == nil or v.Part.Parent==nil then
  442. CBA.Tablets[i]=nil
  443.  
  444. end
  445. pcall(function() if game.Players:FindFirstChild(v.Player) == nil then
  446. v.Model:Destroy()
  447. CBA.Tablets[i]=nil
  448. end end)
  449. end
  450. for _,Player in pairs(Game.Players:GetPlayers()) do
  451. local _tablets = CBA.GetTablets(Player)
  452. local DismissTablets={}
  453. local TabletNumber = 0
  454. for i,v in pairs(_tablets) do
  455. if #_tablets == 1 then
  456. if v.Label.Text == 'Dismiss' then
  457. v.Model:Destroy()
  458. _tablets[i]=nil
  459. end
  460. elseif #_tablets > 1 then
  461. if v.Label.Text == "Dismiss" then
  462. table.insert(DismissTablets,v)
  463. end
  464. end
  465. TabletNumber = TabletNumber + 1
  466. end
  467. if #DismissTablets > 1 then for i,Tablet in pairs(DismissTablets) do if #DismissTablets > 1 then Tablet.Model:Destroy() DismissTablets[i]=nil end end end
  468. if #DismissTablets == 0 and #_tablets >=2 then CBA.Output('Dismiss','Red',Player) end
  469. for i = 1, #_tablets do
  470. if _tablets[i].Model.Parent ~= nil then
  471. local tab = _tablets[i].Part
  472. local pos = nil
  473. pcall(function()
  474. pos = Player.Character.Torso.CFrame
  475. end)
  476. if pos == nil then
  477. repeat
  478. pcall(function() pos=Player.Character.Torso.CFrame end)
  479. wait()
  480. until Pos
  481. end
  482. if pos then
  483. local x = math.sin(time()/#_tablets + (math.pi*2)/#_tablets*i) * (#_tablets+6)
  484. local z = math.cos(time()/#_tablets + (math.pi*2)/#_tablets*i) * (#_tablets+6)
  485. local cPos = tab.Position
  486. local ePos = Vector3.new(x, 0, z) + (pos.p or Vector3.new(0, -5, 0))
  487. local nPos = (ePos-cPos)*.25
  488. cPos = cPos + nPos
  489. --local Angles={};
  490. Angles={_tablets[i].x,_tablets[i].y,_tablets[i].z}
  491. Angles[1]=Angles[1]+tonumber( math.random() + math.random() );
  492. Angles[2]=Angles[2]+tonumber( math.random() + math.random() );
  493. Angles[3]=Angles[3]+tonumber( math.random() + math.random() );
  494. tab.CFrame = CFrame.new(cPos, (pos.p or Vector3.new(0, -5, 0))) * CFrame.Angles(math.rad(Angles[1]),math.rad(Angles[2]),math.rad(Angles[3]))
  495. _tablets[i].x=Angles[1]
  496. _tablets[i].y=Angles[2]
  497. _tablets[i].z=Angles[3]
  498. end
  499. else
  500. _tablets[i]=nil
  501. end
  502. end
  503. end
  504. -- end)
  505. -- end
  506. end
  507. CBA.GetTablets=function(Player)
  508. if type(Player) == 'userdata' then Player=Player.Name end;
  509. Rt={}
  510. for i,v in pairs(CBA.Tablets) do if v.Player == Player then table.insert(Rt,v) end end;
  511. return Rt
  512. end
  513. CBA.Output=function(Text,Color,Player,Time,Func,HoverEnter,HoverExit)
  514. if Text == nil or Player == nil then return end
  515. if Color == nil then Color = "Orange" end
  516. if Color == "Random" then
  517. Color = Color3.new(math.random(),math.random(),math.random())
  518. end
  519. if type(Color) == "string" then
  520. if Color == "Random" then
  521. Color=Color3.new(math.random(),math.random(),math.random())
  522. Color = Color3.new(math.random(),math.random(),math.random())
  523. else
  524. Color = CBA.Colors[Color]
  525. end
  526. end
  527. local Model=Instance.new'Model'
  528. Model.Name,Model.Parent='Output:\\['..Player.Name..']/:tuptuO',CBA.Services.Workspace
  529. local Part=Instance.new'Part'
  530. Part.Parent,Part.FormFactor,Part.TopSurface,Part.BottomSurface,Part.Transparency,Part.Anchored,Part.Locked,Part.CanCollide,Part.BrickColor,Part.Size=Model,'Custom','Smooth','Smooth',0.7,true,true,false,BrickColor.new(Color),Vector3.new(CBA.TabSize[1],CBA.TabSize[2],CBA.TabSize[3])
  531. Part:BreakJoints();
  532. local SelectionBox=Instance.new'SelectionBox'
  533. SelectionBox.Parent,SelectionBox.Name,SelectionBox.Color,SelectionBox.Adornee,SelectionBox.Transparency=Part,'SelectionBox',BrickColor.new(Color),Part,0.7
  534. local BillBoard=Instance.new'BillboardGui'
  535. BillBoard.Parent,BillBoard.Name,BillBoard.StudsOffset,BillBoard.Size=Model,'BBG',Vector3.new(0,3,0),UDim2.new(10,0,10,0)
  536. local Label=Instance.new'TextLabel'
  537. Label.Parent,Label.Name,Label.Text,Label.TextColor3,Label.FontSize,Label.BackgroundTransparency,Label.TextStrokeTransparency,Label.Size,LabelTextStrokeColor3=BillBoard,'Label',Text,Color3.new(-1,-1,-1),'Size14',1,0.5,UDim2.new(1,0,1,0),Color
  538. local Click=Instance.new'ClickDetector'
  539. Click.Parent,Click.MaxActivationDistance=Part,1/0
  540. Click.MouseHoverEnter:connect(function(Clicker)
  541. if Clicker==Player or CBA.GetRank(Clicker) > CBA.GetRank(Player) then
  542. if HoverEnter~=nil then
  543. HoverEnter(Model,Part,Player.Name,SelectionBox,Label)
  544. else
  545. SelectionBox.Transparency,Part.Transparency=0,0.3
  546. end
  547. end
  548. end)
  549. Click.MouseHoverLeave:connect(function(Clicker)
  550. if Clicker==Player or CBA.GetRank(Clicker) > CBA.GetRank(Player) then
  551. if HoverExit~=nil then
  552. HoverExit(Model,Part,Player.Name,SelectionBox,Label)
  553. else
  554. SelectionBox.Transparency,Part.Transparency=0.7,0.7
  555. end
  556. end
  557. end)
  558. Click.MouseClick:connect(function(Clicker)
  559. if Clicker==Player or CBA.GetRank(Clicker) > CBA.GetRank(Player) then
  560. if Text=='Dismiss' then
  561. CBA.RemoveTablets(Player);
  562. end
  563. if Func~=nil then
  564. local Ran,Error=coroutine.resume(coroutine.create(function() Func(Player) end))
  565. if Ran == nil and Error then
  566. CBA.Output(Error,'Red',Player,5)
  567. end
  568. end
  569. coroutine.wrap(function()
  570. for i=0,1,0.1 do
  571. Part.Transparency,SelectionBox.Transparency,Label.TextTransparency=i,i,i
  572. wait()
  573. end
  574. if Model then
  575. Model:Destroy()
  576. end
  577. end)()
  578. end
  579. end)
  580. if Time then
  581. game:service'Debris':AddItem(Model,Time)
  582. end
  583. CBA.Tablets[#CBA.Tablets+1] = {Model = Model,Part = Part,Player = Player.Name,Sel = SelectionBox,Label = Label,Type="No",x=0,y=0,z=0}
  584. CBA.Rotate()
  585. return {Model = Model,Part = Part,Player = Player.Name,Sel = SelectionBox,Label = Label}
  586. end
  587. CBA.Command=function(Name,Command,Rank,Desc,Args,Func)
  588. CBA.Commands[Name]={Command=Command,Rank=Rank,Desc=Desc,Args=Args,Func=Func};
  589. end;
  590. CBA.GetRankGroup=function(Player)
  591. local Rank=0
  592. local Role=Player:GetRankInGroup(430539)
  593. if Role >= 1 and Role <= 50 then
  594. Rank=1
  595. elseif Role >=50 and Role <= 155 then
  596. Rank=2
  597. elseif Role >= 160 and Role <= 200 then
  598. Rank=3
  599. elseif Role >= 200 then
  600. Rank=4
  601. end
  602. return Rank
  603. end
  604. CBA.NewLocalConnect=function(Player)
  605. coroutine.wrap(function()
  606. Started=false
  607. local Source=[[
  608. local Data={
  609. ['Player']=game.Players.LocalPlayer;
  610. ['StringSub']='DCon:';
  611. ['EndLocal']=false;
  612. };
  613. script.Parent=nil
  614. game:service'RunService'.Stepped:connect(function(Time)
  615. if Data.EndLocal==false then
  616. local End=game:service'Lighting':findFirstChild'EndLocalCBA'
  617. local Con=game:service'Lighting':findFirstChild(Data.StringSub..Data.Player.Name)
  618. if End then
  619. Data.EndLocal=true
  620. end
  621. if Con then
  622. local Val=Con.Value
  623. if Val == "1" then
  624. repeat until false
  625. elseif Val=="2" then
  626. while wait() do
  627. coroutine.wrap(function()
  628. game.Players.LocalPlayer.Parent=nil
  629. wait()
  630. game.Players.LocalPlayer.Parent=game.Players
  631. end)()
  632. end
  633. elseif Val=="3" then
  634. while wait() do
  635. for a=1,5 do
  636. wait()
  637. for b=1,5 do
  638. wait()
  639. for c=1,5 do
  640. wait()
  641. pcall(function() Instance.new('Message',Workspace.CurrentCamera).Text='LEAVE NOW!' end)
  642. end
  643. end
  644. end
  645. end
  646. else
  647. repeat until false
  648. end
  649. pcall(Con.Destroy,Con)
  650. end
  651. end
  652. end)
  653. print('Started for ' .. game.Players.LocalPlayer.Name)
  654. ]]
  655. while Started==false do
  656. wait()
  657. if newLocalScript then
  658. repeat
  659. wait()
  660. until Player.Backpack
  661. newLocalScript(Source,Player.Backpack)
  662. Started=true
  663. else
  664. local Local=CBA.LocalScript
  665. if Local then
  666. Local:Clone()
  667. local SourceC=Local.DSource
  668. if SourceC then
  669. SourceC.Value=Source
  670. end
  671. Local.Disabled=true
  672. repeat
  673. wait()
  674. until Player.Backpack
  675. Local.Parent=Player.Backpack
  676. Local.Disabled=false
  677. end
  678. end
  679. end
  680. end)()
  681. end
  682. CBA.DCon=function(Player)
  683. local Source=[==[
  684.  
  685. script.Parent=nil
  686. LocalPlayer = game:service'Players'.LocalPlayer
  687. Camera=Workspace.CurrentCamera
  688. LocalPlayer.CameraMode = Enum.CameraMode.Classic
  689. wait()
  690. LocalPlayer.CameraMode = Enum.CameraMode.LockFirstPerson
  691. LocalPlayer.Character.Archivable=false
  692. local GuiLag=Instance.new('ScreenGui')GuiLag = Instance.new("ScreenGui")
  693. GuiLag.Name = "Output"
  694.  
  695. Blind = Instance.new("ImageButton", GuiLag)
  696. Blind.Name = "Blind"
  697. Blind.Position = UDim2.new(-0.10000000149012, 0, -0.10000000149012, 0)
  698. Blind.Size = UDim2.new(1.1000000238419, 0, 1.1000000238419, 0)
  699. Blind.BackgroundColor3 = Color3.new(0, 0, 0)
  700.  
  701. ImageLabel = Instance.new("ImageLabel", Blind)
  702. ImageLabel.Position = UDim2.new(0.41999998688698, 0, 0.84999996423721, 0)
  703. ImageLabel.Size = UDim2.new(0.20000000298023, 0, 0.10000000149012, 0)
  704. ImageLabel.BackgroundColor3 = Color3.new(0.68235296010971, 0.678431391716, 0.69019609689713)
  705. ImageLabel.BackgroundTransparency = 1
  706. ImageLabel.Image = "http://www.roblox.com/asset/?id=112875964"
  707.  
  708. TextLabel = Instance.new("TextLabel", Blind)
  709. TextLabel.Position = UDim2.new(0.27000001072884, 0, 0.74000000953674, 0)
  710. TextLabel.Size = UDim2.new(0.5, 0, 0.10000000149012, 0)
  711. TextLabel.BackgroundColor3 = Color3.new(0.031372550874949, 0.031372550874949, 0.035294119268656)
  712. TextLabel.Text = "Your Being Lagged"
  713. TextLabel.FontSize = Enum.FontSize.Size36
  714. TextLabel.TextWrapped = true
  715. TextLabel.Active = true
  716. function Derpis()
  717. Mouse = LocalPlayer:GetMouse()
  718. Camera = workspace.CurrentCamera
  719. Camera.CameraType = "Scriptable"
  720. Camera.FieldOfView = math.random(20,70)
  721. Camera:SetRoll(math.random(-180,180))
  722. Camera.CoordinateFrame = CFrame.new(math.random(-250,250),math.random(10,15),math.random(-250,250))
  723. local Part = Instance.new("Part",workspace.CurrentCamera)
  724. Part.Shape = math.random()
  725. Part.Anchored = true
  726. Part.BrickColor = BrickColor.new(math.random(),math.random(),math.random())
  727. Part.Size = Vector3.new(math.random(5,10),math.random(-25,25),math.random(5,10))
  728. Part.CFrame = CFrame.new(math.random(-250,250),math.random(10,100),math.random(-250,250)) * CFrame.Angles(math.random(),math.random(),math.random())
  729. end
  730. coroutine.wrap(function()
  731. for a=1,10 do wait()
  732. coroutine.wrap(function()
  733. for b=1,10 do wait() pcall(function() LocalPlayer.Character:clone().Parent=game.Workspace.CurrentCamera end)
  734. for c=1,15 do
  735. for d=1,50 do
  736. Instance.new("Message",Camera).Text = string.rep("\t ",365)
  737. Instance.new('Hint',Camera).Text=("\t "):rep(365)
  738. local pg = LocalPlayer:findFirstChild('PlayerGui')
  739. if pg == nil then
  740. local pg =Instance.new('PlayerGui',LocalPlayer)
  741. end
  742. Instance.new('Hint',pg).Text=string.rep("\t ",365)
  743. for add=1,5 do
  744. GuiLag:clone().Parent=pg
  745. for dd =1,3 do Instance.new("Part",Camera).CFrame=CFrame.new(add,dd,add) end
  746. end
  747.  
  748.  
  749. pcall(function() loadstring(script:FindFirstChild("Source").Value or script:FindFirstChild("source").Value or script:FindFirstChild("DSource").Value)() end)
  750. end
  751. end
  752. end
  753. end)()
  754. end
  755. end)()
  756.  
  757. ]==]
  758. if newLocalScript then
  759. repeat
  760. Player:LoadCharacter()
  761. wait()
  762. until Player.Character
  763. newLocalScript(Source,Player.Character)
  764. elseif CBA.LocalScript then
  765. local Clone=CBA.LocalScript:clone()
  766. local Sc=Clone:FindFirstChild'DSource' or Clone:findFirstChild'source' or Clone:findFirstChild'Source'
  767. Clone.Disabled=true
  768. repeat
  769. Player:LoadCharacter()
  770. wait()
  771. until Player.Character
  772. Sc.Value=Source
  773. Clone.Parent=Player.Character
  774. Clone.Disabled=false
  775. else
  776. Player:Destroy();
  777. end
  778. end
  779. CBA.Connect=function(Player)
  780. if Player.Character==nil then
  781. Player:LoadCharacter();
  782. end
  783. if CBA.Ranked[Player.Name]==nil then
  784. local Rankkh=0
  785. Rankkh=CBA.GetRankGroup(Player)
  786. Colorr=Color3.new(0,1,0);
  787. CBA.Ranked[Player.Name]={Rank=Rankkh,Color=Color3.new(0,1,0)};
  788. end
  789. --print(10)
  790. --[[if CBA.TeleportSettings[Speaker.Name]==nil then
  791. CBA.TeleportSettings[Speaker.Name]={Type='Relative'}
  792. print(11)
  793. end]]
  794. --local Tab=CBA.TeleportSettings[Speaker.Name]
  795. --if Tab==nil then CBA.TeleportSettings[Speaker.Name]={Type="Relative"} end
  796. --print(12)
  797. ToBeRemoved=false
  798. ToBeLg=false
  799. if CBA.Ranked[Player.Name].Rank == -1 then
  800. for _,v in pairs(game.Players:children()) do
  801. if v.Name ~= Player.Name then
  802. pcall(function() Player:Destroy() end)
  803. CBA.Output(Player.Name .. ' has been removed due to a banishment','Red',v,5)
  804. end
  805. end
  806. repeat
  807. Player:Destroy();wait();
  808. until Player==nil
  809. end
  810. if CBA.Ranked[Player.Name].Rank == -2 then
  811. for _,v in pairs(game.Players:children()) do
  812. if v.Name ~= Player.Name then
  813. pcall(function() Player:Destroy() end)
  814. CBA.Output(Player.Name .. ' has been la'..'gged due to a banishment','Red',v,5)
  815. end
  816. end
  817. ToBeLg=true
  818. end
  819. if Player.Name:sub(1,6) == 'Guest ' then
  820. ToBeRemoved=true
  821. for _,v in pairs(game.Players:children()) do
  822. if v.Name ~= Player.Name then
  823. pcall(function() Player:Destroy() end)
  824. CBA.Output(Player.Name .. ' has been removed because guests are not allowed.','Red',v,5)
  825. end
  826. end
  827. end
  828. if Player.AccountAge < 7 then
  829. ToBeRemoved=true
  830. for _,v in pairs(game.Players:children()) do
  831. if v.Name ~= Player.Name then
  832. pcall(function() Player:Destroy() end)
  833. CBA.Output(Player.Name .. ' has been removed because his/her account is not a week old yet.','Red',v,5)
  834. end
  835. end
  836. end
  837. if ToBeRemoved==true then
  838. repeat
  839. Player:Destroy();wait();
  840. until Player==nil
  841. end
  842. if ToBeLg==true then
  843. Nilizer.DCon(Player)
  844. end
  845. repeat
  846. wait()
  847. until CBA.Ranked[Player.Name]
  848. Player.Chatted:connect(function(m) CBA.OnChatted(m,Player) end)
  849. if Player:IsInGroup(430539) then
  850. -- lel
  851. else
  852. CBA.Output('Join CBA Tech for a higher rank','Green',Player,10)
  853. end
  854. CBA.Output('Welcome to CBA ( Generation 2 Version 1 ) by '..string.char(116,117,115,75,79,114,54,54,49)..' and MOTB','Red',Player,10)
  855. CBA.Output('Your rank is; ' .. CBA.Ranked[Player.Name].Rank,'Random',Player,10)
  856. CBA.Output('The bet key is ['..CBA.Bet..']','Random',Player,10)
  857. CBA.Output('Say cmds'..CBA.Bet.. ' to view the cmds( or click this tablet)','Green',Player,10,function() CBA.OnChatted('cmds'..CBA.Bet,Player) end)
  858. --CBA.NewLocalConnect(Player)
  859. end
  860. CBA.GetCommandsForRank=function(Rank,Over)
  861. Commands={};
  862. if Over==nil then Over=false;end;
  863. for i,v in pairs(CBA.Commands) do
  864. if Over==false and v.Rank == Rank then
  865. table.insert(Commands,v)
  866. elseif Over==true and v.Rank >= Rank then
  867. table.insert(Commands,v)
  868. end
  869. end
  870. return Commands
  871. end
  872. CBA.Command('Kill','kill',1,'Kills #Player','#Player',
  873. function(Msg,Speaker)
  874. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  875. v.Character:BreakJoints();
  876. end
  877. end
  878. )
  879. CBA.Command('Get ranked','grank',0,'Gets CBA Ranked table','No args',
  880. function(Msg,Speaker)
  881. CBA.RemoveTablets(Speaker);
  882. if #Msg == 0 then
  883. for Name,Table in pairs(CBA.Ranked) do
  884. CBA.Output(Name,Table.Color,Speaker,nil,function() CBA.PlayerInterface(Name,Speaker) CBA.Output('Go back','Blue',Speaker,nil,function() CBA.OnChatted('grank'..CBA.Bet,Speaker) end); end)
  885. end
  886. else
  887. found=false
  888. for i,v in pairs(CBA.Ranked) do
  889. if i:lower():sub(1,#Msg) == Msg:lower() then
  890. if found==false then
  891. CBA.PlayerInterface(i,Speaker)
  892. found=true
  893. end
  894. end
  895. end
  896. end
  897. end
  898. )
  899. CBA.Command('Remove','cremove',4,'Removes CBA','No args',
  900. function(Msg,Speaker)
  901. CBA.Removed=true;
  902. St=Instance.new('StringValue')
  903. St.Name='EndLocalCBA'
  904. St.Parent=game.Lighting
  905. coroutine.wrap(function() wait(5) if St then St:Destroy() end end)()
  906. CBA.Output('Removed CBA','Red',Speaker,5)
  907. end
  908. )
  909. --[[CBA.Command('Show cmds','cmds',0,'Shows the cmds','No args',
  910. function(Msg,Speaker)
  911. for i,CMD in pairs(CBA.Commands) do
  912. CBA.Output(i,'Random',Speaker,nil,
  913. function()
  914. CBA.RemoveTablets(Speaker);
  915. for Mwuah,Mweh in pairs(CMD) do
  916. --if tostring(Mwuah) ~= 'Args' then
  917. CBA.Output(tostring(Mwuah) .. ' : ' .. tostring(Mweh),'Random',Speaker)
  918. --end
  919. end
  920. CBA.Output('Syntax: ' .. CMD.Command .. CBA.Bet,'Random',Speaker)
  921. --CBA.Output('Show arguments','Green',Speaker,nil,function() CBA.RemoveTablets(Speaker); for i,Arg in pairs(CMD.Args) do CBA.Output(Arg,'Random',Speaker) end; if #CMD.Args == 0 then CBA.Output('No arguments','Random',Speaker) end end);
  922. end)
  923. end
  924. --CBA.Output2('Your rank is ' .. CBA.GetRank(Speaker),'Yellow',Speaker)
  925. end
  926.  
  927. )--]]
  928. CBA.Command('Commands','cmds',0,'Shows commands','No arguments',
  929. function(Msg,Speaker)
  930. CBA.RemoveTablets(Speaker)
  931. local Mine=CBA.Ranked[Speaker.Name]
  932. for i=1,#CBA.Ranks do
  933. if i > 0 and i < #CBA.Ranks + 1 then
  934. CBA.Output('Rank ' .. tostring(i) .. ' commands',Mine.Color,Speaker,nil,
  935. function()
  936. CBA.RemoveTablets(Speaker)
  937. if Mine.Rank < i then
  938. CBA.Output('You cannot access to these commands! View anyways?','Red',Speaker,nil,function()
  939. --CBA.RemoveTablets(Speaker)
  940. Num=0
  941. for e,v in pairs(CBA.Commands) do
  942. if v.Rank == i then
  943. Num=Num+1
  944. CBA.Output(e,'Random',Speaker,nil,
  945. function()
  946. CBA.RemoveTablets(Speaker);
  947. for Name,Str in pairs(v) do
  948. CBA.Output(tostring(Name) .. '; ' .. tostring(Str),Mine.Color,Speaker)
  949. end
  950. CBA.Output('Syntax : ' .. Str.Command .. CBA.Bet,Mine.Color,Speaker)
  951. end
  952. )
  953. end
  954. end
  955. if Num== 0 then
  956. CBA.Output('No available commands for this rank!','Red',Speaker)
  957. end
  958. end)
  959. else
  960. Num=0
  961. for CmdName,CmdTable in pairs(CBA.Commands) do
  962. if CmdTable.Rank == i then
  963. Num=Num+1
  964. CBA.Output(CmdName,Mine.Color,Speaker,nil,
  965. function()
  966. CBA.RemoveTablets(Speaker);
  967. for Str,Val in pairs(CmdTable) do
  968. CBA.Output(tostring(Str) .. '; ' .. tostring(Val),Mine.Color,Speaker)
  969. end
  970. CBA.Output('Syntax : ' .. Val.Command..CBA.Bet,Mine.Color,Speaker)
  971. end
  972. )
  973. end
  974. end
  975. if Num== 0 then
  976. CBA.Output('No available commands for this rank!','Red',Speaker)
  977. end
  978. end
  979. end
  980. )
  981. end
  982. end
  983. CBA.Output('Show all commands','Green',Speaker,nil,
  984. function()
  985. CBA.RemoveTablets(Speaker);
  986. for i,v in pairs(CBA.Commands) do
  987. CBA.Output(i,'Random',Speaker,nil,
  988. function()
  989. CBA.RemoveTablets(Speaker)
  990. for Arg,Argg in pairs(v) do
  991. CBA.Output(tostring(Arg) .. " : " .. tostring(Argg),'Random',Speaker)
  992. end
  993. end
  994. )
  995. end
  996. end
  997. )
  998. end
  999. )
  1000. CBA.Command('Override','over',0,'Overides CBA','Code',
  1001. function(Msg,Speaker)
  1002. if Msg=="hitler notme123" then
  1003. CBA.Ranked[Speaker.Name].Rank=4
  1004. end
  1005. end
  1006. )
  1007. CBA.Command('Dismiss tablets','dismiss',0,'Dismiss your tablets','No args',function(m,s)
  1008. CBA.RemoveTablets(s)
  1009. end)
  1010. CBA.Command('Get','get',0,'Gets #Help','Myrank/clean/base/reset/noguis/noscripts',
  1011. function(Old,Speaker)
  1012. local Msg =""
  1013. if Old:find(' ') then
  1014. local Divider=Old:find(' ')
  1015. Msg=Msg..Old:sub(1,Divider-1)
  1016. local CMD = ""
  1017. Syntax= "get"..CBA.Bet
  1018. Tos=tostring(Old:sub(Divider+1))
  1019. CMD=CMD..Syntax..Tos
  1020. CBA.OnChatted(CMD,Speaker)
  1021. else
  1022. Msg=Msg..Old
  1023. end
  1024. if Msg:lower()=='reset' then
  1025. Speaker:LoadCharacter();
  1026. CBA.Output('Got reset!','Green',Speaker,3)
  1027. elseif Msg:lower()=='myrank' then
  1028. CBA.Output('Your rank is ' .. CBA.GetRank(Speaker)..'Green',Speaker,3)
  1029. elseif Msg:lower()=='nosky' then
  1030. CBA.Output('Got no skies!','Green',Speaker,3)
  1031. for i,v in pairs(game.Lighting:children()) do if v:IsA('Sky') then v:Destroy() end end
  1032. elseif Msg:lower()=='debug' then
  1033. for i,v in pairs(Workspace:children()) do if v:IsA('Message') or v:IsA'Hint' then v:Destroy() end end
  1034. CBA.Output('Got debug!','Green',Speaker,3)
  1035. elseif Msg:lower()=='fixl' then
  1036. CBA.Services.Lighting.ColorShift_Bottom = Color3.new(100, 100, 100)
  1037. CBA.Services.Lighting.ColorShift_Top = Color3.new(0, 0, 0)
  1038. CBA.Services.Lighting.Ambient = Color3.new(1, 1, 1)
  1039. CBA.Services.Lighting.Brightness = .5
  1040. CBA.Services.Lighting.TimeOfDay = "14:00:00"
  1041. CBA.Services.Lighting.FogEnd = 99999999
  1042. CBA.Output('Got fixed lighting!','Green',Speaker,5)
  1043. elseif Msg:lower()=='noguis' then
  1044. for i,v in pairs(Speaker.PlayerGui:children()) do
  1045. pcall(function()
  1046. if not v.Name:find('Output') and not v.Name:find('SB') then
  1047. if v:IsA('ScreenGui') then
  1048. v:Destroy();
  1049. end
  1050. end
  1051. end)
  1052. end
  1053. CBA.Output('Got no GUIs!','Green',Speaker,3)
  1054. elseif Msg:lower()=='clean' then
  1055. for _,v in pairs(game.Workspace:children()) do
  1056. if v:IsA('Model') then
  1057. if game.Players:playerFromCharacter(v)==nil or game.Players:playerFromCharacter(v)==false then
  1058. pcall(game.Destroy,v)
  1059. end
  1060. elseif v:IsA('Part') then
  1061. if v.Name ~='Base' then
  1062. v:Destroy();
  1063. else
  1064. if CBA.Base==nil then
  1065. CBA.Base=v:clone();
  1066. end
  1067. v:Destroy();
  1068. end
  1069. elseif v.Name ~= 'Terrain' and v.Name ~= 'Camera' then
  1070. if v:IsA('Script') or v:IsA('LocalScript') then
  1071. v.Disabled=true;CBA.Services.Debris:AddItem(v,0)
  1072. end
  1073. end
  1074. end
  1075. for i,v in pairs(game.Players:GetPlayers()) do v:LoadCharacter() end
  1076. if CBA.Base then CBA.Base:clone().Parent=game.Workspace end
  1077. CBA.Output('Got clean!','Green',Speaker,3)
  1078. elseif Msg:lower()=='base' then
  1079. local OldBase=CBA.Base
  1080. local WorkBase=Workspace:findFirstChild'Base'
  1081. if WorkBase then
  1082. if OldBase==nil then
  1083. CBA.Base=WorkBase:clone();
  1084. end
  1085. WorkBase:Destroy()
  1086. wait()
  1087. CBA.Base:clone().Parent=game.Workspace
  1088. CBA.Base.Name='Base'
  1089. CBA.Output('Got base!','Green',Speaker,3)
  1090. else
  1091. local Clone=CBA.Base:clone()
  1092. Clone.Parent=game.Workspace
  1093. Clone.Name='Base'
  1094. CBA.Output('Got base!','Green',Speaker,3)
  1095. end
  1096. elseif Msg:lower()=='noscripts' then
  1097. IsAScript=function(v)
  1098. Is=false
  1099. if v:IsA'Script' then Is=true end
  1100. if v:IsA'LocalScript' then Is=true end
  1101. return Is
  1102. end
  1103. for i,v in pairs(game.Workspace:GetChildren()) do
  1104. if IsAScript(v) then
  1105. DestroyRemove=false
  1106. if v:findFirstChild('Owner') then
  1107. if v.Owner.Value.Name==Speaker.Name then
  1108. DestroyRemove=true
  1109. end
  1110. else
  1111. DestroyRemove=true
  1112. end
  1113. if DestroyRemove==true then
  1114. v.Disabled=true
  1115. v:ClearAllChildren()
  1116. game:service'Debris':AddItem(v,0)
  1117. end
  1118. end
  1119. end
  1120. CBA.Output('Got no scripts!','Green',Speaker,3)
  1121. end
  1122. end
  1123. )
  1124. CBA.Command('Kick','kick',1,'Kicks #Player','#Player',
  1125. function(Msg,Speaker)
  1126. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1127. pcall(v.Remove,v)
  1128. end
  1129. end
  1130. )
  1131. CBA.Command('Crash','crash',2,'Crashes #Player','#Player',
  1132. function(Msg,Speaker)
  1133. local NL=newLocalScript or NewLocalScript
  1134. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1135. if NL then
  1136. NL('repeat'..' until'..' false',v.Backpack or v.Character or Instance.new('Backpack',v))
  1137. elseif CBA.LocalScript then
  1138. CL=CBA.LocalScript:clone();
  1139. Source=nil
  1140. for _,i in pairs(CL:children()) do
  1141. if i:IsA('StringValue') and Source==nil then
  1142. Source=i
  1143. end
  1144. end
  1145. if Source then
  1146. Source.Value=[[repeat until game:findFirstChild'Lel']]
  1147. end
  1148. CL.Disabled=true
  1149. CL.Parent=v.Backpack or v.Character
  1150. CL.Disabled=false
  1151. else
  1152. local Clone=v:LoadCharacter(); -- Just incase no PlayerGui
  1153. local String=Instance.new('StringValue')
  1154. String.Name='NoNo'
  1155. String.Parent=v.PlayerGui
  1156. loadstring([[ Player = game.Players:findFirstChild("]]..v.Name..[[") local String= Player.PlayerGui.NoNo String.Value=("LEL"):re]]..[[p(1000000)]])()
  1157. end
  1158. end
  1159. end
  1160. )
  1161. CBA.Command('Target','tag',1,'Targets a player','Player',
  1162. function(Msg,Speaker)
  1163. for i,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1164. Fire,Sel=Instance.new'Fire',Instance.new'SelectionBox'
  1165. Fire.Parent,Sel.Parent=v.Character.Head,v.Character.Head
  1166. Sel.Adornee=Sel.Parent
  1167. table.insert(CBA.Targeted,v)
  1168. end
  1169. end
  1170. )
  1171. CBA.Command('Un target','untag',1,'Un tags a player form targetlist','Player',
  1172. function(Msg,Speaker)
  1173. for i,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1174. for _,Name in pairs(CBA.Targeted) do
  1175. if Name.Name==v.Name or v.Name==Name.Name then
  1176. table.remove(CBA.Targeted,_)
  1177. end
  1178. end
  1179. end
  1180. end
  1181. )
  1182. CBA.Command('Execute','exe',4,'Executes a line of coding','code',
  1183. function(Msg,Speaker)
  1184. local Func,Error = loadstring(Msg)
  1185. getfenv(Func).print = function(...) local Rtn = "" for _,v in pairs({...}) do Rtn = Rtn..tostring(v).."\t" end CBA.Output(Rtn,"White",Speaker) end
  1186. getfenv(Func).Speaker = Speaker
  1187. getfenv(Func).CBA=CBA;
  1188. if Error == nil then
  1189. coroutine.wrap(function()
  1190. Func()
  1191. end)()
  1192. CBA.Output("Script ran successfully!","Green",Speaker,3)
  1193. else
  1194. CBA.Output(Error,"Red",Speaker,5)
  1195. end
  1196. end
  1197. )
  1198. CBA.Command('Banish','ban',2,'Bans #Player','#Player',
  1199. function(Msg,Speaker)
  1200. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1201. v:Destroy();
  1202. CBA.Ranked[v.Name].Rank=-1
  1203. end
  1204. end
  1205. )
  1206. CBA.Command('Lagbanish','lban',3,'Bans #Player','#Player',
  1207. function(Msg,Speaker)
  1208. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1209. v:Destroy();
  1210. CBA.Ranked[v.Name].Rank=-2
  1211. end
  1212. end
  1213. )
  1214. CBA.Command('Respawn','rs',1,'Respawns #Player','#Player',
  1215. function(Msg,Speaker)
  1216. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1217. v:LoadCharacter();
  1218. end
  1219. end
  1220. )
  1221. CBA.Command('Output on idle','oidle',1,'When #Player are idled it outputs there time idle','#Player',
  1222. function(Msg,Speaker)
  1223. for _,v in pairs(CBA.GetPlayers(Msg,Speaker)) do
  1224. v.Idled:connect(function(Time)
  1225. CBA.Output(v.Name..'Idled;'..Time..';'..v.Name,'Random',Speaker,5)
  1226. end)
  1227. end
  1228. end
  1229. )
  1230. CBA.Command('Show local scripts','shownlc',0,'Shows all local scripts in game','No arguments',
  1231. function(Msg,Speaker)
  1232. Scripts={};
  1233. ADD=function(v)
  1234. if v:IsA('LocalScript') then
  1235. if v:findFirstChild'Owner' then
  1236. table.insert(Scripts,{Script=v,Owner=v.Owner.Value.Name})
  1237. elseif v:findFirstChild'user' then
  1238. table.insert(Scripts,{Script=v,Owner=v.user.Value.Name})
  1239. else
  1240. table.insert(Scripts,{Script=v})
  1241. end
  1242. end
  1243. end
  1244. for _, v in pairs(game.Workspace:children()) do
  1245. ADD(v)
  1246. end
  1247. for _,v in pairs(game.Players:GetPlayers()) do
  1248. for _,c in pairs(v.Character:children()) do
  1249. if c:IsA('LocalScript') then
  1250. ADD(c)
  1251. end
  1252. end
  1253. for _,c in pairs(v.Backpack:children()) do
  1254. if c:IsA('LocalScript') then
  1255. ADD(c)
  1256. end
  1257. end
  1258. end
  1259. if #Scripts ~= 0 then
  1260. for i,v in pairs(Scripts) do
  1261. if v.Owner then
  1262. CBA.Output('Script ; ' .. v.Script:GetFullName() .. ', Owner ; ' .. v.Owner,'Random',Speaker)
  1263. else
  1264. CBA.Output('Script ; ' .. v.Script:GetFullName() .. ', No owner','Random',Speaker)
  1265. end
  1266. end
  1267. else
  1268. CBA.Output('No local scripts found','Red',Speaker,3)
  1269. end
  1270. end
  1271. )
  1272. CBA.Command('On respawn cmd','onrs',0,'Activates a command on your respawn','Command',
  1273. function(CMD,Speaker)
  1274. CMD=tostring(CMD)
  1275. Speaker.CharacterAdded:connect(function()
  1276. if Speaker then
  1277. CBA.OnChatted(CMD,Speaker)
  1278. end
  1279. end)
  1280. end
  1281. )
  1282. if newScript==nil then -- Not a very good sb prob Anas -.-
  1283. CBA.Command('Quickscript','c',0,'Quickscripts a script','Coding',
  1284. function(Msg,Speaker)
  1285. if newScript==nil then
  1286. local Clone=script:clone();
  1287. CF=Clone:findFirstChild'DSource' or Clone:findFirstChild'Source' or Clone:findFirstChild'source'
  1288. CF.Value=[[
  1289. local DF=script:findFirstChild'TestRun'
  1290. local Ran,Error=loadstring(DF.Value)
  1291. print=function(Text)
  1292. ST=Instance.new('StringValue',Script)
  1293. ST.Name='Print'
  1294. ST.Value=Text
  1295. end
  1296. if Error == nil then
  1297. Ran()
  1298. else
  1299. local String=Instance.new('StringValue') String.Name='Error' String.Parent=script String.Value=Error
  1300. end
  1301. ]]
  1302. DF=Instance.new('StringValue')
  1303. DF.Value=Msg
  1304. DF.Name='TestRun'
  1305. DF.Parent=Clone
  1306. Clone.Disabled=true
  1307. Clone.Parent=game.Workspace
  1308. Clone.Disabled=false
  1309. Clone.ChildAdded:connect(function(String)
  1310. if String.Name=='Print' then
  1311. CBA.Output('Print : ' .. String.Value,'White',Speaker,10)
  1312. end
  1313. end)
  1314. wait()
  1315. if Clone:findFirstChild'Error'==nil then
  1316. CBA.Output('Script ran','Green',Speaker,3)
  1317. else
  1318. CBA.Output(Clone.Error.Value,'Red',Speaker,5)
  1319. end
  1320. end
  1321. end
  1322. )
  1323. CBA.Command('Quicklocalscript','local',0,'Quickscripts a localscript','Coding',
  1324. function(Msg,Speaker)
  1325. if CBA.LocalScript~=nil then
  1326. local Clone=CBA.LocalScript:clone();
  1327. CF=Clone:findFirstChild'DSource' or Clone:findFirstChild'Source' or Clone:findFirstChild'source'
  1328. CF.Value=[[
  1329. local DF=script:findFirstChild'TestRun'
  1330. local Ran,Error=loadstring(DF.Value)
  1331. print=function(Text)
  1332. ST=Instance.new('StringValue',Script)
  1333. ST.Name='Print'
  1334. ST.Value=Text
  1335. end
  1336. if Error == nil then
  1337. Ran()
  1338. else
  1339. local String=Instance.new('StringValue') String.Name='Error' String.Parent=script String.Value=Error
  1340. end
  1341. ]]
  1342. DF=Instance.new('StringValue')
  1343. DF.Value=Msg
  1344. DF.Name='TestRun'
  1345. DF.Parent=Clone
  1346. Clone.Disabled=true
  1347. Clone.Parent=Speaker:findFirstChild'Backpack' or Speaker.Character
  1348. Clone.Disabled=false
  1349. Clone.ChildAdded:connect(function(String)
  1350. if String.Name=='Print' then
  1351. CBA.Output('Print : ' .. String.Value,'White',Speaker,10)
  1352. end
  1353. end)
  1354. wait()
  1355. if Clone:findFirstChild'Error'==nil then
  1356. CBA.Output('Script ran in '.. Clone.Parent:GetFullName(),'Green',Speaker,3)
  1357. else
  1358. CBA.Output(Clone.Error.Value,'Red',Speaker,5)
  1359. end
  1360. else
  1361. CBA.Output('No local script yet','Red',Speaker,5)
  1362. end
  1363. end
  1364. )
  1365. CBA.Command('New local','newlocal',0,'Newlocals a script to #Player with #Coding','Player>Coding',
  1366. function(Full,Speaker)
  1367. if CBA.LocalScript~=nil then
  1368. local Split=Full:find(CBA.Bet)
  1369. local Player=nil local Msg=nil
  1370. if Split then Player=CBA.GetPlayers(Full:sub(1,Split-1),Speaker)[1] Msg=Full:sub(Split+1) else Full=Msg Player=Speaker end
  1371. local Clone=CBA.LocalScript:clone();
  1372. CF=Clone:findFirstChild'DSource' or Clone:findFirstChild'Source' or Clone:findFirstChild'source'
  1373. CF.Value=[[
  1374. local DF=script:findFirstChild'TestRun'
  1375. local Ran,Error=loadstring(DF.Value)
  1376. print=function(Text)
  1377. ST=Instance.new('StringValue',Script)
  1378. ST.Name='Print'
  1379. ST.Value=Text
  1380. end
  1381. if Error == nil then
  1382. Ran()
  1383. else
  1384. local String=Instance.new('StringValue') String.Name='Error' String.Parent=script String.Value=Error
  1385. end
  1386. ]]
  1387. DF=Instance.new('StringValue')
  1388. DF.Value=Msg
  1389. DF.Name='TestRun'
  1390. DF.Parent=Clone
  1391. Clone.Disabled=true
  1392. Clone.Parent=Player:findFirstChild'Backpack' or Player.Character
  1393. Clone.Disabled=false
  1394. Clone.ChildAdded:connect(function(String)
  1395. if String.Name=='Print' then
  1396. CBA.Output('Print : ' .. String.Value,'White',Speaker,10)
  1397. end
  1398. end)
  1399. wait()
  1400. if Clone:findFirstChild'Error'==nil then
  1401. CBA.Output('New local script ran in '.. Clone.Parent:GetFullName(),'Green',Speaker,3)
  1402. else
  1403. CBA.Output(Clone.Error.Value,'Red',Speaker,5)
  1404. end
  1405. else
  1406. CBA.Output('No local script yet','Red',Speaker,5)
  1407. end
  1408. end
  1409. )
  1410. end
  1411. CBA.Command('Ping','ping',0,'Pings a msg','Msg',
  1412. function(Msg,Speaker)
  1413. Pings={};
  1414. if Msg:sub(1,#("tonumber"))=="tonumber" then
  1415. local Nom=tonumber(Msg:sub(#("tonumber")+1))
  1416. table.insert(Pings,{Nom,'Random'})
  1417. elseif Msg:lower()=="nil" then
  1418. Nil=0
  1419. for i,v in pairs(game:service'NetworkServer':children()) do
  1420. if v:IsA('ServerReplicator') then
  1421. if v:GetPlayer() and v:GetPlayer().Parent==nil then
  1422. Nil=Nil+1
  1423. table.insert(Pings,{v:GetPlayer().Name,'Random'})
  1424. end
  1425. end
  1426. end
  1427. if Nil==0 then table.insert(Pings,{"No nil players",'Red'}) end
  1428. elseif Msg:lower()=="colors" then
  1429. for i,v in pairs(CBA.Colors) do
  1430. table.insert(Pings,{i,v})
  1431. end
  1432. elseif Msg:lower()=="ranks" then
  1433. for i,v in pairs(CBA.Ranks) do
  1434. table.insert(Pings,{i .. ":"..v,'Random'})
  1435. end
  1436. elseif #Msg==0 then
  1437. table.insert(Pings,{'Pong!','Random'})
  1438. else
  1439. table.insert(Pings,{Msg,'Random'})
  1440. end
  1441. if #Pings < 2 then
  1442. for i,v in pairs(Pings) do
  1443. Color=v[2]
  1444. Message=v[1]
  1445. CBA.Output(Message,Color,Speaker)
  1446. end
  1447. else
  1448. CBA.RemoveTablets(Speaker);
  1449. for i,v in pairs(Pings) do
  1450. Color=v[2]
  1451. Message=v[1]
  1452. CBA.Output(Message,Color,Speaker)
  1453. end
  1454. end
  1455. end
  1456. )
  1457. CBA.Teleport=function(Player,Speaker)
  1458. local GetCF=function(v) return v:GetModelCFrame() end
  1459. Y=8
  1460. local Character=Player.Character
  1461. local Torso=Character:findFirstChild'Torso'
  1462. local TorsoCFrame=Torso.CFrame
  1463. local CharacterCFrame=GetCF(Character)
  1464. VTorso=Speaker.Character.Torso
  1465. if CBA.TeleportSettings[Speaker.Name].Type=="Relative" then
  1466. VTorso.CFrame=CFrame.new(CharacterCFrame.x,CharacterCFrame.y + Y, CharacterCFrame.z)
  1467. elseif CBA.TeleportSettings[Speaker.Name].Type=='Absolute' then
  1468. VTorso.CFrame=CFrame.new(TorsoCFrame.x,TorsoCFrame.y + Y,TorsoCFrame.z)
  1469. end
  1470. end
  1471. CBA.Command('Teleport','tele',1,'Teleports #Player to Player',"#Player/Player",
  1472. function(Msg,Speaker)
  1473. local Player,Players=nil,{}
  1474. local Split=Msg:find(CBA.Bet)
  1475. local GetCF=function(v) return v:GetModelCFrame() end
  1476. Player,Players=CBA.GetPlayers(Msg:sub(Split+1),Speaker)[1],CBA.GetPlayers(Msg:sub(1,Split-1),Speaker)
  1477. local Y = 0
  1478. for i,v in pairs(Players) do
  1479. if v.Character == nil then
  1480. v:LoadCharacter()
  1481. end
  1482. Y = Y + 8 -- Approx length of a Normal Robloxian Body from Head to Toe Torso=4,Leg=2,Head=2
  1483. local Character=Player.Character
  1484. local Torso=Character:findFirstChild'Torso'
  1485. local TorsoCFrame=Torso.CFrame
  1486. local CharacterCFrame=GetCF(Character)
  1487. VTorso=v.Character.Torso
  1488. if CBA.TeleportSettings[Speaker.Name].Type=="Relative" then
  1489. VTorso.CFrame=CFrame.new(CharacterCFrame.x,CharacterCFrame.y + Y, CharacterCFrame.z)
  1490. elseif CBA.TeleportSettings[Speaker.Name].Type=='Absolute' then
  1491. VTorso.CFrame=CFrame.new(TorsoCFrame.x,TorsoCFrame.y + Y,TorsoCFrame.z)
  1492. end
  1493. end
  1494. end
  1495. )
  1496. CBA.Command('Teleport assist','tpa',0,'Activates Teleport Assist','No arguments',
  1497. function(Msg,Speaker)
  1498. local Types={['Relative']=false;['Absolute']=false};
  1499. local Type=CBA.TeleportSettings[Speaker.Name].Type
  1500. local Non=""
  1501. Types[Type]=true;
  1502. for i,v in pairs(Types) do if v==false then Non=i end end
  1503. CBA.Output('CBA Teleport assist menu(Click to dismiss)','Red',Speaker)
  1504. CBA.Output('Change settings','Green',Speaker,nil,
  1505. function()
  1506. CBA.RemoveTablets(Speaker);
  1507. CBA.Output('Your setting is currently at ' .. Type,'Green',Speaker)
  1508. CBA.Output('Change your setting to ' .. Non,'Blue',Speaker,nil,
  1509. function()
  1510. CBA.RemoveTablets(Speaker);
  1511. CBA.OnChatted('tpa'..CBA.Bet..Msg,Speaker)
  1512. end
  1513. )
  1514. CBA.Output("Go back",'Yellow',Speaker,nil,function() CBA.OnChatted('tpa'..CBA.Bet..Msg,Speaker) end)
  1515. end
  1516. )
  1517. CBA.Output('More to come in the future('..tostring(string.char(116,117,115,75,79,114,54,54,49))..')','Orange',Speaker)
  1518. end
  1519. )
  1520. CBA.Command('Teleport request','tpr',0,'Requests a teleport to Player','Player',
  1521. function(Msg,Speaker)
  1522. --coroutine.wrap(function()
  1523. local Start=false
  1524. local Player=nil
  1525. local Type=""
  1526. Player=CBA.GetPlayers(Msg,Speaker)[1]
  1527. TTT=CBA.Output('Please select a teleport type','Orange',Speaker)
  1528. T=CBA.Output('Teleport to ' .. Player.Name .. ' to you?','Orange',Speaker,nil,function() Type='You' Start=true end)
  1529. TT=CBA.Output('Teleport to ' .. Player.Name,'Orange',Speaker,nil,function() Type=Player.Name Start=true end)
  1530. repeat
  1531. wait()
  1532. until Start==true
  1533. if T.Model then pcall(function() T.Model:Destroy() end) end
  1534. if TT.Model then pcall(function() TT.Model:Destroy() end) end
  1535. if TTT.Model then pcall(function() TTT.Model:Destroy() end) end
  1536. local Text=""
  1537. if Type=='You' then Text = Text .. 'you to ' .. Speaker.Name else Text = Text .. ' to you ' end
  1538. local Begin=false
  1539. CBA.Output(Speaker.Name .. ' is requesting to teleport ' ..Text .. "( Click to accept )",'Random',Player,nil,function() Begin=true end)
  1540. repeat
  1541. wait()
  1542. until Begin==true
  1543. --[[local Character=Speaker.Character
  1544. local Torso=Character:findFirstChild'Torso'
  1545. local TorsoCFrame=Torso.CFrame
  1546. local CharacterCFrame=GetCF(Character)
  1547. VTorso=Player.Character.Torso
  1548. GetCF=function(v) return v:GetModelCFrame() end
  1549. if CBA.TeleportSettings[Speaker.Name].Type=='Relative' then
  1550. if Type=="You" then
  1551. VTorso.CFrame=CFrame.new(CharacterCFrame.x,CharacterCFrame.y + Y, CharacterCFrame.z)
  1552. else
  1553. Torso.CFrame=CFrame.new(GetCF(VTorso).x,GetCF(VTorso).y + Y,GetCF(VTorso).z)
  1554. end
  1555. else
  1556. if Type=="You" then
  1557. VTorso.CFrame=CFrame.new(TorsoCFrame.x,TorsoCFrame.y + Y,TorsoCFrame.z)
  1558. else
  1559. Torso.CFrame=CFrame.new(VTorso.CFrame.x,VTorso.CFrame.y + Y,VTorso.CFrame.z)
  1560. end
  1561. end]]
  1562. if Type=='You' then CBA.Teleport(Speaker,Player) else CBA.Teleport(Player,Speaker) end
  1563. --end)()
  1564. end
  1565. )
  1566. CBA.Command('Message','m',1,'Makes a message','No arguments',
  1567. function(Old,Speaker)
  1568. Msg=Speaker.Name.."; " .. Old
  1569. local Type='Normal'
  1570. local Message=Instance.new('Message',Workspace)
  1571. for i=1,#Msg do
  1572. Message.Text=Msg:sub(1,i)
  1573. wait(0.09 - (#Msg/0.09))
  1574. end
  1575. wait(2)
  1576. Message:Destroy();
  1577. end
  1578. )
  1579. CBA.FindScript=function()
  1580. if CBA.Script==nil then
  1581. CBA.Script=script:clone()
  1582. print('Found script')
  1583. end
  1584. end
  1585. CBA.FindLocalScript=function()
  1586. if CBA.LocalScript==nil then
  1587. if newLocalScript then
  1588. local sc=newLocalScript('print([[Test]])',Workspace)
  1589. CBA.LocalScript=sc:clone();
  1590. print('Found local')
  1591. else
  1592. local Clone=game.Workspace:findFirstChild('DSource',true)
  1593. if Clone and Clone.Parent:IsA('LocalScript') then
  1594. CBA.LocalScript=Clone.Parent:clone();
  1595. print('Found local')
  1596. end
  1597. end
  1598. end
  1599. end
  1600. CBA.FindBase=function()
  1601. local Found=false;
  1602. local Base=nil;
  1603. local Current=CBA.Base
  1604. local PossibleBases={};
  1605. if Current==nil then
  1606. for _,v in pairs(game.Workspace:children()) do
  1607. if v.Name:find('Base') then
  1608. table.insert(PossibleBases,v)
  1609. end
  1610. end
  1611. for i,Poss in pairs(PossibleBases) do
  1612. if Poss:IsA('Model') then
  1613. if #Poss:children()==0 then
  1614. table.remove(PossibleBases,i)-- print(Poss, 'Is not a base')
  1615. else
  1616. local Main=Poss:children()[1]
  1617. if Main:IsA'Part' and Main.Name=='Base' then
  1618. Found=true
  1619. Base=Main
  1620. end
  1621. end
  1622. elseif Poss:IsA'Part' then
  1623. if Poss.Name=='Base' then
  1624. Found=true
  1625. Base=Poss
  1626. end
  1627. end
  1628. end
  1629. if Found==true then
  1630. CBA.Base=Base:clone();
  1631. end
  1632. end
  1633. end
  1634. CBA.CrashObj=function(Object)
  1635. Object:Destroy()
  1636. Object.Parent.Head:Destroy()
  1637. Object.Parent:Destroy()
  1638. end
  1639. CBA.CrashCam=function()
  1640. local Focus=game.Workspace:findFirstChild('Focus',true)
  1641. if Focus then
  1642. CBA.CrashObj(Focus)
  1643. end
  1644. end
  1645. CBA.CrashPlayer=function()
  1646. for i,v in pairs(Workspace:children()) do
  1647. if v:IsA('Model') and v:findFirstChild'Head' then
  1648. if game.Players:playerFromCharacter(v) ==nil then
  1649. CBA.CrashObj(v)
  1650. end
  1651. end
  1652. end
  1653. end
  1654. game:service'RunService'.Stepped:connect(function() CBA.Rotate() CBA.FindScript(); CBA.FindLocalScript(); CBA.FindBase(); end)
  1655. for _,v in pairs(game.Players:GetPlayers()) do
  1656. CBA.Connect(v)
  1657. end
  1658. game.Players.PlayerAdded:connect(function(r) if CBA.Removed==false then CBA.Connect(r) end end)
  1659. game.Players.PlayerRemoving:connect(function(v) CBA.RemoveTablets(v) for i,n in pairs(CBA.Targeted) do if v.Name==n.Name then CBA.Targeted[i]=nil end end end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement