Skip to content

Plugin

Supported Class Platform & Data NotCreatable

The main object responsible for creating custom Studio widgets, toolbars, buttons, and other plugin UI elements.

17 Nova members · 45 modern Roblox members not implemented yet

Description

Plugin is the main object responsible for creating custom Studio widgets, plugin toolbars, plugin buttons, and more. The Plugin object can be accessed through the Global.RobloxGlobals.plugin global reference in a Script that is executed as a plugin.

Inheritance

Object → Instance → Plugin

Nova inheritance: Instance → Plugin

Properties

CollisionEnabled Supported Property Returns whether the user has enabled Collisions in Studio's toolbar.
CollisionEnabled: bool

Returns whether the user has enabled Collisions in Studio's toolbar.

Roblox documentation

GridSize Supported Property Returns the grid snapping size the user has set in Studio.
GridSize: float

Returns the grid snapping size the user has set in Studio.

Returns the grid snapping size the user has set in Studio's toolbar. Note that this property may have slight rounding errors; for example it may be 0.0099999997764826 for a user setting of 0.01, or 0.4000000059604645 for a user setting of 0.4.

Roblox documentation

Methods

Activate Supported Function Sets the state of the calling plugin to activated.
Plugin:Activate(bool exclusiveMouse)

This method sets the state of the calling plugin to activated. Activating the plugin allows mouse control through the GetMouse() method.

At any given time, there are either 0 or 1 activated plugins. Activating a plugin will deactivate all other plugins and they will receive a Deactivation event.

See Also

  • IsActivatedWithExclusiveMouse() which returns true if the plugin is currently active with an exclusive mouse, after having been activated via this method.
  • Unloading which fires immediately before the plugin is unloaded or reloaded via uninstallation, deactivation, or updating.
Roblox reference signature
Plugin:Activate(exclusiveMouse: bool): null
Security: PluginSecurity

Roblox documentation

CreateToolbar Supported Function Creates a new PluginToolbar with the given name.
Plugin:CreateToolbar(string name): Instance

This method creates a new PluginToolbar with the given name. The toolbar can then be used to create plugin buttons.

Roblox reference signature
Plugin:CreateToolbar(name: string): PluginToolbar
Security: PluginSecurity

Roblox documentation

GetJoinMode Supported Function Returns the JointCreationMode the user has set in Studio's toolbar.
Plugin:GetJoinMode(): JointCreationMode

Returns the JointCreationMode the user has set in Studio's toolbar.

Security: PluginSecurity

Roblox documentation

GetMouse Supported Function Returns a Mouse that can be used while the plugin is active.
Plugin:GetMouse(): Instance

Returns a Mouse that can be used while the plugin is active.

This method returns a PluginMouse that can be used while the plugin is active through Activate().

Roblox reference signature
Plugin:GetMouse(): PluginMouse
Security: PluginSecurity

Roblox documentation

GetSetting Supported Function Retrieves a previously stored value with the given key, or nil if the given key doesn't exist.
Plugin:GetSetting(string key): Variant

Retrieves a previously stored value with the given key, or nil if the given key doesn't exist.

Because multiple instances of the same plugin can run simultaneously (for example, if multiple Studio windows are open), you shouldn't depend on this value staying the same over time. The other plugin instances can update the setting at any time.

This call can silently fail and return nil if multiple instances of the same plugin are actively reading and writing data. If your plugin expects to write to settings frequently, you should double-check the returned value from this call after a short while to distinguish between a setting being temporarily unavailable and a setting not existing.

Roblox reference signature
Plugin:GetSetting(key: string): Variant
Security: PluginSecurity

Roblox documentation

GetStudioUserId Supported Function Deprecated Returns the Studio user's userId if they're logged in, otherwise returns 0.
Plugin:GetStudioUserId(): int

Returns the Studio user's userId if they're logged in, otherwise returns 0.

Roblox reference signature
Plugin:GetStudioUserId(): int64
Security: PluginSecurity

Roblox documentation

Negate Supported Function Negates the given parts and returns the resulting NegateOperations.
Plugin:Negate(Objects objects): Objects

Negates the given parts and returns the resulting NegateOperations.

