oscarcx123 / afk-arena-tools

afk arena / 剑与远征 辅助工具
BSD 3-Clause "New" or "Revised" License
47 stars 8 forks source link

[Question] Why not use their API instead of scraping the app #11

Closed pedrokehl closed 3 years ago

pedrokehl commented 3 years ago

Hi,

Today I was a little bit bored, playing my AFK Arena, and I thought to myself, "why not automatize this?" So yeah, I found your repository... but I was wondering, why not sniff the app and try to understand how the connection with their server works and reproduce the same for repeated work? I imagine that it's because some secure practices that Lilith uses, but would like to hear from you if you ever tried it. If you never tried it, just let me know, I would definitely spend some time doing this for fun. By the way, very nice work here!

oscarcx123 commented 3 years ago

I'm glad you liked it!

Speaking of reverse engineering, someone else on GitHub made a bot using Lilith's API, and Lilith took down the repo (including all the forks) by sending a DMCA notice. There might be other bots floating around, but as an open source project, I guess that's the line we shouldn't cross.

I started this project a year ago and didn't expect it to become my most popular repo. Therefore, the lack of documentation, the resolution of the assets, the strong coupling between framework and scripts, all makes future development quite impossible.

I was planning to refactor the code but didn't have enough spare time to do it. Also, I don't know how many people are using this tool so I might be better off by leaving it as it is because the current version is still functional.

My original plan:

Let me know what you think.

pedrokehl commented 3 years ago

Interesting, I didn't know about it. So I better not try to implement it based on Lilith's API.

Yeaah, I see your point. I'm inclined to agree with you that since the current version is functional and there's no big feature missing, I would leave it as it is... At least if there's no major changes on the game UI that breaks the script.

I'm too lazy to work on a script based on pixel.. I would prefer to implement intelligence for the battles, and things like this.. But unfortunately, Lilith doesn't want people playing with their API (And I understand their side).

I'm gonna chase another side-project for me to spend my time. Thank you for the attention.