Please Steal this Code!
If you've ever considered developing your own MUD client (an online text gaming app) but were discouraged by the preliminary protocol implementation step, this code will set you free to start working immediately on the features you care about. If you're new to the idea of online text games, here's the fact you need to know - there are hundreds of "MUD" servers out there, and all use the same basic protocol. This means you may develop a client application which connects your users to ANY of those games, then add features to delight and excite them.
Despite the hobbyist community's frequent introduction of new MUD servers (see www.mudconnect.com), online text games as a genre are languishing. Starting with Everquest's first release, the availability of graphical online RPG games has been pulling gamers away, and text game developers (both client and server) haven't yet "upped their game" accordingly. Clients are especially problematic, because most are at least 10 years old, developed on decade-old platforms. They get the job done, but they don't look or feel modern, so potential gamers hesitate to give them a chance.
Today's technology offers an opportunity to deliver a much-improved user experience - imagine a client which "feels like" an open book rather than a rainbow-on-black avalanche of text, or a themable multi-window client complete with high-res background image, animations, smooth scrolling, transparency, and streaming music. Client developers also face entirely new challenges in taking text gaming to touch screens, tablets, and mobile phones.
Starting from scratch, would-be MUD client developers are often quickly discouraged when they learn there are two big hills to climb - Telnet, a 30-year-old protocol documented in truly archaic format, and ANSI color, the standard for embedding color information in MUD text. Telnet tends to be the most problematic because its byte values aren't readable by the human eye (they don't map to printable characters), and because due to its introduction in a time when bandwidth was scarce, a lot of complexity was introduced to keep it efficient.
You can read more about MUD client development here: Modernizing the MUD Client.
Using the Code
This code project includes all the C# code you need to support both Telnet and ANSI color, AND a sample WPF (Windows Presentation Foundation) application which uses that code to complete a bare-essentials MUD client.
Please take this code and build a better client! The text gaming community will thank you!
Interested in becoming more involved in the text gaming community? Try these sites:
- 4th April, 2011: Initial version
- 14th April, 2011: Added one bullet to list of related links