Tutorial Tools of the Trade: Notepad ++ v.1

Discussion in 'Starbound Modding' started by The | Suit, Oct 8, 2015.

  1. The | Suit

    The | Suit Agent S. Forum Moderator

    In the this part of Tutorials for Tools of the trade we look at Notepad++.
    When it comes to user friendliness with a decent feature set, it is probably one of the best in the playing field for windows.
    Notepad++ is by far one of the best applications to use if you never used a codepad style app before, especially if you are a person who can get easily lost in menus and features.

    https://notepad-plus-plus.org/ ( Windows Only )

    Search Functionality.
    When it comes to search functionality it may not be as fast as sublime but it does offer one advantage over it.
    The use of extension filters without having to resort to regex.

    When you hit Control + F a full feature window appears, which includes all 4 search tabs in one window.
    The one we will be focusing on is Find in Files.


    Find in files will let you look for a specific reference to a piece of code through all files which exist in the directory of your choosing.
    For example say you want to know all files which reference a particular file.
    This is important since when making a mod you want to make sure you do not miss a single associated file.
    In this case lets deal with biomes, barren. So what I can do is set the folder to entire unpacked place barren inside. then hit search.

    Every instance of the word Barren would be displayed in the results. So now when I create a new biome I will know where all I have to make changes in order for my biome to be considered valid.

    Or say I want to look for a particular lua snippet. To see how its used, I could do the same, but I would needlessly be searching JSON files also. This is where "filter" comes in.
    By changing the filter to *.lua - now the search engine only bothers to search lua files. Which drastically cuts down search time.

    Long story short the search functionality will be a great tool in your belt when utilized effectively.

    Bracket Highlighting
    Just like Sublime - Notepad ++ has bracket highlighting. But unlike sublime it comes with a much more powerful one in comparison.
    It includes both sidebar highlighting as well as contrast bracket highlighting.


    You will notice both the beginning and closing bracket are highlighted in red when your cursor is placed next to one of them.
    Also on the left side bar you will notice a line indicating all content within it.
    Unlike Sublimes simple single underline which is barely noticeable without a separate package.

    In Notepad++ case there isn't any specific separation for JSON, but using JavaScript as the set language when dealing with JSON starbound file-s will work easily as well.

    Plugins \ Extensions
    Unlike Sublime though, Notepad++ has few plugins to add extra features. But in case of your needs for starbound modding,
    it already comes with a full package feature set and there really isn't much more you need from it.
    But if you are curious what is available, you will find a few here;

    Notepad ++ also does support columns similar to sublime. Though its not as readily apparent.
    To create a column to more easily see 2 documents at once, click on the tab you want as a separate column then choose "move to other view"

    Other Tools of the Trade Guides:
    lazarus78 likes this.
  2. lazarus78

    lazarus78 The Waste of Time

    I prefer using Java as the language for JSON. Seems to highlight better.

    Also, if you use tab indentations, it will highlight the apprpriate vertical line connecting the brackets.

  3. bk3k

    bk3k Oxygen Tank

    Now I found something that added proper JSON to the language menu a while back. Forgot where I found it, but anyone could Google their way to it. But anyhow that isn't why I'm replying to this thread.

    For those who don't want to mess with the style options and all that, but want much easier to read Starbound logs... check out the attached file.
    1. Unzip that file somewhere. It is an xml file
    2. Open notepad++
    3. Click up top on the "Language" menu.
    4. Towards the bottom it says "define your own language" so click there.
    5. In the window that opens, at the top left it says "import" so click there.
    6. Browse to where ever that file you unzipped is and select that file.

    There you go! Your starbound.log file just became much easier to read! If anyone has any suggestion where that could be improved, let me know. For one thing, I notice it isn't treating hexadecimal as actual numbers and I don't know how to/if I can fix that(aside from editing/compiling their source code LOL). The other failure occurs if a mod's name incorporates ' then it will throw everything after that point off. Also not something I know how to fix(if possible). But I think this is way better than nothing.

    I didn't think to attach screen shots(which seems obvious to do).

    logFile1.png logFile2.png logFile3.png

    Attached Files:

    Last edited: Dec 27, 2016
    Le'Orange likes this.

Share This Page