View/Edit #1111:_enterfunc

Switch to edit mode.

Name(s): _enterfunc
1:  if (callers()[1][2] != "bf_move" || callers()[1][4] != #102)
2:    raise(E_PERM)
3:  endif
4:  {what, source} = args
5:  if (!(co = $list_utils:iassoc(what, this.coords, 1)))
6:    if (!(incom = $list_utils:iassoc(what, this.incoming, 1)))
7:      "We're not expecting you.  Get out."
8:      move(what, source)
9:      if (what.location == this)
10:       move(what, $junk_pile)
11:     endif
12:   else
13:     this.coords = {@this.coords, this.incoming[incom]}
14:     this.incoming = listdelete(this.incoming, incom)
15:   endif
16: else
17:   "Huh, you're already here.  Got new coords?"
18:   if (incom = $list_utils:iassoc(what, this.incoming, 1))
19:     "Yup."
20:     this.coords[co] = this.incoming[incom]
21:     this.incoming = listdelete(this.incoming, incom)
22:   else
23:     "Nope."
24:   endif
25: endif
26: "Last modified by whiz (#3135) on Tue Apr  1 23:24:42 2008 EDT."

Verb arguments: this none this
Verb perms: Readable eXecutable NOT-Debug
Verb owned by: Hacker (#60)

You are not logged in.

[home | help | who | search | setup | code]