I have been exploring concurrency and state while working on a text adventure game and one of the tricky things is how to refresh the screen when something happens. When an app is awaiting user input via
Mix.Shell.IO.prompt/1, is there any way to refresh/redraw the screen? For example, when something happens in the game, I would need to notify the user, and ideally I would want to do this BEFORE they input their next command and press enter.
I hope that makes sense. I’m scratching my head a bit when there is probably a simple solution. Thanks for any tips!