Category Archives: Basternae and ModernMUD

Posts about the Basternae MUD and/or the ModernMUD codebase.

First Very Broken Version of the WPF-Based Client

Here’s a screenshot of the Basternae Client, version 0.20:

There are some things missing and in a few ways it’s a step back from the previous C++-based client (version 0.18 — 0.19 was never released).  However, it does work with the new map graphics.  Roads still need a little work, but that’s a server-side change.

There are some very broken things about version 0.20 of the client, and I wouldn’t recommend installing it (which is why there’s no download link).

– Aliases aren’t in yet.
– It leaks memory like a sieve.
– A bunch of ANSI color things need work.
– It doesn’t even exit properly.

It can only get better from here.

Back to WPF

A while back I made a start on building the client using WPF, the Windows Presentation Foundation. It only made sense to give it a shot since the whole MUD is based on C# and .NET.

That effort stalled due to a roadblock or two, probably because I didn’t know about routed events and partly because I didn’t understand RegEx very well. I have a better handle on regular expressions thanks to spending some time with the Django web framework.

In the process of trying to rework the C++/wxWidgets-based client to support the new tiled map graphics I’ve experienced a lot of pain. The kind of pain that can only be explained by the fact that a string is not a first-class object in C++ and that text parsing can get to be unbearable when you have a complex stream over TCP.

That has prompted me to take a look at the WPF version of the client again. Rather than being based on some ugly recursive character-by-character text processing code, it’s based primarily on regular expressions — one to parse out the ANSI codes, and one to process the XML tags for the various client data (life meter, map info, room description, etc.). The first one was done when I left off, but the second piece hadn’t been started yet. Well, it’s in place now and I can continue building the rest of the newer client.

Getting the WPF version up to and past the usability of the wxWidgets version will probably be faster than untangling the text parsing in the spaghetti code.

Client Work

John Baker has delivered a new set of artwork for the client and I’ve spent some time working on integrating it into the code.

What I’ve discovered is that the client code is rather brittle and prone to explode.  It will need some significant work before a new version is ready to release.  Testing with valgrind has helped a bit, but it still requires some heavy lifting to get right.

I started working on the client 6 years ago, long before I knew C++ very well (I’ve known C a lot longer, but it took a while to get the hang of C++ and the OO world).  The client was originally written to use the Simple DirectMedia Layer (SDL) and has had some bizarre things done to it over the years.

So — there are significant changes coming with it, but no idea when they’re coming.

Minor Data Fixes

I finally got around to taking care of two things that have been bugging me for a bit.

1. Every boot the MUD would reset the time/day/year to the first day of the first month of the first year (time zero).  Now time continues across reboots.  No more Groundhog Day.

2. The current, maximum, and record number of players data was not being kept correctly.  It is now.

They haven’t been deployed to the server yet since I’m in the middle of reworking the map engine on both the client and server for the new graphics, but when that’s done those two fixes will ride along.

Stuff After Death

Lyran mentioned that it’d pretty tough to do anything after dying above level 5 for complete lack of equipment.  I added a toggle that lets players start with newbie equipment every time they die no matter what level they are and turned it on.

Newbie equipment isn’t exactly a huge advantage, so it might be worth leaving that on permanently.  It’s bad enough that you lose your sword +5, no reason you should have to walk around barefoot with no pants on.  A level 6 adventurer shouldn’t find it too hard to scrounge up 2 silver pieces worth of equipment anyhow.

A Dozen More Spells Working

These spells were made to work today:

Water Elementalist

* Blending
* Minor Blending
* Tide of the Seas
* Water Bolt
* Dispel Magic

Air Elementalist

* Coldshield

Earth Elementalist

* Dirt Cloud

Fire Elementalist

* Fireskin
* Fireshield

Paladin

* Judgement

Anti-Paladin

* Apocalypse

Cleric

* Soulshield

A Bunch of Spells

Nearly three dozen spells were made functional today:

Air Elementalist

* Airy Starshell
* Hypnotic Pattern
* Telekinesis

Cleric

* Create Water
* Detect Poison
* Group Heal
* Know Alignment
* Silence
* Turn Undead

Druid

* Analyze Balance
* Harbor of Balance
* Twilight

Earth Elementalist

* Earthen Starshell
* Earthen Tomb
* Stornogs Spheres

Fire Elementalist

