explaingit

dengzhilei/czn_auto

14PythonAudience · generalComplexity · 2/5Setup · easy

TLDR

A Windows automation bot for the Chinese card game Chaos Dream that uses screen recognition to click through card-farming runs automatically until your target card appears.

Mindmap

mindmap
  root((czn auto))
    What it does
      Farm card rewards
      Screen state detection
      Auto click sequences
    Features
      Background click mode
      Resolution scaling
      Target card detection
    Tech Stack
      Python
      Template matching
      JSON config
    Setup
      Installer or zip
      No Python needed
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Automatically farm card rewards in the Chaos Dream card game without manual clicking until your chosen target card appears.

USE CASE 2

Run the bot in background click mode so your real mouse cursor stays free while it plays.

USE CASE 3

Adjust the JSON config to tune timing, click positions, and monitor selection for your specific screen resolution.

Tech stack

PythonWindows APIJSONGitHub ActionsInno Setup

Getting it running

Difficulty · easy Time to first run · 5min

Windows only. Download the installer or portable zip from the releases page, no Python installation needed.

In plain English

CZN Auto is a Windows automation tool for a Chinese card game called Chaos Dream. It watches the game window using screenshot recognition and clicks through repeated card-farming sequences automatically, stopping when it finds a specific card the player is looking for. No Python installation is needed for regular users. A downloadable installer and a portable zip are available from the releases page. The tool identifies the current game screen state by matching template images against screenshots. States it recognizes include the main menu, the team selection screen, dialogue and cutscene screens, the three-choice card reward screen, and the card reward screen. For each state it knows what to click next. When the three-choice reward screen appears, it checks whether any of the options contains the target keyword. If the target card appears in the card reward screen, it stops. If not, it exits and starts the next run automatically. By default the tool uses Windows background window messages to send clicks, which means it usually does not move the real mouse cursor. There is also a real-mouse fallback mode for compatibility. Click positions are stored as proportional coordinates (a fraction of the screen width and height) so the tool scales across 1080p, 1440p, and 4K resolutions without manual adjustment. Template images for recognition live in a templates folder and can be replaced by advanced users to match different screen layouts. Configuration is a single JSON file with timing values, click positions, click mode, monitor selection, and screenshot backend. The README documents all fields and covers common troubleshooting cases such as clicks landing in the wrong position, dialogue advancing too slowly, or the reward screen closing before a card is identified. For developers, the tool is written in Python 3.11 and includes build scripts that produce both the portable zip and an Inno Setup installer via a single batch file or a GitHub Actions workflow.

Copy-paste prompts

Prompt 1
I downloaded czn_auto for the Chaos Dream game. How do I set the target card keyword in the JSON config file so the bot stops automatically when that card appears?
Prompt 2
The click positions in czn_auto are landing in the wrong spot on my 4K monitor. How does the proportional coordinate system work and how do I calibrate it?
Prompt 3
I want to add a new game screen state to czn_auto so it handles a new dialogue type. Where in the Python code do I add a template image and define the next click action for that state?
Prompt 4
The reward screen in czn_auto is closing before the card is identified. Which timing config values should I increase to fix this?
Open on GitHub → Explain another repo

← dengzhilei on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.