Describe the bug
2.0.0 introduces the ability to use #xx# to display the value of a variable as a character from the ASCII table. Options in menu event have a max length of 6 characters. However, when using #xx# to display characters within a menu, the text field within the editor will only accept four characters and, upon trying to type in a fifth, delete everything typed after the third character.
This is to say that "#00##00##00##00#" will display properly in the game and editor. When trying to add one more "#00#" the editor will then force "#00##00##00#" into the text input field.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
This is an issue because menu options are able to display six characters but the text field is not allowing the user to input any more than four characters using the "#xx#" format.
Platform (please complete the following information):
You may be able to write them externally and paste them for now, #00# should be considered 1 character once written, but before is considered regular per character text.
There is also an old plugin floating around discord by @pau-tomas that is menu without a text limit check.
It's unfortunate that character count for menu is not based on the total character count of the fields, but quite tricky to do.
You may be able to write them externally and paste them for now
A tiny bit inconvenient, but I can confirm that this does work.
There is also an old plugin floating around discord by pau-tomas that is menu without a text limit check.
Ah yeah, I had forgotten about this.
It would also be really convenient if we could have some method for storing "strings", like you could define that a string %NAME% was represented by #00# -> #06#. We could even then consider adding support for NULL terminator. That way In our dialog code, we would only write "Hello %NAME%!", and it would print the characters in the range defined by %NAME% until NULL was encountered
Could do, a short hand for a set of #00# to # 06# wouldn't be a bad idea.
You would still need to define/know how many characters it can take at max per string, to count towards character limit in dialogue.
The null terminator would be cool, so you don't end up with an empty space if your name is short, however would that rule out a simple editor hack which could just replace the %NAME% with the right set of #xx#s to process into variables?
I'd need to dig deeper into how we determine/compile a number variable byte from a letter variable byte. Get's a tad confusing as variables are optimized to use only what is needed.
A UI only solution that maps #STRING# (or %STRING%) to a set of character variables #00# and replaces them at compile time was my thinking for this.
It'd require a string editor of some sort to create the mapping, but I think it should be doable.
Yeah, that would be a very powerful feature to implement. And with the now 30 actor limit, it would actually be possible to implement on screen keyboards that can store the values to those strings. I see this as a very useful feature.
@thomas-alrek 30 actors per scene, but only 10 on screen at once,
However, the new point and click scene supports many more trigger click spaces, and @pau-tomas had a working keyboard example in script just hours after #00# was implemented 馃槅
Or you could just attach a script to a button, when pressed it grabs the player "cursor" (Point-and-Click, RPG, whatever) Y, runs it through a Switch statement, then a sub-switch that grabs their X and sets the next character variable to the appropriate value. You could possibly even skip the bulky Switch and do it mathematically, but you'd have to account for offsets for the characters compared to the expected display. That'd be pretty easy if you stuck to just the contiguous letters, though.
One addition I'd like, if it doesn't already exist, is to allow for writing characters directly with the command, like #A120# just outputting the matching character. Reason being while you can use Alt-Codes to input non-standard characters, some don't work properly in the text entry field due to their nature, so parts of the sheet are unusable. This would let us reclaim that space without storing it in a variable first.
@SetsuneW I think that's unrelated, if you're having issues typing or finding a character, try this https://gist.github.com/RichardULZ/2920dca52989902dbb7225318256c545 another thread on the discussion of more languages also talked about defining the characters usable /mapped in ascii so you could use your own letters.
I don't think it was unrelated to the post I was replying to. I did find your chart yesterday, but copy/paste operations with unprintable characters can be a clunky process, especially since you can't differentiate them in the GB Studio text box.
Most helpful comment
@thomas-alrek 30 actors per scene, but only 10 on screen at once,
However, the new point and click scene supports many more trigger click spaces, and @pau-tomas had a working keyboard example in script just hours after #00# was implemented 馃槅