What is a DL Macro?
Only Staff have the ability to create macros, and even then only on the
build server.
In its simplest form, a macro is just a list of DL commands. On a deeper
level, it allows for much more interactive NPCs, Rooms, Items, and in the
end, the over all playing environment. Macros give us the ability to
execute a list of commands on nearly any character under a host of different
circumstances. Add in the ability to execute commands that normally
cannot be executed, and many more possibilities are available.
If you execute the "macros" command alone, you are provided with a list
of the global macros. At this point (and it will likely not stay this
way) all macros are global, meaning anyone with access to macros can view
or modify them. Please do not modify other people's macros.
> macros
Global Macro Libraries
------------------------
#1 Test Library
------------------------
To view the macros in a library, use the macros command along with the
library number.
> macros 1
Macros from library #1 - Test Library
---------------------------------------
#1 Speed Test
---------------------------------------
If you'd like to create your own macro library (please do!) you can do so
with the macros library command like so:
> macros library <new library name>
Currently, you can create as many libraries as you desire, please don't
go crazy with them though, especially since you probably cannot delete them.
To view a macro in a library, you'll use macros show along with the
associated library and macro number.
> macros 1 show 1
#1 Speed Test
---------------
1 > mecho You begin to feel as if you've lost control of your body.
2 > mecho Something is controlling you! You feel your mouth begin to move.
3 > 'This is a macro speed test!
4 > 'Oh dear, a macro is controlling me!
5 > speed 1
6 > 'It can make me talk really fast.
7 > 'So fast that it is difficult to keep up with.
8 > 'Which I suppose could have its purposes...
9 > speed 20
10 > 'Or it could talk slower, like this.
11 > 'Which is much easier to keep up with if you are trying to read along.
12 > 'Slow enough that everyone can read it as long as the room is relatively calm.
13 > smile
14 > bow
15 > 'It can make me do more than talk!
16 > 'This is the end of the macro speed test.
17 > speed 1
18 > mecho The force that was controlling your body seems to have left.
This macro has a couple of examples of the "extra" commands, I referenced
above. Most notably mecho (macro echo -- echos a message to anyone the macro
is played upon) and speed (adjusts the speed of the macro playback -- speed
of 8-10 is approx. 1 second between each command, speed 0 is immediate).
These commands are only available when you are recording, editing, or playing a
macro.
To start recording a macro, you'll use the macro record command along with
the library number and the name of the macro like this (then you'll start
entering commands as I do -- note the prompt change, this allows for editing):
> macros 1 record Yet Another Test Macro
Now recording macro "Yet Another Test Macro".
1 Command> 'This is a test macro?
You say, 'This is a test macro?'
1 Last --> 'This is a test macro?
2 Command> 'Yes, and people are reading this, so I'm not talking to myself.
You say, 'Yes, and people are reading this, so I'm not talking to myself.'
2 Last --> 'Yes, and people are reading this, so I'm not talking to myself.
3 Command> macro record
Finished recording macro "Yet Another Test Macro".
Note: To stop recording or editing, you can use macro record or
macro edit they are interchangable (and no further arguments are required
to finish). At this point, I've created a new macro that uses the say
command twice:
> macros 1
Macros from library #1 - Test Library
---------------------------------------
#1 Speed Test
#2 Yet Another Test Macro
---------------------------------------
> macros 1 show 2
#2 Yet Another Test Macro
---------------------------
1 > 'This is a test macro?
2 > 'Yes, and people are reading this, so I'm not talking to myself.
You can edit a macro in similar fashion:
> macro 1 edit 2
Editing macro "Yet Another Test Macro".
1 Next --> 'This is a test macro?
1 Command> 'Arg, yet another test macro?!
You say, 'Arg, yet another test macro?!'
1 Last --> 'Arg, yet another test macro?!
2 Next --> 'This is a test macro?
2 Command> step end
3 Last --> 'Yes, and people are reading this, so I'm not talking to myself.
4 Command> step -3
1 Next --> 'Arg, yet another test macro?!
1 Command> macro record
Finished recording macro "Yet Another Test Macro".
Here, a command was introduced that can be executed only when a macro is
being recorded or edited, but it isn't recorded in the macro -- the step
command. It is used to move around between the command when you are editing
(or recording) a macro. While editing, to insert commands, you simply type
them in.
Macros can be renamed:
> macro 1 name 2 Another Test Macro
Library #1 macro #2 has been changed to "Another Test Macro".
> macro 1 show 2
#2 Another Test Macro
-----------------------
1 > 'Arg, yet another test macro?!
2 > 'This is a test macro?
3 > 'Yes, and people are reading this, so I'm not talking to myself.
You can execute a macro (on yourself) by using the macro command with the
library number and macro number alone:
> macro 1 2
Playing macro "Another Test Macro".
>
You say, 'Arg, yet another test macro?!'
>
You say, 'This is a test macro?'
>
You say, 'Yes, and people are reading this, so I'm not talking to myself.'
Finished playing macro "Another Test Macro".
Note: When the macro is executed on a non-Staff member, they do not see
the information about the macro starting, finishing or changing speed.
You can use macro abort to stop editing/recording a macro and discard any
changes you've made and use macro unrecord to remove commands from a macro:
> macro 1 edit 2
Editing macro "Another Test Macro".
1 Next --> 'Arg, yet another test macro?!
1 Command> macro unrecord next |