I found the ultimate build queue!
Moderator: Content Developer
I found the ultimate build queue!
Because of a constant defeat in DSD, I programmed an AI to search for the best move. Amazingly the best move is similar to what the Pros had adviced me to do (when I was newbie). It was 3-solar + 2-mex (or 3), and 1-vehicle factory.
Fortunately I was unable to obtain the complete ultimate build queue. Because I need a supercomputer to complete the search. The search-space is soo big: it took minutesss to search for just 2 minute of simulated 'gameplay'.
I only simulate T1 economy (solar, wind, metal maker, Janus, and constructor vehicle) and make some assumption.
Please share findings if you try it.
:)
Fortunately I was unable to obtain the complete ultimate build queue. Because I need a supercomputer to complete the search. The search-space is soo big: it took minutesss to search for just 2 minute of simulated 'gameplay'.
I only simulate T1 economy (solar, wind, metal maker, Janus, and constructor vehicle) and make some assumption.
Please share findings if you try it.
:)
- Attachments
-
- SpringAITest(fixed).zip
- Java source-code for a simple economic AI (fixed)
- (7.12 KiB) Downloaded 39 times
Last edited by msafwan on 22 May 2011, 21:29, edited 1 time in total.
Re: I found the ultimate build queue!
Awesome!
Just a few weeks ago I was considering trying to "solve" spring's economy through simulation. I quickly found out that the number of variables was huge and that it was really a very complex problem, so I didn't pursue the idea at all.
But yeah, soooo many variables. It's crazy. And yes, on DSD the best queue seems to be 3 mex, then 2 solar (1 if you get enough E shared to you), factory, then your 3rd solar.
By the way, I think the best solution to this problem would be numerical. That is, try a bunch of different possibilities through simulation, and then see which one gives you the most M/E by X minutes (where you only specificy X in the simulation).
Just a few weeks ago I was considering trying to "solve" spring's economy through simulation. I quickly found out that the number of variables was huge and that it was really a very complex problem, so I didn't pursue the idea at all.
But yeah, soooo many variables. It's crazy. And yes, on DSD the best queue seems to be 3 mex, then 2 solar (1 if you get enough E shared to you), factory, then your 3rd solar.
By the way, I think the best solution to this problem would be numerical. That is, try a bunch of different possibilities through simulation, and then see which one gives you the most M/E by X minutes (where you only specificy X in the simulation).
Re: I found the ultimate build queue!
Thanks. I like that you like it. :)
Currently this simulation select build-queue that produce the most Janus. Janus is the most expensive unit I think, so if you can build Janus: then you can build others too. -Here's a sample output:
Front position start with
2 mex,
2 solar, and
1 veh factory.
Next build:
1 Wind
8 Janus
1 Wind
7 Janus
1 MetalMaker
4 Janus
1 Wind
4 Janus
1 Wind
16 Janus...
I will try your method next.
Currently this simulation select build-queue that produce the most Janus. Janus is the most expensive unit I think, so if you can build Janus: then you can build others too. -Here's a sample output:
Front position start with
2 mex,
2 solar, and
1 veh factory.
Next build:
1 Wind
8 Janus
1 Wind
7 Janus
1 MetalMaker
4 Janus
1 Wind
4 Janus
1 Wind
16 Janus...
I will try your method next.
Re: I found the ultimate build queue!
ideally you want to be able to react and change your strategy according to what happens in the battle; not that theres anything bad about what you've put, but it won't work every time against every opponent
the real success here doesn't lie with your queue... it lies in the fact that you were able to listen to a teammate and coordinate, something that too many BA players sadly don't seem to grasp
also : make some scouts first.
also : wind is not very strong on DSD
the real success here doesn't lie with your queue... it lies in the fact that you were able to listen to a teammate and coordinate, something that too many BA players sadly don't seem to grasp

also : make some scouts first.
also : wind is not very strong on DSD
Re: I found the ultimate build queue!
Cant oyu insert some stuff before the calculation?like a situation where you already played the first 2 minutes...
Re: I found the ultimate build queue!
That is a very interessting problem to fiddle with.
I think that is most important, if you want the most Janus after 5 minutes you need a different buildorder then if you go for most Janus after 10 minutes.
The most Janus after what time?Currently this simulation select build-queue that produce the most Janus.
I think that is most important, if you want the most Janus after 5 minutes you need a different buildorder then if you go for most Janus after 10 minutes.
Re: I found the ultimate build queue!
Yes you can. You can copy all the important variable from the present moment and paste it into the source-code. -The simulation will only depend on these following value:Cant oyu insert some stuff before the calculation?like a situation where you already played the first 2 minutes...
energyLevel=561;
energyIncome=65-6;
energyMaxCapacity= 1200;
metalLevel=166;
metalIncome=5.6;
metalMaxCapacity=1200;
(total)buildSpeed=300;
hasBuildConscructor?=false;
solarCount=2;
advSolarCount=0;
windCount=0;
metalMakerCount=0;
conscVehCount=0;
janusCount=0;
But note: that the simulation didn't simulate tech 2. The reason why is because it would take too long to simulate (it check all possible combination), hence tech2 is excluded. -Imagine the possiblity of building tech2 at start, later, and in the end with the given combination of building solar, or adv solar, or/and metal maker or adv metal maker.... it would take hours...
This is true. We could build eco first and then spam Janus (meaning: we sacrifice immediate reward for future bounty). But the AI is inefficient for long term planning; it can do it, but it will take tremendous amount of CPU time (if it succeed then it would be the ultimate PERFECT move).The most Janus after what time?
I think that is most important, if you want the most Janus after 5 minutes you need a different buildorder then if you go for most Janus after 10 minutes.
Currently the look-ahead is at 2 minute. I found it has tolerable waiting time. It can be set here:
depthCutOff=120; (120 second)
Re: I found the ultimate build queue!
remember that janus alone are completely useless. it usually means pushing with com. by the way u make mexes that cost 'something'. also wind give totally random E income, so... that and u forgot to include e storage which is obligatory when spamming wind.
Re: I found the ultimate build queue!
You don't need a supercomputer you just need multi-threading.
Re: I found the ultimate build queue!
genius spotedCheesecan wrote:You don't need a supercomputer you just need multi-threading.
Re: I found the ultimate build queue!
somebody go make a mission with highscore depending on built flash.
or fastet nuke tech or something.
below&above this post: bitch, please.
or fastet nuke tech or something.
below&above this post: bitch, please.
Re: I found the ultimate build queue!
Get your spelling right next time you want to call someone a fool.Satirik wrote:genius spotedCheesecan wrote:You don't need a supercomputer you just need multi-threading.
Re: I found the ultimate build queue!
Okay, I did it, it boosted the speed, but still it isn't fast enough. Firstly: because I'm a newbie in multi-thread, but anyway I did it by splitting the search-tree into 2; 1 for each core and combined the result in the end of the search, but it is still not enough to completely search a 40 minutes game. -2 thread reduce the search-time by half, but the search time is too big: half isn't enough.You don't need a supercomputer you just need multi-threading.
And I made more bug...
This is amazing. It is like using humans to find the best move (it's like copying move from the Pros). It's like "crowdsourcing"; where you use the 'crowd' to solve a problem.somebody go make a mission with highscore depending on built flash.
or fastet nuke tech or something.
____
- Attachments
-
- SpringAITest(2thread).zip
- Just in case someone wanted to use the code for other stuff.
- (7.85 KiB) Downloaded 18 times
Re: I found the ultimate build queue!
NOW these are all hacky ideas of a crazy programer, but here they are XD.
if we could have variables with the number of the human amount of scouts, or flash.
For each human flash built increment variable.
counters would be easy to make
XD
if (human_is_queingunits== 1 && repeat_on ==1)
{
if (human_scout_level > 12)
{
make_scout = 20;
attack_order = 1;
}
something like this XD
if (human_flash_level > 3)
{
make_flash = 7;
attack_order = 1;
}
}
OFC - this would have to depend on a timer that would analise how mutch time the enemy has been building flash.
OFC - this depends on a ligth cheating AI.
Now if we could have a variable that counts the number of enemy units that pass the middle of the map, reaction could be made, like simple commands, (send all units to attack ), or divide total_amount_units in half and send trou top or south to attack.
This would be interesting at best.
Also ERRORS AI sends a scout to each mex a human makes, its a very interesting practice ai to play with.
if we could have variables with the number of the human amount of scouts, or flash.
For each human flash built increment variable.
counters would be easy to make

XD
if (human_is_queingunits== 1 && repeat_on ==1)
{
if (human_scout_level > 12)
{
make_scout = 20;
attack_order = 1;
}
something like this XD
if (human_flash_level > 3)
{
make_flash = 7;
attack_order = 1;
}
}
OFC - this would have to depend on a timer that would analise how mutch time the enemy has been building flash.
OFC - this depends on a ligth cheating AI.
Now if we could have a variable that counts the number of enemy units that pass the middle of the map, reaction could be made, like simple commands, (send all units to attack ), or divide total_amount_units in half and send trou top or south to attack.
This would be interesting at best.
Also ERRORS AI sends a scout to each mex a human makes, its a very interesting practice ai to play with.
Re: I found the ultimate build queue!
crowds are only right if they hit a problem for the first time and the agents involved dont get a chance to copy from each other.