Excalibur (Twine 2, SugarCube 2.x) features a few instances of Chapel’s typing sim macro, but clicking into typing sim textareas doesn’t bring up the keyboard on mobile devices, meaning that the game can currently only be played on laptops and desktop computers. We’d love to resolve that for better compatibility with other devices.
Is there a way to force the keyboard to display on a phone or tablet when a textarea element is in focus?
I’ve been meaning to do something about this but I haven’t had time. I plan to probably make it so you tap the text area to fill in the message, either one letter at a time or all at once. Bringing up the software keyboard, afaik, isn’t really a viable solution.
Edit: Actually I think there is a way to do this. I’ll report back soon.
I’ve updated the
That’s brilliant news, Chapel! Thanks very much for your work on this.
Thank you so much, this is exciting!
I’m running into one issue. I replaced the old JS with the new, but when I test, the error “[tw-user-script-0]: Macro.add(…) is not a function” comes up. Textareas are now replaced with “Error: macro <> does not exist,” but anything between the macro tags is still displayed.
That’s really weird and doesn’t make a whole lot of sense. Not sure if I can fix that. I can double check to make sure the script works again later. You aren’t using some horribly outdated version of SugarCube, right?
I’ll let you know what happens when I check the script, but I did test it. In fact, I uploaded the test file to check mobiles, and its still there and working: typesim
So sorry for the inconvenience; I should have thought of that sooner. I’m certain you tested everything thoroughly by the time you first updated; I just managed to organize our JS weirdly.
Thanks so much for taking the time to look at this and even modify the macro. Your work is fantastic and much-appreciated!
It should work anywhere. That it doesn’t suggests to me that there could be an error somewhere in your JS code, so that may be something worth looking into.
That makes sense. I’ll definitely look into that and figure out what’s up. Thanks again for your help!
Thanks to you both for getting this working!