Topic: Improving the AI
the-x Topic Opener |
Posted at: 2019-07-10, 11:14
I have played hundreds of games the last days, with AI, self swapping to AI optimzing it and giving it back to AI, or let my build play from AI on. So I have lots of Ideas and improvements to make a script based AI better. The only problem is that i have not enough programming skills so, maybe I can swap my Ideas with womeone who is good in programming and we can try to implement the Ideas. Most important thing is that I want an AI that trains faster, so for single player its more fun and can even be challenging to play games with some AIs versus yourself on small maps. Top Quote |
Tibor |
Posted at: 2019-07-10, 17:55
Ideas are always welcomed, especially low-hanging fruits, where coding needed is up to few hours and outlook for success is high. Therefore it would be very convenient if you knew the current AI code to know what changes are easy to implement. Sometimes ideas described in few sentences can require hundreds of hours of coding. So we can start with some easy fixes and discuss them at least. Top Quote |
the-x Topic Opener |
Posted at: 2019-07-12, 15:08
Yes, that would be great The main thing I want to do first is have a closer look on the build order, cause there many changes could be made, this should be relatively easy to implement?- maybe later i also want to develop 2 different AIs, like rushing as efficiently as possible and one going more for economy Top Quote |
hessenfarmer |
Posted at: 2019-07-12, 15:29
First of all we should clarify some things in the beginning. AI has no fixed order or anything like that. Basically it picks a couple of fields and evaluates the possibiliteis on these fields. Then it makes a ranking of the possibilities due to a lot of decisiongates and weights (this is where the genetic algorithm with all the values defined kicks in). Top Quote |
Tibor |
Posted at: 2019-07-12, 18:35
Two more points to add:
Top Quote |
WorldSavior |
Posted at: 2019-07-25, 19:04
What about splitting the AI into several AIs which work together? One builds only roads, one builds only buildings, one launches only attacks and so on... Wanted to save the world, then I got widetracked Top Quote |
hessenfarmer |
Posted at: 2019-07-25, 22:12
In fact all of these topics are already seperate functions. they are called from a main scheduler and are run sequentially. So either I got your sugesstion wrong or I believe it already being implemented. Nevertheless any suggestion or discussion input is very welcome. Currently road building is slightly improved in my eyes, building algorithm has been improved as well for some shortfalls but now this has other issues uncovered or even produced. AI now builds too much buildings although it can't man them. My next fix is therefore to limit the buildings by a factor times the available workers tools or even better by already buzild unmanned buildings of same type. As I said often the best way in my eyes is doing one step after the other, as every new stepm will reveal new issues. Last para was just to let you know what i have already in plan. Top Quote |
Tibor |
Posted at: 2019-07-27, 16:09
Indeed, the AI has own scheduler and about 15 jobs that are called in own intervals.. @hessenfarmer: new roading for AI is still waiting for merge If you perceive the vacant production sites that problem, I can modify fitness function to penalty this. And train another hundred of rounds... If it will not help, just go on... Top Quote |
WorldSavior |
Posted at: 2019-07-28, 17:05
15? Interesting!
Looks like it's already implemented. My idea was that each component of the AI can be trained separately. Wanted to save the world, then I got widetracked Top Quote |
Tibor |
Posted at: 2019-07-28, 17:15
This is not bad idea, but currently all DNA numbers are messed up together, so it would be quite painfull to separate them into corresponding areas - but possible. However, I dont see this as a way to speed up training, because it would take the same time and only part of AI would benefit from it... Top Quote |