manny405 / sapai

Super auto pets engine built with reinforment learning training in mind
MIT License
66 stars 21 forks source link

updated peacock ability, fixed #46 and fixed hatching chick lvl 3 #51

Closed jimkaal closed 2 years ago

jimkaal commented 2 years ago

Updated peacock to 2/5 Modified ability to be 50% of attack with max triggers

Addresses part of #32

jimkaal commented 2 years ago

Fixed #46 in battles, since butterfly always activates TransferStats with attack 1 priority in StartOfBattle, i added a check after all StartOfBattle triggers that checks for self summons (currently only butterfly). This makes sure butterfly summon has the correct priority compared to snipers. in effects - evolve, made sure to create a new pet instead of just the name and removed the new pet effect trigger, since the above priority issue

added unittests for both high and low attack caterpillars to test the pet priority

jimkaal commented 2 years ago

Thank you for that comment, I put the "maxTriggers" in the wrong place Modified the unittest and fixed the issue

jimkaal commented 2 years ago

Apparently hatching chick level 3 was not added to the StartOfTurn triggers nor unittests. Immediately threw an error when its ability was used, GainExperience used target pet ability to determine experience amount, which only works for caterpillar. Modified this to now check the triggering pet's ability.