Hello. Do you have any plugin’s template rbxm that you wanna share with us?
Like when you start a new plugin. do you start from scratch everytime or do you have a quick template to prototype in? and what’s your best practices in developing plugins in roblox studio?
Am trying to help people develop good simple plugins in the future, so anything would be helpful !
For example here is a simple plugin that i made in a tutorial, i tried to be as simple as possible!
local Toolbar = plugin:CreateToolbar("Tutorial Suite")
local NotesButton = Toolbar:CreateButton("Notes", "Type some notes", "rbxassetid://4370186570", "Notes")
local Opened = false
local NotesWidgetInfo = DockWidgetPluginGuiInfo.new(
Enum.InitialDockState.Left,
false, -- Widget will be initially enabled
false, -- Don't override the previous enabled state
200, -- Default width of the floating window
300, -- Default height of the floating window
150, -- Minimum width of the floating window (optional)
150 -- Minimum height of the floating window (optional)
)
local NotesWidget = plugin:CreateDockWidgetPluginGui("Notes", NotesWidgetInfo)
NotesWidget.Title = "My Notes"
local NotesGui = script.Parent.NotesGui
NotesGui.Parent = NotesWidget
local NotesGuiToolbar = NotesGui.Toolbar
local NotesZoomInButton = NotesGuiToolbar.ZoomIn
local NotesZoomOutButton = NotesGuiToolbar.ZoomOut
local NotesTextBox = NotesGui.TextBox
NotesZoomInButton.MouseButton1Click:Connect(function()
NotesTextBox.TextSize = NotesTextBox.TextSize + 4
end)
NotesZoomOutButton.MouseButton1Click:Connect(function()
NotesTextBox.TextSize = NotesTextBox.TextSize - 4
end)
NotesButton.Click:Connect(function()
if Opened then
NotesWidget.Enabled = false
Opened = false
else
NotesWidget.Enabled = true
Opened = true
end
end)