@startup #1=@dolist secure(get(#10/GFUN_LIST))=@function/privileged [first(##,:)]=[rest(##,:)]; @dolist secure(get(#10/ADDCMD_LIST))=@addcommand [first(##,:)]=[rest(##,:)]; @@ uncomment to add TrueName speech; @@ @trig me/SPEECH_TRIG &SPEECH_TRIG #1=@dolist secure(get(#10/SPEECHCMD_LIST))=@addcommand/preserve [first(##,:)]=[rest(##,:)]; @addcommand/preserve :=#55/DO_COLON &HELP_TRUE_NAMES #8=On some MUSHes, the 'look', 'say', and 'pose' commands (as well as their abbreviations, such as 'l', '\\\"', ':', and ';'), obey \\\"True Names\\\". True Names are a convenient way of prefixing the things you say/pose with something other than your actual character name. In some cases this might be just a title you'd like to add onto your name (\\\"Lord Chantris\\\") or it could be a full name or in-character alias (\\\"Brandon Corey\\\"), or the name of an NPC that you're playing in that particular scene (\\\"The nondescript man in black\\\").%r%rYou can set your true name with '&TN me = '. If you're just using your regular character name, please DO NOT set a True Name -- do this ONLY when the name is different.%r%rNote that this ONLY affects looks, says, and poses -- it doesn't affect WHO, pages, places code, and so forth. &WHO_IDLE_FN #10=[setq(x,86400 3600 60 1)][setq(y,switch(member(whenfalse(%qx,gte(%0,##)),1),0,4,#$))][setq(z,div(%0,extract(%qx,%qy,1)))][ifelse(lt(%qz,10),%b,)]%qz[extract(d h m s,%qy,1)] &CUSTOM_FINGER_FN #10=[objeval(%q0,s(edit(first(%0,<),%b,\\\\\\\\%b)))][iter(rest(%0,<),[u(FINGER_FMT_FN,first(##,>))][objeval(%q0,s(edit(rest(##,>),%b,\\\\\\\\%b)))],<,@@)] &PCREATE_DATA #10=#54 &DO_LIST_PA #11=$+list personal aliases: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,lattr(%q0/ALIAS_*))][switch(%q0:%q1,:*,You have no personal mail aliases defined.,*:,You have no personal mail aliases defined.,Personal mail aliases: [lcstr(sort(iter(%q1,rest(##,_))))])] &DO_CC #11=$+cc *: @pemit %#=[setq(0,get(%#/MBOX))][setq(9,switch(u(SEND_STATUS_FN,%#),IN_PROG,MSG_CC,!))][null(set(%q0,%q9:[setq(8,secure(%0))][setq(1,map(RAW2LIST_FN,%q8))][edit(%q1,#-1,)]))][switch(%q9,!,v(NOT_IN_PROG_ERR),Carbon copy set.[setq(2,u(LIST_ERR_FN,%q1,%q8))][switch(%q2,,,%rUnknown addresses: %q2)])] &DO_MARK_RANGE #11=$+mark *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))]=1, {@pemit %#=u(NO_MSGS_ERR,%0)}, {&MARK_LIST %q0=setinter(setunion(get(%q0/MARK_LIST),%q9),%q1); @pemit %#=Message(s) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] marked.} &DO_SEND #11=$+send: @eval switch([setq(0,get(%#/MBOX))][u(SEND_STATUS_FN,%#)]:[setq(9,[get(%q0/MSG_TO)] [get(%q0/MSG_CC)] [get(%q0/MSG_BCC)])][gt(words(%q9),v(MAX_MAILTO))],IN_PROG:0,[null(iter([setq(1,u(LIST2DEST_FN,%q9))][filter(NOBOX_FILT_FN,%q1)],u(CREATE_MBOX_FN,##,8)))][u(SEND_MSG_FN,%#,%q0,add(u(LAST_SENT_FN,%q0),1),%q1,iter(%q1,get(##/MBOX)),%l)],IN_PROG:1,pemit(%#,A message cannot have more than [v(MAX_MAILTO)] recipients.),pemit(%#,v(NOT_IN_PROG_ERR))) &DO_TAG #11=$+tag *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][pos(=,%0)]:[or(strmatch(%q0,),strmatch(%q1,))]=#-1:1, {@pemit %#=You have no mail.},#-1:0, {&TAG_%0 %q0=setinter(setunion(get(%q0/TAG_%0),%q3),%q1); @pemit %#=Message %q2 (current) marked with tag '[lcstr(%0)]'.} &IS_PLAYER #11=[hastype(%#,PLAYER)] &DO_DESTROY_MAILBOX #11=$+destroy mailbox for *: @switch/first [hasflag(%#,Wizard)]:[setq(0,get(*%0/MBOX))]%q0=0:*, {@pemit %#=Permission denied.},1:, {@pemit %#=No mailbox to destroy.}, {@dolist get(%q0/RECV_LIST)={@wipe [setq(3,first(##,-))][setq(4,rest(##,-))][switch(strmatch(get(%q3/P-%q4),%q0),0,#-1,%q3)]/?-%q4; &P-%q4 %q3=remove(get(%q3/P-%q4),%q0)}; @dolist lattr(%q0/P-*)=@trig me/DEST_MBOX_TRIG1=%q0,rest(##,-); @wait 2=@trig me/DEST_MBOX_TRIG2=%#,num(*%0),%q0} &DO_TAG_RANGE #11=$+tag *=*: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))]=1, {@pemit %#=u(NO_MSGS_ERR,%0)}, {&TAG_%1 %q0=setinter(setunion(get(%q0/TAG_%1),%q9),%q1); @pemit %#=Message(s) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] marked with tag '[lcstr(%1)]'.} &DO_UNDELETE_RANGE #11=$+undelete *: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))],1,u(NO_MSGS_ERR,%0),Message\\(s\\) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] removed from deletion list.[set(%q0,DEL_LIST:[setinter(setdiff(get(%q0/DEL_LIST),%q9),%q1)])]) &DO_REPLY_RANGE #11=$+reply *: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,u(GET_RANGE_FN,%0,%q0,%q1))][u(QSEND_STATUS_FN,%#)]:[words(%q2)],IN_PROG:*,v(IN_PROG_ERR),OVER_QUOTA:*,v(OVER_QUOTA_ERR),*:0,u(NO_MSGS_ERR,%0),*:1,[set(%q0,MSG_TO:[setq(3,first(%q2,-))][setq(4,rest(%q2,-))][get(%q3/PLAYER)])][set(%q0,MSG_SUBJECT:[setq(5,rest(get(%q3/S-%q4),!))][switch(%q5,Re: *,%q5,Re: %q5)])][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)],You can only reply to one message at a time.) &DO_REMOVE_GA #11=$+remove global alias *: @pemit %#=switch([hasflag(%#,wizard)]:[lattr(v(DATA_OBJ)/ALIAS_%0)],0:*,Permission denied.,1:ALIAS_%0,Global mail alias '[lcstr(%0)]' removed.[set(v(DATA_OBJ),ALIAS_%0:)],No such global mail alias to remove.) &DO_FLUSH #11=$+flush: @pemit %#=switchall([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/DEL_LIST))][or(strmatch(%q0,),strmatch(%q1,))]:%q2:[eq(member(%q2,extract(%q1,get(%q0/CURR_NUM),1)),0)],1:*:*,u(NO_MSGS_ERR),0::*,No deleted messages to flush \\([words(%q1)] remain\\).,0:*:0,set(%q0,CURR_NUM:),0:?*:*,Messages marked for deletion flushed \\([words(%q2)] deleted\\, [sub(words(%q1),words(%q2))] remain\\).[u(DEL_MSGS_FN,%q0,%q2)][set(%q0,DEL_LIST:)]) &DO_REVIEW_LETTERS #11=$+review letters: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,u(SENT_LIST_FN,%q0))][setq(2,words(%q1))][switch(%q0:%q1,:*,You have sent no mail.,*:,No letters available for review.,[u(REVIEW_HDR)][map(REVIEW_LIST_FN,extract(%q1,1,40))])]; @dolist switch(lt(%q2,41),1,,rest(lnum(add(div(%q2,40),1))))={@pemit %#=after(map(REVIEW_LIST_FN,extract(%q1,add(mul(##,40),1),40)),%r)} &DO_DELETE_RANGE #11=$+delete *: @pemit %#=switchall([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))]:[u(MAILOPT_FN,get(%#/MAIL_CONFIG_OPTIONS),soft,hard,delete)]:[eq(member(%q9,extract(%q1,%q2,1)),0)],1:*:*,u(NO_MSGS_ERR,%0),0:soft:*,Message\\(s\\) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] marked for deletion.[set(%q0,DEL_LIST:[setunion(get(%q0/DEL_LIST),%q9)])],0:hard:0,set(%q0,CURR_NUM:),0:hard:*,Message\\(s\\)[u(CRITERION_FN,%0)] deleted.[u(DEL_MSGS_FN,%q0,%q9)]) &DO_BOUNCE #11=$+bounce *=*: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,u(GET_RANGE_FN,%1,%q0,%q1))][u(SEND_STATUS_FN,%#)]:[words(%q2)],IN_PROG:*,v(IN_PROG_ERR),*:0,u(NO_MSGS_ERR,%1),*:1,[setq(7,map(RAW2LIST_FN,%0))][setq(4,u(LIST_ERR_FN,%q7,secure(%0)))][switch(%q4,,,pemit(%#,Unknown addresses: %q4))][null(iter([setq(8,edit(%q7,#-1,))][setq(9,switch(%q8,,%#,%q8))][setq(6,filter(NOT_HAS_MSG_FN,u(LIST2DEST_FN,%q9)))][filter(NOBOX_FILT_FN,%q6)],u(CREATE_MBOX_FN,##,7)))][u(BOUNCE_MSG_FN,%#,first(%q2,-),rest(%q2,-),%q6,iter(%q6,get(##/MBOX)),%l,%q9)],You can only bounce one message at a time.) &DO_READ_RANGE #11=$+read *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))]%q9=, {@pemit %#=u(NO_MSGS_ERR,%0)},#-1 NO MATCH, {@pemit %#=u(NO_MSGS_ERR,%0)}, {@dolist [setq(6,u(MAILOPT_FN,get(%#/MAIL_CONFIG_OPTIONS),standard,compact,format))]%q9=@pemit %#=u(READ_%q6_FN,##); &NEW_LIST %q0=setinter(setdiff(get(%q0/NEW_LIST),%q9),%q1); &CURR_NUM %q0=member(%q1,extract(%q9,words(%q9),1))} &DO_SET_MAIL_OPTION #11=$+set mail option *=*: @pemit %#=[ifelse(setr(0,get(%#/MBOX)),,[u(CREATE_MBOX_FN,%#,0)])][switch(%0:[u(OK_%0_OPT_FN,%1)],autoforward:0,You can only forward mail to valid players.,autoforward:1,Your mail will [switch(%1,,no longer be forwarded[set(%q0,FORWARD_TO:)],now be forwarded to [set(%q0,FORWARD_TO:[switch(%1,,,iter(%1,num(*##)))])][null(iter(filter(NOBOX_FILT_FN,get(%q0/FORWARD_TO)),u(CREATE_MBOX_FN,##,8)))][u(COMMA_LIST_FN,iter(%1,name(*##)))])].,delete:0,Your delete option must be 'soft' or 'hard'.,space:0,Your space option must be 'space' or 'return'.,format:0,Your format option must be 'standard' or 'compact'.,*:1,Your [lcstr(%0)] option has been set to '[lcstr(%1)]'.[set(%#,MAIL_CONFIG_OPTIONS:[setunion(get(%#/MAIL_CONFIG_OPTIONS),lcstr(%1))])],That is not a valid mail option.)] &DO_UNTAG_RANGE #11=$+untag *=*: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))]=1, {@pemit %#=u(NO_MSGS_ERR,%0)}, {&TAG_%1 %q0=setinter(setdiff(get(%q0/TAG_%1),%q9),%q1); @pemit %#=Message(s) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] removed from tag list '[lcstr(%1)]'.} &DO_SKIM #11=$+skim: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,words(%q1))][switch(%q0:%q9,:*,You have no mail.,*:0,You have no mail.,[setq(5,u(MAILOPT_FN,get(%#/MAIL_CONFIG_OPTIONS),standard,compact,format))][u(SKIM_%q5_HDR)][map(SKIM_FN,extract(%q1,1,40))][switch(%q5:[lte(%q9,40)],standard:1,%r%r[repeat(=,78)])])]; @dolist switch(lt(%q9,41),1,,rest(lnum(add(div(%q9,40),1))))={@pemit %#=after([map(SKIM_FN,extract(%q1,add(mul(##,40),1),40))][switch(%q5:[lte(%q9,mul(##,40))],standard:1,%r%r[repeat(=,78)])],%r)} &DO_REVIEW #11=$+review letter *: @switch/first [setq(0,get(%#/MBOX))][setq(1,u(SENT_LIST_FN,%q0))][setq(2,u(REVIEW_RANGE_FN,%0,%q0,%q1))]%q0:%q1:%q2=:*:*, {@pemit %#=You have sent no +mail.},*::*, {@pemit %#=No letters available for review.},*:*:, {@pemit %#=No such letter(s) available for review.}, {@dolist %q2=@pemit %#=u(REVIEW_FN,##,%q1)} &DO_MAIL_STATUS #11=$+mail status: @pemit %#=[setq(0,get(%#/MBOX))][switch(%q0,,You do not have a mailbox.,Mailbox Status%r[u(MBOX_STATUS_FN,%q0,get(%#/MAIL_CONFIG_OPTIONS))])] &DO_SKIM_RANGE #11=$+skim *: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][setq(7,words(%q9))][switch(%q7,0,u(NO_MSGS_ERR,%0),[setq(5,u(MAILOPT_FN,get(%#/MAIL_CONFIG_OPTIONS),standard,compact,format))][u(SKIM_%q5_HDR)][map(SKIM_FN,extract(%q9,1,40))][switch(%q5:[lte(%q7,40)],standard:1,%r%r[repeat(=,78)])])]; @dolist switch(lt(%q7,41),1,,rest(lnum(add(div(%q7,40),1))))={@pemit %#=after([map(SKIM_FN,extract(%q9,add(mul(##,40),1),40))][switch(%q5:[lte(%q7,mul(##,40))],standard:1,%r%r[repeat(=,78)])],%r)} &DO_REPLY #11=$+reply: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,extract(get(%q0/RECV_LIST),get(%q0/CURR_NUM),1))][u(QSEND_STATUS_FN,%#)]:%q1,IN_PROG:*,v(IN_PROG_ERR),OVER_QUOTA:*,v(OVER_QUOTA_ERR),*:,No current message to reply to.,[set(%q0,MSG_TO:[setq(2,first(%q1,-))][setq(3,rest(%q1,-))][get(%q2/PLAYER)])][set(%q0,MSG_SUBJECT:[setq(4,rest(get(%q2/S-%q3),!))][switch(%q4,Re: *,%q4,Re: %q4)])][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)]) &DO_MAIL_DEFAULTS #11=$+mail defaults: @pemit %#=[repeat(-,78)]%r[center(Mail Defaults,78)]%r[repeat(-,78)]%r%r[ljust(Delete option:,20)] [v(OPTION_DELETE)]%r[ljust(Format option:,20)] [v(OPTION_FORMAT)]%r[ljust(Space option:,20)] [switch(s(%vs),%b,space,%r,return,%vs)]%r[ljust(Haven-Mail status:,20)] [v(HAVEN_MAIL)]%r%r[ljust(Expiration Time:,20)] [u(TIME_FMT_FN,v(RETRACT_TIME))]%r[ljust(Mail Quotas:,20)] [v(QUOTA_MAIL)]%r[ljust(Max Unread:,20)] [get(v(MBOX_OBJ)/MAX_UNREAD)]%r[ljust(Max Read:,20)] [get(v(MBOX_OBJ)/MAX_READ)]%r[switch(v(DASH_MSG),,,%r[ljust(Dash-Message:,20)] [v(DASH_MSG)])]%r[ljust(Mail-Enter:,20)] [v(DFL_MAIL_ENTER)]%r[ljust(Mail-Send:,20)] [v(DFL_MAIL_SEND)]%r[ljust(Mail-Deliver:,20)] [v(DFL_MAIL_DELIVER)]%r[ljust(Mail-Toss:,20)] [v(DFL_MAIL_TOSS)]%r[ljust(Mail-Note:,20)] [v(DFL_MAIL_NOTE)]%r%r[ljust(Current mailboxes:,20)] [words(lcon(v(STORAGE_OBJ)))]%r[ljust(Global aliases:,20)] [words(lattr(v(DATA_OBJ)/ALIAS_*))]%r%r[repeat(-,78)] &DO_UNMARK_RANGE #11=$+unmark *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))][or(strmatch(%q0,),strmatch(%q9,))]=1, {@pemit %#=u(NO_MSGS_ERR,%0)}, {&MARK_LIST %q0=setinter(setdiff(get(%q0/MARK_LIST),%q9),%q1); @pemit %#=Message(s) [u(COMMA_LIST_FN,sort(iter(%q9,member(%q1,##))))][u(CRITERION_FN,%0)] unmarked.} &DO_UNDELETE #11=$+undelete: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][setq(4,get(%q0/DEL_LIST))][or(strmatch(%q0,),strmatch(%q1,))]:[member(%q4,%q3)],1:*,You have no mail.,0:0,That message is not marked for deletion.,Message %q2 \\(current\\) removed from deletion list.[set(%q0,DEL_LIST:[setinter(remove(%q4,%q3),%q1)])]) &DO_PROOF #11=$+proof: @pemit %#=[setq(0,get(%#/MBOX))][switch(u(SEND_STATUS_FN,%#),IN_PROG,u(PROOF_FN,%#),v(NOT_IN_PROG_ERR))] &DO_CLEAR_RANGE #11=$+clear *: @fo %#={+delete %0} &DO_UNMARK #11=$+unmark: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][or(strmatch(%q0,),strmatch(%q1,))]=1, {@pemit %#=You have no mail.}, {&MARK_LIST %q0=setinter(remove(get(%q0/MARK_LIST),%q3),%q1); @pemit %#=Message %q2 (current) marked.} &DO_REPLYALL #11=$+replyall: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,extract(get(%q0/RECV_LIST),get(%q0/CURR_NUM),1))][u(QSEND_STATUS_FN,%#)]:%q1,IN_PROG:*,v(IN_PROG_ERR),OVER_QUOTA:*,v(OVER_QUOTA_ERR),*:,No current message to reply to.,[set(%q0,MSG_TO:[setq(2,first(%q1,-))][setq(3,rest(%q1,-))][setq(4,get(%q2/R-%q3))][get(%q2/PLAYER)] [first(%q4,!)])][set(%q0,MSG_CC:[extract(%q4,2,1,!)])][set(%q0,MSG_SUBJECT:[setq(4,rest(get(%q2/S-%q3),!))][switch(%q4,Re: *,%q4,Re: %q4)])][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)]) &DO_TOSS #11=$+toss: @pemit %#=switch([setq(0,get(%#/MBOX))][u(SEND_STATUS_FN,%#)],IN_PROG,[wipe(%q0/MSG_*)][u(u(NFY_MAIL_FN,%#,%l,TOSS),%#)],v(NOT_IN_PROG_ERR)) &DO_EXPAND_GA #11=$+expand global alias *: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,get(v(DATA_OBJ)/ALIAS_%0))][switch(%q1,,No such alias to expand.,Global mail alias '[lcstr(%0)]' expands to: [u(LIST_PRINT_FN,%q1)])] &DO_RESEND #11=$+resend letter *=*: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,u(SENT_LIST_FN,%q0))][setq(3,extract(%q1,%0,1))][setq(2,%q0-%q3)][u(SEND_STATUS_FN,%#)]:[words(%q3)]=IN_PROG:*,v(IN_PROG_ERR),*:1,[setq(7,map(RAW2LIST_FN,%1))][setq(4,u(LIST_ERR_FN,%q7,secure(%1)))][switch(%q4,,,pemit(%#,Unknown addresses: %q4))][null(iter([setq(8,edit(%q7,#-1,))][setq(9,switch(%q8,,%#,%q8))][setq(6,filter(NOT_HAS_MSG_FN,u(LIST2DEST_FN,%q9)))][filter(NOBOX_FILT_FN,%q6)],u(CREATE_MBOX_FN,##,7)))][u(RESEND_MSG_FN,%#,%q0,%q3,%q6,iter(%q6,get(##/MBOX)),%l,%q9)],That is not a valid letter.) &DO_BCC #11=$+bcc *: @pemit %#=[setq(0,get(%#/MBOX))][setq(9,switch(u(SEND_STATUS_FN,%#),IN_PROG,MSG_BCC,!))][null(set(%q0,%q9:[setq(8,secure(%0))][setq(1,map(RAW2LIST_FN,%q8))][edit(%q1,#-1,)]))][switch(%q9,!,v(NOT_IN_PROG_ERR),Blind carbon copy set.[setq(2,u(LIST_ERR_FN,%q1,%q8))][switch(%q2,,,%rUnknown addresses: %q2)])] &DO_DESTROY_MBOX_DBREF #11=$+destroy mbox dbref *: @switch/first [hasflag(%#,Wizard)]:[setr(0,switch(setr(9,get(%0/PLAYER)),,,%0))]=0:*, {@pemit %#=Permission denied.},1:, {@pemit %#=No mailbox to destroy.}, {@dolist get(%q0/RECV_LIST)={@wipe [setq(3,first(##,-))][setq(4,rest(##,-))][switch(strmatch(get(%q3/P-%q4),%q0),0,#-1,%q3)]/?-%q4; &P-%q4 %q3=remove(get(%q3/P-%q4),%q0)}; @dolist lattr(%q0/P-*)=@trig me/DEST_MBOX_TRIG1=%q0,rest(##,-); @wait 2=@trig me/DEST_MBOX_TRIG2=%#,%q9,%q0} &DO_MAIL_STATUS_FOR #11=$+mail status for *: @pemit %#=[setq(0,get(*%0/MBOX))][switch([hasflag(%#,wizard)]:[num(*%0)]:%q0,0:*:*,Permission denied.,1:#-1:*,No such player.,1:*:,[name(*%0)] does not have a mailbox.,{Mail Status for [name(*%0)] \\(mailbox %q0\\):%r[u(MBOX_STATUS_FN,%q0,get(*%0/MAIL_CONFIG_OPTIONS))]})] &DO_FORWARD #11=$+forward *=*: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,u(GET_RANGE_FN,%1,%q0,%q1))][u(QSEND_STATUS_FN,%#)]:[words(%q2)],IN_PROG:*,v(IN_PROG_ERR),OVER_QUOTA:*,v(OVER_QUOTA_ERR),*:0,u(NO_MSGS_ERR,%1),*:1,[set(%q0,MSG_TO:[setq(3,map(RAW2LIST_FN,%0))][setq(9,edit(%q3,#-1,))][switch(%q9,,%#,%q9)])][set(%q0,MSG_SUBJECT:Fwd: [setq(4,first(%q2,-))][setq(5,rest(%q2,-))][setq(6,get(%q4/S-%q5))][setq(7,get(%q4/R-%q5))][rest(%q6,!)])][set(%q0,MSG_TEXT:Forwarded message from [name(get(%q4/PLAYER))] at [convsecs(first(%q6))]:%r[space(8)]----------%r[ljust(To:,10)] [u(LIST_PRINT_FN,first(%q7,!))][u(EXIST_PRINT_FN,Cc:,extract(%q7,2,1,!))]%rText:%r[get(%q4/M-%q5)]%r[space(8)]----------%r)][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)][setq(8,u(LIST_ERR_FN,%q3,%0))][switch(%q8,,,%rUnknown addresses: %q8)],You can only forward one message at a time.) &DO_REVIEW_LETTERS_RANGE #11=$+review letters *: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,u(SENT_LIST_FN,%q0))][setq(2,u(REVIEW_RANGE_FN,%0,%q0,%q1))][setq(3,words(%q2))][switch(%q0:%q1:%q2,:*:*,You have sent no +mail.,*::*,No letters available for review.,*:*:,No such letter\\(s\\) available for review.,[u(REVIEW_HDR)][map(REVIEW_LIST_FN,extract(%q2,1,40))])]; @dolist switch(lt(%q3,41),1,,rest(lnum(add(div(%q3,40),1))))={@pemit %#=after(map(REVIEW_LIST_FN,extract(%q2,add(mul(##,40),1),40)),%r)} &DO_MARK #11=$+mark: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][or(strmatch(%q0,),strmatch(%q1,))]=1, {@pemit %#=You have no mail.}, {&MARK_LIST %q0=setinter(setunion(get(%q0/MARK_LIST),%q3),%q1); @pemit %#=Message %q2 (current) marked.} &DO_DUMPMAIL_RANGE #11=$+dumpmail *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(9,u(GET_RANGE_FN,%0,%q0,%q1))]%q9=, {@pemit %#=u(NO_MSGS_ERR,%0)},#-1 NO MATCH, {@pemit %#=u(NO_MSGS_ERR,%0)}, {@dolist %q9=@pemit %#=u(DUMPMAIL_FMT_FN,##)} &DO_READ #11=$+read: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,words(get(%q0/RECV_LIST)))][setq(2,words(get(%q0/NEW_LIST)))][switch(%q0:%q1:%q2,:*:*,There is no mail in your mailbox.,*:0:*,There is no mail in your mailbox.,*:*:0,You do not have unread mail \\(%q1 messages remain\\).,You have %q2 unread mail message\\(s\\) out of a total of %q1.)] &DO_DASHDASH #11=$--: @fo %#=+send &DO_ADD_PA #11=$+add personal alias *=*: @pemit %#=switchall([setq(0,get(%#/MBOX))][u(SEND_STATUS_FN,%#)]:[lattr(%q0/ALIAS_%0)],NEED_BOX~*:*,u(CREATE_MBOX_FN,%#,0),*:ALIAS_%0,You already have an alias called '[lcstr(%0)]'.,Alias added. [set(%q0,ALIAS_%0:[setq(1,map(RAW2LIST_FN,%1))][edit(%q1,#-1,)])][setq(2,u(LIST_ERR_FN,%q1,%1))][switch(%q2,,,Unknown addresses: %q2)]) &DO_REPLYALL_RANGE #11=$+replyall *: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,u(GET_RANGE_FN,%0,%q0,%q1))][u(QSEND_STATUS_FN,%#)]:[words(%q2)],IN_PROG:*,v(IN_PROG_ERR),OVER_QUOTA:*,v(OVER_QUOTA_ERR),*:0,v(MSGS_ERR),*:1,[set(%q0,MSG_TO:[setq(3,first(%q2,-))][setq(4,rest(%q2,-))][setq(5,get(%q3/R-%q4))][get(%q3/PLAYER)] [first(%q5,!)])][set(%q0,MSG_CC:[extract(%q5,2,1,!)])][set(%q0,MSG_SUBJECT:[setq(5,rest(get(%q3/S-%q4),!))][switch(%q5,Re: *,%q5,Re: %q5)])][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)],You can only reply to one message at a time.) &DO_SET_MAIL_QUOTA #11=$+set mail quota *=*/*: @pemit %#=switch([setq(0,get(*%0/MBOX))][hasflag(%#,Wizard)]:[num(*%0)]:%q0,0:*:*,Permission denied.,*:#-1:*,No such player.,1:*:,[name(*%0)] does not have a mailbox.,Mail quotas for [name(*%0)] set to [setr(1,floor(%2))] messages \\\\([setr(2,floor(%1))] unread\\\\).[set(%q0,MAX_READ:%q1)][set(%q0,MAX_UNREAD:%q2)]) @aconnect #11=@wait [setq(0,get(%#/MBOX))][switch(%q0:[u(QUOTA_STATUS_FN,%q0)],:*,#-1,*:1,30,#-1)]=@pemit %#=u(OVER_QUOTA_MSG,%q0,%q1,%q2,%q3,%q4) &DO_DELETE #11=$+delete: @pemit %#=switchall([setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][setq(4,first(%q3,-))][setq(5,rest(%q3,-))][or(strmatch(%q0,),strmatch(%q1,))]:[u(MAILOPT_FN,get(%#/MAIL_CONFIG_OPTIONS),soft,hard,delete)]:[eq(%q2,words(%q1))]:[strmatch(get(%q4/P-%q5),%q0)],1:*:*:*,You have no mail.,0:soft:*:*,Message [get(%q0/CURR_NUM)] \\(current\\) marked for deletion.[set(%q0,DEL_LIST:[setunion(get(%q0/DEL_LIST),%q3)])],0:hard:*:*,Message %q2 \\(current\\) deleted.[set(%q0,RECV_LIST:[remove(get(%q0/RECV_LIST),%q3)])][set(%q0,NEW_LIST:[remove(get(%q0/NEW_LIST),%q3)])][set(%q0,MARK_LIST:[remove(get(%q0/MARK_LIST),%q3)])][set(%q0,DEL_LIST:[remove(get(%q0/DEL_LIST),%q3)])],0:hard:1:*,set(%q0,CURR_NUM:),0:hard:*:1,wipe(%q4/?-%q5),0:hard:*:0,[set(%q4,P-%q5:[remove(get(%q4/P-%q5),%q0)])]) &DO_ADD_GA #11=$+add global alias *=*: @pemit %#=switch([hasflag(%#,wizard)]:[lattr(v(DATA_OBJ)/ALIAS_%0)],0:*,Permission denied.,1:,Global alias added. [set(v(DATA_OBJ),ALIAS_%0:[setq(0,get(%#/MBOX))][setq(1,map(RAW2LIST_FN,%1))][edit(%q1,#-1,)])][setq(2,u(LIST_ERR_FN,%q1,%1))][switch(%q2,,,Unknown addresses: %q2)],The global mail alias '[lcstr(%0)]' already exists.) &DO_EXPAND_PA #11=$+expand personal alias *: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,get(%q0/ALIAS_%0))][switch(%q0:%q1,:*,No such alias to expand.,*:,No such alias to expand.,Personal mail alias '[lcstr(%0)]' expands to: [u(LIST_PRINT_FN,%q1)])] &DO_REMOVE_PA #11=$+remove personal alias *: @pemit %#=switch([setr(0,get(%#/MBOX))]:[lattr(%q0/ALIAS_%0)],:*,No such alias to remove.,*:ALIAS_%0,Alias removed.[set(%q0,ALIAS_%0:)],No such alias to remove.) &DO_MAIL #11=$+mail *=*: @pemit %#=switchall([setq(0,get(%#/MBOX))][u(QSEND_STATUS_FN,%#)],IN_PROG,v(IN_PROG_ERR),OVER_QUOTA,v(OVER_QUOTA_ERR),NEED_BOX~SEND,u(CREATE_MBOX_FN,%#,0),*~SEND,[setq(0,get(%#/MBOX))][set(%q0,MSG_TO:[setq(1,map(RAW2LIST_FN,secure(%0)))][setq(9,edit(%q1,#-1,))][switch(%q9,,%#,%q9)])][set(%q0,MSG_SUBJECT:[trim(%1)])][u(u(NFY_MAIL_FN,%#,%l,ENTER),%#)][setq(2,u(LIST_ERR_FN,%q1,secure(%0)))][switch(%q2,,,%rUnknown addresses: %q2)]) &DO_LIST_TAGS #11=$+list tags: @pemit %#=[setq(0,get(%#/MBOX))][setq(1,lattr(%q0/TAG_*))][switch(%q0:%q1,:*,You have no mail tags.,*:,You have no mail tags.,Mail tags: [iter(sort(%q1),lcstr(rest(##,_)))])] &DO_EDIT #11=$+edit *=*/*: @pemit %#=switch([setq(0,get(%#/MBOX))][u(SEND_STATUS_FN,%#)]:[member(text subject to cc bcc,lcstr(%0))],IN_PROG:0,v(NO_PART_ERR),IN_PROG:*,[set(%q0,MSG_%0:[switch(%0,text,edit(get(%q0/MSG_TEXT),%1,%2),subject,edit(get(%q0/MSG_SUBJECT),secure(%1),secure(%2)),map(RAW2LIST_FN,u(EDIT_TO_FN,%#,get(%q0/MSG_%0),%1,%2)))])][u(PROOF_FN,%#)],v(NOT_IN_PROG_ERR)) &DO_MAIL_STATUS_REPORT #11=$+mail status report: @switch hasflag(%#,wizard)=0, {@pemit %#=Permission denied.}, {@pemit %#=[setq(0,lcon(v(STORAGE_OBJ)))][setq(1,words(%q0))][u(MS_REPORT_HDR)][map(MS_REPORT_FN,extract(%q0,1,40))]; @dolist switch(lt(%q1,41),1,,rest(lnum(add(div(%q1,40),1))))={@pemit %#=after(map(MS_REPORT_FN,extract(%q0,add(mul(##,40),1),40)),%r)}} &DO_DASH #11=$-*: @pemit %#=[setq(0,get(%#/MBOX))][setq(9,switch([u(SEND_STATUS_FN,%#)]:[strmatch(%0,-)],*:1,-,IN_PROG:0,MSG_TEXT,!))][null(set(%q0,%q9:[switch(lattr(%q0/MSG_TEXT),,%0,[get(%q0/MSG_TEXT)][u(SEP_FN,get(%#/MAIL_CONFIG_OPTIONS))]%0)]))][switch(%q9:[gte(strlen(get(%q0/MSG_TEXT)),3500)]:[v(DASH_MSG)],-:*:*,,!:*:*,v(NOT_IN_PROG_ERR),*:1:*,v(LENGTH_MSG),*:0:?*,v(DASH_MSG))] &DO_LIST_GA #11=$+list global aliases: @pemit %#=[setq(0,lattr(v(DATA_OBJ)/ALIAS_*))][switch(%q0,,There are no global mail aliases defined.,Global mail aliases: [lcstr(sort(iter(%q0,rest(##,_))))])] &DO_CLEAR #11=$+clear: @fo %#=+delete &DO_RETRACT #11=$+retract letter *: @pemit %#=switch([setq(0,get(%#/MBOX))][setq(1,u(SENT_LIST_FN,%q0))][setq(2,extract(%q1,%0,1))]%q0:%q1:%q2:[u(OK_RETRACT_FN,%q0,%q2)],:*:*:*,You have sent no mail.,*::*:*,No letters available for review.,*:*::*,No such letter available for review.,*:*:*:0,That letter cannot be retracted now.,*:*:*:1,Letter retracted.[null(iter(get(%q0/P-%q2),[set(##,RECV_LIST:[remove(get(##/RECV_LIST),%q0-%q2)])][set(##,NEW_LIST:[remove(get(##/NEW_LIST),%q0-%q2)])][set(##,DEL_LIST:[remove(get(##/DEL_LIST),%q0-%q2)])][set(##,MARK_LIST:[remove(get(##/MARK_LIST),%q0-%q2)])]))][wipe(%q0/?-%q2)]) &DO_MAILSTATUS #11=$+mailstatus *: @pemit %#=Mail status:[map(MAIL_STATUS_FN,%0)] &DO_NOTE #11=$+note *: @pemit %#=switchall([setq(0,get(%#/MBOX))][u(QSEND_STATUS_FN,%#)],IN_PROG,v(IN_PROG_ERR),OVER_QUOTA,v(OVER_QUOTA_ERR),NEED_BOX~SEND,u(CREATE_MBOX_FN,%#,0),*~SEND,[setq(0,get(%#/MBOX))][setq(1,add(u(LAST_SENT_FN,%q0),1))][set(%q0,P-%q1:%q0)][set(%q0,R-%q1:%#!!!1)][set(%q0,S-%q1:[secs()]![switch(%0,*=*,trim(first(%0,=)),Personal Note)])][set(%q0,M-%q1:[trim(switch(%0,*=*,rest(%0,=),%0))])][set(%q0,RECV_LIST:[get(%q0/RECV_LIST)] %q0-%q1)][set(%q0,NEW_LIST:[get(%q0/NEW_LIST)] %q0-%q1)][u(u(NFY_MAIL_FN,%#,%l,NOTE),%#)]) &DO_UNTAG #11=$+untag *: @switch/first [setq(0,get(%#/MBOX))][setq(1,get(%q0/RECV_LIST))][setq(2,get(%q0/CURR_NUM))][setq(3,extract(%q1,%q2,1))][pos(=,%0)]:[or(strmatch(%q0,),strmatch(%q1,))]:[member(get(%q0/TAG_%0),%q3)]=#-1:1:*, {@pemit %#=You have no mail.},#-1:0:0, {@pemit %#=Message %q2 (current) is not tagged with '[lcstr(%0)]'.},#-1:0:*, {&TAG_%0 %q0=setinter(remove(get(%q0/TAG_%0),%q3),%q1); @pemit %#=Message %q2 (current) removed from tag list '[lcstr(%0)]'.} &DO_QMAIL #11=$+qmail */*=*/*: @pemit %#=switch([setr(8,num(*%0))]:[controls(%#,%q8)],#-1:*,No such player.,*:0,Permission denied.,switchall([setq(0,get(%q8/MBOX))][u(QSEND_STATUS_FN,%q8)],IN_PROG,v(IN_PROG_ERR),OVER_QUOTA,v(OVER_QUOTA_ERR),NEED_BOX~SEND,u(CREATE_MBOX_FN,%q8,0),*~SEND,[setq(0,get(%q8/MBOX))][setq(1,map(RAW2LIST_FN,secure(%1)))][ifelse(words(%q1),Message sent on behalf of [name(%q8)].[set(%q0,MSG_TO:[setq(9,edit(%q1,#-1,))][setr(5,switch(%q9,,%q8,%q9))])][set(%q0,MSG_SUBJECT:[trim(%2)])][set(%q0,MSG_TEXT:%3)][null(iter([setq(6,u(LIST2DEST_FN,%q5))][filter(NOBOX_FILT_FN,%q6)],u(CREATE_MBOX_FN,##,7)))][setq(2,u(LIST_ERR_FN,%q1,secure(%1)))][switch(%q2,,,%rUnknown addresses: %q2)][u(SEND_MSG_FN,%q8,%q0,add(u(LAST_SENT_FN,%q0),1),%q6,iter(%q6,get(##/MBOX)),loc(%q8))],No valid recipients.)])) &RAW2LIST_FN #12=[switch([isdbref(num(*%0))]:[lattr(%q0/ALIAS_%0)]:[lattr(v(DATA_OBJ)/ALIAS_%0)],1:*:*,num(*%0),0::,#-1,0:?*:*,~PA-%0,0:*:?*,~GA-%0,#-1)] &NO_MSGS_ERR #12=No messages match that criterion[u(CRITERION_FN,%0)]. &REVIEW_FN #12=[repeat(-,78)]%r[ljust(Letter [member(%1,%0)],41)] Date Sent: [convsecs(first(get(%q0/S-%0),!))]%r[setq(8,get(%q0/R-%0))][ljust(To:,10)] [u(LIST_PRINT_FN,first(%q8,!))][u(EXIST_PRINT_FN,Cc:,extract(%q8,2,1,!))][u(EXIST_PRINT_FN,Bcc:,extract(%q8,3,1,!))]%r[ljust(Held:,10)] [u(COMMA_LIST_FN,iter(get(%q0/P-%0),name(get(##/PLAYER))))]%r[ljust(Subject:,10)] [rest(get(%q0/S-%0),!)]%r[repeat(=,78)]%r[get(%q0/M-%0)]%r[repeat(-,78)] &SPLICE_LISTS_FN #12=[elements(%1,sort(iter(%0,member(%1,##))))] &LENGTH_MSG #12=Warning: You are close to exceeding the maximum message length. &REVIEW_TO_FN #12=[neq(match(iter(edit(extract(get(%q0/R-%0),1,3,!),!,%b),switch(##,#*,name(##),~GA-*,rest(##,-),~PA-*,rest(##,-),##)),%q9),0)] &EDIT_TO_FN #12=[iter(%1,switch(##,#*,edit(name(##),%2,%3),~PA-*,edit(rest(##,-),%2,%3),~GA-*,edit(rest(##,-),%2,%3),edit(##,%2,%3)))] &TIMEZONE #12=-0500 (EST) &DFL_MAIL_SEND #12=You send off your +mail message. &NOT_IN_PROG_ERR #12=You are not currently writing a mail message. &IN_PROG_ERR #12=You are already writing a mail message. &REVIEW_SUBJ_FN #12=[strmatch(rest(get(%q0/S-%0),!),*%q9*)] &DFL_MAIL_TOSS #12=You discard your +mail message. &READ_COMPACT_FN #12=[setq(2,first(%0,-))][setq(3,rest(%0,-))][setq(4,get(%q2/S-%q3))][setq(5,get(%q2/R-%q3))][repeat(-,78)]%r[ljust(Message [member(%q1,%0)],37)] Date Received: [convsecs(first(%q4,!))]%r[ljust(From:,10)] [name(get(%q2/PLAYER))]%r[ljust(To:,10)] [u(LIST_PRINT_FN,first(%q5,!))][u(EXIST_PRINT_FN,Cc:,extract(%q5,2,1,!))][u(TAG_PRINT_FN,filter(TAG_FILT_FN,lattr(%q0/TAG_*)))]%r[ljust(Subject:,10)] [rest(%q4,!)]%r[repeat(=,78)]%r[get(%q2/M-%q3)]%r[repeat(-,78)] &MS_REPORT_HDR #12=Mbox # %b Player %b Player Name [space(7)] Sent %b Recv %b New %b Fwd %b Als %b Tag%r------ %b ------ %b ----------- [space(7)] ---- %b ---- %b --- %b --- %b --- %b --- &SEND_STATUS_FN #12=[switch(%q0:[lattr(%q0/MSG_TO)],:*,NEED_BOX~SEND,*:,OKAY~SEND,IN_PROG)] &OK_SPACE_OPT_FN #12=[neq(member(space return,lcstr(%0)),0)] &LIST_PRINT_FN #12=[setq(9,words(%0))][switch(%q9,1,u(LIST_RSLV_FN,%0),2,{[u(LIST_RSLV_FN,first(%0))], [u(LIST_RSLV_FN,rest(%0))]},[iter(extract(%0,1,sub(%q9,1)),{[u(LIST_RSLV_FN,##)],})] [u(LIST_RSLV_FN,extract(%0,%q9,1))])] &READ_STANDARD_FN #12=[setq(2,first(%0,-))][setq(3,rest(%0,-))][setq(4,get(%q2/S-%q3))][setq(5,get(%q2/R-%q3))][repeat(=,78)]%r[ljust(Message [member(%q1,%0)],37)] Date Received: [convsecs(first(%q4,!))]%r[ljust(From:,10)] [name(get(%q2/PLAYER))]%r[ljust(To:,10)] [u(LIST_PRINT_FN,first(%q5,!))][u(EXIST_PRINT_FN,Cc:,extract(%q5,2,1,!))][u(TAG_PRINT_FN,filter(TAG_FILT_FN,lattr(%q0/TAG_*)))]%r[ljust(Subject:,10)] [rest(%q4,!)]%r[repeat(-,78)]%r%r[get(%q2/M-%q3)]%r%r[repeat(=,78)]%rOptions: +delete, +bounce, +forward, +reply, +replyall, +mark, +tag &LIST2DBREF_FN #12=[switch(%0,#-1,,#*,%0,~PA-*,map(LIST2DBREF_FN,get(%q0/ALIAS_[rest(%0,-)])),~GA-*,map(LIST2DBREF_FN,get(v(DATA_OBJ)/ALIAS_[rest(%0,-)])),)] &EXP_PA_FN #12=[switch(%0,~PA-*,get(%q0/ALIAS_[rest(%0,-)]),%0)] &DEST_MBOX_TRIG2 #12=@wait 2={@dest %2; &MBOX %1; @pemit %0=Mailbox for [name(%1)] (%1) destroyed.} &DEST_MBOX_TRIG1 #12=@dolist get(%0/P-%1)={&RECV_LIST ##=remove(get(##/RECV_LIST),%0-%1); &NEW_LIST ##=remove(get(##/NEW_LIST),%0-%1); &DEL_LIST ##=remove(get(##/DEL_LIST),%0-%1); &MARK_LIST ##=remove(get(##/MARK_LIST),%0-%1)} &SEND_TRIG #12=&P-%2 %1=%4; &R-%2 %1=[map(EXP_PA_FN,get(%1/MSG_TO))]![map(EXP_PA_FN,get(%1/MSG_CC))]![map(EXP_PA_FN,get(%1/MSG_BCC))]![words(%4)]; &S-%2 %1=[secs()]![get(%1/MSG_SUBJECT)]; &M-%2 %1=[get(%1/MSG_TEXT)][switch(get(%0/MAIL_SIG),,,%r[u(%0/MAIL_SIG)])]; @dolist %4={&RECV_LIST ##=[get(##/RECV_LIST)] %1-%2; &NEW_LIST ##=[get(##/NEW_LIST)] %1-%2}; @wipe %1/MSG_*; @switch/first match([v(HAVEN_MAIL)] [get(%5/MAIL-HAVEN)],yes)=0, {@pemit/contents %5=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}, {@pemit %0=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}; @dolist %3={@switch/first [match([v(HAVEN_MAIL)] [get(loc(##)/MAIL-HAVEN)],yes)]:[hasflag(##,Connect)]=0:1, {@pemit/contents loc(##)=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)},*:1, {@pemit ##=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)}} &OK_FORMAT_OPT_FN #12=[neq(member(compact standard,lcstr(%0)),0)] &REVIEW_RANGE_FN #12=[iter(secure(%0),switch(1,strmatch(all,##*),%2,strmatch(last,##*),last(%2),strmatch(##,to:*),filter(REVIEW_TO_FN[setq(9,rest(##,:))],%2),strmatch(##,last:*),extract(%2,max(1,sub(words(%2),sub(rest(##,:),1))),rest(##,:)),strmatch(##,subject:*),filter(REVIEW_SUBJ_FN[setq(9,rest(##,:))],%2),strmatch(##,text:*),filter(REVIEW_TEXT_FN[setq(9,rest(##,:))],%2),strmatch(##,*-*),extract(%2,first(##,-),add(sub(rest(##,-),first(##,-)),1)),extract(%2,##,1)))] &AUTHOR_FN #12=[istrue(%2,strmatch(##,%0-*))] &SEP_FN #12=[switch([match(%0,space)]:[match(%0,return)],0:0,s(%vs),0:*,%r,%b)] &RETRACT_TIME #12=2592000 &MAX_MAILTO #12=100 "A_MAIL #12=yes &REVIEW_TEXT_FN #12=[strmatch(get(%q0/M-%0),*%q9*)] &DFL_MAIL_ENTER #12=You begin writing a +mail message. &DUMP_PRINT_FN #12=[switch(%1,,,{%r%0 [setq(9,words(%1))][switch(%q9,1,u(DUMP_RSLV_FN,%1,%2),2,{[u(DUMP_RSLV_FN,first(%1),%2)], [u(DUMP_RSLV_FN,rest(%1),%2)]},[iter(extract(%1,1,sub(%q9,1)),{[u(DUMP_RSLV_FN,##,%2)],})] [u(DUMP_RSLV_FN,extract(%1,%q9,1),%2)])]})] &DUMPMAIL_FMT_FN #12=[setq(2,first(%0,-))][setq(3,rest(%0,-))][setq(4,get(%q2/S-%q3))][setq(5,get(%q2/R-%q3))][setq(6,edit(mudname(),%b,))][setq(7,get(%q2/PLAYER))]From [name(%q7)]@%q6 [setq(8,convsecs(first(%q4,!)))]%q8%rDate: [u(DUMP_DATE_FN,%q8)]%rFrom: [name(%q7)]@%q6 \\(%q7@%q6\\)[u(DUMP_PRINT_FN,To:,first(%q5,!),%q6)][u(DUMP_PRINT_FN,Cc:,extract(%q5,2,1,!),%q6)]%rSubject: [rest(%q4,!)]%rEOH%r%r[edit(edit(get(%q2/M-%q3),%r%r,%r %r),%rFrom,%r>From)]%rEOM%r &OVER_QUOTA_MSG #12=[repeat(*,78)]%r[repeat(*[space(76)]*%r,2)]* [center(YOU HAVE TOO MUCH +MAIL.,74)] *%r[repeat(*[space(76)]*%r,2)]* [center(Your mail quota is %1 / %2 un/read messages.,74)] *%r* [center(You have %4 messages \\(%3 unread\\).,74)] *%r*[space(76)]*%r* [center(You will not be able to send +mail until you clear some of your messages.,74)] *%r* [center(Also\\, each time you connect\\, you will receive this annoying message.,74)] *%r[repeat(*[space(76)]*%r,2)]* [center(PLEASE CLEAN UP YOUR +MAIL. THANK YOU.,74)] *%r[repeat(*[space(76)]*%r,2)]%r[repeat(*,78)] &OVER_QUOTA_ERR #12=You have exceeded your saved +mail quota. You cannot send messages until you are below that quota. &QSEND_STATUS_FN #12=[switch(%q0:[lattr(%q0/MSG_TO)]:[v(QUOTA_MAIL)],:*:*,NEED_BOX~SEND,*::no,OKAY~SEND,*::yes,switch(ulocal(QUOTA_STATUS_FN,%q0),1,OVER_QUOTA,OKAY~SEND),IN_PROG)] &SKIM_STANDARD_HDR #12=[repeat(=,78)]%r%r[space(28)]List of Mail Messages%r%r[u(SKIM_COMPACT_HDR)] &LIST_ERR_FN #12=[filter(LIST_FILT_FN,splice(%0,%1,#-1))] &MAIL_STATUS_FN #12=%r %b[switch(num(*%0),#-1,[capstr(lcstr(%0))]: No such player.,[name(*%0)]: [u(MAIL_CHECK_FN,get(*%0/MBOX))])] &TIME_FMT_FN #12=[switch(gte(%0,86400),0,,1,[div(%0,86400)]d%b)][switch(gte(%0,3600),0,,1,sub(div(%0,3600),mul(div(%0,86400),24))h%b)][switch(gte(%0,60),0,,1,div(mod(%0,3600),60)m%b)][mod(%0,60)]s &COMMA_LIST_FN #12=[setq(8,words(%0))][switch(%q8,0,,1,%0,2,{[first(%0)], [rest(%0)]},[iter(extract(%0,1,sub(%q8,1)),{##,})] [extract(%0,%q8,1)])] &DUMP_DATE_FN #12=[first(%0)], [extract(%0,3,1)] [extract(%0,2,1)] [last(%0)] [extract(%0,4,1)] [v(TIMEZONE)] &MAILOPT_FN #12=[switch([match(%0,%1)]:[match(%0,%2)],0:0,get(v(DATA_OBJ)/OPTION_%3),0:*,%2,%1)] &MBOX_STATUS_FN #12=[setq(1,get(%0/FORWARD_TO))][switch(%q1,,,{Mail autoforwarded to: [u(COMMA_LIST_FN,iter(%q1,name(##)))]%r})][words(get(%0/RECV_LIST))] messages received, [words(get(%0/NEW_LIST))] unread, [words(get(%0/DEL_LIST))] marked for deletion.%r[words(lattr(%0/P-*))] sent. [words(lattr(%0/ALIAS_*))] personal aliases. [words(lattr(%0/TAG_*))] tags.%rQuotas: [get(%0/MAX_READ)] total. [get(%0/MAX_UNREAD)] unread.%rDelete option: [switch([match(%1,soft)]:[match(%1,hard)],0:0,default,0:*,hard,soft)]. Space option: [switch([match(%1,space)]:[match(%1,return)],0:0,default,0:*,return,space)]. &PROOF_FN #12=[repeat(-,78)]%r[ljust(To:,10)] [u(LIST_PRINT_FN,get(%q0/MSG_TO))][u(EXIST_PRINT_FN,Cc:,get(%q0/MSG_CC))][u(EXIST_PRINT_FN,Bcc:,get(%q0/MSG_BCC))]%r[ljust(Subject:,10)] [get(%q0/MSG_SUBJECT)]%r[repeat(=,78)]%r[get(%q0/MSG_TEXT)][switch(get(%0/MAIL_SIG),,,%r[u(%#/MAIL_SIG)])]%r[repeat(-,78)] &DUMP_RSLV_FN #12=[switch(%0,,,#-1,Error@%1,#*,[name(%0)]@%1 \\(%0@%1\\),~PA-*,[lcstr(rest(%0,-))]@%1 \\(personal alias@%1\\),~GA-*,[lcstr(rest(%0,-))]@%1 \\(global alias@%1\\),Error@%1)] &TEXT_SEARCH_FN #12=[istrue(%2,strmatch(get([first(##,-)]/M-[rest(##,-)]),*%0*))] &LIST2DEST_FN #12=[setdiff(iter(map(LIST2DBREF_FN,%0),switch(get([get(##/MBOX)]/FORWARD_TO),,##,#-1 NO MATCH,##,get([get(##/MBOX)]/FORWARD_TO))),#-1)] &SKIM_FN #12=%r[setq(2,first(%0,-))][setq(3,rest(%0,-))][setq(4,member(%q1,%0))][switch(%q4,get(%q0/CURR_NUM),+,%b)][switch(member(get(%q0/NEW_LIST),%0),0,%b,U)][switch(member(get(%q0/MARK_LIST),%0),0,%b,M)][switch(member(get(%q0/DEL_LIST),%0),0,%b,D)][rjust(%q4\\),4)] %b[ljust(name(get(%q2/PLAYER)),17)] [ljust(mid(rest(get(%q2/S-%q3),!),0,27),27)] [rjust(strlen(get(%q2/M-%q3)),4)] %b[extract(convsecs(first(get(%q2/S-%q3),!)),1,2,:)] &TAG_FILT_FN #12=[neq(member(get(%q0/%0),%q2-%q3),0)] &REVIEW_LIST_FN #12=%r[rjust([member(%q1,%0)]\\),4)] %b[ljust(mid(rest(get(%q0/S-%0),!),0,24),26)] \\[[rjust(words(get(%q0/P-%0)),2)]\\] [setq(9,first(first(get(%q0/R-%0),!)))][ljust(switch(%q9,#*,name(%q9),~GA-*,rest(%q9,-),~PA-*,rest(%q9,-),%q9),17)] [rjust(strlen(get(%q0/M-%0)),4)] %b[extract(convsecs(first(get(%q0/S-%0),!)),1,2,:)] &LIST_FILT_FN #12=[not(or(isdbref(%0),strmatch(%0,~PA-*),strmatch(%0,~GA-*)))] &REVIEW_HDR #12=[space(6)]Subject[space(20)]Held Recipient[space(9)]Size %bSent%r[space(6)]-------[space(20)]---- ---------[space(9)]---- %b---- &NFY_MAIL_FN #12=[switch([strmatch(get(%1/MAIL-%2),?*)]:[strmatch(get(%0/MAIL-%2),?*)],0:0,DFL_MAIL_%2,1:*,%1/MAIL-%2,%0/MAIL-%2)] &NOBOX_FILT_FN #12=[not(hasattr(%0,MBOX))] &DFL_MAIL_DELIVER #12=You have new +mail from [name(%1)]. &GET_RANGE_FN #12=[iter(secure(%0),switch(1,strmatch(%1,),,strmatch(%2,),,strmatch(all,##*),%2,strmatch(current,##*),extract(%2,get(%1/CURR_NUM),1),strmatch(deleted,##*),u(SPLICE_LISTS_FN,get(%1/DEL_LIST),%2),strmatch(last,##*),last(%2),strmatch(marked,##*),u(SPLICE_LISTS_FN,get(%1/MARK_LIST),%2),strmatch(next,##*),extract(%2,add(get(%1/CURR_NUM),1),1),strmatch(previous,##*),extract(%2,sub(get(%1/CURR_NUM),1),1),strmatch(unread,##*),u(SPLICE_LISTS_FN,get(%1/NEW_LIST),%2),switch(1,strmatch(##,author:*),u(SPLICE_LISTS_FN,u(AUTHOR_FN,get(*[rest(##,:)]/MBOX),%1,%2),%2),strmatch(##,last:*),extract(%2,max(1,sub(words(%2),sub(rest(##,:),1))),rest(##,:)),strmatch(##,subject:*),u(SPLICE_LISTS_FN,u(SUBJECT_FN,rest(##,:),%1,%2),%2),strmatch(##,tag:*),u(SPLICE_LISTS_FN,get(%1/TAG_[rest(##,:)]),%2),strmatch(##,text:*),u(SPLICE_LISTS_FN,u(TEXT_SEARCH_FN,rest(##,:),%1,%2),%2),strmatch(##,*-*),extract(%2,first(##,-),add(sub(rest(##,-),first(##,-)),1)),extract(%2,##,1))))] &LIST_RSLV_FN #12=[switch(%0,,,#-1,Error,#*,name(%0),~PA-*,[lcstr(rest(%0,-))] ,~GA-*,[lcstr(rest(%0,-))] ,Error)] &MS_REPORT_FN #12=%r[rjust(%0,6)] %b [setq(2,get(%0/PLAYER))][rjust(%q2,6)] %b [ljust(switch([type(%q2)]:[after(name(%0),Mail Data for%b)],PLAYER:%q2,name(%q2),#-1*:%q2,* BAD MAILBOX *,*:%q2,** BAD PLAYER **,* BAD POINTER *),19)] [rjust(words(lattr(%0/S-*)),4)] %b [rjust(words(get(%0/RECV_LIST)),4)] %b [rjust(words(get(%0/NEW_LIST)),3)] %b [rjust(words(get(%0/FORWARD_TO)),3)] %b [rjust(words(lattr(%0/ALIAS_*)),3)] %b [rjust(words(lattr(%0/TAG_*)),3)] &MAIL_CHECK_FN #12=[switch(get(%0/NEW_LIST),,No unread mail.,#-1 NO MATCH,No unread mail.,New mail since [setq(9,first(get(%0/NEW_LIST)))][convsecs(first(get([first(%q9,-)]/S-[rest(%q9,-)])))].)] &OK_AUTOFORWARD_OPT_FN #12=[not(member(iter(%0,strmatch(##,name(*##))),0))] &GET_MBOX_FN #12=[get(%0/MBOX)] &OK_DELETE_OPT_FN #12=[neq(member(soft hard,lcstr(%0)),0)] &OK_RETRACT_FN #12=[switch(lt(add(first(get(%0/S-%1),!),v(RETRACT_TIME)),secs()),1,1,switch(eq(words(get(%0/P-%1)),extract(get(%0/R-%1),4,1,!)),0,0,1,not(member(iter(get(%0/P-%1),neq(member(get(##/NEW_LIST),%0-%1),0)),0))))] "A_STATUS_FN #12=[setq(1,get(%0/MAX_UNREAD))][setq(2,get(%0/MAX_READ))][setq(3,words(get(%0/NEW_LIST)))][setq(4,words(get(%0/RECV_LIST)))][or(gt(%q3,%q1),gt(%q4,%q2))] &EXIST_PRINT_FN #12=[switch(%1,,,%r[ljust(%0,10)] [u(LIST_PRINT_FN,%1)])] &CRITERION_FN #12=[switch(1,strmatch(%0,author:*),%b\\(author search\\),strmatch(%0,last:*),%b\\(last search\\),strmatch(%0,subject:*),%b\\(subject search\\),strmatch(%0,tag:*),%b\\(tag search\\),strmatch(%0,text:*),%b\\(text search\\),strmatch(all,%0*),%b\\(all\\),strmatch(current,%0*),%b\\(current\\),strmatch(deleted,%0*),%b\\(deleted\\),strmatch(last,%0*),%b\\(last\\),strmatch(marked,%0*),%b\\(marked\\),strmatch(next,%0*),%b\\(next\\),strmatch(previous,%0*),%b\\(previous\\),strmatch(unread,%0*),%b\\(unread\\),)] &SKIM_COMPACT_HDR #12=[space(10)]Sender[space(12)]Subject[space(21)]Size %bReceived%r[space(10)]------[space(12)]-------[space(21)]---- %b-------- &BOUNCE_TRIG #12=&P-%2 %1=trim([get(%1/P-%2)] %4); &R-%2 %1=[setq(5,get(%1/R-%2))][extract(%q5,1,2,!)]![trim([extract(%q5,3,1,!)] [map(EXP_PA_FN,%6)])]![add(extract(%q5,4,1,!),words(%4))]; @dolist %4={&RECV_LIST ##=[get(##/RECV_LIST)] %1-%2; &NEW_LIST ##=[get(##/NEW_LIST)] %1-%2}; @switch/first match([v(HAVEN_MAIL)] [get(%5/MAIL-HAVEN)],yes)=0, {@pemit/contents %5=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}, {@pemit %0=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}; @dolist %3={@switch/first [match([v(HAVEN_MAIL)] [get(loc(##)/MAIL-HAVEN)],yes)]:[hasflag(##,Connect)]=0:1, {@pemit/contents loc(##)=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)},*:1, {@pemit ##=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)}} &NOT_HAS_MSG_FN #12=[eq(member(get([get(%0/MBOX)]/RECV_LIST),%q2),0)] &RESEND_TRIG #12=&P-%2 %1=trim([get(%1/P-%2)] %4); &R-%2 %1=[setq(5,get(%1/R-%2))][first(%q5,!)]![trim([extract(%q5,2,1,!)] [map(EXP_PA_FN,%6)])]![extract(%q5,3,1,!)]![add(extract(%q5,4,1,!),words(%4))]; @dolist %4={&RECV_LIST ##=[get(##/RECV_LIST)] %1-%2; &NEW_LIST ##=[get(##/NEW_LIST)] %1-%2}; @switch/first match([v(HAVEN_MAIL)] [get(%5/MAIL-HAVEN)],yes)=0, {@pemit/contents %5=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}, {@pemit %0=u(u(NFY_MAIL_FN,%0,%5,SEND),%0)}; @dolist %3={@switch/first [match([v(HAVEN_MAIL)] [get(loc(##)/MAIL-HAVEN)],yes)]:[hasflag(##,Connect)]=0:1, {@pemit/contents loc(##)=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)},*:1, {@pemit ##=u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)}} &SENT_LIST_FN #12=[sort(iter(lattr(%0/P-*),rest(##,-)),n)] &SUBJECT_FN #12=[istrue(%2,strmatch(rest(get([first(##,-)]/S-[rest(##,-)]),!),*%0*))] &DFL_MAIL_NOTE #12=You write a note to yourself. &NO_PART_ERR #12=You can only edit \"text\", \"subject\", \"to\", \"cc\", and \"bcc\". &TAG_PRINT_FN #12=[switch(%0,,,%r[ljust(Tags:,10)] [iter(%0,lcstr(rest(##,_)))])] &LAST_SENT_FN #12=[last(u(SENT_LIST_FN,%0))] &BOUNCE_MSG_FN #12=[set(%1,P-%2:[trim([get(%1/P-%2)] %4)])][set(%1,R-%2:[setq(5,get(%1/R-%2))][extract(%q5,1,2,!)]![trim([extract(%q5,3,1,!)] [map(EXP_PA_FN,%6)])]![add(extract(%q5,4,1,!),words(%4))])][u(DELIVER_FN,%0,%1,%2,%3,%4,%5)] &RESEND_MSG_FN #12=[set(%1,P-%2:[trim([get(%1/P-%2)] %4)])][set(%1,R-%2:[setq(5,get(%1/R-%2))][first(%q5,!)]![trim([extract(%q5,2,1,!)] [map(EXP_PA_FN,%6)])]![extract(%q5,3,1,!)]![add(extract(%q5,4,1,!),words(%4))])][u(DELIVER_FN,%0,%1,%2,%3,%4,%5)] &DELIVER_FN #12=[null(iter(%4,[set(##,RECV_LIST:[get(##/RECV_LIST)] %1-%2)][set(##,NEW_LIST:[get(##/NEW_LIST)] %1-%2)]))][switch(match([v(HAVEN_MAIL)] [get(%5/MAIL-HAVEN)],yes),0,remit(%5,u(u(NFY_MAIL_FN,%0,%5,SEND),%0)),pemit(%0,u(u(NFY_MAIL_FN,%0,%5,SEND),%0)))][null(iter(%3,switch([match([v(HAVEN_MAIL)] [get(loc(##)/MAIL-HAVEN)],yes)]:[hasflag(##,Connect)],0:1,remit(loc(##),u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)),*:1,pemit(##,u(u(NFY_MAIL_FN,%0,loc(##),DELIVER),##,%0)))))] &DEL_MSGS_FN #12=[null(iter(%1,[set(%0,RECV_LIST:[remove(get(%0/RECV_LIST),##)])][wipe([setq(3,first(##,-))][setq(4,rest(##,-))][switch(strmatch(get(%q3/P-%q4),%q0),0,#-1,%q3)]/?-%q4)][set(%q3,P-%q4:[remove(get(%q3/P-%q4),%q0)])]))][set(%q0,NEW_LIST:[setq(5,get(%q0/RECV_LIST))][setinter(get(%q0/NEW_LIST),%q5)])][set(%q0,DEL_LIST:[setinter(get(%q0/DEL_LIST),%q5)])][set(%q0,MARK_LIST:[setinter(get(%q0/MARK_LIST),%q5)])] &CREATE_MBOX_FN #12=[setq(%1,create(Mail Data for %0,10,t))][command(@parent,r(%1),v(MBOX_OBJ))][set(%0,MBOX:[r(%1)])][set(r(%1),PLAYER:%0)][set(r(%1),Dark)][tel(r(%1),v(STORAGE_OBJ))] &SEND_MSG_FN #12=[set(%1,P-%2:%4)][set(%1,R-%2:[map(EXP_PA_FN,get(%1/MSG_TO))]![map(EXP_PA_FN,get(%1/MSG_CC))]![map(EXP_PA_FN,get(%1/MSG_BCC))]![words(%4)])][set(%1,S-%2:[secs()]![get(%1/MSG_SUBJECT)])][set(%1,M-%2:[get(%1/MSG_TEXT)][switch(get(%0/MAIL_SIG),,,%r[u(%0/MAIL_SIG)])])][wipe(%1/MSG_*)][u(DELIVER_FN,%0,%1,%2,%3,%4,%5)] &FMT_3RWHO_FN #37=[ljust(name(%0),47)] [setq(2,sort(iter(setinter(orgwho(ulocal(DBREF2ORG_FN,%0)),%q0),name(##))))][ljust(mid(extract(%q2,1,1),0,9),9)] [ljust(mid(extract(%q2,2,1),0,9),9)] [ljust(mid(extract(%q2,3,1),0,9),9)][switch(gt(words(%q2),3),1,u(%vg/NAME_3COL_FN,extract(%q2,4,3999)))] &DBREF2KN_FN #37= &DBREF2ORG_FN #37=[setq(0,lattr(%vd/*_ORG))][setq(1,iter(%q0,get(%vd/##)))][elements(iter(%q0,first(##,_)),iter(%0,member(%q1,##)))] @name #53=Placeholder Object &WATCHED #53=- &ORGS #53=- &LASTLOGOUT #53=- &MBOX #53=- &FIRST_LOGIN #53=- &PROPLOC #53=- @desc #53=This object prevents privileged attributes from being cleaned from the database. @set #53=halt @set #53=safe @set #53=constant @tel #53=#50 @name #54=Registration Data @set #54=halt @set #54=safe @tel #54=#50 @attribute/access mbox=wizard @attribute/access proploc=wizard @attribute/access watched=wizard