>_ DevTrendsen

Language

Home

Languages

Sections

Frontend Backend Mobile DevOps AI / ML GameDev Blockchain Embedded Security
JavaScript

How the Genshin Impact Automation Script Catalog Works

Anyone who has played Genshin Impact knows this routine: collect 168 curiosities for character ascension, clear ore spots, complete daily dungeons. The process turns into a second job. The community solves this problem in its own way. The BetterGI project uses computer vision and input emulation to automate the grind, and repository 4 serves as something like a central package manager for it.

I became curious to see how the developers organized the user script repository. When hundreds of people submit farming routes, combat rotations, and custom JS macros, a project can easily turn into a mess. Here the authors built a strict moderation and structure system through regular Pull Requests.

What's Inside the Repository

The repository powers a web storefront 5. Users launch the BetterGI client, select the needed scenario from the catalog, and the app pulls data directly from Git. No complex server-side database — GitHub acts as the single source of truth.

The catalog is divided into four main areas:

  • 6 — combat rotation scripts. These describe character ability timings, pauses, and dungeon completion conditions.
  • 7 — navigation routes. These are JSON files with character movement coordinates from teleports to resource collection points.
  • 8 — complex JavaScript automation scenarios with pattern recognition and a custom interface.
  • 9 — logic for the "Summon of the Seven" card mode.

Navigation Script Architecture

The largest part of the catalog is resource collection routes (10). To keep thousands of files readable, the community introduced a strict naming standard:

0

Example from the repository: 11 (Crystals, Liyue, Cloud Retainer, 6 pieces). Route numbers aren't arbitrary. Routes are sorted either by teleport order to reduce loading times, or by resource density to farm the richest spots first.

Conflicts are handled in an interesting way. Suppose two authors created collection routes for the same flower, but for different character setups:

1

If the player has a character that collects resources remotely, they download one preset. If collection is done by a standard two-handed sword character for breaking ore — another. The catalog structure isolates these variants using folders with the 12 suffix.

Complex JavaScript Scenarios

Simple movements don't cover all tasks. For complex things like automatic ley line farming or ascension material runs, JS scripts are used. Typical folder structure in 13:

2

Inside 14, developers tie together template image matching (Template Matching via OpenCV) and click simulation. If the required icon from the 15 folder appears on screen, a logic branch is triggered.

For parameter configuration, script authors can attach custom HTML overlays. The repository rules have clear requirements for them: heavy SPA bundles without source code are prohibited, so the overlay's web engine doesn't consume extra RAM during gameplay.

3

Contributors and Support

The project is maintained by an active Chinese community. The bulk of changes come through GitHub PRs, where authors adhere to strict commenting and formatting rules.

Active Contributors of babalae/bettergi-scripts-list - Last 28 days

Who Will Find This Project Useful

If you write game bots or create computer vision-based automation, 16 is a great example of how to organize a collaborative script database:

  • How to make GitHub a package registry without writing a backend.
  • How to store image recognition assets alongside executable code.
  • How to build a file naming scheme that eliminates duplication and confusion between dozens of authors.

The source is open, and documentation on scenario formats is available on the project website. Even if you're far from Genshin Impact, the architectural solutions for file organization and contribution standards can be borrowed for your own utilities.

Related projects