Deleted from the LambdaCore 8/3/93 by Nosredna Syntax: @realm [owners] [from root] [missing descendants] Displays a part of the parenting tree of objects on the MOO, i.e. all the descendants of a given object owned by particular players. owners: a list of players whose objects you are interested in. If one of these is * or !, @realm will display objects only if they belong to players you didn't mention. (defaults to you) root: the object which is an ancestor of all the objects you are interested in. (defaults to $root_class). descendants: a list of objects (descendants of root) which you are not interested in. Neither they nor their descendants will be displayed. @realm also displays the objects which are ancestors of root, and, if it is not redundant, the owners of all objects. @realm has a habit of running out of ticks if you try displaying large chunks of the MOO. @program $builder:@realm "Usage: @realm [owner] [from root] [missing list_to_miss]"; "Where owner is a player's name or #nnn"; " root is $property or #nnn"; " list_to_miss elements are #nnn or $property"; set_task_perms(player); "Let the owner kill the task..."; miss = {}; root = #1; who = {}; c = 1; for q in (args) if (c == 1) if (q == "*" || q == "!") who = setadd(who, $nothing); elseif (q == tostr(z = toobj(q))) who = setadd(who, z); elseif (index("from", q)) c = 2; elseif (index("missing", q)) c = 3; elseif (valid(z = $string_utils:match_player(q))) who = setadd(who, z); endif elseif (c == 2) if (index("missing", q)) c = 3; elseif (valid(z = this.location:match_object(q))) root = z; elseif (q == tostr(z = toobj(q))) root = z; elseif (q == "me") root = this; elseif (q == "here") root = this.location; elseif (q[1] == "$" && (z = q[2..length(q)]) in properties(#0) && typeof(#0.(z)) == OBJ) root = #0.(z); endif elseif (c == 3) if (q == tostr(z = toobj(q))) miss = listappend(miss, z); elseif (q[1] == "$" && (z = q[2..length(q)]) in properties(#0)) miss = listappend(miss, #0.(z)); elseif (valid(z = this.location:match_object(q))) miss = listappend(miss, z); endif endif endfor if (who == {}) who = {player}; endif if (player.wizard && length(who) == 1 && valid(who[1])) quota = tostr(", ", who[1].ownership_quota, " additional allowed"); else quota = ""; endif anc = {}; spc = ""; anc = $object_utils:ancestors(root); for k in [1..length(anc)] foo = anc[length(anc) + 1 - k]; player:notify(tostr(spc, foo.name, " (", foo, ") [", foo.owner.name, " (", foo.owner, ")]")); spc = spc + " "; endfor text = this:realm2(root, who, spc, miss); player:notify_lines(text[2]); player:notify(tostr("*** Objects: ", length(text[2]), " in hierarchy, ", text[1], " owned", quota, ". ***")); . @program $builder:realm2 root = args[1]; owner = args[2]; space = args[3]; missing = args[4]; number = 0; text = {}; set_task_perms(caller_perms()); for foo in (children(root)) $command_utils:suspend_if_needed(0); if (!(foo in missing)) branch = this:realm2(foo, owner, space + " ", missing); text = {@text, @branch[2]}; number = number + branch[1]; endif endfor bra = ket = ""; if ((root.owner in owner && 1) != ($nothing in owner && 1) && (number = number + 1) || (text != {} && ((bra = "<") && (ket = ">")))) text = listinsert(text, tostr(space, bra, root.name, " (", root, ")", ket, @length(owner) == 1 && owner != {$nothing} ? {} | {" [", valid(root.owner) ? root.owner.name | "** recycled **", " (", root.owner, ")]"})); endif return {number, text}; .