|
|
1 месяц назад | |
|---|---|---|
| .. | ||
| docs | 1 месяц назад | |
| jfbym_diag | 1 месяц назад | |
| lua-dec2 | 1 месяц назад | |
| scripts | 1 месяц назад | |
| src | 1 месяц назад | |
| tests | 1 месяц назад | |
| .env.example | 1 месяц назад | |
| .gitignore | 1 месяц назад | |
| .python-version | 1 месяц назад | |
| CHANGELOG.md | 1 месяц назад | |
| README.md | 1 месяц назад | |
| after_ready_start.png | 1 месяц назад | |
| before_launch.png | 1 месяц назад | |
| captcha_attempt1.png | 1 месяц назад | |
| captcha_attempt2.png | 1 месяц назад | |
| captcha_attempt3.png | 1 месяц назад | |
| captcha_attempt4.png | 1 месяц назад | |
| captcha_attempt5.png | 1 месяц назад | |
| cdp_captcha_state.png | 1 месяц назад | |
| cdp_game_page.png | 1 месяц назад | |
| cdp_login_page.png | 1 месяц назад | |
| cdp_main_page.png | 1 месяц назад | |
| gameupdate2.png | 1 месяц назад | |
| gameupdate_window.png | 1 месяц назад | |
| no_launch_on_detail.png | 1 месяц назад | |
| pyproject.toml | 1 месяц назад | |
| pytest.ini | 1 месяц назад | |
| search_commit.png | 1 месяц назад | |
| search_results.png | 1 месяц назад | |
| spawnLauncher.js | 1 месяц назад | |
| target_card.png | 1 месяц назад | |
Python SDK for driving the cq2 (传奇) game through 13 new-player tasks via protocol-level simulation.
3-layer (login / transport / task) + Lua bridge (lupa). Single-account synchronous async API.
Pre-alpha. 996box authentication, detailed server resolution, TCP role login, and entry through SC2 world initialization are implemented. The 13 gameplay task classes remain protocol stubs.
../docs/superpowers/specs/2026-09-18-real-game-login-design.md../docs/superpowers/plans/2026-09-18-real-game-login.mduv sync --group dev
from cq2_sdk import Cq2Client
async with Cq2Client(account="your-account", password="...") as cli:
# Existing roles are selected automatically. If this zone has no role,
# pass char_name="角色名", job=0, sex=0 explicitly.
session = await cli.launcher.run_until_enter_game(zone_index=0)
print(session.char_name, session.world_ready)
# Gameplay tasks are still under protocol development.
result = await cli.run_newbie_flow()
print(f"完成 {len(result.completed_tasks)} 步, 用时 {result.elapsed}")
run_until_enter_game() returns only after the world server sends SC2. A live
smoke run does not create a role unless char_name is supplied.
cd cq2_sdk
uv sync
uv run pytest