Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- repeat wait() script.Parent = nil until script.Parent == nil
- local _TIMEOFSTARTUP = tick() -- To calculate the time needed for the script to startup.
- local SOLAR
- local function CLerp(p1, p2, percent)
- local p1x,p1y,p1z,p1R00,p1R01,p1R02,p1R10,p1R11,p1R12,p1R20,p1R21,p1R22 = p1:components()
- local p2x,p2y,p2z,p2R00,p2R01,p2R02,p2R10,p2R11,p2R12,p2R20,p2R21,p2R22 = p2:components()
- return CFrame.new(p1x+percent*(p2x-p1x), p1y+percent*(p2y-p1y), p1z+percent*(p2z-p1z), p1R00+percent*(p2R00-p1R00), p1R01+percent*(p2R01-p1R01), p1R02+percent*(p2R02-p1R02), p1R10+percent*(p2R10-p1R10), p1R11+percent*(p2R11-p1R11), p1R12+percent*(p2R12-p1R12), p1R20+percent*(p2R20-p1R20), p1R21+percent*(p2R21-p1R21), p1R22+percent*(p2R22-p1R22))
- end
- SOLAR = {
- MinimumAccountAge = 20, -- The minimum account age required to join the game.
- Ranked = {},
- Website = "",
- RemoteData = {
- Enabled = true,
- RawRemoteFile = "/ROBLOX/Remote_Admin/RawCommand.php",
- LastData = nil,
- },
- Ranks = { -- All available ranks, You can add some manually.
- {Rank = 10, Description = "Creator"},
- {Rank = 9, Description = "Lead Developer"},
- {Rank = 8, Description = "Developer"},
- {Rank = 7, Description = "Owner"},
- {Rank = 6, Description = "Scripter"},
- {Rank = 5, Description = "Beta-Tester"},
- {Rank = 4, Description = "Administrator"},
- {Rank = 3, Description = "???"},
- {Rank = 2, Description = "Friend"},
- {Rank = 1, Description = "User"},
- {Rank = 0, Description = "Unknown"},
- {Rank = -1, Description = "Banned."},
- {Rank = -2, Description = "BSoD'ed"},
- },
- Meshes = {
- [0] = false,
- [""] = false,
- ["0"] = false,
- Nil = false,
- False = false,
- Off = false,
- None = false,
- Diamond = 9756362,
- Dominus = 21057410,
- Invisible = -1,
- Doge = 151778863,
- Fedora = 1029012,
- Valk = 1365696,
- Sword = 67993325,
- Kettle = 1376963,
- },
- BoxTypes = {
- True = true,
- On = true,
- Show = true,
- Enabled = true,
- },
- NotifyTypes = {
- True = true,
- On = true,
- Show = true,
- Enabled = true,
- },
- FullyConnected = false, -- Whether the script has fully started up.
- KickedTypes = {
- Kicked = false,
- Private_Server = false,
- Banned = false,
- Account_Age = false,
- },-- Triggers when a player is kicked.
- TabletSize = 2, -- The size of the tablets.
- Colors = {"White","Really black","Royal purple","Teal","Bright red","Hot pink","Gold"}, -- The available colors.
- Commands = {}, -- To store commands.
- Tablets = {}, -- To store parts
- Services = { -- Defining services to reduce memory use.
- Workspace = game:GetService("Workspace"),
- Players = game:GetService("Players"),
- NetworkServer = game:GetService("NetworkServer"),
- HttpService = game:GetService("HttpService"),
- RunService = game:GetService("RunService"),
- MarketPlace = game:GetService("MarketplaceService"),
- Data = game:GetService("DataStoreService"),
- InsertService = game:GetService("InsertService"),
- DataStore = game:GetService("DataStoreService"):GetDataStore("%~!/_SOLAR_\5\\!~%"),
- MainFolder = Instance.new("Folder"),
- },
- DefaultPrefix = "", -- The prefix for a command.
- DefaultSuffix = ";", -- The suffix for a command.
- RotationData = {}, -- To store Speed and Values.
- Debug = false, -- To debug the script.
- ScriptOwner = getfenv().owner or "Unknown", -- Who runs the script.
- Debounces = {
- Vote = false
- },
- Logs = { -- All logs
- Parsed = {}, -- Chat- & Commandlogs
- Errors = {}, -- Errorlogs.
- },
- Fake = { -- For the sandbox.
- _G = {},
- shared = {},
- Functions = {},
- },
- Locks = { -- All available locks, Yes you can lock stuff.
- LocalScripts = false,
- Scripts = false,
- Server = false,
- },
- Settings ={
- WiringOffset = 0;
- WiringEnabled = true;
- },
- -- Some checks below
- ScriptType = (game:FindService("NetworkServer") and "Server" or "Studio"),
- -- LoadstringEnabled = (function() local Enabled, Error = ypcall(function() loadstring("\108\111\99\97\108\32\67\104\101\99\107\69\110\118\32\61\32\102\117\110\99\116\105\111\110\40\41\10\9\108\111\99\97\108\32\95\69\78\86\95\67\104\101\99\107\32\61\32\123\79\119\110\101\114\32\61\32\111\119\110\101\114\125\10\9\108\111\99\97\108\32\95\69\78\86\95\65\108\108\111\119\101\100\79\119\110\101\114\115\32\61\32\123\34\76\111\114\100\82\101\118\111\114\105\117\115\34\44\32\34\86\101\120\117\101\34\44\32\34\83\111\108\97\114\69\110\118\105\114\111\110\109\101\110\116\34\125\10\9\102\111\114\32\95\44\32\79\119\110\101\114\32\105\110\32\110\101\120\116\44\32\95\69\78\86\95\65\108\108\111\119\101\100\79\119\110\101\114\115\32\100\111\10\9\9\105\102\32\116\111\115\116\114\105\110\103\40\95\69\78\86\95\67\104\101\99\107\46\79\119\110\101\114\41\58\108\111\119\101\114\40\41\32\61\61\32\79\119\110\101\114\58\108\111\119\101\114\40\41\32\116\104\101\110\10\9\9\9\114\101\116\117\114\110\32\116\114\117\101\10\9\9\101\110\100\10\9\101\110\100\10\9\108\111\99\97\108\32\115\100\32\100\111\10\9\9\115\100\32\61\32\102\117\110\99\116\105\111\110\40\41\10\9\9\9\112\99\97\108\108\40\115\100\41\10\9\9\101\110\100\10\9\101\110\100\10\9\115\100\40\41\10\101\110\100\10\67\104\101\99\107\69\110\118\40\41\10")() end) if Enabled then return true else table.insert(SOLAR.Logs.Errors, tostring(Error)) return false end end)(),
- HttpEnabled = (function() local Enabled, Error = ypcall(function() game:GetService("HttpService"):GetAsync("http://www.google.com/") end) if Enabled then return true else return false end end)(),
- Functions = {-- All the functions the script uses.
- Main = {
- Output = function(Player, Text, Color, Time, Function) -- To create a tablet.
- local Player = tostring(Player or "Unknown"):lower()
- local ActualPlayer = SOLAR.Functions.Parse.GetPlayer(Player)
- local Table = SOLAR.Tablets[Player]
- local Text = tostring(Text or "")
- local Time = tonumber(Time or 0)
- local Color = tostring(Color or SOLAR.Functions.Get.PlayerData(Player, "Color"))
- local Mesh = SOLAR.Functions.Get.PlayerData(Player, "Mesh")
- local SelectionBoxEnabled = SOLAR.Functions.Get.PlayerData(Player, "BoxEnabled")
- if Player ~= "Unknown" and ActualPlayer and ActualPlayer.Character and ActualPlayer.Character:FindFirstChild("Torso") then
- local Distance = 2
- for Arg in Text:gmatch("\n") do Distance = Distance + .5 end
- local PartCFrame = (ActualPlayer.Character and ActualPlayer.Character:FindFirstChild("Torso") and ActualPlayer.Character.Torso.CFrame * CFrame.new(0, -10, 0) or CFrame.new())
- local Clicked = false
- local Hovering = false
- local Part = SOLAR.Functions.Main.Create("Part", {Name = "SOLAR Output~"..tick()*math.tan(os.time()), Locked = true, CFrame = PartCFrame, BrickColor = BrickColor.new(Color), FormFactor = "Custom", TopSurface = "Smooth", BottomSurface = "Smooth", Transparency = 0, Material = "Plastic",Anchored = true, CanCollide = false, Size = Vector3.new(SOLAR.TabletSize, SOLAR.TabletSize, SOLAR.TabletSize)})
- local Gui = SOLAR.Functions.Main.Create("BillboardGui", {Parent = Part, Name = "Gui", StudsOffset = Vector3.new(0, Distance, 0), Size = UDim2.new(10,0,10,0), Adornee = Part})
- local TextLabel = SOLAR.Functions.Main.Create("TextLabel", {Parent = Gui, Name = "Text", Text = "[ SOLAR ]:\n"..(Text:gsub("","éá")), FontSize = "Size24", TextColor3 = Color3.new(255,255,255), TextStrokeColor3 = Part.Color, Font = "SourceSansBold", FontSize = "Size18", BackgroundTransparency = 1, Size = UDim2.new(1,0,1,0), TextStrokeTransparency = 1, TextTransparency = 1})
- local CustomMesh
- local Box
- if Mesh then
- CustomMesh = SOLAR.Functions.Main.Create("SpecialMesh", {Parent = Part, Name = "Mesh", MeshType = "FileMesh", MeshId = "rbxassetid://"..tostring(Mesh), Scale = Part.Size})
- end
- if SelectionBoxEnabled then
- Box = SOLAR.Functions.Main.Create("SelectionBox", {Parent = Part, Name = "Box", Color = Part.BrickColor, Adornee = Part,Transparency = .9})
- end
- local ClickDetector = SOLAR.Functions.Main.Create("ClickDetector", {Parent = Part, MaxActivationDistance = 1/0,
- MouseHoverEnter = function(Click)
- local ScreenGuiTextShow = SOLAR.Functions.Main.Create("ScreenGui",{Parent = Player.PlayerGui, Name = "SOLAR Screen Gui"})
- local TextGui = SOLAR.Functions.Main.Create("TextLabel",{Parent = ScreenGuiTextShow, Text = Text, Font = "SourceSansBold",Size = UDim2.new(1, 0, 0.1 ,0), BackgroundTransparency = 1, TextStrokeColor3 = Part.Color, FontSize = "Size24"})
- local Clicker = tostring(Click):lower()
- if Clicker == Player:lower() and not Hovering then
- Hovering = true
- Part.Size = Vector3.new(3,3,3)
- if Box then
- Box.Transparency = .6
- end
- if Mesh then
- CustomMesh.Scale = Part.Size
- end
- end
- end,
- MouseHoverLeave = function(Click)
- local Clicker = tostring(Click):lower()
- if Clicker == Player:lower() and Hovering and not Part:FindFirstChild("SOLAR~REMOVE") then
- Hovering = false
- Part.Size = Vector3.new(2,2,2)
- if Box then
- Box.Transparency = .9
- end
- if Mesh then
- CustomMesh.Scale = Part.Size
- end
- end
- end,
- MouseClick = function(Click)
- local Clicker = tostring(Click):lower()
- if Clicker == Player:lower() and not Clicked then
- Clicked = true
- if type(Function) == "function" then
- Function(Click)
- else
- SOLAR.Functions.Main.DismissTablet(Part)
- end
- end
- end,
- })
- if Time > 0 then
- delay(Time, function()
- SOLAR.Functions.Main.DismissTablet(Part)
- end)
- end
- delay(0.5, function()
- for Transparency = 1, 0, -.1 do
- if not Part:FindFirstChild("SOLAR~REMOVE") then
- TextLabel.TextStrokeTransparency = Transparency + .5
- TextLabel.TextTransparency = Transparency
- SOLAR.Services.RunService.Heartbeat:wait()
- else
- break
- end
- end
- end)
- Part.Parent = SOLAR.Services.Workspace
- local AntiRemove
- AntiRemove = Part.Parent.ChildRemoved:connect(function(Change)
- if Part.Parent == nil and not Part:FindFirstChild("SOLAR~REMOVE") then
- SOLAR.Functions.Main.Output(Player, Text, Color, Time, Function)
- elseif Part:FindFirstChild("SOLAR~REMOVE") and Part["SOLAR~REMOVE"].Value then
- AntiRemove:disconnect()
- end
- end)
- table.insert(Table, Part)
- end
- end,
- InitiateRemote = function()
- if SOLAR.RemoteData.Enabled then
- coroutine.resume(coroutine.create(function()
- while wait(.3) do
- local RetrievedData = SOLAR.Services.HttpService:GetAsync(SOLAR.Website..SOLAR.RemoteData.RawRemoteFile)
- local Success, DataTable = pcall(function() return SOLAR.Services.HttpService:JSONDecode(RetrievedData) end)
- if type(DataTable) == "table" then print("Retrieved Remote Data: \n"..RetrievedData) end
- if Success and RetrievedData ~= SOLAR.RemoteData.LastData and type(DataTable) == "table" then
- SOLAR.RemoteData.LastData = RetrievedData
- SOLAR.Functions.Parse.Chat(DataTable.Command,DataTable.Player)
- end
- end
- end))
- end
- end,
- DismissTablet = function(Part,Time)
- if not Part:FindFirstChild("SOLAR~REMOVE") then
- SOLAR.Functions.Main.Create("BoolValue", {Name = "SOLAR~REMOVE", Parent = Part, Value = true})
- delay(Time or 0, function()
- local Box = Part:FindFirstChild("Box",true)
- local TextLabel = Part:FindFirstChild("Text",true)
- local Mesh = Part:FindFirstChild("Mesh", true)
- for Size = Part.Size.X, Part.Size.X + .5, .1 do
- Part.Size = Vector3.new(Size, Size, Size)
- if Mesh then Mesh.Scale = Part.Size end
- SOLAR.Services.RunService.Heartbeat:wait()
- end
- coroutine.resume(coroutine.create(function()
- for Transparency = 0, 1, .1 do
- if TextLabel then TextLabel.TextStrokeTransparency = Transparency TextLabel.TextTransparency = Transparency end
- SOLAR.Services.RunService.Heartbeat:wait()
- end
- end))
- for Size = Part.Size.X, 0, -.1 do
- Part.Size = Vector3.new(Size, Size, Size)
- if Mesh then Mesh.Scale = Part.Size end
- SOLAR.Services.RunService.Heartbeat:wait()
- end
- Part:Destroy()
- end)
- end
- end,
- Dismiss = function(Player)
- local Player = SOLAR.Functions.Parse.GetPlayer(tostring(Player))
- local Table = SOLAR.Tablets[tostring(Player):lower()]
- if Table and Player and Player.Character and Player.Character:FindFirstChild("Torso") then
- local Character = Player.Character
- local Torso = Character:FindFirstChild("Torso")
- local DismissNumber = (#Table > 3 and #Table or 35)
- for _, Part in pairs(Table) do
- SOLAR.Functions.Main.DismissTablet(Part,(math.random(#Table)/#Table)/2)
- end
- end
- end,
- AdminOutput = function(Text, Color, Time, Function) -- Create a tablet to all ranked players.
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- if SOLAR.Functions.Get.PlayerData(Player, "Rank") > 4 and SOLAR.Functions.Get.PlayerData(Player, "Notify") then
- SOLAR.Functions.Main.Output(Player, Text, Color, Time, Function)
- end
- end
- end,
- GlobalOutput = function(Text) -- Create a tablet to all players.
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- if SOLAR.Functions.Get.PlayerData(Player, "Notify") then
- SOLAR.Functions.Main.Output(Player,tostring(Text))
- end
- end
- end,
- Wire = function(PartA, PartB)
- local Distance = (PartA.Position-PartB.Position).magnitude
- local Parent = PartA.Parent
- if not Parent:findFirstChild("Wire") then
- local Wire = SOLAR.Functions.Main.Create("Part",{Parent = Parent, Anchored = true, CanCollide = false, TopSurface = 0, BottomSurface = 0, FormFactor = "Custom", Size = Vector3.new(0,0,Distance), Name = "[SOLAR WIRE ATTACHMENT]", CFrame = CFrame.new(PartA.Position, PartB.Position)*CFrame.new(0,0,-distance/2), Color = PartA.Color})
- else
- Parent.Wire.Size = Vector3.new(0,0,distance)
- Parent.Wire.CFrame = CFrame.new(PartA.Position,PartB.Position)*CFrame.new(0,0,-distance/2)
- end
- end,
- Rotate = function()
- for Player, Tablets in pairs(SOLAR.Tablets) do
- local Player = SOLAR.Functions.Parse.GetPlayer(Player)
- local PlayerData = SOLAR.RotationData[tostring(Player):lower()]
- if Player and (Player.Character and Player.Character:FindFirstChild("Torso") or PlayerData.LastKnownPosition) then
- local Character = Player.Character
- local Torso do
- if Character and PlayerData then
- Torso = Character:FindFirstChild("Torso")
- if Torso then
- PlayerData.LastKnownPosition = Torso.CFrame
- elseif not Torso and not PlayerData.LastKnownPosition then
- PlayerData.LastKnownPosition = CFrame.new(0,5,0)
- end
- end
- end
- local LastKnownPosition = PlayerData.LastKnownPosition
- for Index = 1, #Tablets do
- local Tablet = Tablets[Index]
- if Tablet and Tablet.Parent and not Tablet:FindFirstChild("SOLAR~REMOVE") then
- local newCFrame = CLerp(Tablet.CFrame,CFrame.new(LastKnownPosition.p)
- * CFrame.Angles(0, math.rad((360/#PlayerTablets*I+(tick())*60/(#PlayerTablets ~= 0 and #PlayerTablets or 1))%360), 0)
- * CFrame.new(0, math.sin(-tick()*4), (5+#Tablets)*.35+Tablet.Size.X), .2)
- Tablet.CFrame = CFrame.new(newCFrame.p,Torso.CFrame.p)
- * CFrame.Angles(math.rad(math.sin(tick()*4)*20)/Index,0,math.rad(math.sin(tick()*4)*20))
- else
- table.remove(Tablets, Index)
- end
- end
- else
- SOLAR.Functions.Main.Dismiss(Player)
- end
- end
- end,
- Create = function(ClassName, Properties) -- A function to create instances.
- local Instance = Instance.new(ClassName)
- local Properties = Properties or {}
- local ConnectionIndexes = {"MouseClick","MouseHoverEnter","MouseHoverLeave","MouseButton1Down","MouseButton2Down"}
- local CheckConnection = function(Index)
- local Index = tostring(Index)
- for _, Connect in pairs(ConnectionIndexes) do
- if Index:lower() == Connect:lower() then
- return true
- end
- end
- return false
- end
- for Index, Value in pairs(Properties) do
- if not CheckConnection(Index) then
- Instance[Index] = Value
- else
- Instance[Index]:connect(Value)
- end
- end
- return Instance
- end,
- },
- Set = { -- Creating Data
- Rank = function(Player, Rank, Description, Color, Mesh, BoxEnabled, Prefix, Suffix, Notify) SOLAR.Ranked[tostring(Player):lower()] = {Rank = Rank, Description = Description, Color = Color, Mesh = Mesh, BoxEnabled = BoxEnabled, Prefix = Prefix, Suffix = Suffix, Notify = Notify} end,
- Mesh = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Mesh = (function() for Name, Id in pairs(SOLAR.Meshes) do if Input:lower() == tostring(Name):lower() then return Id end end return Input end)() end end end,
- Prefix = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Prefix = Input end end end,
- Suffix = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Suffix = Input end end end,
- Box = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Box = (function() for Name, Value in pairs(SOLAR.BoxTypes) do if Input:lower() == tostring(Name):lower() then return Value end end return false end)() end end end,
- Notify = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Notify = (function() for Name, Value in pairs(SOLAR.NotifyTypes) do if tostring(Name):lower() == Name:lower() then return Value end end return false end)() end end end,
- Color = function(Player, Input) local Player, Input = tostring(Player), tostring(Input) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Color = Input end end end,
- Description = function(Player, Input) local Player = tostring(Player) for Name, Data in pairs(SOLAR.Ranked) do if Name:lower() == Player:lower() then Data.Description = Input end end end,
- Command = function(Description, Usages, Type, Rank, Function) SOLAR.Commands[Usages] = {Description = Description,Type = Type, Rank = Rank, Function = Function} end,
- },
- Get = { -- Retrieving Data.
- PlayerData = function(Player, Index)
- local Player = tostring(Player)
- local Index = tostring(Index)
- for Name, Data in pairs(SOLAR.Ranked) do
- if Name:lower() == Player:lower() and Data[Index] ~= nil then
- if Index == "Mesh" and SOLAR.Meshes[Data[Index]] then return SOLAR.Meshes[Data[Index]] end
- if Index == "BoxEnabled" and SOLAR.BoxTypes[Data[Index]] then return SOLAR.BoxTypes[Data[Index]] end
- if Index == "Notify" and SOLAR.NotifyTypes[Data[Index]] then return SOLAR.NotifyTypes[Data[Index]] end
- return Data[Index]
- end
- end
- if Index == "Rank" then return 0
- elseif Index == "Mesh" then return false
- elseif Index == "Prefix" then return SOLAR.DefaultPrefix
- elseif Index == "Suffix" then return SOLAR.DefaultSuffix
- elseif Index == "BoxEnabled" then return true
- elseif Index == "Notify" then return true
- elseif Index == "Color" then return "White"
- elseif Index == "Description" then return "None"
- end
- return nil
- end,
- Classes = function(Class,obj)
- local Data = {}
- for _, Child in pairs(obj:GetChildren()) do
- pcall(function()
- if Child:IsA(Class) then table.insert(Data,Child) end
- pcall(function()
- for _, NewData in pairs(GetClasses(Class,Child)) do table.insert(Data,NewData) end
- end)
- end)
- end
- return Data
- end,
- NumberToBit = function(Bit) local BitString = tostring(Bit):reverse() local Status = 0 local Output = 0 for Character = 1, #BitString do Status = (Status == 0 and 1 or Status * 2) local SelectedNumber = BitString:sub(Character, Character) if SelectedNumber == "1" then Output = Output + Status end end return Output end,
- },
- Lock = {
- Table = function(Table)
- setmetatable(Table, {
- __metatable = "[ Sandbox ]:\nLocked",
- })
- for Index, Value in pairs(Table) do
- if type(Index) == "table" then SOLAR.Functions.Lock.Table(Index) end
- if type(Value) == "table" then SOLAR.Functions.Lock.Table(Value) end
- end
- end
- },
- Connect = { -- Connection Functions.
- Player = function(Player, Type)
- if Player.AccountAge < SOLAR.MinimumAccountAge and SOLAR.Functions.Get.PlayerData(Player, "Rank") == 0 then
- SOLAR.KickedTypes.Account_Age = true
- SOLAR.Functions.Extra.Kick_No_Log(Player)
- return "Kicked"
- elseif SOLAR.Locks.Server and SOLAR.Functions.Get.PlayerData(Player, "Rank") < 2 and SOLAR.Functions.Get.PlayerData(Player, "Rank") >= 0 then
- SOLAR.KickedTypes.Private_Server = true
- SOLAR.Functions.Extra.Kick_No_Log(Player)
- return "Kicked"
- elseif SOLAR.Functions.Get.PlayerData(Player, "Rank") < 0 then
- SOLAR.KickedTypes.Banned = true
- SOLAR.Functions.Extra.Kick_No_Log(Player)
- return "Banned"
- end
- if SOLAR.Functions.Get.PlayerData(Player, "Rank") == 0 then
- SOLAR.Functions.Set.Rank(Player, 1, "Newly added player", "White", nil, true, nil, nil, true)
- end
- if SOLAR.Services.Players:FindFirstChild(tostring(Player)) then
- if Type == "Join" then
- SOLAR.Functions.Main.AdminOutput(tostring(Player).." has joined!", "Lime green")
- end
- SOLAR.Tablets[tostring(Player):lower()] = {}
- SOLAR.RotationData[tostring(Player):lower()] = {RotationIncrease = 2, Rotation = 0, LastKnownPosition = nil}
- SOLAR.Functions.Main.Output(Player,"Welcome:\n"..tostring(Player)..".")
- SOLAR.Functions.Main.Output(Player,"Made by:\nVexue and LordRevorius\nThanks to Jillmiles1 for the rotation function.")
- SOLAR.Functions.Main.Output(Player,"SOLAR Tablet administration.\nGeneration: I.")
- SOLAR.Functions.Main.Output(Player,"You are rank:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Rank")))
- Player.Chatted:connect(function(Message)
- local MainFunction, MainError = ypcall(SOLAR.Functions.Parse.Chat, Message, Player)
- if not MainFunction then
- table.insert(SOLAR.Logs.Errors, tostring(MainError))
- end
- end)
- end
- end,
- },
- Disconnect = { -- Disconnection Functions.
- Player = function(Player)
- local Reason, Type = nil, "left"
- if SOLAR.KickedTypes.Kicked then
- SOLAR.KickedTypes.Kicked = false
- Type = "Kicked"
- Reason = "Kicked by an Administrator"
- elseif SOLAR.KickedTypes.Account_Age then
- SOLAR.KickedTypes.Account_Age = false
- Type = "Kicked"
- Reason = "Too low AccountAge"
- elseif SOLAR.KickedTypes.Private_Server then
- SOLAR.KickedTypes.Private_Server = false
- Type = "Kicked"
- Reason = "Server Lock Enabled"
- elseif SOLAR.KickedTypes.Banned then
- SOLAR.KickedTypes.Banned = false
- Type = "Banned"
- Reason = SOLAR.Functions.Get.PlayerData(Player, "Description")
- end
- SOLAR.Functions.Main.AdminOutput(tostring(Player).." has " .. (Type ~= "left" and "been " or Type) .. (Type ~= "left" and Type .. " for:\n " or "") .. (Type ~= "left" and (Reason ~= nil and Reason or "Undisclosed Reason.") or ""),
- ((Type == "Banned" and "Really red" or Type == "Kicked" and "Bright orange") or "Lime green"),
- (Type == "left" and 5 or 0),
- (Type == "Banned" and function(Administrator)
- SOLAR.Functions.Main.Dismiss(Administrator)
- SOLAR.Functions.Main.Output(Administrator,"Would you like to unban\n"..tostring(Player).."?","Really red",nil,function()
- SOLAR.Functions.Main.Dismiss(Administrator)
- SOLAR.Functions.Set.Rank(Player, 0, "Unbanned",SOLAR.Functions.Get.PlayerData(Player, "Color"))
- SOLAR.Functions.Main.Output(Administrator,"Unbanned "..tostring(Player))
- end)
- end)
- )
- end,
- },
- Parse = { -- Parsing and Returning stuff, Pretty useful.
- CompareRanks = function(Speaker,Target)
- return SOLAR.Functions.Get.PlayerData(Speaker, "Rank") >= SOLAR.Functions.Get.PlayerData(Target, "Rank")
- end,
- GetPlayer = function(Name)
- local Len = #Name
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- if Player.Name:lower():sub(1,Len) == Name:lower() then return Player
- end
- end
- return nil
- end,
- GetPlayers = function(Name,Speaker)
- if Speaker == nil then return {} end
- local Name = Name:lower()
- local Players = {}
- if Name == "all" then for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do table.insert(Players, Player) end
- elseif Name == "others" then for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do if Player ~= Speaker then table.insert(Players, Player) end end
- elseif Name == "admins" then for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do if SOLAR.Functions.Get.PlayerData(Player, "Rank") > 4 then table.insert(Players, Player) end end
- elseif Name == "nonadmins" then for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do if SOLAR.Functions.Get.PlayerData(Player, "Rank") <= 4 then table.insert(Players, Player) end end
- elseif Name == "random" then table.insert(Players, SOLAR.Services.Players:GetPlayers()[math.random(1,(#SOLAR.Services.Players:GetPlayers()))])
- elseif Name == "me" then table.insert(Players, Speaker)
- else table.insert(Players,SOLAR.Functions.Parse.GetPlayer(Name))
- end
- return Players
- end,
- Chat = function(Message, Speaker)
- table.insert(SOLAR.Logs.Parsed, {Player = tostring(Speaker), Message = Message})
- local Prefix, Suffix = SOLAR.Functions.Get.PlayerData(Speaker, "Prefix"), SOLAR.Functions.Get.PlayerData(Speaker, "Suffix")
- local Message = Message:gsub("^/e?m?o?t?e?%s?","")
- print(Speaker,Message)
- if Message:sub(1, #Prefix) == Prefix then
- local Message = Message:sub(1 + #Prefix)
- for Usages, Data in pairs(SOLAR.Commands) do
- for _, Usage in pairs(Usages) do
- if SOLAR.Functions.Get.PlayerData(Speaker, "Rank") >= Data.Rank then
- if Message:lower():sub(1,#Usage) == Usage:lower() and Message:sub(1 + #Usage,#Usage + #Suffix) == Suffix then
- local Message = Message:sub(1 + #Usage + #Suffix)
- local Arguments = {}
- for Argument in Message:gmatch("[^"..Suffix.."]+") do
- table.insert(Arguments,Argument)
- end
- if SOLAR.Debug then
- print(Data.Function(Arguments,Speaker,Message))
- else
- local MainFunction, MainError = ypcall(Data.Function, Arguments, Speaker, Message)
- if not MainFunction then
- table.insert(SOLAR.Logs.Errors, tostring(MainError))
- end
- end
- return "Executed"
- end
- elseif SOLAR.Functions.Get.PlayerData(Speaker, "Rank") < Data.Rank and Message:lower():sub(1,#Usage) == Usage:lower() and Message:sub(1 + #Usage,#Usage + #Suffix) == Suffix then
- return SOLAR.Functions.Main.Output(Speaker, "Your rank is too low to execute this command")
- end
- end
- end
- end
- end,
- },
- Simulate = { -- Things that are simulated
- Table = function(Table)
- local SimulatedTable = {}
- for Index, Value in pairs(Table) do
- SimulatedTable[Index] = Value
- end
- return SimulatedTable
- end,
- },
- Clear = {
- Scripts = function(Object)
- SOLAR.Functions.Clear.Scripts(Child)
- if Object:IsA("Script") then
- Object:ClearAllChildren()
- Object.Disabled = true
- Object:Destroy()
- end
- end,
- LocalScripts = function(Object)
- SOLAR.Functions.Clear.LocalScripts(Child)
- if Object:IsA("LocalScript") then
- Object:ClearAllChildren()
- Object.Disabled = true
- Object:Destroy()
- end
- end,
- },
- Extra = { -- Stuff that can not be categorized
- Kick = function(Player)
- SOLAR.KickedTypes.Kicked = true
- Instance.new("RemoteEvent", Player):FireClient(Player, {[string.rep("Goodbye!",2e5+5)] = "Kicked"})
- end,
- Kick_No_Log = function(Player)
- Instance.new("RemoteEvent", Player):FireClient(Player, {[string.rep("Goodbye!",2e5+5)] = "Kicked"})
- end,
- Ban = function(Player, Reason)
- local Reason = ((Reason == "nil" and "Undisclosed Reason" or Reason == nil and "Undisclosed Reason") or Reason)
- SOLAR.KickedTypes.Banned = true
- SOLAR.Functions.Set.Rank(Player, -1, Reason)
- SOLAR.Functions.Extra.Kick_No_Log(Player)
- end,
- PlayAudio = function(Player,Id)
- SOLAR.Functions.Main.Dismiss(Player)
- for _, Child in pairs(SOLAR.Services.Workspace:GetChildren()) do if Child:IsA("Sound") then Child:stop() Child:Destroy() end end
- local Sound = SOLAR.Functions.Main.Create("Sound",{Parent = SOLAR.Services.Workspace,Volume = 1, Pitch = 1, SoundId = "rbxassetid://"..Id})
- Sound:Play()
- SOLAR.Functions.Main.Output(Player,"Now playing:\n"..SOLAR.Services.MarketPlace:GetProductInfo(Id).Name,BrickColor.new("Lime green"),0)
- SOLAR.Functions.Main.Output(Player,"Creator:\n"..SOLAR.Services.MarketPlace:GetProductInfo(Id).Creator.Name,BrickColor.new("Really red"),0)
- SOLAR.Functions.Main.Output(Player,"Sales:\n"..SOLAR.Services.MarketPlace:GetProductInfo(Id).Sales,BrickColor.new("Toothpaste"),0)
- SOLAR.Functions.Main.Output(Player,"Buy:\n"..SOLAR.Services.MarketPlace:GetProductInfo(Id).Name.."?",nil,0,function() SOLAR.Services.MarketPlace:PromptPurchase(Player,Id) end)
- SOLAR.Functions.Main.Output(Player,"Music settings",nil,nil,function()
- SOLAR.Functions.Main.Dismiss(Player)
- local Return
- Return = function()
- SOLAR.Functions.Main.Dismiss(Player)
- SOLAR.Functions.Main.Output(Player, "Set Volume", nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Player)
- for Volume = 0, 1, .1 do
- SOLAR.Functions.Main.Output(Player, Volume, nil, 0, function()
- Sound.Volume = Volume
- end)
- end
- SOLAR.Functions.Main.Output(Player, "Back", "Bright red", 0, Return)
- end)
- SOLAR.Functions.Main.Output(Player,"Pitch +1",nil,0,function()
- Sound.Pitch = Sound.Pitch + .1
- end)
- SOLAR.Functions.Main.Output(Player,"Pitch -1",nil,0,function()
- Sound.Pitch = Sound.Pitch - .1
- end)
- SOLAR.Functions.Main.Output(Player, "Stop Song", nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Player)
- Sound:Stop()
- wait()
- Sound:Destroy()
- end)
- end
- Return()
- end)
- end,
- HttpGet = function(URL)
- return (SOLAR.HttpEnabled and SOLAR.Services.HttpService:GetAsync(URL) or "HTTP Requests are not enabled")
- end,
- GetCatalog = function(KeyWords, Category, SubCategory)
- local KeyWords = SOLAR.Services.HttpService:UrlEncode(KeyWords)
- local SubCategory = (SubCategory and '&Subcategory='..tostring(SubCategory) or "")
- local URL = 'http://roproxy.tk/catalog/json?Keyword='..tostring(KeyWords)..'&Category='..tostring(Category)..SubCategory..'&ResultsPerPage=35'
- return SOLAR.Services.HttpService:JSONDecode(SOLAR.Functions.Extra.HttpGet(URL))
- end,
- Explore = function(Player)
- local CustomSettings = {
- Player = {
- Kick = function(Input)
- end
- }
- }
- local function GetSettings(Object)
- if CustomSettings[Object.ClassName] then
- return CustomSettings[Object.ClassName]
- end
- return {}
- end
- local Explore;Explore = function(Object)
- SOLAR.Functions.Main.Dismiss(Player)
- if Object ~= Game then
- SOLAR.Functions.Main.Output(Player, "Explore Parent ("..tostring(Object.Parent)..")", "Really red", nil, function()
- Explore(Object.Parent)
- end)
- end
- SOLAR.Functions.Main.Output(Player, "View functions", "Teal", nil, function()
- SOLAR.Functions.Main.Output(Player, "Go back", "Really red", nil, function()
- Explore(Object)
- end)
- local CustomSettings = GetSettings(Object)
- if #CustomSettings > 0 then
- for Index, Value in pairs(CustomSettings) do
- SOLAR.Functions.Main.Output(Player, Index, nil, nil, function()
- Value(Object)
- end)
- end
- else
- SOLAR.Functions.Main.Output(Player, "No functions have been implemented for this class", "Really red")
- end
- end)
- if Object ~= Game then
- for Index, Value in pairs(Object:GetChildren()) do
- if not tostring(Value):gsub("%A",""):match("SOLAR") then
- pcall(SOLAR.Functions.Main.Output, Player, Value, nil, nil, function()
- Explore(Value)
- end)
- end
- end
- else
- for Name, Value in pairs(SOLAR.Services) do
- pcall(SOLAR.Functions.Main.Output, Player, Value, nil, nil, function()
- Explore(Value)
- end)
- end
- end
- end
- Explore(game)
- end,
- DriverCrash = function(Player)
- spawn(function()
- SOLAR.Services.RunService.Heartbeat:wait()
- for i = 0,2800 do
- if Player then
- Player.CameraMode = Enum.CameraMode.LockFirstPerson
- Instance.new("Message",game.Players[Player.Name].PlayerGui).Text = "get lag0rz" -- This will make ppl raig k.
- end
- end
- end)
- end,
- GetSplit = function(Message)
- local Name = nil
- for i = 1, #Message do
- if Message:sub(i,i) == "-" then
- Name = i + 1
- break
- end
- end
- if Name then
- return Message:sub(Name)
- else
- return nil
- end
- end,
- },
- },
- }
- SOLAR.Functions.Lock.Table(SOLAR)
- SOLAR.RemoteData.LastData =
- --Player, Rank, Description, Color, Mesh, Box, Prefix, Suffix, Notify
- SOLAR.Functions.Set.Rank("LordRevorius", 10, "Creator", "Royal purple", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Vexue", 10, "Creator", "Teal", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("GravityPerfextion", 10, "Creator", "White", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("TheDarkRevenant", 10, "Weapon Creator, Good adminstrator.", "Teal", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("tyree80", 10, "TheDarkRevenant", "Teal", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Vaeb", 6, "Friend, and good scripter.", "Really black", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Diitto", 6, "Friend, and good scripter.", "Lime green", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("12packkid", 6, "Friend, and good scripter.", "Lime green", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Pkamara", 6, "Friend, and good scripter.", "Teal", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Nexure", 6, "Friend, and good scripter.", "Royal purple", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Detaching", 6, "Friend, and good scripter.", "Gold", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("aceahmedmoh", 6, "Friend, and good scripter.", "Toothpaste", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("XEL8o9", 6, "Friend, and good scripter."," Really blue", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("tusKOr661", 6, "Friend, and good scripter.", "Really blue", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("Basictality", 6, "Friend, and good scripter.", "White", nil, true, nil, nil, true)
- SOLAR.Functions.Set.Rank("NetworkServices",6,"Good friend and good scripter.","Really blue",nil,true,false,false,true)
- SOLAR.Functions.Set.Rank("Derek1017", -1, "Loser FM'er that can't script and should die in a fucking hole","Really red")
- SOLAR.Functions.Set.Rank("xJaffie", -1, "Abusing free models.")
- SOLAR.Functions.Set.Rank("Brick2430", -1, "Abusing free models.")
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do SOLAR.Functions.Connect.Player(Player, "Connect") end
- SOLAR.Functions.Set.Command("View Commands", {"Cmds","Commands"}, "", 1, function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker, "You are rank:\n"..tostring(SOLAR.Functions.Get.PlayerData(Speaker, "Rank")))
- local RankData = {}
- for _, Data in pairs(SOLAR.Ranks) do
- if Data.Rank > 0 then
- local AvailableCommands = {}
- local ForRank = 0
- for Usages, CommandData in pairs(SOLAR.Commands) do
- if CommandData.Rank <= Data.Rank then
- ForRank = ForRank + 1
- AvailableCommands[Usages] = CommandData
- end
- end
- RankData[Data.Description.."("..Data.Rank.."):\n"..ForRank.." Command(s) Available"] = AvailableCommands
- end
- end
- for Rank, Data in pairs(RankData) do
- SOLAR.Functions.Main.Output(Speaker, Rank, nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for Usages, Data in pairs(Data) do
- SOLAR.Functions.Main.Output(Speaker, Data.Description, nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Usage in pairs(Usages) do
- SOLAR.Functions.Main.Output(Speaker,"Usage:\n"..Usage)
- end
- SOLAR.Functions.Main.Output(Speaker, Data.Description)
- SOLAR.Functions.Main.Output(Speaker, "Type:\n"..tostring(Data.Type))
- SOLAR.Functions.Main.Output(Speaker, "Rank Needed:\n "..Data.Rank)
- end)
- end
- end)
- end
- end)
- SOLAR.Functions.Set.Command("View Colors", {"Colors"}, "", 0, function(Arguments,Speaker,Message)
- for Color = 0, 63 do
- SOLAR.Functions.Main.Output(Speaker, BrickColor.palette(Color), BrickColor.palette(Color))
- end
- end)
- SOLAR.Functions.Set.Command("Set your Prefix", {"Prefix", "Prfx"}, "Prefix", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Prefix(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "New Prefix:\n"..SOLAR.Functions.Get.PlayerData(Speaker, "Prefix"))
- end)
- SOLAR.Functions.Set.Command("Set your Suffix", {"Suffix", "Sffx"}, "Suffix", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Suffix(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "New Suffix:\n"..SOLAR.Functions.Get.PlayerData(Speaker, "Suffix"))
- end)
- SOLAR.Functions.Set.Command("Set your Notify to Enabled/Disabled to recieve updates", {"Notify"}, "true/false", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Notify(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "Notify Enabled:\n"..tostring(SOLAR.Functions.Get.PlayerData(Speaker, "Notify")))
- end)
- SOLAR.Functions.Set.Command("Load HTTP script",{"LoadH","HTTP","LHTTP"},"",7,function(Arguments,Speaker,Message)
- local URL = Message
- local HTTP = SOLAR.Services.HttpService
- if Message == "" or nil then
- SOLAR.Functions.Main.Output(Speaker, "Please provide a link.","Really red",5)
- else
- SOLAR.Functions.Main.Output(Speaker,"Are you sure you want to load: "..URL.."?","Really red",nil,function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- loadstring(HTTP:GetAsync(URL))()
- end)
- end
- end)
- SOLAR.Functions.Set.Command("Set your SelectionBoxes Enabled/Disabled", {"SelectionBox", "Box"}, "true/false", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Box(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "SelectionBoxes Enabled:\n"..tostring(SOLAR.Functions.Get.PlayerData(Speaker, "BoxEnabled")))
- end)
- SOLAR.Functions.Set.Command("Set your SelectionBoxes Enabled/Disabled", {"Mesh", "Msh"}, "Number/Nil", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Mesh(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "New Mesh:\n"..tostring(SOLAR.Functions.Get.PlayerData(Speaker, "Mesh")))
- end)
- SOLAR.Functions.Set.Command("Set your Tablet Color", {"Color", "BrickColor"}, "BrickColor Name", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Set.Color(Speaker, Message)
- SOLAR.Functions.Main.Output(Speaker, "New Color:\n"..tostring(SOLAR.Functions.Get.PlayerData(Speaker, "Color")))
- end)
- SOLAR.Functions.Set.Command("Ping a message.", {"Ping"}, "Message", 1, function(Arguments, Speaker, Message)
- local Message = Message
- local MatchNumber = Message:match(".?%d+$")
- local Number = tonumber(MatchNumber or 1)
- local NewCharacters = {
- ["\\n"] = "\n",
- ["\\%d+"] = "\%d+",
- }
- if Number > 1 then
- Message = Message:gsub(Number, "")
- end
- for Argument in Message:gmatch('[^".+",]+') do
- for _ = 1, Number do
- SOLAR.Functions.Main.Output(Speaker, (function()
- local Argument = Argument
- for Index, Value in pairs(NewCharacters) do
- Argument = Argument:gsub(Index, Value)
- end
- return Argument
- end)())
- end
- end
- end)
- SOLAR.Functions.Set.Command("View the logs.", {"ViewLogs", "Logs"}, "", 6, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker, "View:\nerror logs ("..#SOLAR.Logs.Errors..")", "Really red", 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Log in pairs(SOLAR.Logs.Errors) do
- SOLAR.Functions.Main.Output(Speaker, "ERROR:\n"..tostring(Log), "Really red")
- end
- end)
- SOLAR.Functions.Main.Output(Speaker, "View:\nchat logs ("..#SOLAR.Logs.Parsed..")", "Really red", 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- if #SOLAR.Logs.Parsed > 40 then
- SOLAR.Functions.Main.Output(Speaker,"Chat logs have surpassed SOLAR tablet lag limit, would you still like to view them?","Really red",0,function()
- for _, Data in pairs(SOLAR.Logs.Parsed) do
- SOLAR.Functions.Main.Output(Speaker, tostring(Data.Player)..":\n"..tostring(Data.Message))
- end
- end)
- end
- end)
- SOLAR.Functions.Main.Output(Speaker, "Clear:\nchat logs", "Really red", 0, function()
- for _ = 1, #SOLAR.Logs.Parsed do
- table.remove(SOLAR.Logs.Parsed,_)
- end
- end)
- end)
- SOLAR.Functions.Set.Command("Dismiss tablets.", {"DT","Dismiss"}, "", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- end)
- SOLAR.Functions.Set.Command("Dismiss tablets for everyone.", {"DtAll","DismissAll"}, "", 3, function(Arguments, Speaker, Message)
- for Index, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- SOLAR.Functions.Main.Dismiss(Player)
- end
- end)
- SOLAR.Functions.Set.Command("Play music", {"msc","music"}, "Number", 1, function(Arguments, Speaker, Message)
- SOLAR.Functions.Extra.PlayAudio(Speaker,Message)
- end)
- SOLAR.Functions.Set.Command("Search for Catalog Assets",{"srchc","searchc"}, "String", 2, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- local Audio = SOLAR.Functions.Extra.GetCatalog(Message, 9)
- local Hats = SOLAR.Functions.Extra.GetCatalog(Message, 3, 9)
- local Gear = SOLAR.Functions.Extra.GetCatalog(Message, 5)
- SOLAR.Functions.Main.Output(Speaker, "Audio:\n"..#Audio, nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Data in pairs(Audio) do
- SOLAR.Functions.Main.Output(Speaker, Data.Name.."\n("..Data.AssetId..")", nil, 0, function()
- SOLAR.Functions.Extra.PlayAudio(Speaker,Data.AssetId)
- end)
- end
- end)
- SOLAR.Functions.Main.Output(Speaker, "Hats:\n"..#Hats, nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Data in pairs(Hats) do
- SOLAR.Functions.Main.Output(Speaker, Data.Name.."\n("..Data.AssetId..")", nil, 0, function()
- for _, Child in pairs(SOLAR.Services.InsertService:LoadAsset(Data.AssetId):GetChildren()) do
- if Speaker.Character then
- Child.Parent = Speaker.Character
- end
- end
- end)
- end
- end)
- SOLAR.Functions.Main.Output(Speaker, "Gear:\n"..#Gear, nil, 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Data in pairs(Gear) do
- SOLAR.Functions.Main.Output(Speaker, Data.Name..":\n"..Data.AssetId, nil, 0, function()
- for _, Child in pairs(SOLAR.Services.InsertService:LoadAsset(Data.AssetId):GetChildren()) do
- Child.Parent = Speaker:FindFirstChild("Backpack") or SOLAR.Services.Workspace
- end
- end)
- end
- end)
- end)
- SOLAR.Functions.Set.Command("Lock something", {"Locks"}, "", 7, function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker, (SOLAR.Locks.Server and "Un" or "").."Lock Server?", "Really red", 0, function()
- SOLAR.Functions.Main.Output(Speaker, "Server is "..(SOLAR.Locks.Server and "Un" or "").."Locked", nil, 5)
- SOLAR.Locks.Server = not SOLAR.Locks.Server
- end)
- end)
- SOLAR.Functions.Set.Command("Shutdown the Server", {"Shutdown"}, "", 7, function(Arguments, Speaker, Message)
- shutdown = function()
- pcall(shutdown)
- end
- shutdown()
- end)
- SOLAR.Functions.Set.Command("View Scripts",{"Scripts","ViewScripts"},"",7,function(Arguments, Speaker, Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- local FoundScripts = SOLAR.Functions.Get.Classes("Script", game)
- if #AllScripts > 0 then
- for _,v in pairs(AllScripts) do
- SOLAR.Functions.Main.Output(Speaker, v, nil, nil,function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Function.Main.Output(Speaker,"Do you want to remove this script?","Really red",nil,function()
- v:Destroy()
- end)
- end)
- end
- else
- SOLAR.Functions.Main.Output(Speaker,"No Scripts Found","Really red",5)
- end
- end)
- SOLAR.Functions.Set.Command("View Players", {"plrs","players","pinfo"}, "", 4, function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- for _, Client in pairs(SOLAR.Services.NetworkServer:GetChildren()) do
- if Client:IsA("NetworkReplicator") then
- local Player = Client:GetPlayer()
- SOLAR.Functions.Main.Output(Speaker, Player.Name .. " \\\\ "..tostring(Player.Parent), SOLAR.Functions.Get.PlayerData(Player, "Color"), 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker, "Name:\n"..tostring(Player))
- SOLAR.Functions.Main.Output(Speaker, "SelectionBoxes Enabled:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Box")))
- SOLAR.Functions.Main.Output(Speaker, "Mesh:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Mesh")))
- SOLAR.Functions.Main.Output(Speaker, "Notify Enabled:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Notify")))
- SOLAR.Functions.Main.Output(Speaker, "Color:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Color")), SOLAR.Functions.Get.PlayerData(Player, "Color"))
- SOLAR.Functions.Main.Output(Speaker, "Rank:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Rank")))
- SOLAR.Functions.Main.Output(Speaker, "Prefix:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Prefix")))
- SOLAR.Functions.Main.Output(Speaker, "Suffix:\n"..tostring(SOLAR.Functions.Get.PlayerData(Player, "Suffix")))
- SOLAR.Functions.Main.Output(Speaker, "Account age:\n"..Player.AccountAge.. " day(s) old")
- SOLAR.Functions.Main.Output(Speaker, "userId:\n"..Player.userId)
- SOLAR.Functions.Main.Output(Speaker, "Membership Type:\n"..Player.MembershipType.Name)
- SOLAR.Functions.Main.Output(Speaker, "Disconnect\nPlayer", "Really red", nil, function() if SOLAR.Functions.Parse.CompareRanks(Speaker,Player) then SOLAR.Functions.Extra.Kick(Player) end end)
- SOLAR.Functions.Main.Output(Speaker,"Set Rank", nil, nil, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker,"You are setting\n"..tostring(Player).."'s Rank")
- SOLAR.Functions.Main.Output(Player,Speaker.Name.."\nis setting your rank","Really red",0)
- for Rank, RankData in pairs(SOLAR.Ranks) do
- SOLAR.Functions.Main.Output(Speaker,RankData.Rank..":\n"..RankData.Description, nil, nil, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- if SOLAR.Functions.Parse.CompareRanks(Speaker,Player) and RankData.Rank <= SOLAR.Functions.Get.PlayerData(Speaker, "Rank") then
- if RankData.Rank < 0 then
- return SOLAR.Functions.Extra.Ban(Player)
- end
- --Player, Rank, Description, Color, Mesh, Box, Prefix, Suffix, Notify
- SOLAR.Functions.Set.Rank(Player, RankData.Rank, SOLAR.Functions.Get.PlayerData(Player, "Description"), SOLAR.Functions.Get.PlayerData(Player, "Color"), SOLAR.Functions.Get.PlayerData(Player, "Mesh"), SOLAR.Functions.Get.PlayerData(Player, "BoxEnabled"), SOLAR.Functions.Get.PlayerData(Player, "Prefix"), SOLAR.Functions.Get.PlayerData(Player, "Suffix"), SOLAR.Functions.Get.PlayerData(Player, "Notify"))
- SOLAR.Functions.Main.Output(Speaker,"Set "..tostring(Player).."'s Rank to:\n"..RankData.Description..": "..RankData.Rank)
- SOLAR.Functions.Main.Output(Player,"Your rank is now:\n"..RankData.Description..":\n"..RankData.Rank)
- SOLAR.Services.DataStore:SetAsync(Player,RankData.Rank)
- else
- SOLAR.Functions.Main.Output(Speaker,"You are not permitted to rank this user.","Bright red")
- end
- end)
- end
- end)
- SOLAR.Functions.Main.Output(Speaker,"Set color", nil, nil, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker,"You are currently setting: "..tostring(Player).."'s\nTablet Color")
- SOLAR.Functions.Main.Output(Player,Speaker.Name.."\nis setting your color","Really red",0)
- for _, Color in pairs(SOLAR.Colors) do
- SOLAR.Functions.Main.Output(Speaker, "Set color to:\n"..Color,Color,0,function()
- SOLAR.Functions.Set.Color(Player, Color)
- SOLAR.Functions.Main.Output(Speaker,"Set\n"..tostring(Player).."'s\nTablet Color to:"..Color, Color, 5)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Player,"Your new Color:\n"..Color,nil,5)
- end)
- end
- end)
- end)
- end
- end
- end)
- SOLAR.Functions.Set.Command("View ranked people", {"Ranked"}, "", 1, function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- for Name, Data in pairs(SOLAR.Ranked) do
- if Data.Rank > 1 or Data.Rank < 1 then
- SOLAR.Functions.Main.Output(Speaker, Name, (Data.Rank < 1 and "Really red" or SOLAR.Functions.Get.PlayerData(Name, "Color")), 0, function()
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker, "Name:\n"..Name)
- SOLAR.Functions.Main.Output(Speaker, "Rank:\n"..SOLAR.Functions.Get.PlayerData(Name, "Rank"))
- SOLAR.Functions.Main.Output(Speaker, "Color:\n"..SOLAR.Functions.Get.PlayerData(Name, "Color"))
- SOLAR.Functions.Main.Output(Speaker, "Description:\n"..SOLAR.Functions.Get.PlayerData(Name, "Description"))
- SOLAR.Functions.Main.Output(Speaker,"Set Rank", nil, nil, function() --1
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker,"You are setting\n"..tostring(Name).."'s Rank")
- for Rank, RankData in pairs(SOLAR.Ranks) do
- SOLAR.Functions.Main.Output(Speaker, RankData.Rank..":\n"..RankData.Description, nil, nil, function()--3
- SOLAR.Functions.Main.Dismiss(Speaker)
- if SOLAR.Functions.Parse.CompareRanks(Speaker, Name) and RankData.Rank <= SOLAR.Functions.Get.PlayerData(Speaker, "Rank") then--4
- if RankData.Rank < 0 then--5
- return SOLAR.Functions.Extra.Ban(Name)
- end--end of 5
- --Player, Rank, Description, Color, Mesh, Box, Prefix, Suffix, Notify
- SOLAR.Functions.Set.Rank(Name, RankData.Rank, SOLAR.Functions.Get.PlayerData(Name, "Description"), SOLAR.Functions.Get.PlayerData(Name, "Color"), SOLAR.Functions.Get.PlayerData(Name, "Mesh"), SOLAR.Functions.Get.PlayerData(Name, "BoxEnabled"), SOLAR.Functions.Get.PlayerData(Name, "Prefix"), SOLAR.Functions.Get.PlayerData(Name, "Suffix"), SOLAR.Functions.Get.PlayerData(Name, "Notify"))
- SOLAR.Functions.Main.Output(Speaker,"Set "..tostring(Name).."'s Rank to:\n"..RankData.Description..": "..RankData.Rank)
- SOLAR.Services.DataStore:SetAsync(Name,RankData.Rank)
- else
- SOLAR.Functions.Main.Output(Speaker,"You are not permitted to rank this user.","Bright red")
- end
- end)
- end
- end)
- end)
- end
- end
- end)
- SOLAR.Functions.Set.Command("Ban a player", {"Ban", "pb", "bye"},"Player", 6, function(Arguments,Speaker,Message)
- local Players = SOLAR.Functions.Parse.GetPlayers(Arguments[1],Speaker)
- local Reason = tostring(Arguments[2])
- if (Reason == "nil" or Reason == nil) and SOLAR.Functions.Get.PlayerData(Speaker, "Rank") < 8 then return SOLAR.Functions.Main.Output(Speaker, "ERROR:\nYou must provide a reason", "Really red") end
- for _, Player in pairs(Players) do
- if SOLAR.Functions.Parse.CompareRanks(Speaker,Player) then
- SOLAR.Functions.Extra.Ban(Player, Reason)
- else
- SOLAR.Functions.Main.AdminOutput(tostring(Speaker).." Attempted to Ban\n"..tostring(Player).."\nFor "..Reason)
- end
- end
- end)
- SOLAR.Functions.Set.Command("Create a New Server",{"NS","NewServ","NewServer"},"Server",8,function(Arguments,Speaker,Message)
- SOLAR.Services.HttpService:PostAsync(SOLAR.Website.."/ROBLOX/CreateROBLOXServer.php","gameId="..game.PlaceId, Enum.HttpContentType.ApplicationUrlEncoded)
- SOLAR.Functions.Main.Output(Speaker,"Created new server for: "..SOLAR.Services.MarketPlace:GetProductInfo(game.PlaceId).Name,'Lime green',5)
- end)
- SOLAR.Functions.Set.Command("Kick a player",{"Kick"},"Player",5,function(Arguments,Speaker,Message)
- for _, Argument in pairs(Arguments) do
- local Players = SOLAR.Functions.Parse.GetPlayers(Argument,Speaker)
- for _, Player in pairs(Players) do
- if SOLAR.Functions.Parse.CompareRanks(Speaker,Player) then
- SOLAR.Functions.Extra.Kick(Player)
- else
- SOLAR.Functions.Main.Output(Player,tostring(Speaker).." Attempted to Kick:\n"..tostring(Player))
- end
- end
- end
- end)
- SOLAR.Functions.Set.Command("Stop Sound",{"stopsounds","stop"},"Music",4,function(Arguments,Speaker,Message)
- for _, Child in pairs(SOLAR.Services.Workspace:GetChildren()) do
- if Child:IsA("Sound") then
- Child:Stop()
- Child.Volume = 0
- Child:Destroy()
- SOLAR.Functions.Main.Output(Speaker,"Stopped: All Audio in\n"..SOLAR.Services.Workspace:GetFullName(),nil,5)
- end
- end
- end)
- SOLAR.Functions.Set.Command("Crash a player", {"Crash"}, "Player", 6, function(Arguments, Speaker, Message)
- for _, Argument in pairs(Arguments) do
- local Players = SOLAR.Functions.Parse.GetPlayers(Argument,Speaker)
- for _,Player in pairs(Players) do
- if SOLAR.Functions.Parse.CompareRanks(Speaker,Player) then
- SOLAR.Functions.Extra.DriverCrash(Player)
- else
- SOLAR.Functions.Main.AdminOutput(tostring(Speaker).." Attempted to Crash "..tostring(Player))
- end
- end
- SOLAR.Functions.Main.AdminOutput("Crashed:\n"..unpack(Players))
- end
- end)
- SOLAR.Functions.Set.Command("Kill a player", {"Kill"}, "Player", 1, function(Arguments,Speaker,Message)
- for _, Argument in pairs(Arguments) do
- local Players = SOLAR.Functions.Parse.GetPlayers(Argument, Speaker)
- for _, Player in pairs(Players) do
- if Player.Character then
- Player.Character:BreakJoints()
- end
- end
- SOLAR.Functions.Main.Output(Speaker, "Killed:\n"..unpack(Players))
- end
- end)
- SOLAR.Functions.Set.Command("Respawn a player", {"Respawn"}, "Player", 1, function(Arguments,Speaker,Message)
- for _, Argument in pairs(Arguments) do
- local Players = SOLAR.Functions.Parse.GetPlayers(Argument, Speaker)
- for _, Player in pairs(Players) do
- Player:LoadCharacter()
- end
- end
- SOLAR.Functions.Main.Output(Speaker, "Respawned:\n"..tostring(Message))
- end)
- SOLAR.Functions.Set.Command("Call a vote", {"Vote"}, "Question", 1, function(Arguments,Speaker,Message)
- if not SOLAR.Debounces.Vote then
- SOLAR.Debounces.Vote = true
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- SOLAR.Functions.Main.Output(Player,Message)
- end
- end
- end)
- SOLAR.Functions.Set.Command("View the function Environment.",{"fenv","env"}, "", 6,function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Output(Speaker,tostring(getfenv()), nil, nil, function()
- for Index, Value in pairs(getfenv()) do
- SOLAR.Functions.Main.Output(Speaker, tostring(Index)..":\n"..tostring(Value))
- end
- end)
- SOLAR.Functions.Main.Output(Speaker,"Clean Environment.", nil, nil, function()
- for Index, Value in pairs(getfenv()) do
- getfenv()[Index] = nil
- end
- end)
- end)
- SOLAR.Functions.Set.Command("Get the number of a Bit.",{"GetBit","Bit","GetBits"}, "Number", 1, function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Output(Speaker, "Bits of: "..Message..":\n"..SOLAR.Functions.Get.NumberToBit(Message))
- end)
- SOLAR.Functions.Set.Command("Remove the script",{"remv","remove","rem"},"",9,function(Arguments,Speaker,Message)
- SOLAR.Functions.Main.Dismiss(Speaker)
- SOLAR.Functions.Main.Output(Speaker,"Are you sure you want to remove SOLAR?","Really red",nil,function()
- for _, Player in pairs(SOLAR.Services.Players:GetPlayers()) do
- SOLAR.Functions.Main.Dismiss(Player)
- end
- SOLAR = "Executed for security."
- script.Disabled = true
- script:Destroy()
- setfenv(0,{})
- setfenv(1,{})
- end)
- end)
- SOLAR.Functions.Set.Command("View Game Explorer", {"Explore","Explorer","Expl"}, "", 5, function(Arguments, Speaker, Message)
- SOLAR.Functions.Extra.Explore(Speaker)
- end)
- SOLAR.Functions.Set.Command("View Time", {"Time", "GetTime", "ViewTime"}, "", 1, function(Arguments, Speaker, Message)
- local Time = tick() do Time = math.floor(Time /60 / 60 %24)..":"..math.floor(Time / 60 % 60)..":"..math.floor(Time % 60) end
- local StartTime = math.floor(_TIMEOFSTARTUP/60/60%24)..":"..math.floor(_TIMEOFSTARTUP/60%60)..":"..math.floor(_TIMEOFSTARTUP%60)
- SOLAR.Functions.Main.Output(Speaker, "Server time:\n"..Time)
- SOLAR.Functions.Main.Output(Speaker, "Server time of start:\n"..StartTime)
- SOLAR.Functions.Main.Output(Speaker, "Time it took to start:\n"..SOLAR._TIMEREQUIREDFORSTARTUP.." seconds")
- SOLAR.Functions.Main.Output(Speaker, "Ratio:\n"..math.cos(tick()))
- end)
- SOLAR.Functions.Set.Command("Execute Script",{"exe","execute"}, "Script", 5,function(Arguments,Speaker,Message)
- warn(Speaker, "loadstring(\""..Message.."\")")
- local RealEnvironment, SecureEnvironment, NewEnvironment, Sandbox
- local MainFunction, MainError = ypcall(function()
- local ProtectTable = function(Table)
- return setmetatable(Table,{__metatable = "[ Sandbox ]:\nInvalid permissions"})
- end
- SecureEnvironment = {
- script = SOLAR.Functions.Main.Create("Script", {Name = "SOLAR"}),
- }
- NewEnvironment = {
- __index = (function()
- local EnvironmentFunctions = {}
- for Indexes, Value in pairs{
- ["game,Game"] = game,
- ["workspace,Workspace"] = SOLAR.Services.Workspace,
- Workspace = SOLAR.Services.Workspace,
- _G = SOLAR.Fake._G,
- _VERSION = "LordBox Version 0.8",
- shared = SOLAR.Fake.shared,
- setfenv = setfenv,
- rawset = rawset,
- rawget = rawget,
- newproxy = newproxy,
- setmetatable = setmetatable,
- getmetatable = getmetatable,
- pairs = pairs,
- ipairs = ipairs,
- next = next,
- select = select,
- collectgarbage = collectgarbage,
- assert = assert,
- dofile = dofile,
- load = load,
- pcall = pcall,
- ypcall = ypcall,
- xpcall = xpcall,
- spawn = spawn,
- Spawn = spawn,
- tonumber = tonumber,
- tostring = tostring,
- type = type,
- unpack = unpack,
- newproxy = newproxy,
- gcinfo = gcinfo,
- wait=wait,
- PluginManager = PluginManager,
- settings = settings,
- Stats = Stats,
- UserSettings = UserSettings,
- SOLAR = (function()
- local NewSOLAR = {}
- local SOLAR_Security = {
- __index = SOLAR,
- __metatable = "[ Sandbox ]:\nLocked"
- }
- local Secure = setmetatable(NewSOLAR,SOLAR_Security)
- function NewSOLAR:BreakSandbox()
- return getfenv(2)
- end
- function SOLAR_Security.__index:GetReal()
- return SOLAR
- end
- return NewSOLAR
- end)(),
- loadstring = function(String)
- local Load = loadstring(String)
- setfenv(Load, Sandbox)
- return Load
- end,
- print = function(...)
- local Data, Return = {...}, ""
- for Index,Value in pairs(Data) do
- Return = Return .. tostring(Value) .. (Index < #Data and ", " or "")
- end
- return SOLAR.Functions.Main.Output(Speaker, Return, "White")
- end,
- warn = function(...)
- local Data, Return = {...}, ""
- for Index,Value in pairs(Data) do
- Return = Return .. tostring(Value) .. (Index < #Data and ", " or "")
- end
- return SOLAR.Functions.Main.Output(Speaker, Return, "Bright orange")
- end,
- error = function(String, Level)
- return SOLAR.Functions.Main.Output(Speaker, String, "Really red")
- end,
- getfenv = function(Level)
- local ReturnedEnvironment = SecureEnvironment
- if type(Level) == "function" then
- return ReturnedEnvironment
- elseif type(Level) == "number" and Level >= 0 and Level <= 2 then
- return ReturnedEnvironment
- elseif type(Level) == "nil" then
- return ReturnedEnvironment
- else
- return error("ERROR: Incorrect Environment Level")
- end
- end,
- Instance = ProtectTable{
- new = function(ClassName, Parent)
- if ClassName then
- return Instance.new(ClassName, Parent)
- else
- return error("String expected")
- end
- end,
- Lock = Instance.Lock,
- UnLock = Instance.UnLock,
- },
- UDim2 = ProtectTable{
- new = UDim2.new
- },
- Vector2 = ProtectTable{
- new = Vector2.new
- },
- Vector3 = ProtectTable{
- FromNormalId = Vector3.FromNormalId,
- FromAxis = Vector3.FromAxis,
- new = Vector3.new,
- },
- CFrame = ProtectTable{
- new = CFrame.new,
- Angles = CFrame.Angles,
- fromAxisAngle = CFrame.fromAxisAngle,
- fromEulerAnglesXYZ = CFrame.fromMEulerAnglesXYZ,
- },
- table = ProtectTable{
- setn = table.setn,
- insert = table.insert,
- getn = table.getn,
- foreachi = table.foreachi,
- maxn = table.maxn,
- foreach = table.foreach,
- concat = table.concat,
- sort = table.sort,
- remove = table.remove,
- },
- coroutine = ProtectTable{
- resume = coroutine.resume,
- yield = coroutine.yield,
- status = coroutine.status,
- wrap = coroutine.wrap,
- create = coroutine.create,
- running = coroutine.running,
- },
- string = ProtectTable{
- sub = string.sub,
- upper = string.upper,
- len = string.len,
- gfind = string.gfind,
- rep = string.rep,
- find = string.find,
- match = string.match,
- char = string.char,
- dump = string.dump,
- gmatch = string.gmatch,
- reverse = string.reverse,
- byte = string.byte,
- format = string.format,
- gsub = string.gsub,
- lower = string.lower,
- },
- math = ProtectTable{
- log = math.log,
- acos = math.acos,
- huge = 1/0,
- ldexp = math.ldexp,
- pi = math.pi,
- cos = math.cos,
- tanh = math.tanh,
- pow = math.pow,
- deg = math.deg,
- tan = math.tan,
- cosh = math.cosh,
- sinh = math.sinh,
- random = math.random,
- randomseed = math.randomseed,
- frexp = math.frexp,
- ceil = math.ceil,
- floor = math.floor,
- rad = math.rad,
- abs = math.abs,
- sqrt = math.sqrt,
- modf = math.modf,
- asin = math.asin,
- min = math.min,
- max = math.max,
- fmod = math.fmod,
- log10 = math.log10,
- atan2 = math.atan2,
- exp = math.exp,
- sin = math.sin,
- atan = math.atan,
- },
- os = ProtectTable{
- difftime = os.difftime,
- time = os.time,
- },
- } do
- for Index in Indexes:gmatch("[^, ?]+") do
- EnvironmentFunctions[Index] = Value
- if type(Value) == "function" then
- pcall(setfenv, Value, SecureEnvironment)
- end
- end
- end
- return EnvironmentFunctions
- end)(),
- __newindex = function(Self, Index, Value)
- rawset(NewEnvironment.__index, Index, Value)
- return rawset(Self, Index, Value)
- end,
- __metatable = SecureEnvironment,
- }
- Sandbox = setmetatable(SecureEnvironment, NewEnvironment)
- Speaker = Speaker
- local Function, FunctionError = loadstring(Message, "SOLAR_SCRIPT")
- local SpeakerRank = SOLAR.Functions.Get.PlayerData(Speaker, "Rank")
- if type(Function) == "function" then
- setfenv(Function, Sandbox)
- Function = coroutine.create(Function)
- local Check,Error = coroutine.resume(Function)
- if not Check then
- SOLAR.Functions.Main.Output(Speaker, "ERROR:\n"..tostring(Error), "Really red")
- else
- SOLAR.Functions.Main.Output(Speaker, "Ran Successfully", "Bright orange")
- end
- else
- if not Function then
- error("SYNTAX_ERROR:\n"..tostring(FunctionError))
- end
- end
- end)
- if not MainFunction then
- SOLAR.Functions.Main.Output(Speaker, "PARSING_ERROR:\n"..tostring(MainError), "Really red")
- end
- end)
- SOLAR.Services.Players.PlayerAdded:connect(function(Player)
- SOLAR.Functions.Connect.Player(Player, "Join")
- end)
- SOLAR.Services.Players.PlayerRemoving:connect(SOLAR.Functions.Disconnect.Player)
- SOLAR.Services.RunService.Heartbeat:connect(SOLAR.Functions.Main.Rotate)
- SOLAR.FullyConnected = true
- SOLAR._TIMEREQUIREDFORSTARTUP = -_TIMEOFSTARTUP + tick()
- SOLAR.Functions.Main.AdminOutput("It took "..SOLAR._TIMEREQUIREDFORSTARTUP.." seconds to start the script up.")
- SOLAR.Functions.Main.InitiateRemote()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement