RPG Maker Forums

Advanced AI Conditions
Version 1.0c
 ​
What is this?
This script allows the developper to exert better control on how the AI handles the enemies' action patterns.
Script configuration is almost entirely made via noteboxes and no RGSS3 knowledge is required to use it.
 
Features and Instructions

PART 1: DEFAULT AI CONFIGURATION
 
- TGR settings
TGR determine the frequency a target will be chosen during random targeting rolls. The configuration module below allows you to set how damage and healing affects TGR to make a character more threatening to the eyes of the AI.
 
- Skill settings
Every skill can be given default AI *targeting* conditions all enemies will use. To do it, you have to create an "AI block" in the skill's notebox.
 
Notetags explanation:

<ai_conditions>Explanation: You always start the block with this one. target_hpgt: nExplanation: The target HP must be greater or equal to n%. target_hplt: nExplanation: The target HP must be lesser or equal to n%. target_states: n, n...Explanation: The target must have the specified states already inflicted. target_states_not: n, n...Explanation: The target must NOT have the specified states already inflicted. only_if_targetExplanation: If no suitable target is found, the skill won't be used AT ALL. </ai_conditions>Explanation: You always end the block with this one.PART 2: ENEMY AI CONFIGURATION
 
On top on a default AI, you can setup individual AI conditions for every different enemy. In case of conflict with the default targeting AI, these settings will take precedence.
All these settings make use of the enemy's notebox.
 
NOTE: the term "action index" refers to the order of the action pattern you enter for enemies in the database. For instance, if your list is like this:
 
Attack
Fire II
Poison
 
Attack will be index 1, Fire II will be index 2 and Poison index 3. And so on.
 
Notetags explanation:

<ai_conditions: n, n...>Explanation: One way of starting an AI block. n must be an action index and if you put more than one (separated by comma), the conditions will be applied to each of them. <ai_conditions: n, n...> use_idExplanation: Same as above, but instead of the action index, the skill ID will be used. n must be a valid skill ID in this case. switches: n, n...Condition: designated switches are ON. variables: x, y, x, y...Condition: the variables x have the value y. states: n, n...Condition: acting enemy is under the every of the designated states. hpgt: nCondition: acting enemy has hp greater or equal than n%. hplt: nCondition: acting enemy has hp lesser or equal than n%. mpgt: nCondition: acting enemy has mp greater or equal than n%. mplt: nCondition: acting enemy has mp lesser or equal than n%. party_level: nCondition: party level is greater than n. turns_order: a+bxCondition: it's exactly like in the database condition for turns. target_hpgt: nCondition: The target HP must be greater or equal to n%. target_hplt: nCondition: The target HP must be lesser or equal to n%. target_states: n, n...Condition: The target must have the specified states already inflicted. target_states_not: n, n...Condition: The target must NOT have the specified states already inflicted. only_if_targetCondition: If no suitable target is found, the skill won't be used AT ALL. </ai_conditions> Explanation: You must end the block with this one. 
- Creating Turn Patterns
 
Turn patterns is a special AI setting which completely replace an action pattern with another one at the designated turns. During a turn pattern, the "normal" actions (the ones you entered into the database) won't be taken into consideration, ever. You need to create another block to make a Turn Pattern.

<turn_pattern: a+bx>Used to define the pattern. a is the first turn and b the number of turns after the first. skill: a, ba is the skill id and b the rating. </turn_pattern>End the pattern.  
NOTE 1: You can put as many skill tags as you want.
NOTE 2: In order to assign conditions to a skill inside a turn pattern, you have to create a new AI block with that skill's ID.
 
- Absolute Rating
 
The absolute rating is a special rating you assign to an action during databasing your enemy. An action with this rating will take absolute priority, ignoring all others (even higher ones) provided it can be used.
If you have several actions with an absolute rating, one will be chosen randomly.
 
Download and Terms of Use

  • Contact me for commercial usage.
  • I will not be giving support or fixing bugs for you. I don't have time for that.
  • Please do not distribute them in one huge zip/rar/.7z/whatever compression without my permission.
  • You may use or edit the code as you please as long as it has proper attribution. However, you cannot change the license for the script e.g. removing the permission to use for commercial projects.
  • Please add me in your credits either as Archeia Nessiah/Division Heaven. It can be in the ReadMe/Game Credits/etc.
  • I am not liable for any destructive behavior that the materials could have caused you, such as, but not limited to, computer damage, incontinence, explosion of user’s head, coma, death, and/or halitosis. So edit or use at your own risk.

Latest Threads

Latest Profile Posts

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.
Can someone recommend some fun story-heavy RPGs to me? Coming up with good gameplay is a nightmare! I was thinking of making some gameplay platforming-based, but that doesn't work well in RPG form*. I also was thinking of removing battles, but that would be too much like OneShot. I don't even know how to make good puzzles!
one bad plugin combo later and one of my followers is moonwalking off the screen on his own... I didn't even more yet on the new map lol.

Forum statistics

Threads
106,034
Messages
1,018,446
Members
137,820
Latest member
georg09byron
Top