Giter VIP home page Giter VIP logo

grand-order-reroller's Introduction

THIS REPOSITORY IS OUT OF DATE.

I stopped supporting it when the launch SQ bonus ended. This code serves as a framework that can help you bring this project up to date for yourself.

Grand-Order-Reroller

Unattended rerolls for Fate/Grand Order

Why It Exists

I know MEmu has macro support, but if you ask anyone who uses it, you'll hear that they only automate up until the tutorial 10-roll because the fourth fight is non-determinisitic. You will also hear tips like leaving a lot of time between actions to account for variations in timing, which lengthens the time it takes for you to do a run. Also, in my experience, using MEmu's macros drastically reduced the stability of MEmu.

This script solves some of those problems:

  • Completely unattended unless MEmu crashes (for now).
  • Saves all accounts + rolls in a convinient format for easy access.
  • can handle non-deterministic events.
    • can handle a variable number of yolo-rolls at the end.
    • can handle a variable number of turns in the fourth battle.
    • can naively handle things like IP bans (right now, just wait it out).
  • Improved stability, since MEmu isn't doing anything extra.
  • Ability to change and edit the script without redoing the entire macro, this script can easily be updated to account for changes in the tutorial in the future.

However, it is not perfect. This method of rerolling has two major issues:

  • It requires mouse focus, so it's diffult to do anything else on the same PC at the same time. I have a laptop that I'm not using right now, so that's what I use for this script.
  • Only one instance, as a consequence of the above problem.

Basic Instructions:

  • Install Python. This project uses Python3. Be sure to tick the 'add to path' button during setup.
  • Run pip install pyautogui numpy opencv-python to install dependencies.
  • Download this repo.
  • Setup MEmu
  • Get Grand Order Image
  • Setup your MEmu instance as 1280x720 (default) and make sure it is at 0,0 (upper left) of your screen.
  • Update Grand Order
  • (Optional) Install the Clear Data apk from this repo in MEmu for easy clearing of data.
  • Fill in your preferred name and default password into settings.example.py and rename it to settings.py. Ignore other fields for now.
  • Open CMD/Shell as admin and cd into this repo.
  • Run python main.py

Screenshots

In v3, I switched from PyAutoGUI's image detection to naive computer vision with opencv and numpy. This is much faster and produces much less false negatives. And most importantly for end users, it does not require you to retake all screenshots.

Notes

  • You can adjust the timings for all time.sleep() calls and the delay between PyAutoGUI actions with the TIMING_MULT and PAUSE_TIME variables respectively.
  • I recommend using a VPN to avoid IP bans. Ideally a fully unattended setup would try to get a new IP by disconnecting from and reconnecting to the VPN, but it doesn't do that yet.
  • Possible issues:
    • There have been instances where bind codes have been lost due to an unknown issue. Because of the rarity of the problem, I am unable to determine the cause. However, after losing an account I quite liked, I decided to implement some additional checks that should correct the issue should it occur.
  • I just rolled an Altria/Gil account while writing this. Nice. Update: decided to main that account for now.

Clearing Data

There's an apk included in this repo. If you install that apk then click the icon, it will clear the data and allow you to reroll without downloading any data or messing in ES File Exporer. The script assumes you will have this apk installed and its icon will be located on the home screen directly to the left of the Grand Order icon's default position in the ova linked above.

Roll Tagging and Notifications

As of v3, there is now a roll tagging feature that will inspect rolls and provide some information about the summons in that roll. Right now, in order to avoid conflicting with the main purpose of the script, this functionality is in its own file, roll_handler.py.

Running python roll_handler.py will scan the rolls folder every two minutes for completed but untagged rolls and will rename the folder to reflect what it found.

If you install Pushbullet.py with pip install pushbullet.py and set your API Key in settings.py, then you will also be notified of good rolls.

Be aware that there is no detection of duplicate rolls at this time.

grand-order-reroller's People

Contributors

birdievera avatar nisegami avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

grand-order-reroller's Issues

Confusion

Certain steps such as "run pip install pyautogui numpy opencv-python" and "Open CMD/Shell as admin and cd into this repo." and even "Run python main.py" Aren't self explanatory for someone with no previous experience. I'm simply trying to make life easier for myself with these rerolls.

Clear GO Data

Everything works for me aside from the clear data apk; it clicks it but aside from that it doesnt clear the actual data and if it does then FATE GO won't launch until a full data clear. Any advice on a workaround/fix?

Not doing anything after skip_1

So I've tried the included images, it's not working as said in instruction. I made my own screenshots and it only went up the intro with the training dummy. Even with my own screenshots it still wouldn't go through it.
I've also tried to end the training to reach skip_2 but then, still it doesn't detect anything.

Anything after skip_1 doesn't work for me for some reason. Any ideas?

Update: My modified monitor's color was the issue. It actually viewed all the screenshots I created as washed out colors. I reverted to the original colors and re calibrated it again and it worked.

Worth a try

So I found this today and taking a quick, if inexpert, look through the code I'm reasonably sure this would work with Nox (the emulator that works right now, seeing as memu doesn't). I'm rather out of my depth here, being stuck on getting python to accept the install command because I'm not that bright... but the code looks like it should work beyond my own ineptitude.
Thought I'd mention it, would love to see this work (and save me reroll salt).
Either way, I wish you a good day.

Edit 1: reasonably sure opencv doesn't work, at least it doesn't download with pip. that might crimp the program a bit

No rolls

Hello! ^^ I am aware that this was posted a long time ago, but i have just installed the whole thing and after following the steps to a T (and with quite a bit of struggling as I am a complete n00b), i get no rolls after launching python main.py

Is it because the reroller doesn't work anymore or is it something I did? I mean, it looks like it recognises the command and all, but nothing happens. Thank you! ^^

may work for JP?

If I can access /data/data/com.aniplex.fategrandorder like in FGO-NA-v1.0.0-keripo-mod-2017-06-26-fixed.ova(com.aniplex.fategrandorder.en).
may this should work on Japan version or work for Nox?

only clickyng on the left side

the script starts by opening the game, then when the game is charged just keep clicking on the left side ignoring the agree button of the terms of usage.
this is how my scree looks like whit the memu config of 1280 *720
http://imgur.com/a/7wIN8

I didn't get my 5*

Hewwo :3

I keep re-rolling >_< But I not get my SSR >:O

Pwease help me get my SSR >:3

nuzzle

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.