Skip to content

feat: parse interpolated localized strings#31

Merged
KockaAdmiralac merged 5 commits into
utdrwiki:masterfrom
ezhevita:feat/formatted-localized-strings
Jun 27, 2026
Merged

feat: parse interpolated localized strings#31
KockaAdmiralac merged 5 commits into
utdrwiki:masterfrom
ezhevita:feat/formatted-localized-strings

Conversation

@ezhevita

Copy link
Copy Markdown

Resolves #24.

Adds support for parsing localized strings in the following functions:

  • c_msgnextsubloc
  • c_msgsetsubloc
  • msgnextsubloc
  • msgsetsubloc

Example (gml_GlobalScript_scr_get_completed_file_name from Deltarune Chapter 4):
Screenshot 2026-06-27 at 14 40 25

The interpolated argument can be hovered over to reveal its index:
Screenshot 2026-06-27 at 14 40 59

In the future it could be made so hovering over displays the interpolated expression itself, but this is beyond the scope of this pull request.

@ezhevita

Copy link
Copy Markdown
Author

I thought about displaying interpolated expressions instead of "Argument №X", but it requires to properly parse the line syntactically in order to extract the arguments (since they might contain nested function calls or strings, so just splitting by , is not enough).

There are at least 2 unique occurrences in Deltarune where this is the case:

@KockaAdmiralac KockaAdmiralac left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@KockaAdmiralac KockaAdmiralac merged commit 5df0bba into utdrwiki:master Jun 27, 2026
1 check passed
@ezhevita ezhevita deleted the feat/formatted-localized-strings branch June 27, 2026 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

stringsetsubloc support

2 participants