XMPP Bridge release

XMPP Bridge is being released as an open source project under the BSD license. A repository has been created on GitHub here and you can download the 1.0 tar.gz bundle here.

In addition to the frotz Z-game and MUSH modules, I’ve created example modules for bridging your XMPP client to other text-based apps and network resources. It should also now run on either Ruby 1.9.x or Ruby 1.8.x.

Included in the current release are example modules for…

a GForth interpreter:

gforth via xmpp

gforth via xmpp

the Ruby irb interpreter:

irb via xmpp

irb via xmpp

an IRC client:

irc via xmpp

irc via xmpp

a simple MUC bridge:

muc bridge

muc bridge

 
These modules are far from bug-free and are very simplistic, but they generally get the job done for me.  Some might ask why a MUC bridge when XMPP clients can connect to MUCs already?  Well, not all XMPP clients are MUC-capable, specifically the XMPP client that I use on my Blackberry.  So this gives me a way to participate in a MUC while mobile.  Also, it can serve as a starting point for a MUC management/admin bot.

I can’t really offer much in the way of technical support for this project, but if you have questions your best bet would probably be to ask in the lobby of my XMPP Bridge instance at bridge@xmpplink.com.

1 Comment

Jabber/XMPP Game Bot for Z-Machine, MUSH, and more…

Inspired by Prakbot, an XMPP bridge to the Hitchhiker’s Guide to the Galaxy text adventure, allowing anyone to play the text-based game via Jabber or GoogleTalk, I decided it might be fun to write a similar XMPP bot using Ruby’s XMPP4R. In addition to figuring out how to make an XMPP bridge to a z-machine I also wanted to bridge to other text-based game systems, like a MUSH/MUD or a Trivia game.

What I ended up with was a Jabber/XMPP bot, “XMPP Bridge”, which acts as a sort of “chat lobby” for any subscribed users and from which users can launch other text-based games. So far I have implemented the z-machine bridge, a MUSH bridge, and a simple Trivia game module.

To try it out, just add bridge@xmpplink.com to your contact list. It is currently set to auto-authorize any subscription requests received. Once the XMPP Bridge has accepted your subscription request, just initiate a chat with it and send the !help command to receive a list of valid commands:

Connecting to the Z-Machine:
  
To connect to the z-machine and run a z-game, use the !frotz command. For instance, !frotz zork1 will connect you to the Zork I game:

The z-machine implementation supports Save and Restore. Save files are automatically saved based on the player’s Jabber ID (JID). The advantage to this system is that a player’s Save files are guaranteed to be inaccessible to other players, but the disadvantage is that each player only gets one Save file per z-game. So think before typing “save”, as your last game save will be overwritten.

The !frotz command also supports a screen-width parameter (e.g., !frotz zork1 35) to make it easier for playing and viewing the output on mobile devices.

To get a listing of the available z-games, use the !frotzlist command:

Connecting to the MUSH:
To connect to the MUSH, use the !mush command.

Using a separate thread and a network socket to connect to the MUSH, input and output is bridged between the player’s Jabber client and the MUSH.

Connected to the MUSH:

Simple Trivia Module using an SQLite database for questions:

A trivia game can be started using either the !new command or the !join command, The trivia module supports up to five players per game. Several games can run concurrently and players can join or leave running games or start a completely new game. This module still needs some tweaks (e.g., accepting an answer of “20″ as well as “twenty”). Another issue is the fact that there is no real guarantee that messages sent by the bridge to players will arrive in the same order they were sent.

7 Comments

Bad Behavior has blocked 23 access attempts in the last 7 days.