Help Entries starting with 'I'


@idescformat

Replaces the usual description of the object when it is looked at from within by player-specified text. The evaluated IDESCRIBE attribute is passed as %0; the unevaluated IDESCRIBE can be acquired through v(IDESCRIBE).

This is useful for things like object parents that enforce a consistent "look" for each object's @idesc.

See also:


@idescribe

@idescribe command sets the internal description for an object, which is shown to anyone who enters or looks while inside the object. Meaningless for rooms and exits. May be abbreviated to @idesc.

@oidescribe sets the message seen by others when someone looks at the idesc, and @aidescribe sets the action the object will take (just as with @desc, @odesc, @adesc).

If there is no IDESCRIBE set for an object, those who enter or look inside it will see its @desc, and no o-message or action will be available. If you want to use @aidescribe without @idescribe, set @idescribe to a blank string.

If [=<description>] or [=<message>] omitted, the attribute will be reset.

See also:


@idle

This message is sent in return to every page which successfully reaches you if it evaluates non-null. It is useful if you are idle for long periods of time and wish to inform people where you are, or if you are in a meeting and cannot quickly return pages.

Clever example:

   @idle me=[switch(gt(idlesecs(me),120),1,I'm idle. Use @mail,)]

Players paging me will only see the "I'm idle" message if I've been idle for over 2 minutes (120 seconds).


@infilter

@infilter is meant to be used on objects that have an @listen of "*" (ie, objects that listen to everything, which is commonly used for things like chairs so that someone inside the object can hear everything said/done outside it). @infilter filters out any messages that match one of the patterns and prevents those inside the object from hearing them. It does not stop the @ahear of the listening object from being triggered by things that match the @listen.

For an explanation of infilter patterns, see the help for "@filter".

See also:


@inprefix

@inprefix is intended for use with objects with a @listen of "*". It prepends the <message> string to any message propagated to the contents of <object> from the outside. If there is no @inprefix, no string is prepended to the output.

Example:

  [ First, @create Vehicle and Test (objects #103 and #104) and drop them ]
    > @inprefix Vehicle = From outside,
    Vehicle - Set.
    > enter Vehicle
    Vehicle(#103)
    > @force #104=:bounces.
    From outside, Test bounces.

See also:


@invformat

Replaces the usual "You are carrying:" format when an object uses the "inventory" command, by a player-specified format. This is evaluated as if it were a description or other similar message on the object. The objects carried are passed as a dbref list in %0. A |-delimited list of all the unparsed object names is passed in %1 (so iter(%1,itext(0),|,%r) produces the standard list)

One could change the format to 'You've got: Object1 Object2 Object3' through '@invformat me = You've got: [iter(%0,name(##))]', for example. More complex things are, obviously, possible.

See also:


i18n

Internationalization support in PennMUSH includes: * Support for (8-bit) locale-based character sets, including translation of iso-8859-1 accented characters to html entities for Pueblo, the accent() and stripaccents() functions, and the NOACCENTS flag. * Support for locale-based date/time formats * Support for locale-based message sets for translations of server messages. There are active translation teams (and you can join!) and several languages have practically complete translation files available from the PennMUSH ftp site. * Some support for locale-based string collation * The ability to alias command and function names, so you can generate a set of translated commands/functions.

Most of these features get enabled by setting an appropriate environment variable in the PennMUSH restart script.


IDLE

This command does nothing. It does not reset a connection's idle time. It is useful for people who are connecting from behind a NAT gateway with a short fixed timeout; if you're in this situation, have your client send the IDLE command every minute or so, and the NAT connection won't time out (but you won't appear, to other players, to be active).


IDLE()

This function returns the number of seconds a player has been idle, much as WHO does. <player name> must be the full name of a player, or a player's dbref. Players who are not connected have an idlesecs of "-1", as do dark wizards, when idle() is used on them by a non-priv'ed player.


IF()

These functions evaluate the <condition> and return <true expression> if the <condition> is true, or <false expression> (if provided) if the <condition> is false.

See also:


ILEV()

ilev() itext(<n>) %i<n> inum(<n>)

These functions, when called within an iter(), return the equivalent of ## (itext) or #@ (inum), with reference to the nth more outermost iter(), where n=0 refers to the current iter(), n=1 to an iter() in which the current iter() is nested, etc. %iX is shorthand for itext(X) (up to itext(9). ilev() returns the current nesting depth, or -1 if it is outside an iter(). Thus, itext(ilev()) will return the ## of the outermost iter().

Example:

> say [iter(red blue green,iter(fish shoe, #@:##))]
You say, "1:red 1:red 2:blue 2:blue 3:green 3:green"

Example:

> say [iter(red blue green,iter(fish shoe, [inum(ilev())]:[itext(1)]))]
You say, "1:red 1:red 2:blue 2:blue 3:green 3:green"

Example:

> say [iter(red blue green,iter(fish shoe, [inum(0)]:[itext(0)]))]
You say, "1:fish 2:shoe 1:fish 2:shoe 1:fish 2:shoe"

Example:

> say [iter(red blue green,iter(fish shoe, %i1:%i0))]
You say, "red:fish red:shoe blue:fish blue:shoe green:fish green:shoe"

INAME()

iname() returns the name of object <object>, as it would appear if you were inside it. It is identical to name() except that if the object has a NAMEFORMAT or NAMEACCENT attribute, it is used.

You must be see_all, control <object>, or be inside it to use this function.

See also:


INC()

Inc returns the integer plus 1. If given a string that ends in an integer, it increments only the final integer portion. That is:

Example:

> think inc(3)
4
> think inc(hi3)
hi4
> think inc(1.3.3)
1.3.4
> think inc(1.3)
1.4

Note especially the last example, which will trip you up if you use floating point numbers with inc() and expect it to work like add().

See also:


index

A file similar to news, often indexing the news and events files. May not be available on some MUSHes.


INDEX()

This function is similar to EXTRACT(), except that it requires four arguments, while EXTRACT() uses defaults for its arguments if they aren't given. The function returns <length> items starting from the <first> position. Trailing spaces are trimmed. The comma cannot be used as the <character> separator unless it's escaped with a \.

Examples:

Example:

> say [index(Cup of Tea | Mug of Beer | Glass of Wine, |, 2, 1)]
You say, "Mug of Beer"

Example:

> say [index(%rtoy boat^%rblue tribble^%rcute doll^%rred ball,^,2,2)]
You say, "
blue tribble^
cute doll"

See also:


INFO

This command returns some information about the MUSH you are on, such as its version number, time of last restart, number of players currently connected, and size of database. It can be issued from the connect screen.


Information functions

Information functions return values related to objects or the game.

  alias()       andflags()    andlflags()   config()      controls()
  ctime()       elock()       findable()    flags()       fullalias()
  fullname()    hasattr()     hasattrp()    hasflag()     haspower()
  hastype()     iname()       lflags()      lock()        lstats()
  money()       mtime()       mudname()     name()        nattr()
  nearby()      objid()       objmem()      orflags()     orlflags()
  playermem()   poll()        powers()      quota()       restarts()
  type()        version()     visible()

INHERIT

Flag: TRUST (all types)

TRUST is a security flag used to prevent objects without authorization from using @force, @set, and @trigger on other objects. Authorization is successful if any of these are true:

     1. The enactor is WIZARD ("wizards control all").
     2. The enactor's owner is TRUST ("the player trusts all their objects").
     3. The enactor is TRUST ("this object is trusted").
     4. The target is not TRUST ("this object isn't trusted").

That is, if a non-wizard player is set TRUST, all of their objects may act on each other (case 2). Otherwise, only TRUST objects may act on TRUST objects (case 3) but any of the player's object may act on non-TRUST objects (case 4).

Only TRUST or WIZARD objects may force their owners. Players can always @force, @set, and @trigger their objects.

This flag used to be called INHERIT, and INHERIT is still an alias for it, but TRUST better describes its action.

Read "help trust2" for more.


INSERT()

If <position> is a positive integer, this inserts <new item> BEFORE the item at <position> from the left in <list>.

That means that <new item> then becomes the <position>th element of <list>. If a separator is not given, a space is assumed. Null items are counted when determining position, as in 'items()'.

If <position> is a negative integer, this inserts <new item> AFTER the item at the absolute value of <position> from the RIGHT in <list>.

This is the same as reversing the list before inserting <new item>, and then reversing it again into correct order. For example, when <position> is -1, <new item> will be the last in the list; when <position> is -2, <new item> will be the second item from the right, and so on.

Example:

> say [insert(This is a string,4,test)]
You say, "This is a test string"
> say [insert(one|three|four,2,two,|)]
You say, "one|two|three|four"
> say [insert(meep bleep gleep,-3,GOOP)]
You say, "meep GOOP bleep gleep"

INTERIORS

Here's a quick description of how to make things that can be entered:

  @create Car
  @desc Car=A shiny red car.
  @idesc car=You are sitting inside a luxurious sportscar.
  @set Car=enter_ok
  @oxleave car=climbs out of the car.   { The 'ox' messages are shown to 
  @oxenter car=climbs into the car.     { those OUTSIDE the object.
  @oenter car=joins you inside the car. { The 'o' messages are shown to 
  @oleave car=gets out of the car.      { those INSIDE the object
  @enter car=You get into the car.      { The plain messages are shown to 
  @leave car=You get out of the car.    { the one entering or leaving 

(continued in help interiors2)


INTERIORS2

Now, if you want people inside to be able to hear and communicate with the outside, you also need to do the following.

  @set car=audible  (lets people outside hear what's being said in the car.
  @listen car=*     (lets people inside hear what's being said outside.
  @prefix car=From inside the car,
  @inprefix car=From outside,
  @filter car=* has arrived.,* has left.,joins you inside the car.,
    gets out of the car.
  @infilter car=* has arrived.,* has left.,* climbs out of the car.,
    * climbs into the car.

(The filters will keep people on the outside from seeing the 'o' messages and people on the inside from seeing the 'ox' messages which is a good thing.)

See also:


inventory

Lists what you are carrying. Can be abbreviated by just 'i', or 'inv'. It also tells you how much MUSH money you have. If you are not set OPAQUE, others will also be able to see what is in your inventory by looking at you.

Note that on some MUSHes it is possible to take things that are in someone else's inventory. To be safe, @lock any objects that you do not want to lose.

See also:


IPADDR()

Returns the IP address of the connected player or descriptor. This may be more reliable that get(<player>/lastip) if the player has multple connections from different locations, and the function is called with a descriptor argument.

The caller can use the function on himself, but using on any other player requires privileged power such as Wizard, Royalty or SEE_ALL.

See also:


ISDAYLIGHT()

Returns 1 if it's daylight savings time in the MUSH time zone, otherwise 0.


ISDBREF()

This function returns 1 if the string is a valid object dbref (or object id), and 0 if the string is not a valid object dbref/objid.

See also:


ISINT()

Returns 1 if its argument is an integer, and 0 otherwise. Integers can begin with a '+' or '-' sign, but the rest of the string must be digits.

See also:


ISNUM()

This function returns 1 if <string> is a number, and 0 if it is not. Numbers can begin with a '-' sign (for negatives), but the rest of the characters in the string must be digits, and an optional decimal point.

See also:


ISOBJID()

This function returns 1 if the string is a valid object id, and 0 if the string is not a valid object id.

See also: DBREFS, isdbref(), objid()


ISWORD()

This function returns 1 if every character in <string> is a letter, or 0, if any character isn't a letter. Case does not matter.


ITEMIZE()
  These functions take the elements of <list> (separated by <delim> or
  a space by default), and:
   If there's just one, return it.
   If there's two, return <e1> <conjunction> <e2>
   If there's more than two, return <e1><punc> <e2><punc> ... <conj> <en>
  The default <conjunction> is "and", default punctuation is ","
  Examples:
    > say [itemize(eggs)] * [itemize(eggs bacon)]
    You say, "eggs * eggs and bacon" 
    > say [itemize(eggs bacon spam)]
    You say, "eggs, bacon, and spam"
    > say [itemize(eggs bacon spam, ,&,;)]
    You say, "eggs; bacon; & spam"

ITEMS()

items() counts the number of items in a list using an arbitrary (required) separator. Null items are counted, so:

        items(X|X,|)     => 2     (2 X items)
        items(X||X,|)    => 3     (2 X items and 1 null item)
        items(X X,%b)    => 2     (2 X items)
        items(X%b%bX,%b) => 3     (2 X items and 1 null item)
        items(,|)        => 1     (a single null item)
   Another way to think about this is that items() counts the number
   of delimiters in the string, and adds 1.

ITER()

This works in a manner very similar to @map, except that it returns a string directly. <list> is a space-separated list of words, and <pattern> is what will be "mapped" onto each element of the list, with the token "##" being replaced successively by the next word in the list, and the token "#@" being replaced by the word's position in the list (also see 'help itext()' and see 'help inum()'). The result is concatenated and returned as a space separated list. This is similar to @dolist, but the results are made into a list rather than executed.

The list may be <delimiter>-separated.

By default, the return list will be space-separated. However, by including the output separator (which requires explicitly including the delimiter), you can have it separated by any string.

Continued in HELP ITER2


ITER2

parse() is a synonym for iter(). If you nest iters, ## and #@ refer to the first iter(). See 'help ITEXT()' and 'help INUM()' for how to retrieve their values for any nested iter. See 'help MAP()' for a similar function.

Note that ## and #@ are replaced before evaluation, so the word will be evaluated, which can be a problem when iter()ing on an untrusted list. iter-with-itext or map() should be preferred to iter-with-## whenever you're iterating over user-provided values.

Example:

> say [iter(This is a test string., [strlen(##)])]
You say, "4 2 1 4 7"

Example:

> say [iter(lnum(5), mul(add(##,##),2))]
You say, "0 4 8 12 16"

Example:

> say [iter(lexits(here), [name(##)] (owned by [name(owner(##))]))]
You say, "South (owned by Claudia) North (owned by Roy)"

Example:

> &STRLEN_FN me=[strlen(%0)]
> say [iter(This is a test string., [u(STRLEN_FN, ##)])]
You say, "4 2 1 4 7"

This example could be replaced by the use of map() like so: > say [map(strlen_fun, This is a test string)]

Example:

> say [iter(lnum(3), ##, ,%r)]
You say, "0
1
2"

Generated at Mon Jul 2 00:35:04 2007