Sunteți pe pagina 1din 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

INTRODUCTION TO MOO PROGRAMMING


BASICS
Syntax @j oin us er @mov e ob jec t to pl ac e Description

Teleports you to the named user Move the specified object to the specified location. e.g.: @move me to #502 or @go #502
@move #980 to here

@e jec t ob jec t fr om plac e w he re is us er @ who / @ wh ois

This command is used to remove unwanted objects from places you own. Locates other users Lists current users / Lists current users and their real names

OBJECT INFORMATION
Syntax @examine object @exam object Description

Prints several useful pieces of information about the named object, including the following: its full name, aliases, and object number its owner's name and object number its description its key expression (if it is locked and if you own it) its contents and their object numbers the 'obvious' verbs defined on it
The 'obvious' verbs are those that are readable and that can be invoked as commands. To keep a verb off this list, either make it unreadable (@chmod) or, if it shouldn't be used as a command, give it 'args' of 'this none this' (@args).

@display object (basic information) @d object.property (individual property) @d object:verb (individual verb) @d obj ec t. (all inherited properties) @d obj ec t; (all inherited verbs) @d obj ec t: (all direct defined verbs) @properties object @props object @verbs object @list object:verb @list# object:verbobject:verb - number

@display is a fancy version of @show. As @show, it can select individual verbs or properties to display. In addition, it can display all the verbs or properties defined on an object, or all the verbs or properties defined on any of the object's ancestors. Don't specify a property or verb name after the punctuation mark to get the "all" feature. Returns a list of the names of the properties defined directly on the given <object>, not inherited from its parent. Returns a list of the names of the verbs defined directly on the given <object>, not inherited from its parent.@verbs <object> Prints out the code for the MOO program associated with the named verb on the named object. Normally, the code is shown with each line numbered and with only those parentheses that are necessary to show the meaning of the program. You can change the default behaviour of this command via @prog@prog-options. Displays the direct object, preposition, and/or indirect object specifiers for the named verb on the named object. Prints out the names and object numbers of the found children. Note: this is not a list of all descendents, just direct children. Prints out the names and object numbers of all ancestors.

@args object:verb
@kids object @parents object

1 / 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

OBJECT CREATION, NAMING AND DESCRIPTION


Syntax @create classclass-name named "names" parent@create parent -object named "names named / called Description

@recycle object object@recycle object -nr @describe object as description or @edit objectobject-name.description e.g.: @edit here.description

