DuckeryDoodle Posted February 9, 2021 Posted February 9, 2021 I've just begin making my first Omega Ruby rom hack, and wanted to know how to make the AI better for gym leader and other important trainer? I've seen something. on the pk3ds thread about AI values of 87 and 7, but wanted some more clarification about what to do to increase the difficulty of the game.
ABZB Posted July 8, 2021 Posted July 8, 2021 The AI value is a byte composed of one-bit flags, add up the values of the flags you want. If the value is 0, the game will basically choose a move at random. With each active flag, that random behavior is modified in some way. Note that the numbers on the left are decimal values 1 - Will not use ineffective moves (e.g. Earthquake against a Flying Type), will be more likely to use Super Effective moves 2 - Checks to see if a move will have no effect (e.g. Thunder Wave on a Pokemon that is already Paralyzed), or if a move will very possibly have no effect (e.g. if the opponent's Evasion is raised, more likely to use something like Swift or Aura Sphere). 4 - If the Pokemon has a move that will definitely knock out the opponent if it hits, it will use it. Will always select a high-priority move if it will do so (if it has multiple options) 8 - On the first turn, will always use a Status move (Thunder Wave, Light Screen, Dragon Dance, etc) --- I'm not sure if these actually do anything in the 3DS games, I do know they did in the GBA era: 16 - Will use risky moves more often. This includes suicide moves like Explosion, OHKO moves like Horn Drill, moves conditional on opponent actions like Focus Punch or Mirror Move, moves with a high crit chance, Belly Drum, etc. 32 - Prefers to use strongest damaging moves --- 64 - Likes to use Baton Pass (so basically only useful on a trainer that is doing a Baton Pass chain. 128 - Double/Triple Battle AI (if not enabled, AI will do things like attack its teammate in Double/Triple battles). So basically all trainers you want to have at decimal 7 (= 1+2+4). If the trainer is a Double or Triple Battle trainer, you want the value set to 128 + 7 = 135. I suspect that the person you are quoting was using the hexadecimal representation, decimal 135 is hexadecimal 87
Freeasabird420183 Posted October 23, 2021 Posted October 23, 2021 (edited) On 7/7/2021 at 9:12 PM, ABZB said: The AI value is a byte composed of one-bit flags, add up the values of the flags you want. If the value is 0, the game will basically choose a move at random. With each active flag, that random behavior is modified in some way. Note that the numbers on the left are decimal values 1 - Will not use ineffective moves (e.g. Earthquake against a Flying Type), will be more likely to use Super Effective moves 2 - Checks to see if a move will have no effect (e.g. Thunder Wave on a Pokemon that is already Paralyzed), or if a move will very possibly have no effect (e.g. if the opponent's Evasion is raised, more likely to use something like Swift or Aura Sphere). 4 - If the Pokemon has a move that will definitely knock out the opponent if it hits, it will use it. Will always select a high-priority move if it will do so (if it has multiple options) 8 - On the first turn, will always use a Status move (Thunder Wave, Light Screen, Dragon Dance, etc) --- I'm not sure if these actually do anything in the 3DS games, I do know they did in the GBA era: 16 - Will use risky moves more often. This includes suicide moves like Explosion, OHKO moves like Horn Drill, moves conditional on opponent actions like Focus Punch or Mirror Move, moves with a high crit chance, Belly Drum, etc. 32 - Prefers to use strongest damaging moves --- 64 - Likes to use Baton Pass (so basically only useful on a trainer that is doing a Baton Pass chain. 128 - Double/Triple Battle AI (if not enabled, AI will do things like attack its teammate in Double/Triple battles). So basically all trainers you want to have at decimal 7 (= 1+2+4). If the trainer is a Double or Triple Battle trainer, you want the value set to 128 + 7 = 135. I suspect that the person you are quoting was using the hexadecimal representation, decimal 135 is hexadecimal 87 OOH.. shit so thats how it works.. i figured the higher it was the better/harder the AI will be. that answers some questions. hm so.. just keep Trainers around 8 then? Edited October 23, 2021 by Freeasabird420183
ABZB Posted October 26, 2021 Posted October 26, 2021 On 10/23/2021 at 4:41 PM, Freeasabird420183 said: OOH.. shit so thats how it works.. i figured the higher it was the better/harder the AI will be. that answers some questions. hm so.. just keep Trainers around 8 then? Basically the default "Best AI" value is 7, except for Double and Triple Battles, where you want 135, (7 + 128 for the "turn on Double Battle awareness"). Other values only matter if you make a trainer with a team that needs to do something very specific to work: If, for a particular trainer, you want them to always start with a setup move on the first turn whenever possible, then add 8 to whichever of those is appropriate (15 for single and 143 for double/triple). Similarly, if you make a trainer who is doing a Baton Pass strategy, you'll want to add 64 to that value (so 71 for single and 199 for double, or 79 for single and 207 for double if combined with the previous paragraph).
Isol8iv Posted July 22, 2022 Posted July 22, 2022 Hi, if you're still here ABZB, this is really helpful to know, as I was trying to figure out why something kept spamming Substitute while it already had one up - however, I changed the trainer's AI to 7, and the pokemon started spamming another status move it knows - Lucky Chant. Is there something wrong with Lucky Chant, or should I set it to something else? If your desciption for 2 is right, it shouldn't use Lucky Chant while it's already active. The trainer was Calem in XY, the battle at the tower or mastery, and he was using a Florges - moveset Lucky Chant / Acid Armour (never used this at all) / Light of Ruin / Substitute. After this I tried setting him to 5, and he didn't spam it, he barely used it at all. The only thing I can think of with the 7 is that I had a Fire-type out, which resists Light of Ruin, so he didn't want to use that, but then surely he should have gone for Acid Armour instead?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now