public function distance_of($space) { list($x, $y) = $space->location(); return abs($this->x - $x) + abs($this->y - $y); }