Commit Graph

11 Commits

Author SHA1 Message Date
tretrauit 0140969e4b
game: more refactoring
Signed-off-by: tretrauit <tretrauit@gmail.com>
2022-12-07 12:52:09 +07:00
tretrauit 680cf60720
fix: ImportError fix 2022-09-28 12:24:24 +07:00
tretrauit 96d1c7e8d3
refactor: move gamemanager.py to game & rename to Game
Also add back some staticmethods, because it'll be useful if you only import the Game class
2022-09-20 16:35:56 +07:00
tretrauit 2abbdf066b
refactor: more cleanup
feat: initial support for callbacks
2022-09-18 18:41:58 +07:00
tretrauit f909297ae0
refactor: many refactoring changes
helper: create helper.py with download_file
refactor: move hdiffpatch to its own hdiffpatch.py
fmt: use black for formatting
2022-09-18 11:09:44 +07:00
tretrauit c8823ea3b1
refactor: remove AsyncPath
feat: experimental threaded downloading
Also add very little support to Bilibili version.
Currently this isn't usable, so it'll need some time to be refactored
2022-09-18 01:58:51 +07:00
tretrauit a5659f7ff3
refactor: convert all task-intensive functions to async.
chore: rename gui.py to cli.py
fix: internal downloader can resume download now.
feat: add verify_game, verify_from_pkg_version, clear_cache to installer.py.
feat: add clear_cache to patcher.py.
fix: linux now check for pkexec before executing it.
fix: add get_name to voicepack.py, latest.py, diff.py to get name from path (since the developer didn't set a name to these files in the sdk url)
chore: remove deprecation message in read_version_from_config in installer.py
misc: use chunk from self._download_chunk instead of being hardcoded to 8192.
fix: is_telemetry_blocked will only wait 15s for a connection.
chore: move appdirs to constants.py

This commit refactor almost all functions to be compatible with asyncio, also restructured CLI to use asyncio.run on main function instead of executing it randomly.
Also prioritize the use of asyncio.gather, sometimes making tasks faster
2022-06-25 01:13:47 +07:00
tretrauit da3ee30ab1
Wrap game resource info from the server
Also add function to get the diff archive (for faster updating)

Download function soon, although I can't make sure that the download function will work properly (like pause, resume download etc.)
2022-02-16 22:18:56 +07:00
tretrauit c22918673b
Support chinese variant, QQ object in launcher and some code optimizations 2022-02-16 00:49:33 +07:00
tretrauit 048a7ac9d0
Update tests 2022-01-29 23:32:38 +07:00
tretrauit 015164404c
Update source (still WIP) 2022-01-28 20:08:53 +07:00