trace.c

ds2.4.1/lib/secure/cmds/creators/trace.c · 453 B

From the archive ds2.4.1.zip

Download the archive   « Back to the archive contents

#include <lib.h>
#include <daemons.h>

inherit LIB_DAEMON;

mixed cmd(string args) {
    int x;
    if(!args) args = "0";
    x = atoi(args);
    if(!archp(previous_object())) return 0;
    trace(x);
    write("Set tracing level to "+x+".");
    return 1;
}

int help() {
    message("help", "Syntax: <trace [level]>\n\n"
      "Displays function call tracing to you. See \"man trace\""
      " for details on tracing levels.",
      this_player());
}

Site Stats

Snippets: 1791
Codebases: 571