Introducing CodeBank V-1! (Autocomplete)

Introducing CodeBank V-1

What Is CodeBank?

CodeBank Is An Auto-Complete Plugin That Allows A User To Create Their Own Custom Auto-Completions Through The Use Of A [DockWidgetPluginGui](https://create.roblox.com/docs/reference/engine/classes/DockWidgetPluginGui).

What Makes This Plugin Worthwhile?

CodeBank Is extremely customizable And has many options for custom Auto-Complete Suggestions. Whether you are trying to add a whole thousand line script, or just a few words, CodeBank has you covered. The Main goal of CodeBank is to make scripting faster by allowing people to add Auto-Completions for bits of code that they use often.

HOW TO ADD A COMPLETION:

  1. Open The CodeBank UI By Clicking The Button That Appears In Your Plugin ToolBar.
  2. Click “Create New” At The Top Right-Hand Side Of The UI
  3. Fill Out The Options As Needed.
  4. Click “SUBMIT” In The Bottom Right-Hand Side Of The UI
  5. DONE! :slightly_smiling_face:
  6. Your New Completion Is Now Added Will Show Up When The Given Keyword Is Inputed.

HOW TO DELETE A COMPLETION:

  1. Find The Completion Of Choice In The Main Menu. If You Cannot Find It, You Can Search For It Using The Search Bar At The Top Of The UI
  2. Click On The Edit Button For The Given Completion
  3. Scroll To The Bottom Of The Edit Frame And Click “REMOVE” At The Bottom Left-Hand Side Of The UI.
  4. Click “YES” When The Confirmation Prompt Shows Up.
  5. DONE! :slightly_smiling_face:
  6. The Given Completion Has Now Been Removed.

FEATURES

Feature Purpose
MAIN MENU The Main Menu That Contains All Of Your Auto-Completions. The Only Data Shown Here is The Start And End Keyword As Well As The Label/Name For The Completion.
SEARCH-BAR This Is Used To Search Through All Of Your Custom Auto-Completions. The Search Can Be Filtered Through The Use Of The Search Filter Settings In The Settings Menu.
SETTINGS MENU This Has Various Settings For The Plugin. As Of Right Now, It Only Contains The Search Filter Settings.
CREATION MENU This is a Menu Used For The Creation Of Your Custom Auto-Completions. It Contains The Following Input Sources:
Input Item Parameters
INPUT TEXT (Required) A String That Is The Inputed Text For The Auto-Completion
REPLACEMENT TEXT A String That Is The Outputted Text For The Auto-Completion. Completions Can Also Draw From A Script With The Following Format:
[Path: {Path.To.Script}]
Example:
[Path: game.ServerScriptService.Script]
NOTE: EACH INSTANCE MUST BE SEPARATED WITH A PERIOD. OTHER INSTANCE SEARCHING METHODS WONT WORK, INCLUDING .PARENT
DETAILS A String That Represents The Completion Details
DOCUMENTATION A String That Represents The Completion Info/Documentation
KEYWORDS The Opening And Closing Keywords For The Completion. Both Can Be Blank But A Starting Keyword Is Recommended.
(Default Starting Keyword: "-->")
(Default Ending Keyword: "<--")
CODE SAMPLE A Snippet Of Code That You May Want To Show
LEARN MORE LINE A Link To A Page On create.roblox.com such as A Link To A Documentation Page Or An Install Page.
COMPLETION KIND A Single Enum.CompletionItemKind That Represents This Completion.
Example: {Enum}
COMPLETION TAGS A List Of Enum.CompletionItemTags Separated By Plus Signs.
Example: {Deprecated+AddParens}
OVERLOADS The Number Of Overloads For A Completion (Im Gonna Be Honest, Im Not Quite Sure What This Does But It Was A Parameter For The Auto-Complete Stuff So I Added It Anyway. There's A Chance That The Way I Coded This, This Feature Is Prevented From Working.)
PRESELECT A Boolean That Represents If The Completion Gets Priority Over Others And Automatically Selected.
SINGLE-LINE KEYWORD CHECK A Boolean That Represents Whether Keywords Are Searched For Through The Whole Document Or Just One Line.
EDIT MENU This is a Menu Used For The Editing Your Auto-Completions. It Contains All Of the Input Sources From Creation Menu As Will As The Following Input Sources:
Input Item Parameters
UPDATE SCRIPT (Default Off) A Boolean The Says Whether Or Not The Auto-Completion Should Check The Output TextBox And Attempt To Update The Output Text. This Was Put In Place To Allow Completion Updates Even If The Output Source Script No Longer Exists. Setting This To True Will Cause The Output To Update If The Script Still Exists.

Potential Future Update Ideas

  • Multiple Opening and Closing Keywords Per Completion
  • I might redo the script pathing or add a button that makes script pathing easier to do. One Alternative is That I could just add WaitForChild() and FindFirstChild() To the script pathing.
  • I Could add an option that prevents a completion from showing up in various script types. ex: prevent completion in local-scripts or prevent completion in module-scripts or prevent completion in server-scripts. I may Also Add An Option for command-bar only completions and non-command-bar completions.
  • I Could add an option that prevents the completion from showing up if the word you are typing is not directly after the keyword. (Though a Single Space May Be Allowed, Characters That Are Not Letters Or Numbers Would Also Be Considered As Separations.)

Inspiration:

Sleitnick’s Require Auto-Complete Plugin

Previews

Side Note:

If you see a bug, or have an idea for a feature addition, feel free to let me know.

UPDATES:

  • V-1 - Release
  • V-1.1 - Command-Bar Completions Now Work
  • V-1.2 - Loading Screen Bug Fix And Single-Line Keyword Check Option Has Been Added But Not Fully Implemented.
  • V-1.3 - Added Options For Single-Line Keyword Checks For Completions. This Feature Is Still Not Fully Implemented Yet, The Buttons Do Nothing Other Than Toggling A Boolean.
  • V-1.4 - Added Single-Line Checking Mode.

Current Version: V-1.4

Quick Note:

This Plugin will be temporarily Free during the Early-Release-Stages, starting Now, so I can maybe get a bit of feedback on it. It will likely go back to being paid at a later date.
7 Likes

This is so much nice it’s good on your create and website

1 Like

Also, Currently There is a bug where the loading screen pops up and stays if you try to submit an empty completion. To counter this, click at the top right where the create completion button should be to make it go away. I will try to fix that tomorrow.

EDIT: This Bug Should Be Fixed Now.