SHOW:
|
|
- or go back to the newest paste.
1 | --[[ | |
2 | ||
3 | Leaked by CLarramore from the Pyrex Developer Team. | |
4 | Pyrex developers... | |
5 | ||
6 | ||
7 | well... | |
8 | ||
9 | I have gotten another version of pyrex admin | |
10 | ||
11 | so... | |
12 | ||
13 | k | |
14 | ||
15 | ~CLarramore from Pyrex Developer Team. | |
16 | ||
17 | ||
18 | PLEASE READ OR SCRIPT WILL NOT WORK CORRECT! | |
19 | ||
20 | 1.)Fetures Will Not Work Unless HTTP Service Is On! | |
21 | 2.)Control+f and type in Ranking. You Can Edit Them with your prefrences. | |
22 | 3.)If you want to help develop this admin pm any developer. | |
23 | 4.)Report bugs to any developer. | |
24 | 5.)You Can Customize your tablet color and shape. | |
25 | 7.)Enjoy! | |
26 | ||
27 | ~Pyrex Developer Team. | |
28 | ]] | |
29 | ||
30 | ||
31 | --Removing-- | |
32 | wait() | |
33 | script.Parent = nil | |
34 | script.Name = 'PyrexAdmin' | |
35 | ----------------- | |
36 | for _, Model in pairs(workspace:GetChildren()) do | |
37 | if string.find(Model.Name, 'PyrexModel:') then | |
38 | Model:Destroy() | |
39 | end | |
40 | end | |
41 | ||
42 | ------------------ | |
43 | Players = game:GetService('Players') | |
44 | Lighting = game:GetService('Lighting') | |
45 | Workspace = game:GetService('Workspace') | |
46 | ------------------ | |
47 | Pyrex = { | |
48 | Services = {}; | |
49 | Settings = {}; | |
50 | Functions = {}; | |
51 | Commands = {}; | |
52 | Bet1 = '!'; | |
53 | Bet2 = ';'; | |
54 | Bet3 = '-' | |
55 | } | |
56 | ----------- | |
57 | DeveloperKind = "1" | |
58 | ----------- | |
59 | --Services-- | |
60 | ------------------ | |
61 | Pyrex.Services.RunService = game:GetService('RunService') | |
62 | Pyrex.Services.MarketplaceService = game:GetService("MarketplaceService") | |
63 | Pyrex.Services.HttpService = game:GetService('HttpService') | |
64 | ----------------- | |
65 | --Command model | |
66 | ----------------- | |
67 | --Pyrex.CmdModel = Pyrex.Services.MarketplaceService:GetProductInfo(214887536).Description | |
68 | ------------------ | |
69 | --ADMINS-- | |
70 | ------------------ | |
71 | - | Pyrex.Ranked = {} |
71 | + | Pyrex.Ranked = {"Oraxnge"} |
72 | Pyrex.Pri_List = {} | |
73 | Pyrex.PrivateServer_Enabled = false | |
74 | Pyrex.Logs_Service = {} | |
75 | Pyrex.Gui_Service = {} | |
76 | ------------------ | |
77 | --FUNCTIONS-- | |
78 | ------------------ | |
79 | Pyrex.Functions.Output = function(Player,Color,Text,ColorOverride,Func) | |
80 | pcall(function() | |
81 | if Player.Character then | |
82 | local PlayerModel = nil | |
83 | if Workspace:FindFirstChild('PyrexModel:'..Player.Name) then | |
84 | PlayerModel = Workspace:FindFirstChild('PyrexModel:'..Player.Name) | |
85 | else | |
86 | PlayerModel = Instance.new("Model", workspace) | |
87 | PlayerModel.Name = 'PyrexModel:'..Player.Name | |
88 | end | |
89 | -- | |
90 | local Tablet = Instance.new("Part") | |
91 | local TabletMesh | |
92 | if Pyrex.Ranked[Player.Name]['Type'] == 'Tablet' then | |
93 | TabletMesh = Instance.new('BlockMesh', Tablet) | |
94 | elseif Pyrex.Ranked[Player.Name]['Type'] == "Sphere" then | |
95 | TabletMesh = Instance.new('SpecialMesh', Tablet) | |
96 | TabletMesh.MeshType = 'Sphere' | |
97 | elseif Pyrex.Ranked[Player.Name]['Type'] == "Block" then | |
98 | TabletMesh = Instance.new("BlockMesh",Tablet) | |
99 | end | |
100 | TabletMesh.Name = 'TabletMesh' | |
101 | TabletMesh.Scale = Vector3.new(0,0,0) | |
102 | Tablet.FormFactor = "Custom" | |
103 | Tablet.Transparency = 0.5 | |
104 | if Pyrex.Ranked[Player.Name]['Type'] == 'Tablet' then | |
105 | Tablet.Size = Vector3.new(4.5,5,0.2) | |
106 | elseif Pyrex.Ranked[Player.Name]['Type'] == 'Sphere' then | |
107 | Tablet.Size = Vector3.new(2,2,2) | |
108 | elseif Pyrex.Ranked[Player.Name]['Type'] == 'Block' then | |
109 | Tablet.Size=Vector3.new(2.3,2.3,2.3) | |
110 | end | |
111 | Tablet.CanCollide = false | |
112 | Tablet.TopSurface = 'Smooth' | |
113 | Tablet.BottomSurface = 'Smooth' | |
114 | Tablet.Anchored = true | |
115 | Tablet.Name = "PyrexTablet:"..Player.Name | |
116 | Tablet.Locked = true | |
117 | Tablet.CFrame = Player.Character.Head.CFrame | |
118 | if ColorOverride == true then | |
119 | Tablet.BrickColor = BrickColor.new(Color) | |
120 | else | |
121 | Tablet.BrickColor = BrickColor.new(Pyrex.Ranked[Player.Name]['Color']) | |
122 | end | |
123 | local Billboard = Instance.new("BillboardGui", Tablet) | |
124 | Billboard.Adornee = Tablet | |
125 | Billboard.Enabled = true | |
126 | Billboard.Active = true | |
127 | Billboard.Size = UDim2.new(1, 1, 1,1) | |
128 | Billboard.ExtentsOffset = Vector3.new(0, 1.5, 0) | |
129 | local point = Instance.new("PointLight",Tablet) | |
130 | point.Brightness = 1/0 | |
131 | point.Color = Tablet.BrickColor.Color | |
132 | point.Range = 10 | |
133 | local TL = Instance.new("TextLabel", Billboard) | |
134 | TL.Text = Text | |
135 | TL.BackgroundTransparency = 1 | |
136 | TL.Size = UDim2.new(1, 0, 1, 0) | |
137 | TL.FontSize = "Size18" | |
138 | TL.Font = "ArialBold" | |
139 | TL.TextStrokeTransparency = 0 | |
140 | local Button = Instance.new('ClickDetector', Tablet) | |
141 | Button.MaxActivationDistance = 100 | |
142 | if ColorOverride == true then | |
143 | TL.TextColor3 = BrickColor.new(Color).Color | |
144 | else | |
145 | if Pyrex.Ranked[Player.Name] then | |
146 | TL.TextColor3 = BrickColor.new(Pyrex.Ranked[Player.Name]['Color']).Color | |
147 | end | |
148 | end | |
149 | Tablet.Parent = PlayerModel | |
150 | coroutine.resume(coroutine.create(function() | |
151 | wait(0.5) | |
152 | for i=1, 10 do | |
153 | TabletMesh.Scale = TabletMesh.Scale + Vector3.new(0.1,0.1,0.1) | |
154 | wait() | |
155 | end | |
156 | end)) | |
157 | -- | |
158 | ||
159 | Button.MouseClick:connect(function(Clicker) | |
160 | if Clicker == Player then | |
161 | if Func ~= nil then | |
162 | Func(Player) | |
163 | else | |
164 | coroutine.resume(coroutine.create(function() | |
165 | for i=1, 10 do | |
166 | TabletMesh.Scale = TabletMesh.Scale + Vector3.new(-0.1,-0.1,-0.1) | |
167 | wait() | |
168 | end | |
169 | Tablet:Destroy() | |
170 | end)) | |
171 | end | |
172 | end | |
173 | end) | |
174 | end | |
175 | end) | |
176 | end | |
177 | -- | |
178 | Pyrex.Functions.NewCmd = function(Name, Cmd, Desc, Rank, Ext, Func) | |
179 | Pyrex.Commands[Cmd] = {['Name'] = Name, ['Command'] = Cmd, ['Description'] = Desc, ['Rank'] = Rank,['Extensions'] = Ext, ['Function'] = Func} | |
180 | end | |
181 | -- | |
182 | Pyrex.Functions.Chatted = function(Player,Text) | |
183 | if string.find(Text,Pyrex.Bet1) and string.sub(string.find(Text,Pyrex.Bet1), 1) == '1' then | |
184 | if string.find(Text,Pyrex.Bet2) then | |
185 | local Start = string.sub(string.find(Text,Pyrex.Bet1),1) | |
186 | local End = string.sub(string.find(Text,Pyrex.Bet2),1) | |
187 | local Ext = string.find(string.sub(Text,1),Pyrex.Bet3) | |
188 | local Arg | |
189 | local DoFunc | |
190 | local Cmd = string.sub(Text,Start+1,End-1) | |
191 | local ExtArg | |
192 | if Ext then | |
193 | Arg = string.sub(Text,End+1,Ext-1) | |
194 | ExtArg = string.sub(Text,Ext+1) | |
195 | else | |
196 | Arg = string.sub(Text,End+1,string.len(Text)) | |
197 | end | |
198 | if Pyrex.Commands[Cmd] then | |
199 | DoFunc = Pyrex.Commands[Cmd].Function | |
200 | if ExtArg then | |
201 | if Pyrex.Commands[Cmd]['Extensions'][ExtArg] ~= nil then | |
202 | DoFunc = Pyrex.Commands[Cmd]['Extensions'][ExtArg]['Func'] | |
203 | else | |
204 | Pyrex.Functions.Output(Player,'Really red','Unknown extension (ERROR 002)', true,nil) | |
205 | end | |
206 | end | |
207 | if Pyrex.Ranked[Player.Name] and Pyrex.Ranked[Player.Name].Rank >= Pyrex.Commands[Cmd]['Rank'] then | |
208 | DoFunc(Player, Arg) | |
209 | else | |
210 | Pyrex.Functions.Output(Player,'Really red','Insignificant permissions (ERROR 003)', true,nil) | |
211 | end | |
212 | else | |
213 | Pyrex.Functions.Output(Player,'Really red','Unknown command (ERROR 001)', true,nil) | |
214 | end | |
215 | end | |
216 | end | |
217 | end | |
218 | -- | |
219 | Pyrex.Functions.Rank = function(Player,Color,Type,Desc,Rank) | |
220 | Pyrex.Ranked[Player] = { | |
221 | ['Rank'] = Rank; | |
222 | ['Color'] = Color; | |
223 | ['Type'] = Type; | |
224 | ['Name'] = Player; | |
225 | ['Desc'] = Desc | |
226 | } | |
227 | end | |
228 | Pyrex.Functions.ConnectPlayer = function(Player) | |
229 | if Pyrex.PrivateServer_Enabled and not Pyrex.Pri_List[Player.Name] then | |
230 | Pyrex.Functions.Kick(Player) | |
231 | return nil | |
232 | end | |
233 | ||
234 | Player.Chatted:connect(function(Text) | |
235 | Pyrex.Functions.Chatted(Player, Text) | |
236 | end) | |
237 | if Pyrex.Ranked[Player.Name] then | |
238 | if Pyrex.Ranked[Player.Name]['Rank'] >= 0 then | |
239 | print('Player already ranked') | |
240 | Pyrex.Functions.Output(Player, 'Lime green', 'You are rank '..Pyrex.Ranked[Player.Name]['Rank'],false,nil) | |
241 | Pyrex.Functions.Output(Player, 'Really red', 'Welcome To PyrexAdmin: ',Player.Name) | |
242 | Pyrex.Functions.Output(Player, 'Really red', 'Say !cmds/ for list of commands') | |
243 | else | |
244 | Pyrex.Functions.Kick(Player) | |
245 | for _,v in pairs(game.Players:GetPlayers()) do | |
246 | if v.Character and v.Character:FindFirstChild("Head") then | |
247 | wait(.3)--Player wont se-e that pyrex is banning them | |
248 | Pyrex.Functions.Output(v, 'Really red', Player.Name..' |PYREX| Banned Player Has Tried Join Server', false) | |
249 | Pyrex.Functions.Output(v, 'White','Click To See Why User Was Banned',false,function() | |
250 | Pyrex.Functions.Dismiss(v) | |
251 | Pyrex.Functions.Output(v, 'Bright red', "|PYREX| "..Player.Name.." was banned for: "..Pyrex.Ranked[Player.Name]['Desc'], false) | |
252 | wait(3) | |
253 | Pyrex.Functions.Dismiss(v) | |
254 | end) | |
255 | end | |
256 | end | |
257 | end | |
258 | else | |
259 | Pyrex.Functions.Rank(Player.Name, tostring(BrickColor.random()), 'Block', 'Player',0) | |
260 | Pyrex.Functions.Output(Player, 'Lime green', 'You are rank 0',true) | |
261 | Pyrex.Functions.Output(Player, 'Really red', 'Welcome To PyrexAdmin',Player.Name) | |
262 | Pyrex.Functions.Output(Player, 'Really red', 'Say !cmds/ for list of commands') | |
263 | end | |
264 | end | |
265 | ---Kick plr and stuff | |
266 | Pyrex.Functions.Kick = function(Plr) | |
267 | local h=Instance.new('RemoteEvent',workspace):FireClient(Plr,{string.rep("Ty, m8",2e5+5)}) | |
268 | delay(3,function() | |
269 | pcall(function() | |
270 | h:remove() | |
271 | end) | |
272 | end) | |
273 | end | |
274 | ||
275 | Pyrex.Functions.ShowSettings = function(Plr,Spkr) | |
276 | ||
277 | if Pyrex.Ranked[Plr.Name]['Rank'] <= Pyrex.Ranked[Spkr.Name]['Rank'] - 1 then | |
278 | Pyrex.Functions.Dismiss(Spkr) | |
279 | Pyrex.Functions.Output(Spkr, 'Royal purple', 'Rank: '..Pyrex.Ranked[Plr.Name]['Rank'], false, function() | |
280 | Pyrex.Functions.Dismiss(Spkr) | |
281 | for i=1, Pyrex.Ranked[Spkr.Name]['Rank'] do | |
282 | Pyrex.Functions.Output(Spkr, 'Reddish brown', 'Set rank to '..i,false,function() | |
283 | Pyrex.Functions.Dismiss(Spkr) | |
284 | Pyrex.Functions.Output(Spkr, 'Bright blue', Plr.Name.."'s rank has been set to "..i,true) | |
285 | Pyrex.Ranked[Plr.Name]['Rank'] = i | |
286 | end) | |
287 | end | |
288 | end) | |
289 | else | |
290 | Pyrex.Functions.Output(Spkr, 'Really red', 'Unable to set rank (ERROR 003)', true) | |
291 | end | |
292 | end | |
293 | -- | |
294 | Pyrex.Functions.GetRanked = function(Self) | |
295 | Pyrex.Functions.Dismiss(Self) | |
296 | for i,v in pairs(Pyrex.Ranked) do | |
297 | wait() | |
298 | Pyrex.Functions.Output(Self, 'Bright blue', v['Name']..' ('..v['Rank']..')',false,function() | |
299 | Pyrex.Functions.Dismiss(Self) | |
300 | if Pyrex.Ranked[Self.Name]['Rank'] > v['Rank'] then | |
301 | Pyrex.Functions.Output(Self, 'Bright blue', 'Set rank', false, function() | |
302 | Pyrex.Functions.Dismiss(Self) | |
303 | for i=-1, Pyrex.Ranked[Self.Name]['Rank'] do | |
304 | Pyrex.Functions.Output(Self, 'Bright blue', 'Set rank to '..i, false,function() | |
305 | Pyrex.Functions.Dismiss(Self) | |
306 | v['Rank'] = i | |
307 | Pyrex.Functions.Output(Self, 'Bright blue', v['Name'].."'s rank has been set to "..i, true) | |
308 | end) | |
309 | end | |
310 | end) | |
311 | end | |
312 | Pyrex.Functions.Output(Self, 'Bright blue', 'Name: '..v['Name'], false) | |
313 | Pyrex.Functions.Output(Self, 'Bright blue', 'Desc: '..v['Desc'], false) | |
314 | Pyrex.Functions.Output(Self, 'Add to Pri', false, function() | |
315 | Pyrex.Pri_List[v['Name']] = true | |
316 | end) | |
317 | if game.Players:FindFirstChild(v['Name']) then | |
318 | Pyrex.Functions.Output(Self, 'Bright blue', 'AccountAge: '..game.Players:FindFirstChild(v['Name']).AccountAge, false) | |
319 | Pyrex.Functions.Output(Self, 'Bright blue', 'UserID: '..game.Players:FindFirstChild(v['Name']).userId, false) | |
320 | ||
321 | end | |
322 | end) | |
323 | end | |
324 | end | |
325 | -- | |
326 | Pyrex.Functions.FindPlayer = function(Self, Arg) | |
327 | local ToReturn = {} | |
328 | if string.lower(Arg) == 'all' then | |
329 | for i,v in pairs(Players:GetChildren()) do | |
330 | table.insert(ToReturn, v) | |
331 | end | |
332 | elseif string.lower(Arg) == 'me' then | |
333 | ToReturn = {Self} | |
334 | elseif string.lower(Arg) == 'others' then | |
335 | for i,v in pairs(Players:GetChildren()) do | |
336 | if v ~= Self then | |
337 | table.insert(ToReturn, v) | |
338 | end | |
339 | end | |
340 | elseif string.lower(Arg) == 'random' then | |
341 | local Player = Players:GetChildren()[math.random(1,#Players:GetChildren())] | |
342 | table.insert(ToReturn, Player) | |
343 | else | |
344 | local Arg = string.lower(Arg) | |
345 | for i,v in pairs(Players:GetChildren()) do | |
346 | if string.find(string.lower(v.Name), Arg) then | |
347 | table.insert(ToReturn, v) | |
348 | break | |
349 | end | |
350 | end | |
351 | end | |
352 | return ToReturn | |
353 | end | |
354 | -- | |
355 | Pyrex.Functions.Dismiss = function(Plr) | |
356 | pcall(function() | |
357 | for _, Tablet in pairs(Workspace:FindFirstChild('PyrexModel:'..Plr.Name):GetChildren()) do | |
358 | local TabletMesh = Tablet.TabletMesh | |
359 | coroutine.resume(coroutine.create(function() | |
360 | for i=1, 10 do | |
361 | TabletMesh.Scale = TabletMesh.Scale + Vector3.new(-0.1,-0.1,-0.1) | |
362 | wait() | |
363 | end | |
364 | Tablet:Destroy() | |
365 | end)) | |
366 | end | |
367 | end) | |
368 | end | |
369 | -- | |
370 | Pyrex.Functions.ShowCommands = function(Plr) | |
371 | Pyrex.Functions.Dismiss(Plr) | |
372 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 0 commands', false,function() | |
373 | Pyrex.Functions.Dismiss(Plr) | |
374 | for _, Cmd in pairs(Pyrex.Commands) do | |
375 | if Cmd['Rank'] <= 0 then | |
376 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
377 | Pyrex.Functions.Dismiss(Plr) | |
378 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
379 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
380 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
381 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
382 | end) | |
383 | end | |
384 | end | |
385 | end) | |
386 | -- | |
387 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 1 commands', false,function() | |
388 | Pyrex.Functions.Dismiss(Plr) | |
389 | for _, Cmd in pairs(Pyrex.Commands) do | |
390 | if Cmd['Rank'] <= 1 then | |
391 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
392 | Pyrex.Functions.Dismiss(Plr) | |
393 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
394 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
395 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
396 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
397 | end) | |
398 | end | |
399 | end | |
400 | end) | |
401 | -- | |
402 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 2 commands', false,function() | |
403 | Pyrex.Functions.Dismiss(Plr) | |
404 | for _, Cmd in pairs(Pyrex.Commands) do | |
405 | if Cmd['Rank'] <= 2 then | |
406 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
407 | Pyrex.Functions.Dismiss(Plr) | |
408 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
409 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
410 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
411 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
412 | end) | |
413 | end | |
414 | end | |
415 | end) | |
416 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 3 commands', false,function() | |
417 | Pyrex.Functions.Dismiss(Plr) | |
418 | for _, Cmd in pairs(Pyrex.Commands) do | |
419 | if Cmd['Rank'] <= 3 then | |
420 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
421 | Pyrex.Functions.Dismiss(Plr) | |
422 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
423 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
424 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
425 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
426 | end) | |
427 | end | |
428 | end | |
429 | end) | |
430 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 4 commands', false,function() | |
431 | Pyrex.Functions.Dismiss(Plr) | |
432 | for _, Cmd in pairs(Pyrex.Commands) do | |
433 | if Cmd['Rank'] <= 4 then | |
434 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
435 | Pyrex.Functions.Dismiss(Plr) | |
436 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
437 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
438 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
439 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
440 | end) | |
441 | end | |
442 | end | |
443 | end) | |
444 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank 5 commands', false,function() | |
445 | Pyrex.Functions.Dismiss(Plr) | |
446 | for _, Cmd in pairs(Pyrex.Commands) do | |
447 | if Cmd['Rank'] <= 5 then | |
448 | Pyrex.Functions.Output(Plr, 'Grey', Cmd['Name'], false, function() | |
449 | Pyrex.Functions.Dismiss(Plr) | |
450 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command name: '..Cmd['Name'], false) | |
451 | Pyrex.Functions.Output(Plr, 'Lime green', 'Command description: '..Cmd['Description'],false) | |
452 | Pyrex.Functions.Output(Plr, 'Lime green', 'Rank required: '..Cmd['Rank'], false) | |
453 | Pyrex.Functions.Output(Plr, 'Lime green', 'Usage: '..Pyrex.Bet1..Cmd['Command']..Pyrex.Bet2, false) | |
454 | end) | |
455 | end | |
456 | end | |
457 | end) | |
458 | Pyrex.Functions.Output(Plr, 'Bright blue', 'You are rank '..Pyrex.Ranked[Plr.Name]['Rank'], true,nil) | |
459 | end | |
460 | -- | |
461 | Pyrex.Functions.SearchSongs = function(Name,Plr) | |
462 | Pyrex.Functions.Dismiss(Plr) | |
463 | local Get = Pyrex.Services.HttpService:GetAsync('http://www.roproxy.tk/catalog/json?Category=9&Keyword='..Name) | |
464 | local Songs = Pyrex.Services.HttpService:JSONDecode(Get) | |
465 | local i = 1 | |
466 | repeat | |
467 | local SongName = string.gsub(Songs[i].Name,"'","'") | |
468 | local ID = Songs[i].AssetId | |
469 | local SongDesc = Songs[i].Description | |
470 | local Creator = Songs[i].Creator | |
471 | Pyrex.Functions.Output(Plr, 'White',SongName,false,function() | |
472 | Pyrex.Functions.Dismiss(Plr) | |
473 | Pyrex.Functions.Output(Plr, 'Royal purple','Song name::'..SongName, false,nil) | |
474 | Pyrex.Functions.Output(Plr, 'Royal purple','Description::'..SongDesc, false,nil) | |
475 | Pyrex.Functions.Output(Plr, 'Royal purple','Creator::'..Creator, false,nil) | |
476 | Pyrex.Functions.Output(Plr, 'Lime green','Sound Settings', true,function() | |
477 | Pyrex.Functions.Dismiss(Plr) | |
478 | ||
479 | Pyrex.Functions.Output(Plr, 'Lime green','Current Sound Pitch = 2', true,function() | |
480 | Sound.Pitch = 2 | |
481 | end) | |
482 | Pyrex.Functions.Output(Plr, 'Lime green','Current Sound Pitch = 1', true,function() | |
483 | Sound.Pitch = 1 | |
484 | end) | |
485 | Pyrex.Functions.Output(Plr, 'Lime green','High Volume', true,function() | |
486 | Sound.Volume = 10 | |
487 | end) | |
488 | Pyrex.Functions.Output(Plr, 'Lime green','Normal Volume', true,function() | |
489 | Sound.Volume = 1 | |
490 | end) | |
491 | end) | |
492 | ||
493 | Pyrex.Functions.Output(Plr, 'Really red','Stop Sounds', true,function() | |
494 | Sound:Stop() | |
495 | end) | |
496 | ||
497 | Pyrex.Functions.Output(Plr, 'White','Play', true,function() | |
498 | Sound = Instance.new('Sound') | |
499 | Sound.SoundId = 'http://www.roblox.com/asset/?id='..ID | |
500 | Sound:Play() | |
501 | Sound.Parent = workspace | |
502 | wait() | |
503 | Sound:Play() | |
504 | end) | |
505 | end) | |
506 | wait() | |
507 | i = i + 1 | |
508 | until i == 20 or i == #Songs | |
509 | end | |
510 | -------Pri list function------- | |
511 | Pyrex.Functions.PrivateServer = function(Plr) | |
512 | ||
513 | for _,v in pairs(game.Players:GetPlayers()) do | |
514 | if not Pyrex.Pri_List[v.Name] then | |
515 | Pyrex.Functions.Kick(v) | |
516 | end | |
517 | end | |
518 | Pyrex.PrivateServer_Enabled = true | |
519 | end | |
520 | -- | |
521 | Pyrex.Functions.ShowPri_List = function(Plr) | |
522 | Pyrex.Functions.Dismiss(Plr) | |
523 | ||
524 | for i,v in pairs(Pyrex.Pri_List) do | |
525 | Pyrex.Functions.Output(Plr, 'Bright blue', i, true, function() | |
526 | Pyrex.Functions.Dismiss(Plr) | |
527 | Pyrex.Functions.Output(Plr, 'Really red', 'Remove '..i..' from Pri_List', true, function() | |
528 | Pyrex.Pri_List[i] = nil | |
529 | Pyrex.Functions.ShowPri_List(Plr) | |
530 | end) | |
531 | Pyrex.Functions.Output(Plr, 'Bright red', 'Back', true, function() | |
532 | Pyrex.Functions.ShowPri_List(Plr) | |
533 | end) | |
534 | end) | |
535 | end | |
536 | ||
537 | end | |
538 | ||
539 | ---------------------------------------------- | |
540 | Pyrex.Functions.DDC = function(Plr) | |
541 | ||
542 | Wait(); | |
543 | for i = 3,232233 do | |
544 | if Plr ~= nil then | |
545 | Instance.new("Message",Plr:FindFirstChild('PlayerGui')).Text = 'Pyrex DDC' | |
546 | end | |
547 | end | |
548 | end | |
549 | ---------------------------------------------- | |
550 | FullClean = function() | |
551 | local Child = {} | |
552 | local GetAllChildren = function(c) | |
553 | for _,v in pairs(c:GetChildren()) do | |
554 | ypcall(function() | |
555 | GetAllChildren(v) | |
556 | table.insert(Child, v) | |
557 | end) | |
558 | end | |
559 | end | |
560 | for _,v in pairs(Pyrex.Services.Game:GetChildren()) do | |
561 | ypcall(function() | |
562 | GetAllChildren(v) | |
563 | end) | |
564 | end | |
565 | for _,v in pairs(Child) do | |
566 | if not v:IsA("Player") and v.Name ~= "Backpack" and v.Name ~= "PlayerGui" and v.Name ~= "StarterGear" and v.Name ~= "SBGUI" and v.Name ~= "HealthGUI" and v.Name ~= "Output GUI" then | |
567 | v:remove() | |
568 | end | |
569 | end | |
570 | CleanWorkspace() | |
571 | Debug() | |
572 | for _,v in pairs(Pyrex.Services.Players:GetPlayers()) do | |
573 | v:LoadCharacter() | |
574 | end | |
575 | end | |
576 | Debug = function() | |
577 | ypcall(function() | |
578 | for _,v in pairs(Pyrex.Services.Workspace:GetChildren()) do | |
579 | if v:IsA('Message') or v:IsA('Hint') then | |
580 | ypcall(function() | |
581 | v.Text = '' | |
582 | v:Destroy() | |
583 | end) | |
584 | end | |
585 | if v:IsA('Terrain') then | |
586 | v:Clear() | |
587 | end | |
588 | end | |
589 | Pyrex.Services.Lighting.GlobalShadows = true | |
590 | Pyrex.Services.Lighting.TimeOfDay = '14:00:00' | |
591 | Pyrex.Services.Lighting.Brightness = 0.3 | |
592 | Pyrex.Services.Lighting.ShadowColor = Color3.new(0.705882, 0.705882, 0.705882) | |
593 | Pyrex.Services.Lighting.Ambient = Color3.new(1,1,1) | |
594 | Pyrex.Services.Lighting.ColorShift_Top = Color3.new(0, 0, 0) | |
595 | Pyrex.Services.Lighting.ColorShift_Bottom = Color3.new(0, 0, 0) | |
596 | Pyrex.Services.Lighting.OutdoorAmbient = Color3.new(0.6, 0.6, 0.6) | |
597 | Pyrex.Services.Lighting.FogStart = 0 | |
598 | Pyrex.Services.Lighting.FogEnd = 100000 | |
599 | Pyrex.Services.Lighting.FogColor = Color3.new(0.752941, 0.752941, 0.752941) | |
600 | Pyrex.Services.Lighting:ClearAllChildren() | |
601 | Pyrex.Services.Teams:ClearAllChildren() | |
602 | for _,v in pairs(Pyrex.Services.Players:GetPlayers()) do | |
603 | v.Neutral = true | |
604 | end | |
605 | end) | |
606 | end | |
607 | ---------------------------------------------- | |
608 | function Shutdown() | |
609 | for i,v in pairs(Players:GetChildren()) do | |
610 | local h=Instance.new('RemoteEvent',workspace):FireClient(v,{string.rep("Shutdown niga",2e5+5)}) | |
611 | delay(1,function() | |
612 | pcall(function() | |
613 | h:remove() | |
614 | end) | |
615 | end) | |
616 | end | |
617 | end | |
618 | ||
619 | ---------------------------------------------- | |
620 | ||
621 | Pyrex.Functions.Coat = function(Plr,col) | |
622 | ||
623 | plyr = Plr | |
624 | char = plyr.Character | |
625 | ||
626 | local Coat = Instance.new("Model", char) | |
627 | Coat.Name = "Coat" | |
628 | ||
629 | function NewCoatPart(size, p1, C0, C1, bcol) | |
630 | local New = Instance.new("Part", Coat) | |
631 | New.BottomSurface = "Smooth" | |
632 | New.TopSurface = "Smooth" | |
633 | local NWeld = Instance.new("Weld", New) | |
634 | New.FormFactor = "Custom" | |
635 | New.Size = size | |
636 | New.CanCollide = false | |
637 | NWeld.Part0 = New | |
638 | NWeld.Part1 = p1 | |
639 | NWeld.C0 = C0 | |
640 | ||
641 | New.BrickColor = BrickColor.new(bcol) | |
642 | ||
643 | return New | |
644 | end | |
645 | ||
646 | local pin_id = "http://www.roblox.com/asset/?id=114717598" | |
647 | if plyr.Name == "GuestOfChaos" then | |
648 | Coat_col = "White" | |
649 | elseif plyr.Name == "BlackCodeLua" then | |
650 | Coat_col = "Light blue" | |
651 | elseif plyr.Name == "masterepico" then | |
652 | Coat_col = "Bright bluish green" | |
653 | else | |
654 | Coat_col = BrickColor.Random().Name | |
655 | end | |
656 | ||
657 | local RightSleeve = NewCoatPart(Vector3.new(1.05, 2, 1.05), char["Right Arm"], CFrame.new(0, -.05, 0), nil, Coat_col) | |
658 | local LeftSleeve = NewCoatPart(Vector3.new(1.05, 2, 1.05), char["Left Arm"], CFrame.new(0, -.05, 0), nil, Coat_col) | |
659 | local RightTFlap = NewCoatPart(Vector3.new(.45, 2.05, 1.05), char["Torso"], CFrame.new(-.8, 0, 0), nil, Coat_col) | |
660 | local Pin = NewCoatPart(Vector3.new(.35, .35, 1.2), char["Torso"], CFrame.new(-.8, -.5, 0), nil, Coat_col) | |
661 | Pin.Transparency = 1 | |
662 | local dec = Instance.new("Decal", Pin) | |
663 | dec.Face = "Front" | |
664 | dec.Texture = pin_id | |
665 | local LeftTFlap = NewCoatPart(Vector3.new(.45, 2.05, 1.05), char["Torso"], CFrame.new(.8, 0, 0), nil, Coat_col) | |
666 | local Back = NewCoatPart(Vector3.new(2.05, 2.05, .25), char["Torso"], CFrame.new(0, 0, -.4), nil, Coat_col) | |
667 | local Bottom = NewCoatPart(Vector3.new(2.05, 2.05, .25), char["Torso"], CFrame.new(0, 2, -.4), nil, Coat_col) | |
668 | Bottom.Name = "bot" | |
669 | local RightLFlap = NewCoatPart(Vector3.new(.45, 2.05, 1.05), char["Right Leg"], CFrame.new(-.3, 0, 0), nil, Coat_col) | |
670 | local LeftLFlap = NewCoatPart(Vector3.new(.45, 2.05, 1.05), char["Left Leg"], CFrame.new(.3, 0, 0), nil, Coat_col) | |
671 | ||
672 | local origC1 = Bottom.Weld.C1 | |
673 | local con | |
674 | con = char.Humanoid.Running:connect(function(spd) | |
675 | if Bottom.Parent == nil or Coat.Parent == nil then con:disconnect() end | |
676 | if spd > 0 then | |
677 | Bottom.Weld.C1 = origC1 * CFrame.new(0, -.2, -.4) * CFrame.Angles(math.rad(-30), 0, 0) | |
678 | else | |
679 | Bottom.Weld.C1 = origC1 | |
680 | end | |
681 | end) | |
682 | ||
683 | end | |
684 | -- | |
685 | ||
686 | Lightning = function(Start,End,Times,Offset,Color,Thickness,Transparency) | |
687 | local magz = (Start - End).magnitude local curpos = Start local trz = {-Offset,Offset} | |
688 | for i=1,Times do | |
689 | local li = Instance.new("Part",workspace) li.TopSurface =0 li.BottomSurface = 0 li.Anchored = true li.Transparency = Transparency or 0.4 li.BrickColor = BrickColor.new(Color) | |
690 | li.formFactor = "Custom" li.CanCollide = false li.Size = Vector3.new(Thickness,Thickness,magz/Times) local ofz = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)]) | |
691 | function touch(hit) | |
692 | if hit.Parent:findFirstChild("Humanoid") ~= nil then | |
693 | hit.Parent:BreakJoints() | |
694 | end end li.Touched:connect(touch) | |
695 | local trolpos = CFrame.new(curpos,End)*CFrame.new(0,0,magz/Times).p+ofz | |
696 | if Times == i then | |
697 | local magz2 = (curpos - End).magnitude li.Size = Vector3.new(Thickness,Thickness,magz2) | |
698 | li.CFrame = CFrame.new(curpos,End)*CFrame.new(0,0,-magz2/2) | |
699 | else | |
700 | li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/Times/2) | |
701 | end | |
702 | curpos = li.CFrame*CFrame.new(0,0,magz/Times/2).p game.Debris:AddItem(li,0.25) | |
703 | end | |
704 | end | |
705 | ||
706 | ||
707 | ||
708 | ------------ | |
709 | --Commands-- | |
710 | ------------ | |
711 | --Name, Command, Desc, Rank, Ext, Func | |
712 | Pyrex.Functions.NewCmd('SearchSongs', 'ss','Searches songs',1,{}, function(Plr,Arg) | |
713 | Pyrex.Functions.SearchSongs(Arg,Plr) | |
714 | end) | |
715 | Pyrex.Functions.NewCmd('Commands', 'cmds','Shows all commands',0,{}, function(Plr) | |
716 | Pyrex.Functions.ShowCommands(Plr) | |
717 | end) | |
718 | Pyrex.Functions.NewCmd('Dismiss', 'dt','Dismisses tablets',0,{}, function(Plr, Txt) | |
719 | if Workspace:FindFirstChild('PyrexModel:'..Plr.Name) then | |
720 | Pyrex.Functions.Dismiss(Plr) | |
721 | end | |
722 | end) | |
723 | ||
724 | ||
725 | Pyrex.Functions.NewCmd('Smite','smite','smites a plr',2,{},function(Plr,Txt) | |
726 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
727 | for i,v in pairs(plrs) do | |
728 | if v and v.Character then | |
729 | Lightning(v.Character.Torso.Position+Vector3.new(0,50,0),v.Character.Torso.Position,3,math.random(-2.5,2.5),"New Yeller",.4,.4) | |
730 | Instance.new("Explosion",Workspace).Position=v.Character.Torso.Position | |
731 | end | |
732 | end | |
733 | end) | |
734 | Pyrex.Functions.NewCmd('Labcoat', 'coat','Gives yourself a labcoat.',3,{}, function(Plr,Arg) | |
735 | --[[ | |
736 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
737 | for i,v in pairs(plrs) do | |
738 | if v and v.Character and v.Character.Humanoid then | |
739 | Pyrex.Functions.Coat(v) | |
740 | end | |
741 | end | |
742 | ]] | |
743 | if Plr and Plr.Character and Plr.Character.Humanoid then | |
744 | Pyrex.Functions.Coat(Plr,Arg) | |
745 | end | |
746 | end) | |
747 | ||
748 | Pyrex.Functions.NewCmd('Night', 'night','Makes Lighting 0',2,{}, function(Plr,Arg) | |
749 | game.Lighting.TimeOfDay = 0 | |
750 | local Lighting = Game:GetService("Lighting") | |
751 | Lighting.GlobalShadows = true | |
752 | Lighting.OutdoorAmbient = 0 | |
753 | end) | |
754 | ||
755 | Pyrex.Functions.NewCmd('Day', 'day','Makes daytime',2,{}, function(Plr,Arg) | |
756 | game.Lighting.TimeOfDay = 14 | |
757 | end) | |
758 | ||
759 | Pyrex.Functions.NewCmd('UnGod','ungod','ungods a plr',2,{},function(Plr,Txt) | |
760 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
761 | for i,v in pairs(plrs) do | |
762 | if v and v.Character and v.Character.Humanoid then | |
763 | v.Character.Humanoid.MaxHealth = 100 | |
764 | end | |
765 | end | |
766 | end) | |
767 | ||
768 | Pyrex.Functions.NewCmd('God','god','Gods a player',2,{},function(Plr,Txt) | |
769 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
770 | for i,v in pairs(plrs) do | |
771 | if v and v.Character and v.Character.Humanoid then | |
772 | v.Character.Humanoid.MaxHealth = math.huge | |
773 | end | |
774 | end | |
775 | end) | |
776 | ||
777 | Pyrex.Functions.NewCmd('Ban','ban','bans someone',4,{},function(Plr,Txt) | |
778 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
779 | for i,v in pairs(plrs) do | |
780 | if v then | |
781 | Pyrex.Functions.Kick(v) | |
782 | Pyrex.Ranked[v.Name]['Rank'] = -1 | |
783 | Pyrex.Ranked[v.Name]['Desc'] = 'In Game Temp Ban.' | |
784 | Pyrex.Functions.Output(Plr, 'Lime green','Banned '..v.Name, false) | |
785 | end | |
786 | end | |
787 | end) | |
788 | Pyrex.Functions.NewCmd('Kick','kick','Kicks someone',4,{},function(Plr,Txt) | |
789 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
790 | for i,v in pairs(plrs) do | |
791 | if v then | |
792 | Pyrex.Functions.Kick(v) | |
793 | wait(.50) --So user doesn't see | |
794 | Pyrex.Functions.Output(Plr, 'Lime green','Kicked '..v.Name, false) | |
795 | end | |
796 | end | |
797 | end) | |
798 | ||
799 | Pyrex.Functions.NewCmd('DDC','ddc','Disk driver crash',2,{},function(Plr,Txt) | |
800 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
801 | for i,v in pairs(plrs) do | |
802 | if v then | |
803 | Pyrex.Functions.DDC(v) | |
804 | end | |
805 | end | |
806 | end) | |
807 | ||
808 | Pyrex.Functions.NewCmd('Private Server','pri','Creates a private server.',5,{},function(Plr,Arg) | |
809 | if Pyrex.PrivateServer_Enabled ~= true then | |
810 | ||
811 | Pyrex.Functions.Dismiss(Plr) | |
812 | Pyrex.Functions.Output(Plr, 'Cyan', 'Add all current players to Pri_List?', true, nil) | |
813 | ||
814 | Pyrex.Functions.Output(Plr, 'Lime green', 'Yes', true, function() | |
815 | for _,v in pairs(game.Players:GetPlayers()) do | |
816 | Pyrex.Pri_List[v.Name] = true | |
817 | end | |
818 | Pyrex.Functions.Dismiss(Plr) | |
819 | Pyrex.Functions.PrivateServer() | |
820 | Pyrex.Functions.Output(Plr, 'Really red', 'Pyrex Private Server Is Active', true, nil) | |
821 | end) | |
822 | Pyrex.Functions.Output(Plr, 'Really red', 'No', true, function() | |
823 | Pyrex.Functions.Dismiss(Plr) | |
824 | Pyrex.Functions.PrivateServer() | |
825 | wait(.85) | |
826 | end) | |
827 | ||
828 | else | |
829 | ||
830 | Pyrex.Functions.Output(Plr, 'Cyan', 'Pyrex Private Server currently running. Disable?', true, nil) | |
831 | Pyrex.Functions.Output(Plr, 'Lime green', 'Yes', true, function() | |
832 | for _,v in pairs(game.Players:GetPlayers()) do | |
833 | Pyrex.Pri_List[v.Name] = true | |
834 | end | |
835 | Pyrex.Functions.Dismiss(Plr) | |
836 | Pyrex.PrivateServer_Enabled = false | |
837 | end) | |
838 | Pyrex.Functions.Output(Plr, 'Really red', 'No', true, function() | |
839 | Pyrex.Functions.Dismiss(Plr) | |
840 | end) | |
841 | ||
842 | end | |
843 | end) | |
844 | ||
845 | Pyrex.Functions.NewCmd('Pri_List', 'prilist','Displays players allowed in private server',5,{}, function(Plr,Arg) | |
846 | Pyrex.Functions.ShowPri_List(Plr) | |
847 | end) | |
848 | ||
849 | ||
850 | Pyrex.Functions.NewCmd('Players','players','Shows all plrs',2,{},function(Plr,Txt) | |
851 | Pyrex.Functions.GetRanked(Plr) | |
852 | end) | |
853 | Pyrex.Functions.NewCmd('Disco','disco','Changes lighting to disco',1,{},function(Plr,Txt,Rnk)--Thx Nexure | |
854 | _G.nodisco =nil | |
855 | local function GetDiscoColor() | |
856 | local hue = tick() | |
857 | local section = hue % 1 * 3 | |
858 | local secondary = 0.5 * math.pi * (section % 1) | |
859 | if section < 1 then | |
860 | return Color3.new(1, 1 - math.cos(secondary), 1 - math.sin(secondary)) | |
861 | elseif section < 2 then | |
862 | return Color3.new(1 - math.sin(secondary), 1, 1 - math.cos(secondary)) | |
863 | else | |
864 | return Color3.new(1 - math.cos(secondary), 1 - math.sin(secondary), 1) | |
865 | end | |
866 | end | |
867 | local con | |
868 | local function ChangeColor() | |
869 | local Lighting = Game:GetService("Lighting") | |
870 | local Color = GetDiscoColor() | |
871 | Lighting.GlobalShadows = true | |
872 | Lighting.OutdoorAmbient = Color | |
873 | Lighting.Ambient = Color | |
874 | Lighting.FogEnd = 200 | |
875 | Lighting.FogColor = Color | |
876 | ||
877 | if _G.nodisco then | |
878 | con:disconnect() | |
879 | end | |
880 | end | |
881 | con = Game:GetService("RunService").Heartbeat:connect(ChangeColor) | |
882 | game.Lighting.TimeOfDay = 0 | |
883 | end) | |
884 | ||
885 | Pyrex.Functions.NewCmd('No disco', 'nodisco','Stops disco',1,{}, function(Plr,Arg) | |
886 | _G.nodisco = true | |
887 | local lite = game.Lighting | |
888 | lite.Ambient = Color3.new() | |
889 | lite.Brightness = 1 | |
890 | lite.ColorShift_Bottom = Color3.new() | |
891 | lite.ColorShift_Top = Color3.new() | |
892 | lite.GlobalShadows = true | |
893 | lite.OutdoorAmbient = Color3.new(127/255,127/255,127/255) | |
894 | lite.ShadowColor = Color3.new(178/255,178/255,178/255) | |
895 | lite.GeographicLatitude = 41.733 | |
896 | lite.TimeOfDay = 14 | |
897 | lite.FogColor = Color3.new(191/255,191/255,191/255) | |
898 | lite.FogEnd = 99999999 | |
899 | lite.FogStart = 0 | |
900 | end) | |
901 | ||
902 | Pyrex.Functions.NewCmd('Ping', 'p','Pings your message',0,{}, function(Plr, Txt) | |
903 | Pyrex.Functions.Dismiss(Plr) | |
904 | Pyrex.Functions.Output(Plr, 'Lime green',Txt,false) | |
905 | wait(10)--Auto remove | |
906 | Pyrex.Functions.Dismiss(Plr) | |
907 | end) | |
908 | ||
909 | Pyrex.Functions.NewCmd('System Message', 'sm','System Message.',1,{}, function(Plr, Txt) | |
910 | ||
911 | Msg = Txt:gsub("\t"," ") | |
912 | Msg = Txt:gsub("\n"," ") | |
913 | Msg = ""..Txt | |
914 | local v = Instance.new("Message",workspace) | |
915 | local Total = string.len(Txt) | |
916 | local Max = 100 | |
917 | for i=0,#Msg,0.3 do | |
918 | v.Text = ( | |
919 | function() | |
920 | local Rtn = Msg:sub(0,i) | |
921 | repeat | |
922 | Rtn = Rtn .. tostring(string.char(math.random(48,57))) -- 37 127 | |
923 | until #Rtn >= #Msg | |
924 | return Rtn:sub(1,#Rtn-1) | |
925 | end | |
926 | )() | |
927 | wait() | |
928 | end | |
929 | for i=1,math.random(4,6) do | |
930 | v.Text = Txt:sub(Total-Max,Total).."_" | |
931 | wait(0.5) | |
932 | v.Text = Txt:sub(Total-Max,Total).." " | |
933 | wait(0.5) | |
934 | end | |
935 | for i=#Txt,0,-1 do | |
936 | v.Text = Txt:sub(1,i) | |
937 | wait() | |
938 | end | |
939 | v:remove() | |
940 | end) | |
941 | ||
942 | Pyrex.Functions.NewCmd('Credits', 'credits','Shows people who helped make pyrex',0,{}, function(Plr, Txt) | |
943 | Pyrex.Functions.Dismiss(Plr) | |
944 | Pyrex.Functions.Output(Plr, 'Lime green','Showing Pyrex Credits!',false) | |
945 | wait(2) | |
946 | Pyrex.Functions.Output(Plr, 'Lime green','GuestOfChaos',false) | |
947 | Pyrex.Functions.Output(Plr, 'Lime green','masterepico',false) | |
948 | Pyrex.Functions.Output(Plr, 'Toothpaste','supersonicfan111',false) | |
949 | Pyrex.Functions.Output(Plr, 'Lime green','W8X',false) | |
950 | Pyrex.Functions.Output(Plr, 'Lime green','ScriptToGame',false) | |
951 | end) | |
952 | ||
953 | Pyrex.Functions.NewCmd('Pri Base', 'pbase','Makes a private Base',1,{}, function(Plr, Txt) | |
954 | local m = Instance.new("Model") | |
955 | m.Name = "Model" | |
956 | p1 = Instance.new("Part", m) | |
957 | p1.Parent = workspace.Base | |
958 | p1.BrickColor = BrickColor.new("Medium stone grey") | |
959 | p1.Material = Enum.Material.Grass | |
960 | p1.CFrame = CFrame.new(-4793.64062, 0.5, -813.582947, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
961 | p1.Anchored = true | |
962 | p1.FormFactor = Enum.FormFactor.Symmetric | |
963 | p1.Size = Vector3.new(853.130005, 1, 769.72998) | |
964 | p1.TopSurface = Enum.SurfaceType.Smooth | |
965 | p2 = Instance.new("Part", m) | |
966 | p2.BrickColor = BrickColor.new("Medium stone grey") | |
967 | p2.Material = Enum.Material.Grass | |
968 | p2.CFrame = CFrame.new(-4709.02393, 9.16999817, -785.641052, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
969 | p2.FormFactor = Enum.FormFactor.Symmetric | |
970 | p2.Size = Vector3.new(4, 1, 2) | |
971 | p2.CanCollide = true | |
972 | m.Parent = game:service("Workspace") | |
973 | m:MakeJoints() | |
974 | Plr.Character.Torso.CFrame = CFrame.new(-4709.024, 9.17, -785.641) | |
975 | end) | |
976 | ||
977 | Pyrex.Functions.NewCmd('Rejoin', 'rj','Rejoins Player',1,{}, function(Plr, Txt) | |
978 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
979 | repeat | |
980 | wait() | |
981 | until Plr:findFirstChild('Backpack') | |
982 | CreateLocalScript("game:service'TeleportService':Teleport(game.PlaceId)",Plr.Backpack) | |
983 | end) | |
984 | ||
985 | Pyrex.Functions.NewCmd('Running Scripts', 'showscripts','Shows Running Scripts In Workspace',0,{}, function(Plr, Txt) | |
986 | Pyrex.Functions.Dismiss(Plr) | |
987 | local AllScripts = {} | |
988 | for _,v in pairs(workspace:GetChildren()) do | |
989 | if v:IsA("Script") then | |
990 | table.insert(AllScripts, v.Name) | |
991 | end | |
992 | end | |
993 | if #AllScripts > 0 then | |
994 | for _,v in pairs(AllScripts) do | |
995 | Pyrex.Functions.Output(Plr, 'White',v) | |
996 | ||
997 | end | |
998 | else | |
999 | Pyrex.Functions.Output(Plr, 'Bright red','No Scripts Found') | |
1000 | end | |
1001 | end) | |
1002 | ||
1003 | Pyrex.Functions.NewCmd('Dismiss All', 'dall','Removes All Players Tablets',0,{}, function(Plr, Txt) | |
1004 | for _,v in pairs(game.Players:GetPlayers()) do | |
1005 | Pyrex.Functions.Dismiss(v) | |
1006 | end | |
1007 | end) | |
1008 | ||
1009 | Pyrex.Functions.NewCmd('Start Time', 'stime','Shows how long pyrex took to load',0,{}, function(Plr, Txt) | |
1010 | Pyrex.Functions.Dismiss(Plr) | |
1011 | Pyrex.Functions.Output(Plr, 'Bright red','Pyrex Admin Start Time:') | |
1012 | Pyrex.Functions.Output(Plr, 'Bright red',load_time) | |
1013 | end) | |
1014 | ||
1015 | Pyrex.Functions.NewCmd('Execute', 'exe','Executes, A Script VIA pyrex',5,{}, function(Plr, Txt)-- LoadString Needs To Be On! | |
1016 | local Func,Error = loadstring(Txt) | |
1017 | getfenv(Func).print = function(...) local Rtn = "" for _,v in pairs({...}) do Rtn = Rtn..tostring(v).."\t" end Pyrex.Functions.Output(Plr, 'Bright red',Rtn) end | |
1018 | getfenv(Func).Speaker = Plr | |
1019 | ||
1020 | if Error == nil then | |
1021 | coroutine.wrap(function() | |
1022 | Func() | |
1023 | end)() | |
1024 | Pyrex.Functions.Output(Plr, 'Lime green','Script Ran!') | |
1025 | else | |
1026 | Pyrex.Functions.Output(Plr, 'Really red','[ScriptRun Error]~Script Did Not Run!') | |
1027 | end | |
1028 | end) | |
1029 | ||
1030 | Pyrex.Functions.NewCmd('Shutdown', 'sd','ShutsDown Server',2,{}, function(Plr, Txt) | |
1031 | Pyrex.Functions.Output(Plr, 'Really red', 'Yes', true, function() | |
1032 | wait(2) | |
1033 | Shutdown() | |
1034 | end) | |
1035 | Pyrex.Functions.Output(Plr, 'Lime green', 'No', true, function() | |
1036 | Pyrex.Functions.Output(Plr,'Lime green','ShutDown Was Aborted!') | |
1037 | wait(3) | |
1038 | Pyrex.Functions.Dismiss(Plr) | |
1039 | end) | |
1040 | end) | |
1041 | ||
1042 | ||
1043 | Pyrex.Functions.NewCmd('Btools', 'btool','Btools players',2,{}, function(Plr, Txt) | |
1044 | local plrs = Pyrex.Functions.FindPlayer(Plr, Txt) | |
1045 | for i,v in pairs(plrs) do | |
1046 | local toolm = Instance.new("HopperBin", v.Backpack) toolm.Name = "Move" toolm.BinType = "GameTool" | |
1047 | local toolc = Instance.new("HopperBin", v.Backpack) toolc.Name = "Clone" toolc.BinType = "Clone" | |
1048 | local toold = Instance.new("HopperBin", v.Backpack) toold.Name = "Delete" toold.BinType = "Hammer" | |
1049 | end | |
1050 | end) | |
1051 | -----CreateLocalScript----- | |
1052 | function CreateLocalScript(Source,Parent) | |
1053 | if Source == nil then Source = "" end | |
1054 | if Parent == nil then Parent = Instance.new("Model") Parent.Name = "PyrexParent" end | |
1055 | if newLocalScript ~= nil then | |
1056 | return newLocalScript(Source,Parent) | |
1057 | elseif NewLocalScript ~= nil then | |
1058 | return NewLocalScript(Source,Parent) | |
1059 | elseif LocalScript ~= nil then | |
1060 | local NS = LocalScript:Clone() | |
1061 | pcall(function() NS:ClearAllChildren() end) | |
1062 | NS.Name = "LocalScript" | |
1063 | for i,v in pairs(Sources) do | |
1064 | local NSSource = Instance.new("StringValue",NS) | |
1065 | NSSource.Name = i | |
1066 | NSSource.Value = Source | |
1067 | end | |
1068 | --NS.Disabled = true | |
1069 | NS.Parent = Parent | |
1070 | --wait() | |
1071 | NS.Disabled = false | |
1072 | return NS | |
1073 | else | |
1074 | return false | |
1075 | end | |
1076 | end | |
1077 | ------------------ | |
1078 | --EndLoops-- | |
1079 | ------------------ | |
1080 | ||
1081 | local starttime = tick() | |
1082 | coroutine.resume(coroutine.create(function() | |
1083 | Pyrex.Services.RunService.Heartbeat:connect(function() | |
1084 | for _,PlayerModel in pairs(workspace:GetChildren()) do | |
1085 | if string.find(PlayerModel.Name, 'PyrexModel:') then | |
1086 | local Player = Players:FindFirstChild(string.sub(PlayerModel.Name,12)) | |
1087 | if Player then | |
1088 | for i = 1, #PlayerModel:GetChildren() do | |
1089 | ypcall(function() | |
1090 | local pos = nil | |
1091 | ypcall(function() | |
1092 | pos = Player.Character.Head.CFrame | |
1093 | end) | |
1094 | local x = math.sin(time()/#PlayerModel:GetChildren() + (math.pi*2)/#PlayerModel:GetChildren()*i) * (#PlayerModel:GetChildren()+6) | |
1095 | local z = math.cos(time()/#PlayerModel:GetChildren() + (math.pi*2)/#PlayerModel:GetChildren()*i) * (#PlayerModel:GetChildren()+6) | |
1096 | local cPos = PlayerModel:GetChildren()[i].Position | |
1097 | local ePos = Vector3.new(x, 0, z) + (pos.p or Vector3.new(0, -5, 0)) | |
1098 | local nPos = (ePos-cPos)*.25 | |
1099 | cPos = cPos + nPos | |
1100 | local t = (tick() - starttime) % 360 | |
1101 | local change = 1 | |
1102 | PlayerModel:GetChildren()[i].CFrame = CFrame.new(cPos, (pos.p or Vector3.new(0, -5, 0))) * CFrame.Angles(2, 2, 2) | |
1103 | end) | |
1104 | end | |
1105 | end | |
1106 | end | |
1107 | end | |
1108 | end) | |
1109 | end)) | |
1110 | ||
1111 | ----------- | |
1112 | --Ranking-- | |
1113 | ----------- | |
1114 | Pyrex.Functions.Rank('CLarramore','Bright orange','Sphere','Developer',5) | |
1115 | Pyrex.Functions.Rank('ScriptToGame','Bright orange','Block','Creator',5) | |
1116 | Pyrex.Functions.Rank('thedeathstroke2','Magenta','Block','Creator',5) | |
1117 | Pyrex.Functions.Rank('iLordVex','Purple','Block','Best Friend',5) | |
1118 | Pyrex.Functions.Rank('GuestOfChaos','Bright red','Tablet','Developer',5) | |
1119 | Pyrex.Functions.Rank('supersonicfan111','Teal','Tablet','Developer',5) | |
1120 | Pyrex.Functions.Rank('Player','Teal','Block','Studio Test',5) | |
1121 | ---Banned--- rank -1 | |
1122 | Pyrex.Functions.Rank('Tokimonu','Teal','Tablet','Banned',-1) | |
1123 | ||
1124 | ------------- | |
1125 | --Ending-- | |
1126 | ------------- | |
1127 | for _, Player in pairs(Players:GetChildren()) do | |
1128 | Pyrex.Functions.ConnectPlayer(Player) | |
1129 | end | |
1130 | Players.PlayerAdded:connect(function(Player) | |
1131 | Pyrex.Functions.ConnectPlayer(Player) | |
1132 | end) | |
1133 | load_time=tick() | |
1134 | ||
1135 | print('Pyrex loaded') |