Creating my first roblox studio plugin (Help with detecting script input)

Creating my first plugin

Hey everyone. I’ve never ever created a roblox lua plugin before, but I’m interested in doing so, just to create a “script macro”. I want the plugin to detect what the player is typing in a script, and if it matches a macro that they set inside a gui, then it changes to the value of the macro.

If that would be too difficult, then just for my own personal use I would like to just create a system with keywords/macros that replace my text with the value of the macro.

For example:

Macro: “UIS”
Value: "game:GetService(“UserInputService”)

How would I go about starting with that? I’ve been struggling to find a way to detect what the plugin user is typing in a script. Thank you for reading :slight_smile:

Also the plugin I’m trying to create is something like this other one:

ScriptMacro

I think you can find useful functions in StudioService -StudioService | Documentation - Roblox Creator Hub

1 Like

There’s also ScriptEditorService which allows things like autocomplete ScriptEditorService | Documentation - Roblox Creator Hub

1 Like

PluginMouse might be what you are looking for.

On second thought, KeyDown is deprecated.

1 Like

Thank you I appreciate it, will check it out for sure

Thanks, I’ll look into it anyway :slight_smile:

Bump I’m still stuck lol, my tiny brain can’t understand the docs properly

I am not good at this but I wanna try to help this might not work but maybe try to make a table for the things you wanna detect then do like an
if --you type something == yourtable then
–what you wanna put
end

1 Like