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

improve ai switching with bad moves #3213

Merged
merged 4 commits into from
Aug 29, 2023

Conversation

DizzyEggg
Copy link
Collaborator

If all moves have bad scores, the AI can also switch in double battle, and as a partner player pokemon, as opposed to just an opponent in a single battle.

I moved shouldSwitchMon from ai thinking struct, because it gets overwritten everytime move is chosen for any of the ai battlers. I also created an additional field monToSwitchId, so that it doesn't look for the mon 2 times.

@DizzyEggg DizzyEggg added the category: battle-ai Pertains to Battle Engine Upgrade's AI label Aug 8, 2023
src/battle_ai_main.c Outdated Show resolved Hide resolved
@DizzyEggg DizzyEggg mentioned this pull request Aug 9, 2023
@DizzyEggg
Copy link
Collaborator Author

Conflicts solved, ready to merge @ghoulslash

@ghoulslash ghoulslash merged commit 766a1a2 into rh-hideout:upcoming Aug 29, 2023
@AsparagusEduardo AsparagusEduardo mentioned this pull request Sep 27, 2023
@DizzyEggg DizzyEggg deleted the ai_switch_mon_fix branch June 23, 2024 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: battle-ai Pertains to Battle Engine Upgrade's AI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants