print("morphy: " + text[:10])
есть вывод, но как-то медленно все . . . . . . .
это не разделитель, это часть строки."Люстра KOLARZ Scala 0015.85.7 . . . . . . . Подвесные люстры_208"
"Светильник потолочный EGLO Medici 85446 . . . . . . . Подвесные люстры_208"
"Светильник потолочный EGLO Размер: 110х75 см . . . . . . . Подвесные люстры_208"
radiant_barracks_kills = 0
dire_barracks_kills = 0
for objective in match['objectives']:
for i,e in enumerate(objective):
if e['type'] == 'CHAT_MESSAGE_BARRACKS_KILL':
if objective[i-1]['slot'] < 5:
radiant_barracks_kills += 1
if objective[i-1]['slot'] >= 5:
dire_barracks_kills += 1
string indices must be integers
[{'slot': -1, 'team': 2, 'time': 576.41, 'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'slot': -1, 'team': 2, 'time': 791.491, 'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 129,
'slot': 6,
'team': 3,
'time': 1187.728,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 4,
'slot': 4,
'team': 2,
'time': 1237.115,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 129,
'slot': 6,
'team': 3,
'time': 1366.95,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'slot': -1, 'team': 2, 'time': 1621.088, 'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 130,
'slot': 7,
'team': 3,
'time': 1655.347,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 132,
'slot': 9,
'team': 3,
'time': 1686.872,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 2,
'slot': 2,
'team': 2,
'time': 1751.123,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 4,
'slot': 4,
'team': 2,
'time': 1780.849,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'slot': -1, 'team': 3, 'time': 1927.636, 'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 129,
'slot': 6,
'team': 3,
'time': 2117.449,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'player_slot': 132,
'slot': 9,
'team': 3,
'time': 2156.047,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'key': '512', 'time': 2178.992, 'type': 'CHAT_MESSAGE_BARRACKS_KILL'},
{'player_slot': 4,
'slot': 4,
'team': 2,
'time': 2326.829,
'type': 'CHAT_MESSAGE_TOWER_KILL'},
{'key': '2', 'time': 2333.384, 'type': 'CHAT_MESSAGE_BARRACKS_KILL'}]
{'ability': 5075, 'level': 1, 'time': 249},
{'ability': 5076, 'level': 2, 'time': 378},
{'ability': 5075, 'level': 3, 'time': 448},
{'ability': 5076, 'level': 4, 'time': 595},
{'ability': 5075, 'level': 5, 'time': 744},
{'ability': 5077, 'level': 6, 'time': 959},
{'ability': 5074, 'level': 7, 'time': 1086},
{'ability': 5075, 'level': 8, 'time': 1384},
{'ability': 5076, 'level': 9, 'time': 1386}