The first argument specifies the 'parent' of the new object: loosely speaking, the 'kind' of object you're creating. <class-name> is one of the four standard classes of objects: $note, $letter, $thing, or $container. If the parent you have in mind for your new object isn't one of these, you may use the parent's name (if it's in the same room as you) or else its object number (e.g., #4562) Destroys the indicated object utterly and irretrievably. Naturally, you may only do this to objects that you own. Sets the description string of <object> to <description>. This is the string that is printed out whenever someone uses the 'look' command on <object>. To describe yourself, use 'me' as the <object>. The description of an object is kept in its .description property. For descriptions of more than one paragraph, .description can be a list of strings. The first two forms are used to change the name and aliases of an object. The name is what will be used in most printed descriptions of the object. The aliases are the names by which players can refer to the object in commands. Typically you want to include the name in the aliases, as the MOO parser only checks .aliases when matching, so the first syntax is generally preferred. The first form is used to add aliases to an object's list of aliases. You can separate multiple aliases with commas. The aliases will be checked against the object's current aliases and all aliases not already in the object's list of aliases will be added. The second form of the @addalias command is for use by programmers, to add aliases to a verb they own. All commas and spaces are assumed to be separations between aliases.

@rename object to namename-andand-alias,alias,...,alias


@rename @rename object to name:alias,...,alias newprop@rename object.property to new -prop -name @rename object:verb newnew-verbverb-name object:verbnewverb@rename# object:verb -nr to new -verb -name @addalias alias,...,alias to object object:verb@addalias alias,...,alias to object:verb -name @addalias# alias,...,alias to object:verbobject:verb-nr

The third form, @addalias#, is for unambiguously referring to a verb on an object in case there are more than one with the same name. The verb number is the 1-based index of the verb as it appears in the verbs() (or @verbs) output list. @rmalias alias,...,alias from object The first form is used to remove aliases from an object. If the object is a @rmalias alias,...,alias from object:verbobject:verb-name valid player, space and commas will be assumed to be separations @rmalias# alias,...,alias from object:verbbetween unwanted aliases. Otherwise, only commas will be assumed to object:verb-nr be separations. Note that @rmalias will not affect the object's name, only its aliases. @args object:verbobject:verb-name dobj Changes the direct object, preposition, and/or indirect object specifiers for @args @args object:verbobject:verb-name dobj prep the named verb on the named object. Any specifiers not provided on the @args object:verbobject:verb-name dobj prep iobj command line are not changed. The direct and indirect object specifiers @args# object:verbobject:verb-nr [any above combinations] (<dobj> and <iobj>) must be either 'none', 'this', or 'any'. The preposition specifier (<prep>) must be either 'none', 'any', or one of the prepositional phrases listed in `help prepositions'.

2 / 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

OBJECT PROPERTIES Properties are vital for storing data, and verbs that change and display these data can be quite interesting. Properties are also useful for keeping track of the "state" of an object, and certain states can cause interesting effects.
Syntax @property object.propobject.prop - name Description

@prop object.propobject.prop-name initialinitial-value

Adds a new property named <prop-name> to the named object. The initial value is given by the second argument, if present; it defaults to 0. Normally, a property is created with permissions 'rc' and owned by whoever types the command. However, you may also specify these explicitly

@property <object>.<prop-name> <initial-value> <permissions> @property <object>.<prop-name> <initial-value> <permissions> <owner>


Only wizards can create properties with owners other than themselves. '@property' can be abbreviated as '@prop'. Removes the named property from the named object. Changes the value of the specified object's property to the given value. You must have permission to modify the property, either because you own the property or if it is writable. @set is a valid abbreviation for @setprop.

@rmproperty object.propobject.prop - name @rmprop object.propobject.prop - name @set object.propobject.prop - name to value

PERMISSIONS The @chmod command changes the permissions of an object, property or verb, to those given. The following table shows what permission bits are allowed for each form of the command:
Syntax

@chmod object objectct-permissions @chmod object.propobject.prop-name propertyproperty-permissions @chmod object:verbct:verb-name verbverb-permissions @chmod# object:verbobject:verb-nr verbverb-permissions
OBJECT PERMISSIONS r w f r w c r w x

Description

Changes the permissions of an object, property or verb, to those given. <object-permissions> r, w, f <property-permissions> r, w, c <verb-permissions> r, w, x, d

the object is readable: anyone may list the properties and verbs defined on the object, using ;properties() and ;verbs() the object is writable: anyone may define properties or verbs on it using @property and @verb the object is fertile: anyone may create a child of it using @create the property is "readable", meaning others can use @disply to see its value the property is "writable", meaning others can change its value, using @set the inherited version of this property on a child object will change ownership to the creator of the child the verb's code is readable by everyone, by using @list the verb's code is writable by everyone, by using @edit the verb is executable, and may be called from within another verb

PROPERTY PERMISSIONS

VERB PERMISSIONS

3 / 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

VERBS
Verbs are programs written in the MOO language, which are recognized and executed by the parser. If the first word of a command typed by a participant is not: " : or ; - the parser assumes that this word is a verb. The remaining words are searched for a preposition string. If one is found, then the words between the verb and the preposition are the direct object and any words after the preposition are the indirect object. If no preposition is found, all words are considered to be the direct object. If the objects named by the direct and indirect objects are successfully located, verb definition is checked for on (in this order) :

the player who typed the command, the room that the player is in, the direct object, if any, and the indirect object, if any. Finally, the program is executed.
Description

Syntax @verb object:verbname @verb object:verbname dobj prep iobj

@verb object:verbname dobj prep iobj permissions

Adds a new verb with the given name(s) to the named object. If there are multiple names, they should be separated by spaces and all enclosed in quotes: @verb ball:"bounce kick mum*ble" e.g.: @verb cookie:eat this none none
@verb ball:bonce ball:bonce this to any

@verbs object @list object:verb @list# object:verbobject:verb - number

@args object:verb dobj prep iobj


@addalias alias,...,alias to object:verbobject:verb-name object:verb@addalias# alias,...,alias to object:verb -nr

Returns a list of the names of the verbs defined directly on the given <object>, not inherited from its parent.@verbs <object> Prints out the code for the MOO program associated with the named verb on the named object. Normally, the code is shown with each line numbered and with only those parentheses that are necessary to show the meaning of the program. You can change the default behaviour of this command via @prog@prog-options options. Changes the direct object, preposition, and/or indirect object specifiers for the named verb on the named object. Adds aliases to the named verb on the named object. All commas and spaces are assumed to be separations between aliases. @addalias#, is for unambiguously referring to a verb on an object in case there are more than one with the same name. The verb number is the 1-based index of the verb as it appears in the verbs() (or @verbs) output list. Removes aliases from the named verb on the named object. All commas and spaces are assumed to be separations between aliases.

@rmalias alias,...,alias from object:verbobject:verb-name


@rmalias# alias,...,alias from object:verb-nr

NAMING VERBS

In the simplest case, the verb name is a word made up of any characters other than * or spaces. If the verb name contains a single *, then the name matches any prefix of itself at least as long as the part before the *. If the verb name ends in *, then the name matches any string that begins with the part before the * e.g.:
foo*bar matches foo, foob, fooba, or foobar. foo* matches foo, foobar, food, or foogleman.

4 / 13

Lars MOO Programming Help Document


VERB PREPOSITIONS

. : : v. 1.0 : : .

In addition to the verb name there are three argument specifiers required: the direct object (this / any / none)
the preposition the indirect object (this / any / none)

The direct and indirect object specifiers must be one of the following: this in which the case the object must be the same as the object on which the verb is located any in which case the object can be anything none in which case nothing must be specified The preposition specifier is `none', `any', or one of the items in this list: with/using out of/from inside/from at/to over in front of through in/inside/into under/underneath/beneath on top of/on/onto/upon behind

beside for/about is as off/off of

VERB PERMISSIONS

Verb permission strings are drawn from the following set: r w x d

the verb's code is readable by everyone, by using @list the verb's code is writable by everyone, by using @edit the verb is executable, and may be called from within another verb the verb is set for debugging; if it encounters an error in execution it will print a "traceback" description of the error

The default permission string for verbs is "rd", but if a verb is specified with the arguments "this none this" then it will have the permission string "rxd", which is useful when creating verbs that are to be called from within other verbs. To change the permission bit string of a verb, use the @chmod command: Syntax: @chmod object:verb permissions e.g.: @chmod me:run "rxd"

5 / 13

Lars MOO Programming Help Document


PROGRAMMING VERBS

. : : v. 1.0 : : .

Once a verb has been created and all its arguments are correct, all that remains is to program it. The command to program a verb is:
Syntax @edit object:verb Description

This will move you to the Verb Editor, a special room where you can edit your verb line by line. Type look to get a list of commands: say (line): add a line at the current insertion point list: list the lines of your verb, with line numbers delete # - delete line number # insert # - make the current insert point before line # (to insert at the end, use a dollar sign $ instead of a number) move #a to #b - move line #a to before line #b enter Enters a sequence of lines at the insertion point. Type a single period . on a line to end input. Two other non-editing commands are important: compile - compile your verb (syntax: inside the editor: compile / outside the editor: compile object:verb) quit - quit verb editor and return to your previous location

@program object:verb dobj prep iobj


@program# object:verbobject:verb-nr

@program object:verb

Changes the MOO program associated with the named verb on the named object. If you provide <dobj> <preposition> and <iobj> as in the second form of this command, then it is the first verb with matching direct object, preposition and indirect object specifiers that is the one getting the new program. This is useful if you have several verbs matching the same name. Or, you can use @program# if you know the verb's number. This is the 1-based index of the verb as it appears in the verbs() (or @verbs) output list. Typing the @program command always puts the server into a line-reading mode, in which each line you type is saved away without any action unless said line is one of the following:
. @abort .<text>

A period on a line by itself ends the line-reading mode and continues with the command, in this case, the saved lines are considered as a program, checked for syntax errors and, if no errors are found, installed as the new program for the specified verb.

6 / 13

Lars MOO Programming Help Document Verb Use Syntax

. : : v. 1.0 : : .

tell say_action() announce() announce_all()

Tells only the player a message Announces a _msg to everyone in the room Announces a message to everyone except the player Announces a message to everyone in the room.

player:tell("You fall down");

player.location:announce(player.name + falls.);
here:announce_all("Rock!");

$you:say_action(this.awesome_msg);

announce_all_but() Announces a message to all but one object in the room. here:announce_all_but({player}, "Rock!")
BUILTBUILT-IN OBJECT PROPERTIES name owner location contents programmer wizard r w f

a string an object an object a list of objects a bit a bit a bit a bit a bit

the usual name for this object the player who controls access to it where the object is in virtual reality the inverse of `location' does the object have programmer rights? does the object have wizard rights? is the object publicly readable? is the object publicly writable? is the object fertile?

SPECIAL VARIABLES IN FUNCTIONS (BUILT(BUILT-IN COMMAND PARSER VARIABLES) player this caller verb argstr args dobjstr dobj prepstr iobjstr iobj

an object an object an object a string a string a list of strings a string an object a string a string an object

the player who typed the command the object on which this verb was found the same as `player' the first word of the command everything after the first word of the command the words in `argstr' the direct object string found during parsing the direct object value found during matching the prepositional phrase found during parsing the indirect object string the indirect object value

Example: Creating a pet rock

@create $thing named "<your name>'s pet rock","pet rock","rock","pr" @describe rock as "A small rock. It looks friendly, but doesn't do much." @verb rock:pet this none none rx @property rock.pet_msg "Nothing happens." Rc @set rock.pet_msg to "You pet the rock. Nothing happens." @property rock.other_pet_msg " pets the rock. Nothing happens." rc
@program rock:pet
player:tell(this.pet_msg); player.location:announce(player.name + this.other_pet_msg); .

*Optional

7 / 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

BUILDING BUILDING / DIGGING


Syntax @dig "new"new-roomroom-name" exit"newroom@dig exit -spec to "new -room -name" @dig exitexit-spec to oldold-roomroom-objobj-nr Description

This is the basic building tool. The first form of the command creates a new room with the given name. The new room is not connected to anywhere else; it is floating in limbo. The @dig command tells you its object number, though, so you can use the @move command to get there easily. (e.g.: @move me to #201) e.g. : @dig Narnia (creates a new room Narnia with no exits)

The second form of the command not only creates the room, but one or two exits linking your current location to (and possibly from) the new room. An <exit-spec> has one of the following two forms: <names> e.g.: north,n <names>|<names> e.g.: up,u|down,d Where the first form is used when you only want to create one exit, from your current room to the new room, and the second form when you also want an exit back, from the new room to your current room. In any case, the <names> piece is just a list of names for the exit, separated by commas; these are the names of the commands players can type to use the exit. It is usually a good idea to include explicitly the standard abbreviations for direction names (e.g., 'n' for 'north', 'se' for 'southeast', etc.). DO NOT put spaces in the names of exits; they are useless in MOO.
@dig out,north,n to Secret garden

@dig east,e|west,w to Waste Waste disposal plant plant creates a new room called Waste disposal plant with an exit east from

creates a new room called Secret garden with an exit north from the current room to the new room but no exit back from the new room to the current room

the current room to the new room and an exit west from the new room back to the current room. The third form of the command is just like the second form except that no new room is created; you instead specify by object number the other room to/from which the new exits will connect. E.g.: @dig east,e|west,w to #1032 NOTE: You must own the room at one end or the other of the exits you create. If you own both, everything is alright. If you own only one end, then after creating the exits you should write down their object numbers. You must then get the owner of the other room to use @add-exit and @add-entrance to link your new exits to their room. Example: You want to create a link from you room #802 to another persons room #742 @dig north,n|south,s to #742 Creates an exit from your room #802 to the other persons room #742. The exit from your room is also the entrance to the other room, i.e. #802 exit = #742 entrance, and vice versa #802 entrance = #742 exit The exit and entrance also get their own object number. E.g. the entrance to #742 could be #936 and the exit from #742 could be #851. The owner of room #742 would have to add the exit and entrance by typing: @add@add-entrance #936
@add@add-exit #851 @describe object as description _______________________________ @describe here as description @describe north as description here.description @edit her e.description @edit north.description

Describes the named object. The description can be view by using the look command e.g. look object.
@edit objectobject-name.description can be used for longer descriptions by

creating a list of strings for several paragraphs.

8 / 13

Lars MOO Programming Help Document

. : : v. 1.0 : : .

Syntax @sethome

Description

@resident player @resident !player @resident

Sets your designated home (see `help home') to be the room you're in now. If the current room wouldn't allow you to teleport in, then the `@sethome' command nicely refuses to set your home there. This avoids later, perhaps unpleasant, surprises. Additionally, your home must be a room that will allow you to stay there. Rooms which you own will do this, as will rooms to which you have been added as a resident. See the @resident command for help on adding someone as a resident to a room you own. Adds or removes a player from the residents list of a room. The residents list controls who is allowed to use @sethome in that room. This defaults to just the owner of the room; by manipulating the residents list you may allow additional players to use that room as their home. @resident player adds that player to the list. @resident !player removes that player from the list. @resident with no arguments simply displays the current list (which may be "none", indicating no additional people besides the owner may use that room as their home).

SECURITY @set here.free_entry to 0 @eject object @eject! object @eject object from place @eject! object from place

Prevents teleportation into current room This command is used to remove unwanted objects from places you own. Players thus removed are unceremoniously dumped in their homes (unless that's this room, in which case they are dumped in the default player starting place). Other kinds of objects are checked for a .home property and sent there if possible, otherwise they get thrown into #-1. Unlike @move, @eject does *not* check to see if the object wants to be moved, and with the destination being what it is, there is no question of the destination refusing the move, either. Generally, you should only resort to @eject if @move doesn't work. `@eject <object>' removes <object> from the current room, whereas `@eject <object> from <place>' removes the object from the specified location (in most cases, <place> will need to be specified as an object number). In either case, this command only works if you own the room/entity from which the object is being ejected. `@eject ... from me' suffices to get rid of some unwanted object in your inventory.

9 / 13

BOTS
Syntax

Lars MOO Programming Help Document

. : : v. 1.0 : : .

@create #100 called "bot"bot -name"


@describe botbot-name as "something something" @examine botbot-name

Description

Creates a child-bot of the parent bot object: #100 @addalias for ease if your bot has a long name Describes your bot Returns a list of verbs inherent to the bot object

Syntax hush botbot-name activate botbot-name act botbot-name addword botbot-name addw botbot-name

Description

Silences bot / deactivates bot Activates bot / wakes the bot up Adds a keyword for your bot to respond to (single words only) To teach your bot to respond to 'poofs' with either 'I like Cheezy Poofs too.' or 'I like Cheezy poofs we like Cheezy poofs!' Just type 'addword botname' and enter the keyword 'poofs'. Then enter the appropriate responses a line at a time. End with a single period on a line by itself. Removes a keyword from the bots vocabulary (anything = number) E.g. rmword 5 from #1492 Lists the keywords that your bot responds to Adds a pattern for the bot to respond to E.g.: Pattern: My x isnt very y. Response: What's so great about a y x? Would be something like: Pattern: my %(%w*%) isn't very very %(.*%)
Response: What's so great about a %2 %1?

rmword <anything> from botbot-name botrmw <anything> from bot -name seewords botbot-name seew botbot-name addpat botbot-name addp botbot-name

rmpat <anything> from botbot-name botrmp <anything> from bot -name seepats botbot-name seep botbot-name mvpat <anything> on botbot-name

Add as many response forms as you wish on separate lines. End with a period on a single line. For additional info on the syntax of patterns type 'help regular', or look up regular expressions. Removes a pattern from the bot (anything = number) E.g.: rmpat 12 from Robbie Displays list of the patterns that the bot responds to

addrandom botbot-name addr botbot-name rmrandom <anything> from botbot-name rmr <anything> from botbot-name seerandoms botbot-name botseer bot -name addquestionresponse botbot-name addquestionr botbot-name name

Adds a random response to the bot, These responses are triggered whenever your bot can't find a keyword, a pattern, or a question. Removes a random question response from the bot (anything = number) E.g.: rmrandom 5 from T1000 Displays the list of random responses programmed into the bot Adds a random question response to a question to the bot When your bot senses a question is being asked it responds with a random 'answer'. Removes a random question response to the bot (anything = number) E.g.: rmquestionresponse 6 from Matilda Displays the list of random question responses programmed into the bot

To move pattern number 9 to a position nearer the beginning of the list you might type something like 'mvpat 9 on botname'. You will then be asked to enter a line number to move pattern to.

Moves pattern to a different location in the list (anything = number)

rmquestionresponse <anything> from botbot-name rmquestionr <anything> from botbot-name


seequestionresponses botbot-name seequestionr botbot-name

10 / 13

STRIPPING / REPROGRAMMING A BOT

Lars MOO Programming Help Document

. : : v. 1.0 : : .

Some important things to note if you want to strip a bot down to remove all residue built in expressions and such is the :context_response verb on the bot. To completely have control of what you bot is saying you have to re-program the context_response verb on your bot. Another verb that could be useful to re-program is the :tell verb as well as the activate and hush verbs. NOTE: The context_response verb contains the notorious So you call . your home. and Interesting . you have there what is it for? and the ever so annoying I think .. is a nice name for this place dont you?. If you want these lines removed from your bot you have to re-program the context_response verb on your bot.

REGULAR EXPRESSIONS
Regular expression matching allows you to test whether a string fits into a specific syntactic shape. You can also search a string for a substring that fits a pattern. See also the built-in function match()/rmatch(). A regular expression describes a set of strings. The simplest case is one that describes a particular string; for example, the string `foo' when regarded as a regular expression matches `foo' and nothing else. Nontrivial regular expressions use certain special constructs so that they can match more than one string. For example, the regular expression `foo%|bar' matches either the string `foo' or the string `bar'; the regular expression `c[ad]*r' matches any of the strings `cr', `car', `cdr', `caar', `cadddar' and all other such strings with any number of `a''s and `d''s. Regular expressions have a syntax in which a few characters are special constructs and the rest are "ordinary". An ordinary character is a simple regular expression that matches that character and nothing else. The special characters are `$', `^', `.', `*', `+', `?', `[', `]' and `%'. Any other character appearing in a regular expression is ordinary, unless a `%' precedes it. For example, `f' is not a special character, so it is ordinary, and therefore `f' is a regular expression that matches the string `f' and no other string. (It does *not*, for example, match the string `ff'.) Likewise, `o' is a regular expression that matches only `o'. Any two regular expressions A and B can be concatenated. The result is a regular expression which matches a string if A matches some amount of the beginning of that string and B matches the rest of the string. As a simple example, we can concatenate the regular expressions `f' and `o' to get the regular expression `fo', which matches only the string `fo'. Still trivial.

11 / 13

PORTING PORTING

Lars MOO Programming Help Document

. : : v. 1.0 : : .

The recommended procedure for porting objects presently has two components: social and technical.

Social: There are copyright & courtesy issues involved with porting other people's code to your MOO. The

practical advice that results from these considerations seems to be:


o

If the object/code explicitly states you can copy it, or you have secured the author's permission, port it. If not, don't port it.

This can be a bit frustrating if you want object xyz but xyz's author hasn't logged on in 8 months. The suggestion at that point is to look at the code and try to understand what is being done, then program an object with similar but improved functions. Understand that not everyone thinks porting is a great thing, even when you are courteous, and respect copyright.

Technical: Currently there are lots of gotchas to porting objects, most of them related to coding irregularities on the original objects, and to MOO client operations. Only a couple of those are dealt with here; until someone develops a robust portability system for MOO, you _will_ run into problems from time to time. When that happens, there is nothing like being, or being good friends with, an accomplished MOO programmer. Here is one recommended procedure: On the MOO you're porting the object to, @create using the apropriate parent, and note down the new object number (#xxxx). Turn on recording and turn off autowrap on your client; you do this to record dump your about to do on the source moo. On the MOO you're porting object #nnnn from: a. @wrap off b. @dump #nnnn with create id=#xxxx Edit the dump you recorded. a. Remove the @create from the first line from the first line of the dump, since you've already created the object. b. Scan for hard-coded object numbers other than the one that is the object you created. Fix those, pointing them to the correct object on your MOO, or recoding so they're not needed. c. Scan for things that might have inadvertently been captured along with the dump, e.g.:
You sense that Nern is looking for you in the Living Room: Nern pages, "Come out and help me torture some guests."

PORTING PROCEDURE 1. 2. 3.

4.

5.

Uploading code to your MOO:

Uploading basically means dumping text into the moo. First of all you need to decide whether uploading the whole code or doing it piece by piece. Some clients may have an `upload file'' button or command, this script will put the properties and verbs on the object. With the rmoo/emacs clients, you just copy the code you want to upload and then you type ctrl-c ctrlv or under X-Windows you can also select the code and then use ``Send X-Selection'' from the menu. Now careful ! DON'T UPLOAD TWICE verb definitions, or you will have 2 definitions of the same verb! (guess that applies to most MOOs). To avoid defining verbs twice while uploading the same code several times comment out all those lines after your first uploading: e.g. change @verb #xxxx:"a_verb'' this none this to "@verb #xxxx:"a_verb'' this none this, i.e. add a " in front of the line. Now, test and/or debug the object.
12 / 13

6.

Lars MOO Programming Help Document

. : : v. 1.0 : : .

Who do I ask for permission to port?


There are a few formal and informal rules you should respect: In principle everything published or available over the Internet is copyrighted (e.g. web pages, MOO code, Java applets). If an object's description doesn't explicitly grant permission to port, ASK ! If the code you wish to port has been programmed by a member of the MOO from which you want to port send him Moo-mail. To list the owner, type for example @d <object>. It the owner is not a real player (e.g. hacker or corewizard) ask a wizard for permission (type @help wizard-list to list wizards). If the code seems to have been ported over from another MOO, ask the person who ported it or look at the code to determine where it comes from or if it is ok to port.

13 / 13

S-ar putea să vă placă și