Roblox reference signature
Plugin:Negate(objects: Instances): Instances
Security: PluginSecurity

Roblox documentation

OpenScript Supported Function Deprecated Used to open the given script instance in an editor window, in Roblox studio, at the given line. If no line is given as an argument it will default t…
Plugin:OpenScript(Instance script, int lineNumber = 0)

Used to open the given script instance in an editor window, in Roblox studio, at the given line. If no line is given as an argument it will default to 1.

Prefer ScriptEditorService:OpenScriptDocumentAsync(), which provides better integration with other script editor APIs and is more extensible.

Roblox reference signature
Plugin:OpenScript(script: LuaSourceContainer, lineNumber: int = 1): null
Security: PluginSecurity

Roblox documentation

OpenWikiPage Supported Function Opens the context help window to the wiki page that url links to.
Plugin:OpenWikiPage(string url)

Opens the context help window to the wiki page that url links to.

Roblox reference signature
Plugin:OpenWikiPage(url: string): null
Security: PluginSecurity

Roblox documentation

PromptForExistingAssetId Supported Function Opens a window in Roblox Studio that prompts the user to select an existing AssetType.Animation asset. The assetType parameter must be Animation; oth…
Plugin:PromptForExistingAssetId(string assetType): int

Opens a window in Roblox Studio that prompts the user to select an existing AssetType.Animation asset. The assetType parameter must be Animation; other values are not supported and cause an error.

Opens a window in Roblox Studio that prompts the user to select an existing animation asset from the user's inventory. Pass Animation as the assetType argument.

Returns the selected animation asset ID as an int64, or -1 if the user closes the dialog without selecting an asset. If assetType is not Animation, this method errors.

Roblox reference signature
Plugin:PromptForExistingAssetId(assetType: string): int64
Security: PluginSecurity

Roblox documentation

SaveSelectedToRoblox Supported Function Opens an upload window for the user's current selection.
Plugin:SaveSelectedToRoblox()

Opens an upload window for the user's current selection.

Roblox reference signature
Plugin:SaveSelectedToRoblox(): null
Security: PluginSecurity

Roblox documentation

Separate Supported Function Separates the given UnionOperations and returns the resulting parts.
Plugin:Separate(Objects objects): Objects

Separates the given UnionOperations and returns the resulting parts.

Roblox reference signature
Plugin:Separate(objects: Instances): Instances
Security: PluginSecurity

Roblox documentation

SetSetting Supported Function Stores a given value for later use under the given key. The value will persist even after Studio is closed.
Plugin:SetSetting(string key, Variant value)

Stores a given value for later use under the given key. The value will persist even after Roblox Studio is closed. These settings are saved in .json format as a map with string keys. Arrays are automatically converted to maps by converting the numeric keys to strings first.

