This is going to be the main thread for all AI script bugs and issues
Ai is unable to build trading post on railroad sites(native sites are working)
In TAD the ai was unable to upgrade to ironHorse for trading post (stageCoach worked) so this could still be an issue for DE.
If kbSetPlayerHandicap(cMyID, value) is updated it can cause an OOS. If the client changes the aiMain file and adds a function that updates the kbSetPlayerHandicap that will also cause an OOS. This has the potential to allow players to cause OOS when losing a game.
New AI functions needed
Returns the count of settlers currently working on a mine, a tree or whatever, but ONLY if those settlers are seen by the current player context. (I did not want the AI to cheat and know if there were settlers on something while the AI isn’t supposed to see them.
kbUnitGetInventoryCapacity(int unitID, int resourceID)
Returns the max resource capacity of a unit.
kbUnitGetCurrentInventory(int unitID, int resourceID)
Returns the current resource capacity of a unit.
int kbUnitGetNumberTargeters(int unitID)
Returns the number of units that is tasked to a resource
Returns the number of units the AI sees on a resource
Repairs a unit if repairable
Is the repair option available
Ejects all units from a unit
Is the game a nomad game
Is the game a FFA
kbIsKOTH( void )
Is the game King of the hill
Returns the ID of the trade route (when there is more than 1).
kbUnitGetNumberContained( int unitID )
Returns the number of units inside a unit
Returns the max amount of gatherers from a unit (e.g livestock pen)
Returns the current amount of gatherers from a unit
unitSpecialAttack(int unitID ,int unitID, int specialType)
Units that have a special attack (like ships) allow them to use them.