• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Question - IDE GMS2 Code Editor

M

MarcoLizza

Guest
Hello everybody.

Is it me, or the code editor should really be improved? I don't mean that a editor in the league of Atom/VSCode/SublimeText need to be included, but currently the editor itself diverges too much from the current editors appeal (expecially in the keyboard shortcuts to edit and change the code).

Is there a plan to enhance it, or to support external editors?

Thanks.
 

babyjeans

Member
While it's not the most feature-rich editor, I haven't had too many issues with it. The only thing it hasn't done that I've wanted is 'alt-selecting' for multiple lines, but admittedly, many text editors don't include that feature.
Curious - what are you missing?

Also, the files are all plain-text, and you can totally edit the code files in your favorite editor, just browse to the project's folder and poke around a little bit, you'll see the GML files.
 
F

Feronar

Guest
I'm pretty happy with the code editor. They've made a lot of improvements. The main thing I think it could use is foldable code, particularly custom foldable regions (Which I think they said they would like to do).
For example:
Code:
#REGION Calculate player motion
BunchOfCodeHere();
#ENDREGION
could fold to:
Code:
#REGION Calculate player motion ...
 
I'm pretty happy with the code editor. They've made a lot of improvements. The main thing I think it could use is foldable code, particularly custom foldable regions (Which I think they said they would like to do).
This is good and all, but the real question is why doesn't it already have code folding? Basically every other IDE I've worked in has it as a basic feature. MS Visual Studio, code::blocks, Notepad++, and Vim all have it. And why not have syntax-based folding as well? GMS already keeps track of opening/closing braces.
 
S

Storyteller

Guest
one more vote for this modern 'feature' that is standard in both pro and hobby editors
 
G

georges

Guest
I signed up to the forums just to agree with these requests. I use Atom professionally and have used other, more powerful IDEs in the past. I totally understand that making a great code editor is a huge undertaking.

I'd be quite happy if I could edit GML code in my own editor. GMS2 could pop open an external editor window when I double-click a script and refresh it upon save.

Edit with some more constructive feedback:

1) Double clicking a word highlights other instances of that word - very helpful! But if I shift-arrow to select the same word, it doesn't highlight other instances. If should highlight all instances of whatever is currently selected.

2) Once a word or expression is selected in the editor, pressing Ctrl-g should add the next instance of that word to the selection. This would create a multi-cursor selection and allow me to rename all instances of that variable/function name at once.

3) When I type

if (

I don't get the closing paren automatically inserted...? I read elsewhere on the forums that the editor does that, but I haven't seen it. Same with

if (expr) {

I would expect this to insert the closing bracket, insert a newline and a tab, and put the cursor inside the block so that I end up with this:

if (expr) {
|
}


Thoughts?
 
Last edited by a moderator:
P

piranha305

Guest
i think it was stated that code folding is coming in another post
 

davawen

Member
I would definetly love third party editors to be implemented, and be able to use vs code with :
- Brace autoinsert
- Intelisense
- Way better syntax highlighting
And the list goes on and on...
Adding third party editors would be the best so they don't have to focus to much on the editor and more on the functionalities of game maker itself.
 
Top