* Fiery Starshell
* Group Globe

Illusionist

* Cowardice
* Demi Shadow Magic
* Dispel Invisible
* Hypnotic Pattern
* Mirage Arcana
* Mass Invisibility
* Misdirection
* Phantasmal Killer

Necromancer

* Cloak of Fear
* Heal Undead
* Protect Undead

Ranger

* Dazzle

Shaman

* Greater Ravenflight
* Greater Sustenance

Sorcerer

* Infravision
* Meteor Swarm

Water Elementalist

* Adaptation
* Watery Starshell

In addition, some immortal commands were improved to make development easier and some “to caster” spell messages that were previously not shown are now shown.

Damage type vulnerability, which had only been partially implemented, is fully functional now.

A Few Spell Fixes

I think I remembered what I was working on — spells.

Ten more spells were made functional today:

Air Elementalist

* Chill of the Windsaber
* Hurricane

Cleric

* Destroy Undead

Druid

* Sunburst
* Sunray

Illusionist

* Shadow Magic

Psionicist

* Detonate
* Neural Fragmentation

Shaman

* Greater Mending

Water Elementalist

* Tidal Wave

Now Where Was I?

OK, now that I’ve travelled halfway across the planet, built a good bit of software for a startup (not done yet, but it’s settled down to a saner pace), and unpacked a ton of boxes, it might be a good time to start working on Basternae a bit more.

Except…  I can’t remember where I was and what needed to be done (or priority levels for things that need to happen).

So, could someone go ahead and log into the MUD and tell me what the heck I need to work on?

Basternae.org port 4502.

Seriously, I could use a project manager.  Anyone want to volunteer?

Help Entries Improved

When the help file entries were translated from a text file to our fancy help entry format, the line spacing in each entry was converted from single to double.  It was just a quirk of XML serialization, but it made for long, spammy entries when helps were displayed.  I had gone through and cleaned up one or two hundred of them, but there were about four or five hundred more to go.  I spent a while going through the rest and removing the extra newlines where they weren’t wanted.  It would have taken forever if not for the help editor tool, but thanks to that it only took half an afternoon to clean them up.

Another thing that was a nuisance about the help system was that it would match and display every entry that matched the entered keyword.  If you typed “help heal” you’d get the entries for the spells heal, group heal, full heal, and mass heal.  I’m not even going to say how many entries you’d see if you typed “wall” or “fire”.  While it was intentional that a general match would take place, i.e. if you did “help wall” you’d see all of the help entries for wall of fire, wall of stone, etc., the unintended consequences were that you’d see extra entries even if you had an exact title match.

That’s been changed, so now when you type “help wall of fire” or “help heal” you’ll see the exact entry you were looking for, while you’ll still see multiple entries if you were doing a general query like “help fire” or “help wall”.

Go ahead, log in and play around a bit and see what you think of the way help is organized and how it works now.  Let me know if you see anything wacky or see a way to make it more useful.

Editor Version 0.56 Update

Working on a zone always results in editor improvements, so here’s what we get this release:

* Changed the error window shown for “Check Area” to a scrollable list so all errors can be seen.
* When items in the list of errors found by “Check Area” are double-clicked, the object, room, or mob will open in the edit window so you can change whatever the area check complained about.
* The map window is now refreshed when “apply” is clicked in the room editor so we see the room change color when the terrain type changes.
* The map window is now cleared if there was an area loaded when File –> New is used to create a new area.
* Added a “New” button to the exit edit dialog so new empty rooms with reciprocal exits can be created from the exit editor.  This will be easier than creating both rooms and manually creating an exit in each room pointing to the other.
* Added more content to the help file.

Grey Elf Hometown Layout Finished

I have the general layout of the Grey Elf hometown finished now. There’s a lot of work still to do — room descriptions, shops, mobs, objects, etc., but the layout is done and the repopulation points have been set.

Here’s what it looks like:

Editor Version 0.55 Update

I spent a little while working on the Grey Elf hometown today. That sort of thing always results in editor changes. Version 0.55 was released today with these two changes:

* Added the “Check Area” command to the tools menu. Right now it only checks for missing descriptions on rooms, objects, and mobs.
* Added instrument type selection for the edit values screen when editing instrument objects.

Some Text Fixes

I made a couple minor text fixes, the most noticeable of which was a map rendering glitch that would cause mobs to show up as P’s and the map to be strangely distorted in the client.

I also released a minor update to the client (now version 0.18), with a map fix and a couple window focus improvements.

A Few More Spells

These spells were made to work today:

Cleric

* Dispel Evil
* Dispel Good
* Holy Word
* Unholy Word

Druid

* Gleam of Dawn
* Gleam of Dusk
* Negate Hex

Illusionist

* Magnetism

Anti-Paladin

* Stamina
* Greater Stamina

A Dazzling Array of Spell Fixes

I spent much of the day working on spells, and more than 90 of them have been made to work.

Anti-Paladin

* Fear

Sorcerer

* Sleep
* Minor Paralysis
* Faerie Fire
* Celestial Sword
* Weaken
* Melfs Acid Arrow
* Prismatic Spray
* Immolate
* Shield

Air Elementalist

* Haste
* Wall of Force
* Airy Smith
* Conjure Windsabre
* Wall of Mist

Earth Elementalist

* Wall of Stone
* Wall of Iron
* Earthquake
* Earthen Smith
* Bombard
* Disintegrate

Fire Elementalist

* Identify
* Fiery Smith
* Wall of Fire
* Wall of Sparks
* Flashfire
* Conflaguration

Water Elementalist

* Wall of Ice
* Aquatic Smith

Cleric

* Heal
* Full Heal
* Cure Light
* Cure Serious
* Cure Critical
* Mass Heal
* Create Food
* Vigorize Light
* Vigorize Serious
* Vigorize Critical
* Preserve
* Blindness
* Remove Poison
* Summon
* Cure Blindness
* Cure Disease
* Curse
* Remove Curse
* Continual Light
* Darkness
* True Seeing
* Power Word Blind

Druid

* Barkskin
* Create Spring
* Nourishment
* Lesser Herbal Remedy
* Herbal Remedy
* Soothe Wound
* Moonwell
* Lightning Curtain
* Poison
* Creeping Doom
* Faerie Fog
* Purify

Ranger

* Blur

Shaman

* Lesser Mending
* Mending
* Spirit Ward
* Wellness
* Sustenance
* Etherportal
* Ravenflight
* Pythonsting
* Greater Pythonsting
* Greater Spirit Sight
* Purify Spirit
* Spirit Armor
* Greater Spirit Ward
* Earthen Grasp

Illusionist

* Illusion of Prowess
* Illusion of Incompetence
* Illusionary Wall
* Mirror Image
* Ultra Death Ray
* Nightmares
* Shadow Monsters
* Demi Shadow Monsters
* Shades
* Shadow Shield

Psionicist

* Wormhole
* Energy Drain
* Awe

Enchanter

* Negate Luster
* Illumination

Chances are some of them aren’t perfect, so as always, let me know if you find any glitches.

More Spells Working

I spent a while pushing spell code around today. The following spells have been made to work:

Sorcerer

* Strength
* Dexterity

Cleric

* Bless
* Armor
* Vitality

Shaman

* Fire Ward
* Cold Ward
* Wolfspeed
* Hawkvision
* Pantherspeed
* Bearstrength
* Snailspeed
* Molevision
* Lionrage
* Elephantstrength
* Mousestrength
* Shrewtameness

Anti-Paladin

* Wither

Air Elementalist

* Deny Air

Earth Elementalist

* Miners Intuition
* Deny Earth
* Stoneskin
* Stonestrength

Fire Elementalist

* Deny Fire

Water Elementalist

* Deny Water

Let me know if you find anything strange about any of them.

Working on Psionicist Abilities

I spent a good part of the past week traveling from the midwest to the west coast and back (5 flights total). During airport layovers I took a look at some of Tiu’s psi reports. Since I hadn’t touched psionicist spells/abilities yet it was no surprise that most of them were pretty borked.

I made changes to these spells:
Aura Sight
Biofeedback
Combat Mind
Displacement
Energy Containment
Enhanced Strength
Flight
Inertial Barrier
Intellect Fortress
Mental Barrier

These haven’t been tested thoroughly and may not all work as intended since they were done half-distractedly in various airports (LAX and MSP mostly). No fix for mana use or cast lag yet.

The intent for all psionicist buffs is that they are self-only, don’t stack amount or duration, and you have to wait until they wear off to refresh them. If any of them don’t work that way, let me know.

As always, let me know what’s still broken.