用于在线游戏hyperiums的hapi包装器和工具
hypp的Python项目详细描述
用于Hyperiumsapi(hapi)的python接口。
旨在提供:
- 一个hapi包装器,允许多个连接(即每个用户、每个游戏),
- 每日列表导出的分析工具,
- 一些游戏机制的函数和公式。
麻省理工学院许可。
安装和快速启动
要安装:
pip install hyppy
使用hapi:
from hyppy.hapi import HAPI hapi = HAPI('Hyperiums6') # Get a list of games print hapi.games() # Password authentication for list downloads hapi.authenticate_basic('loginname', 'password') # Download today's planet list for this game hapi.download('planets', './planets.txt.gz') # HAPI key authentication for everything else hapi.authenticate_hapi('loginname', 'hapikey') # Get all player's planets print hapi.planet()