Hello. Recently I found quite good code editor by Microsoft, available for Windows, Linux and Mac, titled as Visual Studio Code. It's pretty much just a text editor, with syntax highlighting feature and auto-completion feature. I'd recommend this editor alongside with other ones (like Notepad++ for Windows or Sublime Text for Linux) as it knows only two formats of line ends (omits Mac CR format on Windows), but it can seriously take over the place of your current text editor (even classic Notepad on Windows or gedit on Linux) It has also debugging options, though much limited compared to full Visual Studio IDE.
My goal is this: Create and release extension for Visual Studio Code for highlighting syntax of Quake engine shaders. I know that shader has this format:
Code: Select all
textures/custom/sprite
{
surfaceparm nolightmap
surfaceparm nodlight
surfaceparm nomarks
surfaceparm noimpact
surfaceparm trans
deformVertexes autosprite
{
map textures/custom/sprite.tga
blendFunc GL_ONE GL_ONE
rgbGen wave square 0 1 .25 .125
}
}
And I would like to know how to make such syntax highlight using
yo code. I mean, how to design keywords plus their parameters, how to design q3map2 directives (and allow for custom ones), allowing for custom surfaceparms, etc. Pretty much take plenty of notes from
obsidian's Shader Manual and make syntax highlighter for VS Code out of that. It's great guide and making a tool for relatively new coding text editor to help to find its users also here between level designers would be great pleasure for me. But it's really new editor and I have to learn all the possibilities for it, including creation of custom syntax highlighter for custom languages (which shader is).