a Finger command

Posted by MegaMoth on Sun 31 Mar 2002 11:59 PM — 2 posts, 15,228 views.

#0
ok, Im working on an RP based MUSH and I was wondering if anyone could tell me how to MUSH code a finger command, I am familiar with MUSH code, and have recently been looking extensively through various tutorials but can find nothing that will show me how to get the desired effect,I want playeds to set up attributes in CG(I know how to do that) and then I want them to be able to finger other players to see the attributes they set... I think you understand what I mean... well you should if your an experianced MUSHer and thanks Gammon for help with time
USA #1
&CMD_FINGER Global Commands=$finger *:think u(Fn_PMatch,Fn_Finger,%0)

&FN_FINGER Global Commands=pemit(%#,[ansi(hc,Finger information for)] [name(%0)][switch(get(%0/Alias),,,%b(#$))]:%r[u(label,Gender)] [switch(subj(%0),he,Male,she,Female,Unknown)]%r[switch(objeval(%#,conn(%0)),-1,[u(label,Last Login)] [get(%0/Last)],[u(label,On For)] [u(Fn_OnFor,conn(%0))]\, idle [u(Fn_Idle,idle(%0))])][if(or(haspower(%#,See_All),hasflag(%#,Wizard),hasflag(%#,Royalty)),%r[u(label,Last Site)] [get(%0/LastSite)] ([get(%0/LastIP)])%r[u(label,Reg. E-mail)] [get(%0/Registered_Email)])]%r[u(label,Location)] [switch(objeval(%#,loc(%0)),#-1,*Undisclosed*,[name(loc(%0))][if(u(Can_Flags,%#,loc(%0)),([loc(%0)][flags(loc(%0))]))])][if(setr(0,objeval(%0,u(%0/Note))),%r[u(label,Note)] %q0)])
@set Global Commands/FN_FINGER=no_command

&FN_PMATCH Global Commands=switch(setr(0,pmatch(%1)),#-1,pemit(%#,Invalid player name: %1),#-2,pemit(%#,Ambiguous player name: %1),ulocal(%0,%q0,%2,%3,%4,%5,%6,%7,%8,%9))
@set Global Commands/FN_PMATCH=no_command