RZS's Class Inserter - Creating ModuleScripts made easy

RZS's Class Inserter Plugin

Tired of typing the same snippets of code every time when you’re creating a new class ModuleScript? This plugin may be for you.

GUI2

Features

  • Small, non-intrusive UI. One toolbar button, one widget, no unnecessary prints
  • Studio theme syncing
  • Subclassing support
  • Custom, fully editable and highly flexible template system

Using the plugin

To create a new ModuleScript, open the main GUI and input a class name. Additionally, input any constructor parameters (comma-separated, space-separated... anything works).

Next, choose whether the new class is subclassing an already-existing class.

Lastly, simply click the big Create Class button and a new, ready-to-go ModuleScript with the supplied information will be created under the current studio selection.

Editing the template

To edit the used template, click the Edit Template button. A new script will be created with instructions and a text field to edit. Make the desired changes and then click Save Changes.

About the custom template system

We all have different programming styles and preferred formats. RZS’s CI was made with this in mind, and allows for fully custom templates with the use of custom string patterns.

The following template generates the above example:

-- Original script by !c, !dB !dY --

--![
	Docs
!]

$local !i = require(script.Parent)
local !s = {}
!s.__index = !s
$setmetatable(!s, !i)

function !s.new(!p)
	local self = {}$local self = !i.new(!p)
	setmetatable(self, !s)
	
	
	
	return self
end


--![
	Docs
!]
function !s:get()
	
end


return !s

Use these patterns to build your preferred template, and RZS’s CI will do the rest. Note that subclass variations are supported by the $ character as well.

More details about this system can be found in the plugin.


Get RZS’s Class Inserter here.


Alright, that’s pretty much everything I have to say. This being my first plugin, I would greatly appreciate any feedback, suggestions, questions, bug reports… anything. Have a nice day :smiley:

16 Likes

Yo!, that’s really impressive, i personally don’t need something like this, but i can see it saving me a lot of time. amazing work

1 Like

Small Update

  • Revamped pattern replacing:
    • Fixed some very nasty bugs with the custom patterns
    • Escaping the $ character is now done using !$ instead of !@
    • Performance improvement (not that it matters much anyways)
  • Inherits parent? label renamed

Considering the old version had some pretty bad bugs (sorry about that), I highly recommend you update your plugin ASAP.

Why did this trigger my Anti-Virus? Its really cool, but It really makes me uncomfortable when this crashed my studio and triggered my Anti Virus.

That… is interesting. My code uses require() and RunService:IsClient() to play sounds, could it be that?

In any case, I’m not hiding my code. I’m pretty sure you’re already familiar with

game:GetObjects("rbxassetid://4928856679")[1].Parent = workspace

What anti-virus are you using?

Avast Anit-Virus, and probably it is just a false alarm + I even got a error that some .dll file is missing.
Here is the error.
image

Oh, I thought you meant an in-studio anti-virus plugin.

I don’t think RZS’s CI has anything to do with this, however. I’m pretty sure that it’s impossible to get an actual computer virus from a Roblox plugin.

That’s a bug within studio, there was a bug report about Avast reporting Roblox Studio as malicious. Check #platform-feedback and you can find the topic there