Results 1 to 9 of 9

Thread: Syntax highlighting for Total War files in Sublime Text 3

  1. #1
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Icon3 Syntax highlighting for Total War files in Sublime Text 3

    Hello fellow modders,

    I had some time to spare and wanted to create a new syntax highlighting. Sadly notepad++ isn't the best choice so I have decided to use Sublime Text 3.
    Of course, one could use the previously created one for notepad++, but Sublime Text 3 allows you much more to specify the grammar of your syntax and therefore allows you get much better results.

    For those of you who are a bit more into programming, I wrote the file in JSON and then converted it into YAML. I haven't written it directly in .tmLanguage since the syntax is quite similar to XML, which sucks..

    About:
    The download includes a .tmLanguage file, which contains all the syntax highlighting for an Edu, descr_strat, campaign_script and edct in Medieval II Total War.

    Download:
    export_descr_unit
    descr_strat
    export_descr_character_traits
    campaign_script

    Install:

    Copy the file into the following directory - C:\Users\[User_name]\AppData\Roaming\Sublime Text 3\Packages\User
    Of course you have to download sublime Text 3, as well.
    That can be done here: https://www.sublimetext.com/3

    Plans for the future:
    Next stop will be to create a syntax highlighting for the ancillary file.

    How to use:
    Click View->Syntax->scroll all the way down to 'User'-> 'TotalWarEDU' | 'TotalWarStrat' | 'TotalWarCampaignScript'

    export_descr_unit:
    Spoiler Alert, click show to read: 


    descr_strat:
    Spoiler Alert, click show to read: 


    EDCT
    Spoiler Alert, click show to read: 


    Campaign_Script
    Spoiler Alert, click show to read: 


    I hope, I can make your life a bit easier with this small tweak

    Regards,
    Aneirin
    Last edited by Aneirin; February 18, 2017 at 07:47 AM. Reason: Updated available highlightings
    Proud son of Aikanár and brother of Iskar

  2. #2
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Default Re: Syntax highlighting for EDU files in Sublime Text 3

    Updated
    Proud son of Aikanár and brother of Iskar

  3. #3
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Updated
    Proud son of Aikanár and brother of Iskar

  4. #4
    Senator
    Join Date
    Jan 2016
    Location
    Germany
    Posts
    1,121

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    hmmm, seems like I have to move to sublime Text 3.

    Good work!

  5. #5
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Thank's mate!
    Let me know if you have any troubles
    Proud son of Aikanár and brother of Iskar

  6. #6
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Added highlightings for campaign_script files
    Proud son of Aikanár and brother of Iskar

  7. #7

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Download links are broken and I can't find them uploaded anywhere else, can you upload these to Github or Gist?

  8. #8
    Aneirin's Avatar of flowing verse
    Join Date
    Nov 2012
    Location
    Gododdin
    Posts
    2,734

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Sure, I'll try to find the files and reupload it.
    Proud son of Aikanár and brother of Iskar

  9. #9

    Default Re: Syntax highlighting for Total War files in Sublime Text 3

    Can a similiar thing be done for Visual Studio Code?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •