I would like to port this question to Python (Windows + Linux + Mac Os)
How to create ASCII animation in Windows Console application using C#?
Thank you!
I would like to port this question to Python (Windows + Linux + Mac Os)
How to create ASCII animation in Windows Console application using C#?
Thank you!
This is precisely the sort of application that I created asciimatics for.
It is a cross-platform console API with support for generating animated scenes from a rich set of text effects. It has been proved to work on various flavours of CentOS and Windows and OSX.
Samples of what is possible are available from the gallery. Here's a sample similar to the animated GIF code provided in other answers.
I assume you're just looking for a way to do any animation, but if you really wanted to replicate the steam train, you could convert it to a Sprite and give it a Path that just runs it across the Screen, then play it as part of a Scene. Full explanations of the objects can be found in the docs.
Colorama: http://pypi.python.org/pypi/colorama
I just ported my example with the animated gif to ASCII animation from my answer here to python. You will need to install the pyglet library from here, as python unfortunately has no built-in animated-gif support. Hope you like it :)
Simple console animation, tested on python3 in Ubuntu. addch() doesn't like that non-ascii character, but it works in addstr().
@Philip Daubmeier: I've tested this under Windoze and it doesn't work :(. There's three basic options going forward: (please choose)