Community
    • Login

    is there a way to make delimeter check UP UNTIL closing char??

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    udludl
    3 Posts 2 Posters 204 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      firedihm
      last edited by firedihm

      I’m trying to make a lang for a file that stores specific string format for a videogame. Strings have tokens inside them that tell the game what color to use when drawing characters.

      Get the ~g~briefcase~w~ and return it back to casino
                   ^green          ^white

      The string is white by default, then the word “briefcase” will be drawn green, and after it color switches back to white.

      So far, I came up with following delimiter rule:
      f1.png

      But this setup has an issue with first ~ of ~w~ being colored green, because I assume npp considers closing char of delimiter as it’s part. That also breaks whole setup, since npp can’t find ~w~ at all and switch text back to white.
      53ed238b-3e0b-4b02-a20b-5d5cfbcf45e4-изображение.png

      So the question I want to ask, is it possible to set a rule for delimiter’s closing char that would only scan up until that char?

      supasillyassS 1 Reply Last reply Reply Quote 0
      • supasillyassS
        supasillyass @firedihm
        last edited by

        @firedihm Change the closing delimiter to just ((EOL)) and add “Delimiter 3” to the nesting of Delimiter 7.

        F 1 Reply Last reply Reply Quote 1
        • F
          firedihm @supasillyass
          last edited by firedihm

          @supasillyass thanks for the suggestion, but looks like nesting is also not the best solution
          78b4ea44-d918-4cc7-8ec8-b532db7aef28-изображение.png

          Header [ ] highlighting breaks. That’s probably because [HELP2_A] has level 5 nesting, so it would need to encounter 5 ((EOL))s to properly exit.

          Simply inserting newlines helps resolve this, but it makes file look stupid
          b2245093-0e91-49a1-a640-717f18b58307-изображение.png

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors