Age of Kings Heaven
Downloads Home
Best Files
Review Guidelines
Main site
Code of Conduct

Advanced Search
AI Files
New Releases
New Reviews
New Comments

Submit File
Browse Categories
New Files
Recent Updates

Downloads Home » AI Files » Instructional AI

Download File Post Review Post Comment

Instructional AI

Author File Description
File Details
Version: The Conquerors 1.0c
My aim was to make a powerful, yet simple and helpful AI.
Almost every rule has comments explaining what it does, why we use it etc...
This AI will do a Fast-Castle in around 18-19 minutes most of the time and is actually quite strong.
If you find AI scripting difficult to understand I hope this can help you provided you know the basics! This is also the Teutonic script in my Rampage RM AI.
AuthorComments & Reviews   ( All | Comments Only | Reviews Only )
Campidoctoris This AI can be a good tutorial to start to completely unexperienced scritpers, although you should warn about you still are getting experience and your strategy could have a few errors. For example, it can be good for closed maps, but it's too slow and vulnerable to agressive AIs in open maps.

From a pedagogic point of view, it's quite good, easy to understand, but it has a few things to improve.

The most important, the only thing that you still need, is adding more constants. You have written a few to make shorter a the names of a few strategic numbers, but constants have more utilities.

One of them is make goals easier to understand. For example, you use one goal to know in what age you are, and it's very easy to know that specif goal has that utility, but it's only because you have commented a lot your script (which isn't a bad habbit). But goals are easier to understand if you name them with a constant. For example, if your goal 1 is for check your age phase, your could define the constant G-AGE-STATUS and set it to 1, later you use the goal G-AGE-STATUS, which is the same than the goal 1, but its name makes it easier to understand, even if you stop to add more comments.

Another utility for constants is replacing a number which is used in a lot of rules, to avoid the work to change it a lot of times if you want modify your strategy and to avoid bugs and errors if you forget one rule in which that number was used.

For example, you want delay your feudal advancing until you have 30 villagers. Imagine that you use that number, 30, in a lot of rules. Also imagine that you decide advance with 29 or 31 villagers. Well, if you have defined the constant DARK-VILLAGERS to 30, you can "change" the number 30 to 29 only changing the defconst command, setting DARK-VILLAGERS to 29 in one only line, so every rule that uses DARK-VILLAGERS constant has been changed also.

And finally, suggest in your script that after learning from your tutorial AI, the new scripter could use the basis that you have provided him to understand better the Training AI from Bear_The Great.

Anyway, your tutorial is a nice try and could be useful to novice players. And it's the only tutorial AI that I've watched perform a Fast Castle strategy instead of a flush, and it's interesting.
File Author
Haha, the thing is, I'm rubbish with constants ;P
The reason for this was to show people a relatively simple start to their AI scripting. So that they could understand the basics and would be able to then progress to a more complicated script that they make. It's not complete, such as it will not research some resource technologies in the Imperial Age and it will usually have an excess of gold due to it usually capturing all 5 relics, and I saved the trading rules for my competitive one :L

Post Review Post Comment

HGDL v0.8.0

Forum Username:


Create a new account
Forgot password?
Favorites: [Who?]1
Size:8.21 KB