def current_dungeons(bonuses, dungeons): """Parse out the current dungeons. """ if isinstance(bonuses, str): bonuses = ojson_loads(bonuses)['bonuses'] bdungs = [dungeons[b['d']] for b in bonuses if b['b'] == 6] return bdungs
def parse_skillup_dungeons(bonuses, dungeons): """Parse out the current skillup dungeons. """ if isinstance(bonuses, str): bonuses = ojson_loads(bonuses)['bonuses'] bdungs = [ dungeons[b.d] for b in bonuses if b.b == 25 and b.get('a', 0) == 0 ] return bdungs
def current_skillup_dungeons(bonuses, dungeons): """Parse out the current skillup dungeons. """ if isinstance(bonuses, str): bonuses = ojson_loads(bonuses)['bonuses'] bdungs = [ dungeons.get(b['d'], b['d']) for b in bonuses if b['b'] == 25 and b.get('a', 0) == 0 ] return bdungs
def loads(s, limit=INSANE_CARD_LIMIT): j = ojson_loads(s) return loadjson(j, limit=limit)
def loads(s): j = ojson_loads(s) return loadjson(j)