Skip to content

Redwall MUCK Site

Sections
Personal tools
You are here: Home » Help Topics » How-To Tutorials » The lsedit List Editor
« August 2008 »
Su Mo Tu We Th Fr Sa
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            
 

The lsedit List Editor

How to use lsedit to store data in lists on objects.

Purpose

First off, you only use this beast if you have a need to. The most common reason to use this is you want to have a textual description of something longer than you can put into "@desc" or "+set desc". You'll know this is you if you put in a long description, look at the object, and it's chopped off at the end.

The other reason we uses lists is for data that programs will process. For instance, making a list of random sounds that a simple MPI could pick from. If you are doing that, you're beyond the need for this little guide.

Usage

Lists are made up of lines of text. They have a name, and they are attached to an object. The name "list" and "property list" are synonomous.

As an example, this will show you how to store a three line list on your character. You can store almost any number of lines, and on any object. So this is representative of what can be done.

First, you choose a name for your list. Like in URL, a slash character acts as a directory seperator. You can have directories full of seperate lists, organized as you like. I'd like to store my list as "things/favorites". So that's the name.

Create the list using the lsedit command "lsedit object=name" as shown:

    lsedit me=things/favorites

Now, you are running the lsedit program. Everything you type goes into lsedit.

Commands in lsedit start with "." character. For instance, type ".help" to see what commands are available.

A good thing to do when creating a new list or overwriting an old is to make sure the list is empty. ".del" removes lines, and this is the easiest way to ensure the list is empty:

    .del 1 999

Now, to add lines to the list, just type them. Hit enter at the end of each line. If your goal is to "look good" when someone looks at the list, try to keep your lines under 72 characters long.

To add to my list of favorite things:

    bright copper kettles
    warm woolen mittens
    brown paper packages tied up with strings

I've added all that I want. However, I'm still running lsedit and it still waits for more text or commands. To tell it to save and exit, the ".end" command is given:

     .end

And that's it! Your list is made.

You can see what's in the list by using lsedit. To see what's in this list, I'd enter:

    lsedit me=/things/favorites
    .L
    .abort

That can also be a lowercase ".l" but it's harder to be clear with lower case on this page.

Notice that we did ".abort" to get out. We could have done ".end" but I made no changes and thus had nothing to save. So I just aborted the program.

Conclusion

lsedit will allow you to add and remove lines of text from a named list on an object.

For usage on long descriptions, see the Clothing and Advanced Descriptions page.

Created by admin
Last modified 2003-10-20 10:37 AM
 
 

Powered by Plone

This site conforms to the following standards: