Changelog
May 31, 2026 ยท View on GitHub
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
Unreleased
- Nothing, yet.
[3.6.1] - 2026-05-31
Fixed
- Fix bug where comments inside multiline strings weren't properly stripped.
3.6.0 - 2026-02-15
Added
- Add multi-line string support.
- Inspired by HexManiacAdvance
- Add text-replacement support to
font_config.json.
[3.5.2] - 2025-02-16
Fixed
- Fix bug where invalid
mapscriptssyntax wasn't raising an error.
3.5.1 - 2024-11-24
Fixed
- Fix bug where
\Ndidn't respectnumLineswhen usingformat().
3.5.0 - 2024-11-10
Added
- Movement can now be inlined within commands using a special
moves()operator, similar to text. For example:applymovement(OBJ_EVENT_ID_PLAYER, moves( walk_left * 4 face_down )) - Print a warning message when
numLinesis missing from a font's config. Defaults tonumLines=2in that case, rather than0. - Added
msgboxto the defaultcommand_config.json, sincemsgbox(.., MSGBOX_YESNO)would be a very common use case.
Changed
- Multi-line string literals will now remove newline characters, and separate each line by a space character instead.
- This should rarely, if ever, be used. But the previous behavior resulted in invalid compiled scripts.
3.4.0 - 2024-08-15
- Add support for AutoVar commands.
- AutoVar commands can be used in place of the
varoperator to streamline comparisons. - AutoVar commands are defined in a new config file
command_config.json.
- AutoVar commands can be used in place of the
- Fix missing semicon character in FireRed/LeafGreen font config
3.3.0 - 2024-01-15
- Add ability to configure number of lines used by
format(). For example, this is useful if the text is intended to render in, a 3-line textbox (instead of the usual 2).- Additionally,
format()now accepts named parameters, andnumLineshas been included infont_config.json.
- Additionally,
3.2.0 - 2023-12-02
Added
- Add
-lmoption for C Preprocessor line markers to improve error messages.-lmis enabled by default. You can specify-lm=falseto disable line markers in the compiled output.
3.1.0 - 2023-11-11
Added
- Add support for configuration of the textbox's cursor width to improve
format()'s ability to fit text on a line.- This is achieved with a new
cursorOverlapWidthfield infont_config.json - Note, this change also changed the
maxLineLengthof the1_latin_frlgfont, so existing uses offormat()could be affected--especially when used in combination with explicit line breaks inside theformat()text content.
- This is achieved with a new
- Add automatic line break (
\N) support toformat()
3.0.3 - 2023-09-04
Fixed
- Fix bug where specifying a non-default font id with
format()would apply the wrong maximum line width configuration.
3.0.2 - 2023-05-20
Fixed
- Fix bug where a
switchstatement with all emptycasebodies would produce invalid output.
3.0.1 - 2023-01-08
Fixed
- Fix bug where
endandreturncommands could cause labels to not render.
3.0.0 - 2022-11-19
Changed
- Font configuration file is now called
font_config.json, and each font in that file contains amaxLineLengthused byformat(). The command-line option-fwhas been renamed to-fcto reflect the new name of the font configuration file.
2.14.0 - 2022-06-27
Added
- Add the ability to define sub-labels inside
scriptstatements. This is useful in some cases where it's more ergonomic to directly jump to a desired location inside a script, similar to C's goto labels.
2.13.0 - 2022-06-16
Added
- Add
martstatement, which is a convenient way to define a list of items used with the decomp'spokemartscript command. Prior to this addition, the mart data had to be encoded using Poryscript'srawstatement.
2.12.0 - 2021-12-27
Added
- Add
value()operator, which can be used on the right-hand side of avar()comparison. It will force acompare_var_to_valuecommand to be output. This makes it possible to compare values that occupy the same range as vars (0x4000 <= x <= 0x40FFand0x8000 <= x <= 0x8015). - Add ability to author inifinite loops using the
whilestatement without any boolean expression.
2.11.0 - 2021-10-23
Added
- Add -l command-line option to define default line length for formatted text.
- Add -f command-line option to define default font id from
font_widths.jsonfor formatted text.
2.10.0 - 2021-04-03
Added
- Add ability to specify custom directives for text. (e.g.
ascii"My ASCII text"will result in.ascii "My ASCII text\0")
2.9.0 - 2020-09-07
Added
- Add optional maximum line length parameter to
format()operator.
2.8.1 - 2020-05-06
Fixed
- Fix bug where
switchstatementdefaultcase didn't work properly when combined with other cases.
2.8.0 - 2020-03-25
Added
- Add ability to use the NOT (
!) operator in front of nested boolean expressions. Example:if (flag(A) && !(flag(B) || flag(C)))
2.7.2 - 2019-11-16
Fixed
- Fix bug where implicit text labels weren't properly inserted into command arguments.
2.7.1 - 2019-11-13
Fixed
- Fix bug where control codes with spaces in them (e.g.
{COLOR BLUE}) were not handled properly informat().
2.7.0 - 2019-11-05
Added
- Add support for compile-time switches using the
poryswitchstatement. This helps with language differences or game-version differences, for example. - Add support for user-defined constants with
constkeyword. This helps with things like defining event object ids to refer to throughout the script.
2.6.0 - 2019-10-26
Added
- Add support for scope modifiers
globalandlocalforscript,text,movement, andmapscriptsstatements. This will force labels for be generated with::(global) or:(local) in the compiled output script.
2.5.0 - 2019-10-16
Added
- Comments can now be used with
//, in addition to the existing '#' style. This is to support users who want to process Poryscript with the C preprocessor. - Add
movementstatement, which is used to define movement data. Use*as a shortcut for repeating a movement command many times.step_endterminator is automatically added to the end of the data. - Add
mapscriptsstatement, which is used to define map scripts. Scripts can be inlined, or simply specified with a label.
Fixed
- Fix harmless bug where
format()could result in empty.string ""lines in the compiled out. - Fix bug where
endcommand was incorrectly being replaced with areturn. - Fix bug where negative numbers were not parsed correctly.
2.4.0 - 2019-10-13
Added
- Add support for text auto-formatting with the
format()operator. Font widths are loaded from a config JSON file. Specify config file with-fw <config filepath>. If-fwis omitted, Poryscript will try to loadfont_widths.jsonby default.
Changed
- Text is now automatically terminated with a
$character, so the user doesn't have to manually type it for all pieces of text. Of course, this does not apply to text withinrawstatements.
2.3.0 - 2019-10-12
Added
- Add
defeated()operator, which is used to check if a trainer has been defeated. Without this newdefeated()operator, it was impossible to write scripts that checked trainer flags without usingraw. - Add
textstatements.
2.2.0 - 2019-10-07
Changed
- Identical implicit texts are now combined into a single text output.
Fixed
- Fix some potential infinite loops when parsing certain invalid scripts.
2.1.1 - 2019-09-14
Fixed
- Fix bug where hexadecimal numbers were not tokenized correctly, resulting in a space after the
0xprefix.
2.1.0 - 2019-09-11
Added
- Add implicit truthiness checks for
var()andflag()operators. - Add NOT (
!) prefix operator forvar()andflag()operators.
Changed
- Errors are now prefixed with
PORYSCRIPT, and they are written tostderr, instead ofstdout. - The program will no longer panic when handled errors occur.
Fixed
- Fix parser errors that were not showing the line number of the error.
2.0.0 - 2019-09-02
Added
- Add single-line comments with the
#character. - Add
go.modfile so the project can be built outside of the Go workspace. - Add
whileloops. - Add
do...whileloops. - Add
breakandcontinuestatements. - Add compound boolean expressions.
- Add output optimization which significantly simplifies and shrinks the resulting compiled scripts. Turn off optimization by specifying
-optimize=false. - Add
switchstatements.
Changed
rawno longer takes a label name.- Removed
raw_global, since there is no longer a concept of being global or local forraw.
Fixed
- Inline texts are now generated with labels that are prefixed to their parent script's name. Otherwise, they would easily clash with external scripts because they were all simply named
Text_<num>.
1.0.0 - 2019-08-27
Initial Release