Use TURBO mode to see the demonstration pattern. (Press the <Shift> key and click the Green Flag for TURBO mode). See original project for explanations. So, I made a Text Engine for this challenge. There is no word wrapping, no colors, but it's case-sensitive. It is very slow, try turbowarp (https://turbowarp.org/816989188?turbo) to make it slightly faster.
The code could be much smaller if it wasn't case-sensitive. Also, I could have optimized the script for letters but I was getting lazy about this project.