Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Knockout phase should happen before "after attack hurt/faint triggers" #74

Open
jimkaal opened this issue Apr 12, 2022 · 0 comments
Open

Comments

@jimkaal
Copy link
Contributor

jimkaal commented Apr 12, 2022

https://www.reddit.com/r/superautopets/comments/u06kr7/not_sure_if_rhino_good_or_he_just_got_way_too_far/

Below test gets stuck in a loop, but with debugging you can see that it spawns a chick way before rhino can trigger his knock out ability on the other roosters.

    def test_rhino(self):
        t0 = Team(["rhino"])
        t1 = Team(["rooster","rooster","rooster","rooster","rooster"])
        b = Battle(t0, t1)
        r = b.battle()
        # print(b.battle_history)
        self.assertEqual(r, 0)

Not sure what is causing the loop yet, but it might be fixed by re-ordering the knock out phase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant