Prog Basics

To start editing a prog, go to the room you wish this prog to go off in, or where the object/mob are reset in.

Type: pedit create <vnum> – This will create a new prog.
Type: pedit <vnum> – To edit an existing prog.
Type: plist all (or plist with no argument for a list) – To see a list of all the progs in the area and what they are attached to,.
Type: show – to see the current information of the prog, which should look like this:

To build the basics of your object, go to the Objects Tutorial first, then come back here for prog basics. You can also reference the Master Prog Document.

Desc: (null)
Vnum: [105]
Involved: FALSE
Debug: FALSE


The Basics of Progs

This tutorial isn’t going to show you how to code a prog. It’s intended to show you the basics of how progs work. I will be going into detail on specific progs in another tutorial.

Desc is a brief one-line description of the prog you are making. Such as: Prog to make fireflies come out at night. It can be set by typing: desc <desc line>.

Vnum is obviously the vnum of your prog, and cannot be changed.


Debug is a neat little option for testing and debugging your prog. If your prog doesn’t work, turn debugger on by typing: debug true. When the prog tries to fire again, it will show you a large list of all the possible targets for the prog, and more importantly, green and red “T” and “F” (for true and false) which should help you locate where the prog stops working (The “F”). You can turn it off by typing: debug false.

Code is the command you type for entering the prog editor. It works exactly like room, object, and mob editors with the same commands. So please remember those commands when in the code section of prog making.

Once you are done making the prog code itself, you add it to the room, object, or mob! (see below)

Keywords: [woven bone necklace tribal pendant]
Area: [ 6] Immortal Realms
Vnum: [ 121]
Type: [clothing]
Level: [ 55]
Wear Loc: [neck]
Extra flags: [no_drop]
Perm Spell: [nothing]
Activation: [never]
Act chance: [0%]
Material: [none]
Condition: [ 100]
Weight: [ 1]
Cost: [10000]
Size: [all]
Ex desc kwd: [none]
Short desc:
a woven bone necklace with tribal markings
Long desc:
A woven bone necklace with tribal markings has been left here.

OBJPrograms for [ 121]:
Number Vnum Trigger Value
——- —– ———— —–
[ 0] 103 speech Kanati!
[ 1] 102 speech You are dismissed, Kanati

Adding a Prog to an Object, Room, or Mob

I’m going to use an object example for this, but the same rules apply for rooms and mobs.

The syntax for adding your prog to your object is as follows: Syntax: addoprog [vnum] [trigger] [phrase].

Notice it says oprog for “Object Prog.” For mobs it would be mprog, and for rooms it would be rprog, respectively.

VNUM should be self explanatory, that is the vnum of your prog that you want to add.

Trigger is what type of thing is going to set this prog off. What has to happen in order for this prog to work? Does a player have to say something? Does someone have to put this object in something else? There are a list of triggers in the Mob Document in the builder section of the website. I will work on putting them in website format later.

Phrase is the actual thing that sets the trigger off. Going back to trigger above, if you set the trigger as something a player has to say (called a SPEECH trigger)..then value is the actual phrase they say (such as “Hi”).

To delete a prog from an object, room, or mob, type: deloprog [num]. The number portion is not the actual vnum of the prog, but the number prog that is on it. As you can see in the example on the left, there are 2 progs, #0 and #1. (Remember the rprog, and mprog changes for rooms and mobs).

Once you have a firm grasp on how to set up a prog and adding it to the room, object, mob, then you can read into some of the more complicated things, such as writing the actual code for a prog.

To exit the object editor, type: done

And be sure to -always- save your area by typing: edit area, asave area, done