Elvas Tower: VS Code syntax highlighting for OpenRails / MSTS (.eng, .wag, .cvf, .sms) files - Elvas Tower

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

VS Code syntax highlighting for OpenRails / MSTS (.eng, .wag, .cvf, .sms) files Rate Topic: -----

#1 User is offline   Matej Pacha 

  • Engineer
  • Group: Posts: Contributing Member
  • Posts: 575
  • Joined: 08-December 10
  • Gender:Male
  • Location:Slovakia
  • Country:

Posted 24 September 2025 - 12:29 PM

Hi guys,

I’m not sure if anyone here is using Visual Studio Code for editing content files, but I was wondering if it could be used with a custom-designed syntax highlighting — and here it is:
https://github.com/m...leSupportForVSC

Please consider this a pre-release. I’m not aiming to make it a bulletproof, number-one tool, just a little helper for those working with ENG, WAG, INC, CVF, or SMS files.

Feel free to use the repository’s Issues section to submit feedback, suggestions, or anything that makes sense.

This is straight out of the oven, so more guidance for those not yet familiar with Visual Studio Code will follow later. Testing and feedback is highly appreciated.

---

Quick reference guide

1. Install Visual Studio Code
2. Install the extension (see INSTALL.md for instructions)
3. Open your Trains folder in VS Code
4. Browse or edit files as needed

#2 User is offline   Matej Pacha 

  • Engineer
  • Group: Posts: Contributing Member
  • Posts: 575
  • Joined: 08-December 10
  • Gender:Male
  • Location:Slovakia
  • Country:

Posted 24 September 2025 - 10:55 PM

How-tos:

Install:
Download the latest zip. The content should look like:
https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/zipContent.png?raw=true

In VSC extensions, select "Install from VSIX..." and follow the instructions
https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/installFromVsix.png?raw=true

When installed successfully, you should see it in the extensions list:
https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/installed.png?raw=true

The best way (in my opinion) is to open entire Trainset folder as a working set. The next set of screenshots shows basic features of the extension:
1) ENG/WAG files syntax support
2) foldable blocks
3) INC file support
4) CVF file support
5) SMS file support

There are more benefits of using Visual Studio Code, like indentation and code formating, support for audio files (you can play wav or mp3 directly), Github Copilot integration, Git versioning, and more.

https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/engWagSupport.png?raw=true

https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/foldable.png?raw=true

https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/incFileSupport.png?raw=true

https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/cvfFileSupport.png?raw=true

https://github.com/matejpacha/ORTSFileSupportForVSC/blob/main/examples/smsFileSupport.png?raw=true

#3 User is offline   copperpen 

  • Executive Vice President
  • Group: Posts: Elite Member
  • Posts: 3,252
  • Joined: 08-August 05
  • Gender:Male
  • Simulator:MSTS & OR
  • Country:

Posted 25 September 2025 - 01:50 AM

Hi Matej

Very nice program. Could not see the vsix on your github page, so downloaded the zip and found it in side that in another zip. Unpacked that, installed VCS worked out how to add the extension, and I now have a very nice editor. Thank you for your work.

#4 User is offline   Matej Pacha 

  • Engineer
  • Group: Posts: Contributing Member
  • Posts: 575
  • Joined: 08-December 10
  • Gender:Male
  • Location:Slovakia
  • Country:

Posted 25 September 2025 - 03:14 AM

View Postcopperpen, on 25 September 2025 - 01:50 AM, said:

Hi Matej

Very nice program. Could not see the vsix on your github page, so downloaded the zip and found it in side that in another zip. Unpacked that, installed VCS worked out how to add the extension, and I now have a very nice editor. Thank you for your work.


Hi,
glad to see some positive feedback. If you have any trouble finding the zip file, here’s a direct link.

Matej

#5 User is offline   Weter 

  • Member, Board of Directors
  • PipPipPipPipPipPipPipPipPipPip
  • Group: ET Admin Group
  • Posts: 9,405
  • Joined: 01-June 20
  • Gender:Not Telling
  • Simulator:ORTS
  • Country:

Posted 27 September 2025 - 02:04 AM

Hello.
While unable to test, I find it very useful, time-efficient and just nice.
Keep going. Thanks for efforts and wish further success!

#6 User is offline   cjakeman 

  • Executive Vice President
  • PipPipPipPipPipPipPipPipPip
  • Group: ET Admin Group
  • Posts: 3,087
  • Joined: 03-May 11
  • Gender:Male
  • Location:Peterborough, UK
  • Simulator:Open Rails
  • Country:

Posted 08 November 2025 - 02:39 AM

View PostMatej Pacha, on 25 September 2025 - 03:14 AM, said:

glad to see some positive feedback. If you have any trouble finding the zip file, here’s a direct link.

Thanks for this, Matej.

I've submitted a PR to add a link to this thread from the website.

Once approved, it will appear in the webpage Contribute > Building Models

#7 User is offline   Matej Pacha 

  • Engineer
  • Group: Posts: Contributing Member
  • Posts: 575
  • Joined: 08-December 10
  • Gender:Male
  • Location:Slovakia
  • Country:

Posted 09 November 2025 - 04:56 AM

Perfect, thank you. I believe this effort could help those who are not afraid of using AI. Visual Studio Code + Github Copilot is able to understand the context of MSTS/OR structure and help to edit/create files with ease.
I'm not planning to do regular updates or to provide 100% keywords coverage. The key is to promote AI to bring more quality content for OR.

Cheers,
Matej

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users