@verb #12:"@folder*2" any any any rdo #8084 @program #12:"@folder*2" any any any "All commands have a folder name first, possibly in quotation marks, and then a command such as a +, -, ++, rename, or delete." if (player != this) return $msg:mtell("huh") endif m = match(argstr, "^%(\"[^\"]+\"%|[^ ]+%)") if (!m) return player:tell("I can't understand your folder name. Please read the help on the @folder command, or use it with no arguments for an interactive @folder usage.") endif fname = argstr[m[3][1][1]..m[3][1][2]] argstr = `argstr[m[2] + 1..$] ! E_RANGE => ""' if (match(fname, "^\".*\"$")) fname = `fname[2..$ - 1] ! E_RANGE => ""' endif if (!(idx = listiassoc(fname, this.audit_folders))) return player:tell("You don't seem to have a folder named '", fname, "'.") endif m = match(argstr, " *%(%+%+%|%+%|-%|rename%|delete%)") if (!m) return player:tell("I can't understand your command. Please read the help on the @folder command, or use it with no arguments for interactive help.") endif cmd = argstr[m[3][1][1]..m[3][1][2]] if (cmd == "+" || cmd == "++" || cmd == "-") whatstr = `argstr[m[3][1][2] + 1..$] ! E_RANGE => ""' if ($command_utils:object_match_failed(what = player:my_match_object(whatstr), whatstr)) return elseif (cmd == "+" || cmd == "-") if (what.owner != player) return player:tell("You don't own ", $su:nn(what), ".") endif for x in [1..length(this.audit_folders)] this.audit_folders[x][2] = setremove(this.audit_folders[x][2], what) endfor if (cmd == "+") this.audit_folders[idx][2] = setadd(this.audit_folders[idx][2], what) endif return player:tell(cmd == "+" ? "Addition" | "Removal", " completed.") else for y in (this.owned_objects) if (y:isa(what)) for x in [1..length(this.audit_folders)] this.audit_folders[x][2] = setremove(this.audit_folders[x][2], y) endfor this.audit_folders[idx][2] = setadd(this.audit_folders[idx][2], y) endif endfor player:tell("Gathering completed.") endif elseif (cmd == "rename") m = match(argstr, "%(\"[^\"]+\"%|[^ ]+%) *$") if (!m) return player:tell("I didn't understand what you wanted me to rename that to.") endif newname = argstr[m[3][1][1]..m[3][1][2]] if (match(newname, "^\".*\"$")) newname = `newname[2..$ - 1] ! E_RANGE => ""' endif this.audit_folders[idx][1] = newname player:tell("Rename completed.") elseif (cmd == "delete") this.audit_folders = listdelete(this.audit_folders, idx) player:tell("Folder removed.") else return player:tell("I didn't understand that.") endif "Last modified by Lao-Tzu (#8084) on Wed Dec 5 15:03:18 2001 MST." .