Skip to main content

rpze: Remote Python, Zombie: Endless

Project description

rpze

Remote Python, Zombie Endless(or endless rp?)

一个远程Python的Plants vs. Zombies TAS及ize测试框架.

主库位于GitHub.

使用

pip install rpze下载, 下载后通过python -m rpze --path "your\path\to\pvz.exe"验证安装, 详情见主库readme.

一个简单的完整rpze脚本示例如下:

from rpze.iztest import *

with InjectedGame(r"your\path\to\pvz.exe") as game:
    iz_test = IzTest(game.controller).init_by_str('''
                 1000 -1
                 3-0 4-0 5-0 3-3
                 .....
                 .....
                 bs3_c
                 b2ljh
                 blyl_
                 cg   cg   xg   ww
                 0    1    300  700
                 4-6  4-6  4-6  4-6''')
    print(iz_test.start_test(True))

结构

总体分成五个包:

  • rp_extend: 对控制pvz游戏本地运作的基本操作的封装
  • basic: DLL注入, 游戏启动, 汇编代码等基础功能
  • structs: PvZ内数据结构以及部分method的的封装
  • flow: coroutine-like测试编写相关的函数
  • iztest: IzTest测试功能以及工具函数
  • examples: 上述的测试功能的编写例子

其中, 若仅对Python的pvz框架感兴趣则只需关注前三个包, 对ize测试感兴趣则着重模仿examples并大致了解structs的成员(PlantsZombies).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rpze-0.2.0.tar.gz (152.3 kB view details)

Uploaded Source

Built Distributions

rpze-0.2.0-cp312-cp312-win_amd64.whl (163.8 kB view details)

Uploaded CPython 3.12 Windows x86-64

rpze-0.2.0-cp311-cp311-win_amd64.whl (163.9 kB view details)

Uploaded CPython 3.11 Windows x86-64

File details

Details for the file rpze-0.2.0.tar.gz.

File metadata

  • Download URL: rpze-0.2.0.tar.gz
  • Upload date:
  • Size: 152.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.9

File hashes

Hashes for rpze-0.2.0.tar.gz
Algorithm Hash digest
SHA256 f59d9712ea1400ae3a73b04130f7405b334ed796291525ce8698b6042fe682b5
MD5 724938abc28a5b40ff8a905cfac11352
BLAKE2b-256 df5a2351c99b50a4a83bc131486e74932fa996356d3aac718fa34c6242fb9265

See more details on using hashes here.

File details

Details for the file rpze-0.2.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: rpze-0.2.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 163.8 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.9

File hashes

Hashes for rpze-0.2.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 df4e977aee219a344169c36fcc439abf07b455dd03969c8f6cb1a90dffc5da1a
MD5 5887faf417a609e2d74f4623da786d99
BLAKE2b-256 49bf5fa6c6f8f62f766e350715180faa728044c64f30bbd7d725459a273041db

See more details on using hashes here.

File details

Details for the file rpze-0.2.0-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: rpze-0.2.0-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 163.9 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.9

File hashes

Hashes for rpze-0.2.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 8a16a299824f430ef21b953271e328aabb76fa43184223fed3d2ee01fd59d775
MD5 5e0818411b12e52b4426b9b0c4afde0f
BLAKE2b-256 ec3df4269211c41e52a6dfd5272ce6a57d363bff93e0f0a0597279ac7e48c6c9

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page