Research Modding - Devs please help us with information for AI compatibility

Hi,

please help us out with any questions to which the answers only you can know for sure.

Questions concerning the usability of a research tree to the AI:
(RS = ResearchSubject)

  • how much is the max cost of a RS in a give tier (if one exists)?
  • what RS does the AI try to get first, what second, and so on?
  • Which entities must not have any prerequisite?
  • When is it possible (if ever) to use more than 1 (max 2) prerequisites?
  • How comes the same RS used for example in the diplomacy 1.32 Tech Military tree does not get researched in a modded tree even though it has no prerequisite?
  • are RS's bound to specific trees/blocks?
  • Are there research subjects that are mandatory for the AI/the game to work?
  • Can I give some direction to the AI for it to research in a predefined order?
  • What is the use of the RS property "priority"? When needs it be 1, when 0?

Thanks alot for helping!

19,930 views 11 replies
Reply #1 Top

Well obviously I don' know for sure, but I'm pretty confident in my answers to some of those questions.



1 how much is the max cost of a RS in a give tier (if one exists)?
2 what RS does the AI try to get first, what second, and so on?
3 Which entities must not have any prerequisite?
4 When is it possible (if ever) to use more than 1 (max 2) prerequisites?
5 How comes the same RS used for example in the diplomacy 1.32 Tech Military tree does not get researched in a modded tree even though it has no prerequisite?
6 are RS's bound to specific trees/blocks?
7 Are there research subjects that are mandatory for the AI/the game to work?
8 Can I give some direction to the AI for it to research in a predefined order?
9 What is the use of the RS property "priority"? When needs it be 1, when 0?

End of quote

1. None, though if its too high obviously the AI may never research it.

2. Depends on many things, including the AI type, but in general it will go for things that unlock ships/buildings just like human players. Beyond that I'm really not sure, though research AIs will obviously spend more resources getting all the techs.

3. Colonies are the big one, both frigate and capital. Scouts I think are also required, and probably a couple of others.

4. I'm pretty sure its possible for anything.

5. Not sure what you mean here, as in the AI won't research it or it won't appear.

6. Nope, you can move them at will.

7. Just fleet supply and capitalships, though if you make everything available at tier 0 you technically don't have to research it.

8./9. Not really beyond the AI types (defensive will try to get mines, starbases earlier etc.). You can try adjusting the priority but there has been no conclusive proof that it does anything.

Reply #2 Top

Can I give some direction to the AI for it to research in a predefined order?
End of quote

You are looking for the "priority" tag. There is, to my knowledge, two values for it, 0 and 1. 0 is, to the AI, a higher priority RS. I realize that doesn't do much for making an order, but it's all I know of other than making a chain of RSs.

Reply #3 Top

Quoting GoaFan77, reply 1

1. None, though if its too high obviously the AI may never research it.

2. Depends on many things, including the AI type, but in general it will go for things that unlock ships/buildings just like human players. Beyond that I'm really not sure, though research AIs will obviously spend more resources getting all the techs.

3. Colonies are the big one, both frigate and capital. Scouts I think are also required, and probably a couple of others.

4. I'm pretty sure its possible for anything.

5. Not sure what you mean here, as in the AI won't research it or it won't appear.

6. Nope, you can move them at will.

7. Just fleet supply and capitalships, though if you make everything available at tier 0 you technically don't have to research it.

8./9. Not really beyond the AI types (defensive will try to get mines, starbases earlier etc.). You can try adjusting the priority but there has been no conclusive proof that it does anything.
End of GoaFan77's quote

Thanks to both of you.

ad 5.: the AI does not research it.

ad 9.: I have no conclusive proof of any real effect that priority has ever had. I once had an idea but I kind of refuted it myself.

Reply #4 Top

This may, or may not be related to research, but i do know that the AI needs every "statcounttype" in order to build, and expand. In other words it needs the colony frig, colony cap, siege frig, etc, etc, Pretty much one of each type in the statcounttype in the build order, or else the AI will be very slow to expand, or at times not build anything at all.

It is possible that certain research "types" may be required.  Just like certain ship types are required. Which research types i do not know. It is possible you may need all of them. Just like the ships themselves. We need to study this some more.

Reply #5 Top

The unmodded AI will generally go for techs that unlock ships/structures, (Except advanced tactical structures.) relationship techs, and fleet supply. Everything else will only be be researched if the AI has maxed it's available fleet supply.

 

:fox:

Reply #6 Top

Quoting Major, reply 4
This may, or may not be related to research, but i do know that the AI needs every "statcounttype" in order to build, and expand. In other words it needs the colony frig, colony cap, siege frig, etc, etc, Pretty much one of each type in the statcounttype in the build order, or else the AI will be very slow to expand, or at times not build anything at all.

It is possible that certain research "types" may be required. Just like certain ship types are required. Which research types i do not know. It is possible you may need all of them. Just like the ships themselves. We need to study this some more.
End of Major's quote

AFAIK the AI does not need every statcount, but won't do without some, especially Colony ship, Scout Ship, Battleship Capital, Siege Frigate (I believe). It can do without carriers, envoys, Starbases and more, though it will not be that efficient.

Quoting Kitkun, reply 5
The unmodded AI will generally go for techs that unlock ships/structures, (Except advanced tactical structures.) relationship techs, and fleet supply. Everything else will only be be researched if the AI has maxed it's available fleet supply.
End of Kitkun's quote

After a few test runs I must say that this is not generally valid. For example the AI researched some RS that had only floatModifiers and led to no other entity (testing all RS with removing all their prerequisites), though the AI will not research RS hat have no use at all (ie no bool or float modifiers, lead to no other entity or only lead to another RS)

Reply #7 Top

Just watch some Vicious AI in the Dev Exe. Even with all the extra cash, it still researches virtually nothing else.

 

:fox:

Reply #8 Top

I did with unfair, and it researched some researches that have no entities as a result, even before researching some of the Ships. Thats why I would want some Developers input, they are the only ones who could explain it and give us some pattern to adhere to. I've watched countless matches in the dev exe now, always modifying the Research Trees /Subjects for testing and never found a clear pattern as to why some subjects get researched and some not.

Thanks for helping though!

Reply #9 Top

The AI is hardcoded to research certain lines of techs first, based on its AI type. From there it bases its research via the priority weighting set in gameplay.constants.

Reply #10 Top

Many many thanks Yarlen!

I know it's much to ask, but to have a list of the techs each race AI type will research first would help our modding efforts tremendously!

Again, thanks for caring for us modders, thats one reason we love Stardock so much! 

Reply #11 Top

Just for the record, I have seen the AI in my mod research random stat enhancing techs (even ones that aren't required for ships/abilities), so they don't completely ignore them.