'Maneuver': maneuver_concentration, 'Save': save_concentration, 'Magic': magic_concentration, } result_consistency_by_unit[race.id][dice_template.id] = { 'Melee': melee_rate, 'Missile': missile_rate, 'Maneuver': maneuver_rate, 'Save': save_rate, 'Magic': magic_rate, } print 'Concentration report :' for race_id, race_value in result_concentration.items(): race = Race.get_by_id(race_id).name print 'Race '+race+':' for category, category_value in race_value.items(): string = ' Category '+category+': ' for icon, value in category_value.items(): string += icon+': '+str(round(value,2))+'; ' print string print 'Consistency report :' for race_id, race_value in result_consistency.items(): race = Race.get_by_id(race_id).name print 'Race '+race+':' for category, category_value in race_value.items(): string = ' Category '+category+': ' for icon, value in category_value.items(): string += str(icon)+': '+str(value)+'%; '
2: DiceType.get_by_id(2), 3: DiceType.get_by_id(3), 4: DiceType.get_by_id(4), } conversion_item_type = { 1: DiceType.get_by_id(5), 2: DiceType.get_by_id(6), 3: DiceType.get_by_id(7), 4: DiceType.get_by_id(8), } medallion_type = DiceType.get_by_id(9) from business.race import Race conversion_race = { 'CORALELF': Race.get_by_id(1), 'DWARF': Race.get_by_id(3), 'GOBLIN': Race.get_by_id(4), 'LAVAELF': Race.get_by_id(2), 'AMAZON': Race.get_by_id(5), 'FIREWALKER': Race.get_by_id(6), 'UNDEAD': Race.get_by_id(7), 'FERAL': Race.get_by_id(8), 'SWAMPSTALKER': Race.get_by_id(9), 'SCALDER': Race.get_by_id(11), 'FROSTWING': Race.get_by_id(10), 'TREEFOLK': Race.get_by_id(12), #All color of eldarim are eldarim 'ELDARIM_WATER': Race.get_by_id(13), 'ELDARIM_AIR': Race.get_by_id(13), 'ELDARIM_FIRE': Race.get_by_id(13),