27 lines
703 B
Python
27 lines
703 B
Python
import logging
|
|
from island.matches import Matches
|
|
|
|
|
|
def count(name="", network_type=None):
|
|
# matches = Matches.from_profile(mode)
|
|
matches = Matches(name, network_type=network_type)
|
|
players = 0
|
|
for m in matches.data:
|
|
c = len(m.query('player', 'join').raw_data)
|
|
|
|
# logging.info("%s: %d", m.name, c)
|
|
print(f"{m.name}: {c}")
|
|
players += c
|
|
# logging.info("%s: %d", network_type, players)
|
|
|
|
|
|
if __name__ == '__main__':
|
|
logging.basicConfig(level=logging.INFO)
|
|
# calcAndSave('CLASSIC')
|
|
# calcAndSave('SURVIVE')
|
|
# logging.info('BA')
|
|
# count('NEW', 'BA')
|
|
# logging.info('WS')
|
|
# count('NEW', 'WS')
|
|
count("wos-data-2022-sd")
|