Difference between revisions of "Zenith/code goodies"
imported>Zenith (Created page with " == Zenith's Code Repository == ===Custom emit command=== &cmd-emit me=$em ?*:@emit %r%t[switch(%0,",[if(strmatch(%1,*"*),"%1,%N says\\, "%1")],:,%N %1,;,%N%1,%0%1)] ''This c...") |
imported>Zenith |
||
Line 1: | Line 1: | ||
− | == Zenith's Code Repository == | + | == [[Zenith]]'s Code Repository == |
===Custom emit command=== | ===Custom emit command=== | ||
&cmd-emit me=$em ?*:@emit %r%t[switch(%0,",[if(strmatch(%1,*"*),"%1,%N says\\, "%1")],:,%N %1,;,%N%1,%0%1)] | &cmd-emit me=$em ?*:@emit %r%t[switch(%0,",[if(strmatch(%1,*"*),"%1,%N says\\, "%1")],:,%N %1,;,%N%1,%0%1)] |
Latest revision as of 18:27, 27 September 2012
Contents
Zenith's Code Repository
Custom emit command
&cmd-emit me=$em ?*:@emit %r%t[switch(%0,",[if(strmatch(%1,*"*),"%1,%N says\\, "%1")],:,%N %1,;,%N%1,%0%1)]
This command is used by typing em <stuff>. Regular MUSH stuff such as " ; : are treated as you'd expect.
Custom description format
@descformat me=--+===[ljust(< %xg[name(me)]%xn >,66,=)]===+--%r%r%0%r%r--+===[rjust(< %xg[v(data_formname)] Character%xn >,66,=)]===+--
A fancy format to show off with when people look at the char. Assumes you've set &data_formname me=<something> - my custom +shift commands switch this up depending on the form I'm in.
Custom shift commands
&cmd-homid me=$homid:+shift shifter-homid;&data_formname me=Human;@sex me=Male;@name me=v(name-homid)
&cmd-archid me=$archid:+shift mokole-archid;&data_formname me=Eotyrannus;@sex me=Unknown;@name me=v(name-archid)
&cmd-suchid me=$suchid:+shift halpatee-suchid;&data_formname me=American Alligator;@sex me=Just Try It;@name me=v(name-suchid)
These replace typing the rather overlong form names used here. It also changes the sex to indeterminate for the reptile forms and updates the name to be form-specific, a feature I like so that I know what body I parked my char in.