Note that the .json format imposes additional restrictions, including the following characters which can corrupt the settings file:

  • Backslashes (\) in keys or values, in particular escaped quotes (\").
  • Newlines (\n) in keys.
  • Quotes (") in keys.
  • Periods (.) in keys.

This call can silently fail if multiple instances of the same plugin are actively reading and writing data. If your plugin expects to write to settings frequently, you may check that the data has been properly written by calling GetSetting().

Roblox reference signature
Plugin:SetSetting(key: string, value: Variant): null
Security: PluginSecurity

Roblox documentation

Union Supported Function Unions the given parts and returns the resulting UnionOperation.
Plugin:Union(Objects objects): Instance

Unions the given parts and returns the resulting UnionOperation.

Roblox reference signature
Plugin:Union(objects: Instances): Instance
Security: PluginSecurity

Roblox documentation

Events

Deactivation Supported Event Fired when the plugin is deactivated.
Deactivation()

Fired when the plugin is deactivated.

Fired when the Plugin is deactivated. This occurs when either the plugin code calls Deactivate(), or because some other plugin called Activate(), which forces all other plugins to lose their active state.

See also Unloading which fires immediately before the plugin is unloaded or reloaded via uninstallation, deactivation, or updating.

Security: PluginSecurity

Roblox documentation

Inherited members

Inherited from Instance: 8 properties, 36 methods, 7 events. They are documented on the base class page.

45 modern Roblox member(s) are not implemented yet — expand to inspect

Members declared by Roblox's Plugin class (or by a missing base class) that Nova does not expose. Use this list to scope a migration; the compatibility guide has the recommended workaround.

Properties

Member Signature Status Notes Flags
DisableUIDragDetectorDrags DisableUIDragDetectorDrags: bool Not yet If true, toolbars and buttons for the plugin will ignore dragging related to a UIDragDetector instance. RobloxScriptSecurity
IsDebuggable IsDebuggable: bool Not yet Indicates whether the plugin's scripts can be debugged in Studio. RobloxScriptSecurity

Methods

Member Signature Status Notes Flags
CreateDockWidgetPluginGui Plugin:CreateDockWidgetPluginGui(pluginGuiId: string, dockWidgetPluginGuiInfo: DockWidgetPluginGuiInfo): DockWidgetPluginGui Not yet Creates a DockWidgetPluginGui given a DockWidgetPluginGuiInfo. Yields, PreferredDescriptorName, ThreadSafety, PreferredDes…
CreateDockWidgetPluginGuiAsync Plugin:CreateDockWidgetPluginGuiAsync(pluginGuiId: string, dockWidgetPluginGuiInfo: DockWidgetPluginGuiInfo): DockWidgetPluginGui Not yet Creates a DockWidgetPluginGui given a DockWidgetPluginGuiInfo. Yields, PluginSecurity
CreatePluginAction Plugin:CreatePluginAction(actionId: string, text: string, statusTip: string, iconName: string, allowBinding: bool = true): PluginAction Not yet Creates a PluginAction which represents a generic performable action in Studio with no directly‑associated [PluginToolbarButton](PluginToolbarButton.m… PluginSecurity
CreatePluginMenu Plugin:CreatePluginMenu(id: string, title: string, icon: string): PluginMenu Not yet Creates a new plugin menu. PluginSecurity
CreateQWidgetPluginGui Plugin:CreateQWidgetPluginGui(pluginGuiId: string, pluginGuiOptions: Dictionary): QWidgetPluginGui Not yet — Yields, RobloxScriptSecurity
Deactivate Plugin:Deactivate(): null Not yet Deactivates the plugin. PluginSecurity
FinishFullLoading Plugin:FinishFullLoading(payload: Variant): null Not yet — CustomLuaState, RobloxScriptSecurity
GetItem Plugin:GetItem(key: string, defaultValue: Variant): Variant Not yet — RobloxScriptSecurity
GetPluginComponent Plugin:GetPluginComponent(name: string): Variant Not yet — CustomLuaState, RobloxScriptSecurity
GetPreinitPayload Plugin:GetPreinitPayload(): Variant Not yet — CustomLuaState, RobloxScriptSecurity
GetSelectedRibbonTool Plugin:GetSelectedRibbonTool(): RibbonTool Not yet Returns the currently selected RibbonTool. PluginSecurity
GetUri Plugin:GetUri(): Dictionary Not yet — RobloxScriptSecurity
ImportFbxAnimation Plugin:ImportFbxAnimation(rigModel: Instance, isR15: bool = true): Instance Not yet Prompts the user to open a .fbx animation file that can be loaded onto the rigModel, then proceeds to insert the animation as a [KeyframeSequence](KeyframeSequence.m… Yields, PreferredDescriptorName, ThreadSafety, PreferredDes…
ImportFbxAnimationAsync Plugin:ImportFbxAnimationAsync(rigModel: Instance, isR15: bool = true): Instance Not yet Prompts the user to open a .fbx animation file that can be loaded onto the rigModel, then proceeds to insert the animation as a [KeyframeSequence](KeyframeSequence.m… Yields, PluginSecurity
ImportFbxRig Plugin:ImportFbxRig(isR15: bool = true): Instance Not yet Prompts the user to open a .fbx file, uploads the individual components of the model as meshes, and generates a character rig for use in animation, which is loaded int… Yields, PreferredDescriptorName, ThreadSafety, PreferredDes…
ImportFbxRigAsync Plugin:ImportFbxRigAsync(isR15: bool = true): Instance Not yet Prompts the user to open a .fbx file, uploads the individual components of the model as meshes, and generates a character rig for use in animation, which is loaded int… Yields, PluginSecurity
Intersect Plugin:Intersect(objects: Instances): Instance Not yet Intersects the given parts and returns the resulting IntersectOperation. PluginSecurity
Invoke Plugin:Invoke(key: string, arguments: Tuple): null Not yet — RobloxScriptSecurity
IsActivated Plugin:IsActivated(): bool Not yet Returns true if this plugin is currently active, after having been activated via the Activate() function. PluginSecurity
IsActivatedWithExclusiveMouse Plugin:IsActivatedWithExclusiveMouse(): bool Not yet Returns true if this plugin is currently active with an exclusive mouse. PluginSecurity
IsLoadedFromProject Plugin:IsLoadedFromProject(): bool Not yet — RobloxScriptSecurity
OnInvoke Plugin:OnInvoke(key: string, callback: Function): Instance Not yet — RobloxScriptSecurity
OnInvokeSuspendOverride Plugin:OnInvokeSuspendOverride(key: string, callback: Function): Instance Not yet — RobloxScriptSecurity
OnSetItem Plugin:OnSetItem(key: string, callback: Function): Instance Not yet — RobloxScriptSecurity
PauseSound Plugin:PauseSound(sound: Instance): null Not yet — RobloxScriptSecurity
PlaySound Plugin:PlaySound(sound: Instance, normalizedTimePosition: double = 0): null Not yet — RobloxScriptSecurity
PromptForExistingAssetIdAsync Plugin:PromptForExistingAssetIdAsync(assetType: string): int64 Not yet Opens a window in Roblox Studio that prompts the user to select an existing AssetType.Animation asset. The assetType parameter must… Yields, PluginSecurity
PromptSaveSelection Plugin:PromptSaveSelection(suggestedFileName: string): bool Not yet Prompts the user to save their current selection with the specified file name. Yields, PreferredDescriptorName, ThreadSafety, PreferredDes…
PromptSaveSelectionAsync Plugin:PromptSaveSelectionAsync(suggestedFileName: string): bool Not yet Prompts the user to save their current selection with the specified file name. Yields, PluginSecurity
ResumeSound Plugin:ResumeSound(sound: Instance): null Not yet — RobloxScriptSecurity
SelectRibbonTool Plugin:SelectRibbonTool(tool: RibbonTool, position: UDim2): null Not yet Activates the specified Roblox Studio tool. PluginSecurity
SetItem Plugin:SetItem(key: string, value: Variant): null Not yet — RobloxScriptSecurity
SetReady Plugin:SetReady(): null Not yet — RobloxScriptSecurity
StartDecalDrag Plugin:StartDecalDrag(decal: Instance): null Not yet — RobloxScriptSecurity
StartDrag Plugin:StartDrag(dragData: Dictionary): null Not yet Starts a drag action given a dictionary of parameters. PluginSecurity
StopAllSounds Plugin:StopAllSounds(): null Not yet — RobloxScriptSecurity

Events

Member Signature Status Notes Flags
Ready Ready() Not yet — RobloxScriptSecurity
Unloading Unloading() Not yet Fires immediately before the Plugin stops running. PluginSecurity
ViewportDragDropped ViewportDragDropped(dragData: Dictionary) Not yet — RobloxScriptSecurity
ViewportDragEntered ViewportDragEntered(dragData: Dictionary) Not yet — RobloxScriptSecurity
ViewportDragLeft ViewportDragLeft() Not yet — RobloxScriptSecurity

Callbacks

Member Signature Status Notes Flags
ProcessAssetInsertionDrag ProcessAssetInsertionDrag(assetId: string, assetTypeId: int, instances: Instances) -> Instances Not yet — NoYield, RobloxScriptSecurity
ProcessAssetInsertionDrop ProcessAssetInsertionDrop() -> null Not yet — NoYield, RobloxScriptSecurity

Roblox reference: Plugin

Generated from Nova's API dump and Roblox creator-docs. Nova-only members come from the engine's reflection metadata.