Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I get started on making a plugin? [closed]

Asked by 10 years ago

Please could anyone help?

  • Thanks DrJawsh
0
Please look here to begin with, it contains a lot of information about the plugin object itself: http://wiki.roblox.com/index.php?title=Plugin Articulating 1335 — 10y
0
I am wondering to get it on the hotbar and all like if you click it, it spawns a part. antlerer 33 — 10y

Locked by evaera

This question has been locked to preserve its current state and prevent spam and unwanted comments and answers.

Why was this question closed?

2 answers

Log in to vote
0
Answered by
Asleum 135
10 years ago

Basically, a plugin works exactly like a normal script, except that it runs each time you open a place it studio, and you've got access to the plugin global variable, wich unlocks you more possibilities. For example, you can get access to the mouse like this :

mouse = plugin:GetMouse()
mouse.Button1Down:connect(function() print("Clicked") end)

To publish and test a plugin you've just created, all you have to do is put your script in a model, then right click the model and choose "Publish as plugin". Check out the wiki article if you want to learn more about plugins : http://wiki.roblox.com/index.php?title=Tutorial:Plugins

Ad
Log in to vote
0
Answered by 10 years ago

Try this.

local Plugin = PluginManager():CreatePlugin()
local Bar = Plugin:CreateToolbar('Part Spawner')
local Button = Bar:CreateButton('Part Spawner', 'Spawn a Part', '')

Button.Click:connect(function()
    local Part = Instance.new('Part', Workspace)
end)

If needed, feel free to add some of your own code, such as

Part.Anchored = true
  • Nen