local Toolbar = plugin:CreateToolbar("Run a Studio-Script")
local Button = Toolbar:CreateButtton("Studio Script","When clcik the buttton a folder will be inserted to serverscriptservice called StudioScript you put the script you want to execute in that folder, and it will be directly executed in roblox studio, because on script you can do several lines adn even more.","rbxassetid://8852012472")
Button.Click:Connect(function()
game:GetService("ServerScriptService").LoadStringEnabled = true
if not game:GetService("ServerScriptService"):FindFirstChild("StudioScript") then
local StudioScripts = Instance.new("Folder")
StudioScripts.Name = "StudioScripts"
StudioScripts.Parent = game:GetService("ServerScriptService")
end
game:GetService("ServerScriptService"):FindFirstChild("StudioScript").ChildAdded:Connect(function(Script)
if not game:GetService("ServerScriptService"):FindFirstChild("StudioScripts"):isA("Folder") then
game:GetService("ServerScriptService"):FindFirstChild("StudioScripts"):Remove()
warn("You can not have somethine else in serverscriptservice called StudioScripts!.")
else
loadstring(Script.Source)
end
end)
end)
Right click on your plugin script, then if your testing your plugin, press Save as Local Plugin if not the Save as Plugin. If you want to include ui for your plugin, parent your script to a folder then right click the folder then press Save as Local Plugin* or Save as Plugin. (you don’t have to test or press F5 to see if your plugin exist, it will just create an error)
Just a tip: in the future, try checking your output for errors as the first thing when something doesn’t work. It will tell you where the error is, and save you the hassle of posting about it.
it says LoadStringEnabled is not a valid memer of serverscriptservice.
but… i don’t see any folder. even if The output says that, why the folder is not there?
and if i create a folder called StudioScripts and put a script in it the script does nto remove
This usually means there’s a typo or the child doesn’t exist yet.
That’s because LoadingStringEnabled is a non-scriptable property of ServerScriptService, which means you cannot change or even read it using scripts. The only solution to that is to completely revise your code, sorry.