Skip to content

Repository files navigation

Roton (with Lyon frontend)

license

This C# project consists of two major components, Roton and Lyon.

Special thanks to Asiekierka for the Reconstruction of ZZT project. Without this, some of the really edge case stuff probably wouldn't have been implemented.

Roton

Roton is an emulation of the ZZT and Super ZZT game creation engines.

Target framework is .NET Standard 2.0. This means it should be compatible with any modern version of .NET and can be linked from .NET Framework 4.6.1+ projects as well.

See the Developer Tips file for more information about developing Roton itself.

Lyon

Lyon is an application that runs an instance of Roton's emulation and presents it via SDL. We use ppy/SDL3-CS for this.

Target framework is .NET 10 or above. If you are able to install .NET 10, it is very likely you will also be able to run Lyon on your operating system.

Target Frameworks

  • Lyon
    • .NET 10+
  • Roton
    • .NET Standard 2.0

Build instructions

The .NET Core SDK is required. Output goes to /Deploy.

Clone the repo:

git clone https://github.com/SaxxonPike/roton.git
cd roton
git submodule init
git submodule update

Restore NuGet packages and build:

dotnet restore
dotnet build

Run unit tests:

dotnet test Source/Roton.Test

Build and run:

dotnet run --project Source/Lyon <path-to-game>

Lyon Command Line

[<path to world>] [--fast] [--no-pester] [--trace]
  • <path to world>
    • If specified, the game will start by loading the specified world. This is also used to determine which engine to use. If you want to boot into Super ZZT worlds, you will need to specify a world with the .SZT extension.
  • --fast
    • When game speed is set to fastest, the game will run as fast as possible instead of throttling.
  • --no-pester
    • Disable many built-in messages ("a fake wall!") and the water sound.
  • --trace
    • All scripts will be traced to the console. This gets very spammy on complex boards!

Using Roton in Your Own Project

Roton provides a RotonServices class that can be used to retrieve the type mapping needed by your favorite dependency injection library.

AutoFac:

// Each concrete type must have all its services registered at the same time
// so that AutoFac knows that they all refer to the same instance.

var map = RotonServices.Get(context, additionalAssemblies)
    .GroupBy(s => s.Implementation);

foreach (var serviceGroup in map)
    builder.RegisterType(serviceGroup.Key)
        .As(serviceGroup.Select(sg => sg.Service).ToArray())
        .AutoActivate()
        .SingleInstance();

Where can I learn more about ZZT?

  • https://museumofzzt.com/ - a preservation site for all things ZZT. The original games can be found here, plus a massive library of others from the community over the years. Administered by Dr. Dos. (The developers really appreciate this site.)
  • http://zzt.org/fora/ - if you want to immerse yourself in the culture and in-jokes, this forum has preserved everything since 2003. Be warned: it's a bit juvenile in there.

How can I contribute to Roton?

Contributions are accepted differently depending on the nature of the contribution.

ZZT emulation fixes

Odd things found in Roton's emulation methods are very likely a product of the reverse engineering process. Changes can be submitted, but often times it's better to file a bug than to commit code to the emulator core unless you've verified using the provided IDA databases. These databases are stored in the IDBs folder.

Lyon, frontend fixes

Fixes to the frontend or SDL integration are very welcome!

Process

Get in touch with either @SaxxonPike or @Spectere once you've finished your work so it can be approved for inclusion in the master branch.

About

Cross-platform ZZT and Super ZZT clone in C#.

Resources

Stars

24 stars

Watchers

8 watching

Forks

Releases

Packages

Used by

Contributors

Languages