This update uses new Regex commands to make full use of its features. The old regex should still work if you're content with it, but the new is included in this update log to be copy/pasted into Fleece's settings.

* Custom commands inside of if statements are now parsed before all others, allowing for more dynamic parsing. Type them up without carets inside of an if statement. ``<<if random(2)>>``

* Updated if statement regex to match this. ``<<\s*if\s*((?:\$|#)?(?:!|-)?[\w\(\),]*)\s*(?:(.*?)\s*(\$?(?:!|-)?[\w\(\),]*))\s*>>``for people who want to copy-paste it into their current settings!

* Else if regex, too: ``<<\s*(else\s*)if\s*((?:\$|#)(?:!|-)?[\w\(\),]*)\s*(?:(.+?)\s*(\$?(?:!|-)?[\w\(\),]*))?\s*>>``

* Updated insert regex, too: ``<<\s*(\$?(?:!|-)?[\w]*)\s*>>``.

* New set regex: ``<<\s*set\s*(\$(?:!|-)?\w*)\s*(\S*?)\s*(\$?(?:!|-)?[\w\(\),]*)\s*>>``

* New command regex: ``<<\s*(\S*)\(\s*(.*?)\s*\)\s*>>``

* Now, the insert tag can use custom commands too, but only if it's explicitly an insert tag. So... ``<<myCommand()>>`` works as a command, but ``<<myCommand() == 0>>`` will do a check and print either "True" or "False".

* The first variable inside of an if statement doesn't have to be a variable anymore. (Doesn't have to start with a $ for evaluation). Extension scripts to the parse have a new "arg0isVariable" boolean to use, but this is optional, so old code will not break if not fully implemented. (Overrides will have to be updated with a new boolean). Variables should still be marked with $, but this is a fallback, now.

* Fixed ``<<endif>>`` tags not working properly if at the end of a passage in some circumstances.

* Linebreak strings and custom parsing is now applied to drawstrings automatically.

* Adjusted excecution order of the "Insert Linebreak Strings" method to work more as intended.

* Added a "csv sort title" option to CSV export settings. If an exported CSV is sorted by theis column, then passages can be sorted by Folder/Subfolder/Title. This means a more logical organization for translators will be possible.

* All applicable ToString() calls now use System.Globalization.CultureInfo.InvariantCulture.

* Added a "lastChoiceIndex" property to drawstrings, which returns the index of the last choice made. This can be a different number than the currently selected choice, since some options may be hidden.

* Parser "visited" methods will now accept multiple passages. eg. ``<<visited(1,2,3)>>`` This will return true if all listed passages have been visited.

* Added a "visitedany" method to parsers that returns true if any of the passages listed are visited.

* The inversions of both of these methods work, so !visited/notvisited and !visitedany/notvisitedany will return the opposite.

* Fixed else if statements not being found if an else statement didn't exist.

* Fixed parser sometimes getting caught up on 0-length strings.

* Restore method better defined now, and Restore does not execute events at very start of passage anymore.

* Fixed drawstring not properly advancing passages under specific circumstances.

* Fixed CSV import failing on stories without a base story.

* Adjusted where passages are marked as visited to be a more expected behaviour.

* Added a "this" option to the visited command, allowing to quickly check if the current passage has been visited. ``<<if visited(this)>>``

* If Fleece detects that a folder is set as its own parent when switching stories, it will correct this issue.

* Added a middle line to the grid view that aligns with 0,0.

* TextArea for editing text in the Fleece window now has a minimum height of 4 lines. (Thanks, Jasper!)


Fleece v2.2.0.unitypackage 3 MB
Jan 20, 2022

Get Fleece

Buy Now$65.00 USD or more

Leave a comment

Log in with itch.io to leave a comment.