Many RPGs and other genres of games use a scrolling textbox to display dialog. This is a very common desire for game developers, so I decided to create dtypewriter to handle this task.
Defold Typewriter provides text scrolling and styling in a Defold game engine project. It uses HTML-style markup for specifying character colors, speeds, new lines, new paragraphs, etc. New features are easy to add, so I expect this extension to grow as I continue using it in my own projects.
Here is an example of how the above gif was formatted with raw text:
"Just like the classic RPG dialog systems, <color=green>dtypewriter<color=default> is a fantastic dialog solution!<paragraph>It can do all kinds of neat things, like <color=green>colors<color=default>, <speed=3>speeds<speed=default>, and <speed=instant>instant text display<speed=default>, among other things!"
Hi, this library looks perfect for what I want to do! I’ve added it into my project and it’s sending all the start, type messages etc but not doing anything on the screen, and I’m not quite sure where I’ve gone wrong. Would it be possible to provide an example of working code I could look over?
Hey I love your project, and it works just as advertised in Defold 1.9 EXCEPT (you knew there’d be an except)
It does not build into a functional HTML5 AFAICT. When I build it, it hangs on a black screen and stays there, doesn’t matter whether I do a test build within the IDE or bundle it and run it remotely.
Digging around, it looks like you’re using Lua 5.2 syntax with :: notation and goto. When I try to run your code internal to Defold’s IDE, it crashes, informing me that it’s not compatible with 5.1.
It builds if I turn off linting (as suggested for other 5.2 problems).
Considering that the HTML5 build appears to be crashing on the :: notation, it seems like the issue is somehow to do with 5.1 vs. 5.2?