def player_reset_mission(self, player):
     # get a number of missions for each thing
     player.mission = []
     player.scanned = []
     player.failed = False
     for i in xrange(cfg_rand_min_max(self.cfg, "DiscoveryQuest", "mission_num")):
         player.mission.append(random.choice(self._missions)) # TODO: validate that this player can still scan those types of objects
 def player_reset_mission(self, player):
     # get a number of missions for each thing
     player.mission = []
     player.scanned = []
     player.failed = False
     for i in xrange(cfg_rand_min_max(self.cfg, "DiscoveryQuest", "mission_num")):
         player.mission.append(random.choice(self._missions)) # TODO: validate that this player can still scan those types of objects
    def spawn(world, cfg, pos=None, setpoints=None, pname=None):
        if pos == None:
            pos = getPositionAwayFromOtherObjects(world, cfg.getint("Bubble", "buffer_object"), cfg.getint("Bubble", "buffer_edge"))

        points = cfg_rand_min_max(cfg, "Bubble", "points")
        if setpoints != None:
            points = setpoints

        b = Bubble(pos, float(cfg.getint("KingOfTheBubble", "bubble_radius_min")), points, cfg.getint("KingOfTheBubble", "bubble_points_drain_speed"), pname, world)
        world.append(b)
        return b
    def spawn(world, cfg, pos=None, setpoints=None, pname=None):
        if pos == None:
            pos = getPositionAwayFromOtherObjects(world, cfg.getint("Bubble", "buffer_object"), cfg.getint("Bubble", "buffer_edge"))

        points = cfg_rand_min_max(cfg, "Bubble", "points")
        if setpoints != None:
            points = setpoints

        b = Bubble(pos, float(cfg.getint("KingOfTheBubble", "bubble_radius_min")), points, cfg.getint("KingOfTheBubble", "bubble_points_drain_speed"), pname, world)
        world.append(b)
        return b
 def __start_bauble_timer(self):
     self.__bauble_spawner = CallbackTimer(cfg_rand_min_max(self.cfg, "TheHungerBaubles", "cornucopia_spawn_time"), self.__cornucopia_bauble_spawn)
     self.__bauble_spawner.start()