mload

mload <vnum> [room] [max]

Load a new mobile into a room.

A fresh copy of the mobile with the given vnum is created and placed in a room. With no room given, it appears in the owner's current room. The optional max limits how many of that mobile may exist before the load is refused. The new mobile's own load handler fires.

Arguments

Returns

null. Like the other action commands, a successful mload in the handle phase suppresses the event's default action. A failed load (unknown vnum, or the max limit reached) does not suppress it.

Examples

after command (say) {
  mload 1
}

Mobile vnum 1 is loaded into the owner's current room. The script compiles and runs to completion.

handle command (cast) {
  mload 1 [room $actor]
}

The mobile is loaded into the actor's room instead (see room).

See also