Wednesday, May 14, 2025

External Editor Toggle Plugin for Godot 4.x!



Hey there, Godot devs! 👋 I’m excited to share a little tool I’ve been using in my workflow: the External Editor Toggle plugin for Godot! 🎮💻 

This plugin adds a handy button to your Godot editor toolbar, letting you toggle between the internal script editor and an external editor (like VS Code) with a single click—or even a keyboard shortcut! Let’s dive in. 🌟

What Does It Do? 🤔

The External Editor Toggle plugin simplifies switching between Godot’s built-in script editor and your favorite external editor. Here’s what it offers:
  • Toolbar Button 🛠️: A sleek button in the Godot toolbar to toggle the text_editor/external/use_external_editor setting.
  • Retro 8-Bit Icons 🕹️: Visual feedback with two 8-bit pixel art icons—one for "External Editor" mode and one for "Internal Editor" mode.
  • Keyboard Shortcut ⌨️: Press Ctrl+E to toggle without clicking—perfect for quick switches while coding.
  • Lightweight Design ⚡: No bulky docks, just a single button that fits right into Godot’s UI with the MainScreenButton theme.
Why I Made It 🛠️
I created this plugin while working on my new Sliding Puzzle game in Godot (check it out under the "Games" section! 🎲). I often switch between Godot’s editor and VS Code for editing scripts like grid.gd and TileButton.gd. Navigating to Editor > Editor Settings > Text Editor > External every time was a hassle, so I built this plugin to save time. ⏳ Plus, I gave it a retro 8-bit vibe to match my puzzle game’s aesthetic—those pixel art icons bring me so much joy! 😍

How to Get It 📥
You can download the plugin right here on my site under the "Tools" section! Here’s how to set it up:
  1. Download: Grab the ZIP file from the Tools page.
  2. Install: Extract the external_editor folder to res://addons/ in your Godot project.
  3. Enable: Go to Project > Project Settings > Plugins and enable the plugin.
  4. Set Path: Make sure your external editor path is set in Editor > Editor Settings > Text Editor > External. If not, you’ll get a handy warning to remind you! ⚠️
Once enabled, you’ll see the "Toggle External Editor" button in your toolbar. Click it (or press Ctrl+E) to switch editors, and the button’s text and icon will update to show the current mode—either "External Editor" or "Internal Editor." 🎉

Toolbar button in "External Editor" mode with its 8-bit icon. 🖼️
Compatibility & License 🔍
  • Compatibility: Tested on Godot 4.2 and 4.3. It might need updates for future Godot versions if the toolbar structure changes.
  • License: Released under the Unlicense, so it’s in the public domain—use, modify, and share it freely! 🌍
Why I Love It ❤️
This plugin has been a game-changer for my workflow. While working on my new sliding puzzle game, I can quickly toggle to VS Code for its powerful features (like better autocomplete and debugging) and then switch back to Godot’s editor for smaller tweaks—all without leaving the toolbar. The Ctrl+E shortcut is a lifesaver when I’m deep in coding mode! 🧑‍💻 Plus, the retro 8-bit icons give me a little nostalgia kick every time I use it—they match the pixel art style of my puzzle game perfectly. 🕹️

Get Involved! 💬
Even though this plugin was mainly for my personal use, I’d love for others to try it out! If you download it and have feedback or ideas for improvements, feel free to reach out. You can also check out the source code on GitHub at https://github.com/hazlema/external_editor/. 🌟
Happy coding, everyone! Let me know what you think of the plugin—or if you’ve tried my new sliding puzzle game too! 🎮

— Frosty ❄️