code: async def expand_now(self, building: UnitTypeId=None, max_distance: Union[int, float]=10, location: Optional[Point2]=None):
          
  
          if not building:
              # self.race is never Race.Random
              start_townhall_type = {Race.Protoss: UnitTypeId.NEXUS, Race.Terran: UnitTypeId.COMMANDCENTER, Race.Zerg: UnitTypeId.HATCHERY}
              building = start_townhall_type[self.race]
  
          assert isinstance(building, UnitTypeId)
  
          if not location:
              location = await self.get_next_expansion()
          
          if location:
              await self.build(building, near=location, max_distance=max_distance, random_alternative=False, placement_step=1)
docs: Takes new expansion.