Insta Path Plugin

Path
BackStory
I always get annoyed when starting a new project then having a lot of variables to make. Takes some time and gets annoying over time. As a result, i decided to make this plugin. It wasn’t going to be at first but, i thought others may find this useful to them.

Plugin

How to use

  1. Select anything you want
    image

  2. Click the Plugin button
    image

3.Selection your options then click “Get Path”
image

  1. A script will appear in the workspace or Output

5.The result

Update v1.1
Settings

-WaitForChild()
-Print to Output
-To Script

-Now Gets all Services

Update v1.2

-Cleaner Code
-Variable separation
-Fixed a bug

34 Likes

Very useful Plugin. Will definitely use this for my future scripts!

Why did I never thought of this before, this is a really amazing plugin

Can you add an option to use WaitForChild instead of Indexing?

If it’s necessary, I always use WaitForChild because I don’t know if everything will replicate instantly and properly.


Great work, I have always wanted to make a custom plugin like this, you made our dream came true my guy.

3 Likes

This is a neat idea. I’d certainly like @RuizuKun_Dev’s suggestion to use WaitForChild, and additionally I think an option to use double quotes rather than single quotes would be nice as I always use double quotes (I find them easier to read personally). It’d be really cool if this plugin created separation/comments between things, e.g. “Services”, “Modules”, “Assets”. Services would include all GetService calls, Assets would be all instances, and Modules would be all requires. Lastly, it’d be awesome to be able to prepend all of this to an existing script. I usually do this by having the user select the target script last and click a special button to prepend.

Additionally, I’m interested in a few things. Does this escape names so that quotes in the names won’t cause problems? Additionally, how are services handled? Is the ClassName checked against GetService or something?

Overall, I like this concept and it may be useful to me. Keep it up! :smile:

3 Likes

@tsougranis this would be perfect for your scripting

1 Like

@Hexcede @RuizuKun_Dev Love the feedback/suggestions and decided to update it. Thanks to both of you!

2 Likes

To answer your questions:

1.) I’ll most defiantly fix the problem with quotes in and Instances name.
2.) All Services that are used to put contain stuff are put into a table. Although, i was thinking of a better way of doing it and just adding all services instead of a select few.
3.No, it isn’t checked against GetService which i should do.

If there is anymore questions you have, feel free to ask them.

2 Likes

Usually what I do is first check if the instance is parented to game, and if it is, then I pcall game:GetService(instance.ClassName), and if it didn’t error, it’s gotta be a valid service. Also since 9 times out of 10 it’ll error, so normally this would slow down your script quite a bit due to how pcalls would return errors, but a recent luau update substantially improved performance when a pcall error, so I’m not worried about this anymore at this point not that it’s particularly a big deal in this case.

What I do to fix quotes is basically escape \, ", and ' characters using gsub. I tend not to use single quotes at all (just a habit/preference to use them I suppose haha) so I usually omit the last one there from my code, however, when I do usually it’s based off of the enclosing character if I know what it is already (e.g. ' doesn’t need to be escaped if the enclosing character is " and vice versa).

Might try what you did to fix those problems. Also happy birthday :partying_face:

1 Like

Update v1.2 released! Added a few stuff.

1 Like

Cool plugin but I can’t see the button since the UI doesn’t scale, and isn’t a widget.