Code Runner
Ever gone through the explorer object by object repeating the same action over and over again? This plugin will help you out! I’ve suffered from this time and time again, so I wrote a simple plugin that allows you to save/edit/delete these tasks for repeated use and a more efficient workflow.
Simply put, you write a function that acts on what you selected on the explorer.
Example of setting a model’s name to one of its descendants properties:
Possible Use Cases
Batch renaming that requires some conditional statements/logic
Batch updating assetids
Finding part offsets from a position for welds
Finding all assetids for preloading with a given selection
Possible Features
Search functionality
Temporary code (to avoid creating/deleting right after)
Run general functions (not just from the selection of the explorer)
Pass parameters in
Despite this being a small project for me, any feedback would greatly appreciated!
Nice module but I do not see how this would be useful. This is something I rarely encounter and when I do I use the command bar. How would this module help us in our development process?
I found it monotonous to keep having to write out for i,v in pairs(game.Selection:Get()) do
so that’s the main reason I created this. There is another use case that I can think of for which is getting part positions relative to a primary part for welds/renderstepped part locking a position.
This is really cool! I really like what you did with running the code, as well. Loading the code into a module script and then requiring the module script is a really smart alternative to loadstring!
Does this support multi-variable/parameter functions? Like with the one you demo’d, since there is only one variable for the function that changes the properties, each instance selected can be substituted into it. Does it work just as well if the function has more than one variable (such as swapping instance names, or renaming an instance to that of another?
At the moment, adding extra arguments to the main function does not do anything. The only argument passed in is the object itself. I plan to add support for custom arguments passed in through the GUI. If you need something similar to a LastObject variable, you can write your own variables.