Welcome to
RuthMOO, an online community hosted at
Brandeis University. This page
is intended to the basics of creating objects on the MOO including: creating
and personalizing your home, digging and managing exits, creating different
kinds of objects and managing your quota. If you have already done this or
know how and are interested in MOO programming, you will probably want to
move on to the RuthMOO: Programming the Environment
page.
Once you've gotten the basic attributes of your character created, you will probably want to create a home for yourself. The easiest way to do this is to first decide where you want to have your home. To find places on RuthMOO where you can build your home type:
help connections |
Once you have selected a location and have gnoe there you have two other decisions to make: the name of your new room and the name of the exit that will lead to it. The name of the exit should be one word with no spaces, preferably no punctuation and should be short, generally 7 characters or less. Additionally, there must be no other exit from the room with the same name. All of these things can be changed later, but you need something to start with.
For our example we will assume that your room will be named "Ruth's Retreat" and the exit leading to it will be named "Ruth". To create the room with exits to and from it connecting it to your current location you would type:
@dig ruth|out to Ruth's Retreat |
Congratulations! You should now have a room. There is one more step to take before the room is your home. First, type the name of the exit leading to your room in order to get there. Once you are in your room you will probably want to give it some sort of description. We'll give Ruth's Retreat a short description:
@describe here as "A quiet private room." |
@sethome |
For more information on building while you are logged onto RuthMOO use the help topics: connections, building, @dig.
If you followed the directions above and dug a new room connected to a public space, you should now own at least four objects: yourself, your room and two exit objects. You can confirm this by typing:
@audit |
Exits are objects, because, well.. they are. And everything else is, and it makes programming and managing the system easier. There are MOOs, many of them in fact, where in addition to exit objects, they also have 'virtual' or 'verb' exits (commonly referred to as v-exits) in which the functionality of the exit (letting people and objects move from room to room) is written into the code and data of the room itself. There are even some MOOs (although not very many) which use no exit objects, only v-exits. There are advantages and disadvantages to all of these schemes. At RuthMOO we currently have only exit objects and have no current plans for implementing any v-exits.
So why does it take two exit objects to create one doorway between two rooms? It is important to remember that MOO is an object oriented system, and that while it is common for MOO objects to map one-to-one with a real world object, this is not always the case. Sometimes it makes more sense to model the functional roles of a real world object as separate objects themselves instead of forcing a one-to-one correspondence. A brief and simplified explanation of how exit objects work may help clarify.
The base functionality of the exit object is contained in two properties; $exit.source and $exit.dest, and one verb, $exit:invoke. Two additional important pieces of data are the name of the exit and its location. The source of an exit is the room you start in before you use the exit. This is also the exit's location. The dest of the exit (destination) is the room you will be in after successfully using the exit.
To use an exit, while in the same room as the exit, you type its name. This will cause the exit's invoke verb to be executed, moving you to the exit's destination. Once you have arrived, you will no longer be in the same room with that exit, so typing its name will not get you back to the room you started from. Instead, we create a return exit whose source and dest are reversed from that of the first exit.
Where appropriate, it is common for such paired exits to have opposite names: north/south, up/down, in/out. Using paired names like this can help people stay oriented when they travel through your spaces which can help them seem more real. Another common and useful convention is to use a shortened version of the destination name as the exit name. Additionally, it is common to use the exit name 'out' for an exit leading from a smaller space into a larger space (out of a house, into the outdoors), or from a private space into a public space (out of your room, into the hallway), and for any room which only has one exit.
Note that it is quite possible to create an exit without a return exit so that only one way travel is possible. This can be useful for effects such as falling down a rabbit hole, among other things.
Another side effect of exits being objects is that they also have descriptions and messages. This means that people can look at an exit and get a preview of what's on the other side. By customizing the exit messages, you can enhance the sense of travelling for not only the person using the exit, but also the people who stay behind and the ones who see the person arrive in the destination. To see the messages on exit which you can customize:
@messages exitname |
For more information about exits while you are logged onto RuthMOO use the help topic: exits.
In order to create a new object you first need to decide what its parent is going to be. Two good generic objects for you to learn about are the Generic Thing and the Generic Container, which are pretty much what they sound like. Children of the Generic Thing can be looked at, picked up, put down, and handed to someone else. Children of the Generic Container also work like children of Generic Thing except that you can also open and close them, put things into them and take things out of them. These two generic objects are the parents of most of the "things" you will use on the MOO, although on most MOOs, including RuthMOO there are many other generic objects which have been created by MOO programmers for other people to use. These can usually be found in a generics museum of some sort. To see a list of your player object's parents type:
@parents me |
Each object on the MOO has one parent from which it inherits verbs and properties. To create a new object, you will need a parent and a name. For this example, let's create a thing called "box":
@create $thing named box |
@chparent box to $container |
@chparent box to #1200 |
If for some reason you decide you don't want to have your box around at all any more, you should go ahead and recycle it. This will destroy the object, freeing the object number to be reused, and cannot be reversed, at least not on RuthMOO:
@recycle box |
For more information about creating objects while you are logged onto RuthMOO use the help topic: @create
When you create objects and program verbs you are using system resources, especially memory, and these resurces are finite. In order to better manage the fair use of these resources, MOO has a quota system. Actually, there are two different quota systems only one of which can be used at a time, and the MOO administrators choose which one to use. The is an object based quota system and a byte based quota system. The object based system assigns each player a maximum number of objects which she can own, regardless of the size of these objects. The byte based system assigns each player a maximum number of bytes. The amount of quota used is calculated by measuring the size of each object the player owns, including its properties and verbs. RuthMOO uses the byte based quota system.
When you do something that will cause your quota to be exceeded you will get either an E_QUOTA error or some other message indicating that you have exceeded your resource limits. To check how much quota you have (or how far over quota you are) type:
@quota |
@measure new me |
If you are really and truly over quota (or approaching that state) there are a few things you can do:
For information on becoming a programmer at RuthMOO and how to program, see RuthMOO: Programming the Environment.
Back to the RuthMOO home page.
This page maintained by S. J. Herdman.