The MUD Development forum.
Game Development Discussion, Chat, Technical Debate, and people who just love games talking about building worlds.

Home » Hosted Mud Projects » Wheelmud » General » New, Feature Full Help System - WheelMUD - A C# MUD Server - Forums - WheelMUD - Design
New, Feature Full Help System - WheelMUD - A C# MUD Server - Forums - WheelMUD - Design [message #339] Sat, 21 March 2015 22:41 Go to previous message
Karak is currently offline  Karak
Messages: 489
Registered: March 2015
Location: Seattle, WA
Senior Member
This thread originates from prior WheelMUD forum software archives. It has been migrated here to preserve the contents.

Post by Pure (27 Sep 2010 11:56 AM):
Hi guys!
I have been working on a new help system for WheelMud, as opposed to the current just showing the command description and usage information.
Currently, I have rewritten HelpManager.cs, IHelpManager.cs, HelpTopic.cs, IHelpTopic.cs and Help.cs for, I will update with the code once I have finished it for the current revision.
Basically, the system reads help not from the database, but from the filesystem. The Files\help directory to be exact. These are loaded into memory during HelpManager.Start(Wink and can be called using the help command, an argumentless command giving the index page.
An example help topic:

This is an example help topic.
This is a <see cref="test">link</see> to another topic.
The first line is a list of aliases separated by '|'.
The name of the file is irrelevant, unless it is 'Files\help\'.
This file will be used for the index, which will be stored in a variable on the HelpManager, as well as in this List<helptopic>.</helptopic>
Hope you like!

And that is basically how they work. They are MXP enabled, so &lt;, &gt; and &amp; should be replaced in the right way.
I would like to start up a standard collection of help topics that are shipped with WheelMud. And, for that, I need your help! If there is any collaborative text editor availible anywhere, I would like to use that to keep track of the current topics.
What do you think? I hope that this system will replace the current way of getting help. Please post your thoughts, queries and issues.
Thanks in advance!

Post by Fastalanasa (27 Sep 2010 01:27 PM):
Yes! The current stuff looks pretty lame. Razz
Just one minor tweak to the breadcrumb. Have the 0 be "root" instead. Everything else looks peachy. Full Speed Ahead!

The Wiki is perfect for collaborative stuff. I'm going to give you rights to write to it, although you should already have them. I'll create a new topic called "Help System" and we can move specific documents there.

Post by Karak (28 Sep 2010 12:25 AM):
Cool. I've got a couple thoughts. Please view this as constructive feedback and open discussion rather than any sort of mandate or whatnot. Smile Our help system is certainly not where it needs to be yet and this does look like welcome progress.
I don't know what you mean by collaborative text editor... Text usually takes pretty well to source control, especially if line returns are used in the content. So people can collaborate on that the same way they collaborate on code. If you mean simultaneous editing of the same text file, seems overkill? If you're just talking about going back and updating a list of topics that are being worked on/completed/etc, we have a couple built-in options: we have a wiki area that would serve this well, or use the 'edit' feature on a forum topic to keep a list up to date. I periodically update a pinned <a href="aft/479/Default.html">list of Commands</a> topic that way.
More to the meat of the subject, you'll probably want to read up on <a href="aft/541/Default.html#603">the Actions Accessing Actions topic</a> which discussed various aspects of help system, if you haven't yet.
On what sounds like inventing new file formats and doing custom file load parsing, IMO that can be overkill and perhaps detrimental. Let's say you have a class called HelpTopic. If you mark up the properties of that class properly, XML serialization/deserialization is done automatically for you, and then you have a data format that is familiar, supported by existing tools/viewers, and somewhat self-documenting to boot rather than "memorize that the Xth line describes the Foo". The help file loader becomes "try to deserialize each XML in the Help directory." If someone broke the schema, most likely it'll result in an appropriate XML read error that could be caught by the deserialize and displayed in the MUD harness output area, rather than potentially silently putting the wrong data into the wrong property since the file format wasn't quite understood. A schema could even be employed to validate the help files outside of rebooting the game.
As far as some of the attributes in the command classes themselves, particularly those with short texts like the brief description that would appear in the "commands command," I do prefer them to be there. TBH I think even the command help text itself may make sense to be there at least sometimes, as it keeps the content close to the code in a case where the two really are strongly tied together; when a developer adds a new syntax to the Foo command, they'll generally forget to update the Foo help text (or opt not to bother due to true or feigned ignorance of the help file), unless it's right there in their face too. Command enhancement and related help text updates should generally be performed hand in hand. This helps foster sharing too IMO: say I invent a "RoShamBo" command and want to share it with other WheelMUD instances - ideally I should be able to post the contents of RoShamBo.cs to share it if that's the way I want to share it, rather than telling people "make this file with this contents then another file over in the help file system with these contents."
IMO the best thing may be to support both paradigms and let the MUD admins use the policies they choose on documentation storage. Imagine you had the ability to have a command whose static init contributed to the help system, called something like:
HelpSystem.Instance.UpdateHelpTopic(new HelpTopic(Wink
Aliases = new string[] { "RoShamBo", "rock", "paper", "scissors" },
Content = "When you use the RoShamBo command, yada yada yada...",
It would be pretty easy to include that in a single RoShamBo.cs, and those admins who have a policy to keep all documentation only in the help files folder would rip it out into a new help file, after they've tested, decide they like, and adopt the code.

Post by Pure (28 Sep 2010 04:30 AM):
Yeah, keep the old system, but only use it if the article cannot be found.
I think that serialization might not work well for the system; as I want the pages to be able to include MXP and such. I think I will stick with the current text files.
I have edited the wiki with details on how to add a help topic to it. I have only made a very simple index page, I'm no artist!
Please could some people help by adding some more?
Thanks in advance!
Read Message
Read Message
Read Message
Read Message
Previous Topic: mysterious registration - WheelMUD - A C# MUD Server - Forums - General - Lounge
Next Topic: Cannot DL the Data.RavenDb NuGet dependencies ATM - WheelMUD - A C# MUD Server - Forums - WheelMUD -
Goto Forum:

Current Time: Tue Jul 23 15:01:30 PDT 2019