MCPcopy Create free account
hub / github.com/JoshuaPostel/texaform / pick

Method pick

python/dog.py:56–65  ·  view source on GitHub ↗
(self, char: str, target: Optional[Point] = None)

Source from the content-addressed store, hash-verified

54 return resp
55
56 def pick(self, char: str, target: Optional[Point] = None):
57 self.send(f"PICK {char}")
58 if target is None:
59 target = self.location.forward(self.facing)
60# (pos, facing, _, _) = self.stat()
61# target = pos.forward(facing)
62 try:
63 self.char_locations[char].remove(target)
64 except KeyError:
65 print(f"{char} {target} was not in known locations")
66
67 def stat(self) -> Tuple[Point, str, int, str]:
68 reply = self.send("STAT")

Callers 2

pick_knownMethod · 0.95
clear_columnFunction · 0.45

Calls 2

sendMethod · 0.95
forwardMethod · 0.80

Tested by

no test coverage detected