Skip to content

Starciad/StarASCII

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 

StarASCII

MIT License NuGet

🧩 ➥ Library for creating ASCII animations for terminals.

Table of Contents

Installation

The latest version is available on NuGet. To install, run:

dotnet add package StarASCII --version *

Replace the asterisk (*) with the desired version.

Alternatively, clone the repository and reference it manually:

git clone https://github.com/Starciad/StarASCII.git

Getting Started

After installation, add the StarASCII namespace:

using StarASCII;

You can now use the SAnimation class to create and run animations:

SAnimation anim = new SAnimation();

Next, add frames using the AddFrame(SFrame) method:

SFrame frame = new SFrame(string, uint);
anim.AddFrame(frame);
  • string: content of the frame.
  • uint: duration in milliseconds.

Once all frames are added, run the animation:

anim.Play();

Important

When calling Play(), the main thread will be paused according to the frame durations.

Explore the classes and features to fully customize your animations.

Tips and Recommendations

  1. Frame size: Keep all frames the same size to avoid visual issues.
  2. Using text files: For complex animations, save frames in external text files or use const or readonly static properties to avoid hardcoded ASCII art.
  3. Reuse animations: To save resources, reuse animations by storing them in collections, lists, or static properties, especially in performance-critical scenarios like loops.

Samples

Try the sample project here. You can also view some GIFs showcasing the library's capabilities:

  • Sample 1: Blinking Eye sample_01
  • Sample 2: Walking Man sample_02
  • Sample 3: Zebra sample_03

Issues

Have a problem? Open an issue!

Contributing

Contributions are welcome! Please check the CONTRIBUTING.md for guidelines.

License

This project is licensed under the MIT License. See the LICENSE.md file for details.

About

🧩 ➥ Library for creating ASCII animations for terminals.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages