Viewing paste scmmd
made on Fri, 17 Oct 2014 00:11:44 -0400
Sane-itized version, click to copy:
&search.cmd #3629=$search:@pemit %#={[setq(n,[u(char.name,%#)])][setq(i,[u(party.int)])][setq(w,[u(party.wis)])][setq(d,[u(party.dex)])][setq(a,[div(add(add(%qi,%qd),%qw),2)])][ifelse(and(lte(1,search.delay),and(or(u(road.here),u(town.here)),u(is,party.mode,travelling))),{[ifelse(u(road.here),{[oemit(%#,%qn searches the area for lost items...[u(sound.search.road)])]You search nearby the road for any lost items...[u(sound.search.road)]%r},{[oemit(%#,%qn searches about the town scavenging for useful items...[u(sound.search.road)])]You search about the town looking for items of interest...[u(sound.search.town)]%r})][ifelse(gte(%qa,rand(0,mul(%qa,3))),{[oemit(%#,You discover something![u(sound.discovery)])][u(spoils)][if(gte(%qd,rand(0,mul(%qd,2))),{[u(encounter.start)]})]},{You search in vain and find nothing.})]},{You search and search but find nothing.})]}

Enter a target attribute, object reference and the mushcode.


$search:@pemit %#={
 [setq(n,[u(char.name,%#)])]
 [setq(i,[u(party.int)])]
 [setq(w,[u(party.wis)])]
 [setq(d,[u(party.dex)])]
 [setq(a,[div(add(add(%qi,%qd),%qw),2)])]
 [ifelse(and(lte(1,search.delay),and(or(u(road.here),u(town.here)),u(is,party.mode,travelling))),
 {
  [ifelse(u(road.here),
   {[oemit(%#,%qn searches the area for lost items...[u(sound.search.road)])]
    You search nearby the road for any lost items...[u(sound.search.road)]%r},
   {[oemit(%#,%qn searches about the town scavenging for useful items...[u(sound.search.road)])]
    You search about the town looking for items of interest...[u(sound.search.town)]%r}
  )]
  [ifelse(gte(%qa,rand(0,mul(%qa,3))),
  {
   [oemit(%#,You discover something![u(sound.discovery)])]
   [u(spoils)]
   [if(gte(%qd,rand(0,mul(%qd,2))),{
     [u(encounter.start)]
    }
   )]
  },
  {You search in vain and find nothing.})]
 },{You search and search but find nothing.})]
}

save as: imprettify (attempt to format for readibility):
Found this useful? Try MUSHcode Repeater
written by orcs.biz