Editor highlighting of tpt

  • L974
    5th Oct 2016 Member 1 Permalink

    I used to write a lot of scripts for Framsticks for my experiments (it has been a while) and they had some configuration files for editors so that the script syntax gets highlighted.  

     

    Is there something like that for tpt somewhere ? It would help me a lot because typos can be a pain in the ***

     

     

  • LBPHacker
    5th Oct 2016 Developer 0 Permalink

    I don't think there is. What editors do you use?

  • L974
    5th Oct 2016 Member 0 Permalink

    I have just looked into it and I think I will make a custom syntax file for tpt (lua) that can be used with the Vim editor.I will post it in the forum when I am finished. But don't wait for it. It will probably take me some time to get it right. Never done something like this before. 

    I think its somewhat important especially when your scripts are getting complicated. With the syntax highlighting

    of tpt it would be a lot easier to find bugs. Typos will be a thing of the past if it works :)

     

     

     

     

    Edit:I can't seem to find a list of all commands etc. that are usable in the script. Where to look for the information?

    Edited once by L974. Last: 5th Oct 2016
  • jacob2
    5th Oct 2016 Member 0 Permalink
    @L974 (View Post)
    https://powdertoy.co.uk/Wiki/W/Powder_Toy_Lua_API.html

    A standard lua highlighter should work just fine though.
  • MiningMarsh
    5th Oct 2016 Member 0 Permalink

    @L974 (View Post)

    Just use any editor with nice lua support.

  • L974
    6th Oct 2016 Member 0 Permalink

    Almost any editor has lua support.:) Thats not the problem. I just want the tpt part to highlight so that you realize right away when you write something wrong.  

    This used to help me A LOT when I was experimenting with Framstick script and it would be great if it worked somehow for tpt.

    I will add the custom highlighting file myself for Vim. (it's not that hard)

    Maybe I need the highlighting help because I am new to tpt script (and I am also disabled since am 30 unfortunately).