IPB Style© Fisana

Jump to content


qBot (yet another AI)


  • Please log in to reply
244 replies to this topic

#21 Mythos_Ruler

Mythos_Ruler

  • 0 A.D. Project Leader

  • Megas Philhellene
    (13,782 posts)

Posted 01 October 2011 - 12:50 AM

I like the idea that farms are so easily capturable. Makes sense. It also allows a scenario designer to place Gaia farms on the map that any player can snatch up.

EDIT:

View Postgudo, on 01 October 2011 - 12:31 AM, said:

Heads up quantamstate, as of r10348, the farm thing is a non-issue. Also, IsSeaCreature has been renamed to just SeaCreature.
Errr, there was a reason we allowed the player to gather from fields they didn't own. See: The Massacre of Delphi map. So, I at least hope the change doesn't affect human players. :) In the end though, I think it should be a viable option to raze an enemy town and just snatch up his existing farms. :)
Michael D. Hafer [aka Mythos_Ruler]

Wildfire Games Project Leader
Contact me: michaeldhafer[at]gmail.com
Support Wildfire Games!


0 A.D.

#22 Pureon

Pureon

  • 0 A.D. Art Team

  • Primus Pilus
    (3,220 posts)

Posted 01 October 2011 - 01:07 AM

View PostMythos_Ruler, on 01 October 2011 - 12:50 AM, said:

I like the idea that farms are so easily capturable. Makes sense. It also allows a scenario designer to place Gaia farms on the map that any player can snatch up.
Absolutely. Farms should remain capturable by other players. AIs will need to find a better way to choose farms - nearby to cc/farmstead or anywhere within territory
Pureon
0 A.D. Designer / Texturer / 3D Artist
Contact email:
pureon{@}wildfiregames.com

#23 gudo

gudo

  • Community Members
    PipPipPip

  • Duplicarius
    (228 posts)

Posted 01 October 2011 - 02:04 AM

The change makes it so that you can't farm opponents farms. Gaian farms are still fair game. Honestly, I like the change. Nine times out of ten, when I come across an enemy farm, I wan to destroy it because I'm raiding. If I've already driven off the defenders, (and so could farm) then I'm probably too busy pressing the attack to farm it. Besides, when you consider the distances you're farmers would have to travel to deposit their goods it's not really worth it anyways. Farms are only useful if you can build a farmstead nearby (meaning you have territory.) If that's the case, just expand your influence and capture it via loyalty.
Did you contribute to 0 AD?
Make sure you're in the credits!


AI Players
JuBot | RootBot | SplitBot | qBot | Marilyn | arBot

#24 historic_bruno

historic_bruno

  • WFG Programming Team

  • Primus Pilus
    (1,923 posts)

Posted 01 October 2011 - 05:05 PM

View PostMythos_Ruler, on 01 October 2011 - 12:50 AM, said:

Errr, there was a reason we allowed the player to gather from fields they didn't own.
Try gathering from an enemy (non-gaia) farm some time :P
Ben Brian [ aka historic_bruno ]

Wildfire Games Programmer
Contact me: ben@wildfiregames.com

#25 Linux_Eki

Linux_Eki

  • Community Members
    Pip

  • Discens
    (36 posts)

Posted 03 October 2011 - 04:30 PM

Simulated 15 minutes. Somehow bot decided that 20 women should just stand near town center. It built barracks and some houses but not any farms. Tested on build 10359 with latest qbot code taken from git.
http://adf.ly/3o5Po My youtube channel. Videos about 0.A.D and maybe something else.

#26 Mythos_Ruler

Mythos_Ruler

  • 0 A.D. Project Leader

  • Megas Philhellene
    (13,782 posts)

Posted 03 October 2011 - 08:39 PM

View Posthistoric_bruno, on 01 October 2011 - 05:05 PM, said:

Try gathering from an enemy (non-gaia) farm some time :P
I wouldn't see anything wrong with doing it. It's a farm field. Seems kinda silly to whack it with swords or shoot it with catapults. :)
Michael D. Hafer [aka Mythos_Ruler]

Wildfire Games Project Leader
Contact me: michaeldhafer[at]gmail.com
Support Wildfire Games!


0 A.D.

#27 quantumstate

quantumstate

  • WFG Programming Team

  • Primus Pilus
    (1,072 posts)

Posted 03 October 2011 - 10:56 PM

View PostLinux_Eki, on 03 October 2011 - 04:30 PM, said:

Simulated 15 minutes. Somehow bot decided that 20 women should just stand near town center. It built barracks and some houses but not any farms. Tested on build 10359 with latest qbot code taken from git.

Thanks for testing, obviously it isn't meant to do that, more to the point I haven't observed it do that. Could you tell me what map you were playing on and which player number qBot was?

Jonathan Waller [ aka quantumstate ]

Wildfire Games AI Scripter
Contact me: jonathanmarkwaller at gmail dot com


Support Wildfire Games!


#28 Linux_Eki

Linux_Eki

  • Community Members
    Pip

  • Discens
    (36 posts)

Posted 04 October 2011 - 05:10 PM

View Postquantumstate, on 03 October 2011 - 10:56 PM, said:

Thanks for testing, obviously it isn't meant to do that, more to the point I haven't observed it do that. Could you tell me what map you were playing on and which player number qBot was?
I played small (2pl.) random map on latium. Qbot was the second player.
I will test it more today. Giving reports later.
http://adf.ly/3o5Po My youtube channel. Videos about 0.A.D and maybe something else.

#29 quantumstate

quantumstate

  • WFG Programming Team

  • Primus Pilus
    (1,072 posts)

Posted 04 October 2011 - 05:28 PM

View PostLinux_Eki, on 04 October 2011 - 05:10 PM, said:

I played small (2pl.) random map on latium. Qbot was the second player.
I will test it more today. Giving reports later.

I just tested on Latium, qBot built farms at the start. I have had a problem with a wood shortage in late game which should now be fixed and the map looks quite wood scarce so if you arrived at qBot later in the game it may just have run out of wood. I would advise against playing on Latium due to the wood deficit, until the resource drop code is written it won't give a very good game. I would recommend Oasis II or Hellanized Egypt, Badlands should be better for a random map but not great. Make sure you update to the latest version before testing again since I did some significant bug fixing.

Thanks for the reports, they are helpful.

Jonathan Waller [ aka quantumstate ]

Wildfire Games AI Scripter
Contact me: jonathanmarkwaller at gmail dot com


Support Wildfire Games!


#30 Linux_Eki

Linux_Eki

  • Community Members
    Pip

  • Discens
    (36 posts)

Posted 04 October 2011 - 06:02 PM

Ok. Getting newest code first. I test new versions of bots with reveal map enabled so I can see how they grow and if they are bugged.
http://adf.ly/3o5Po My youtube channel. Videos about 0.A.D and maybe something else.

#31 JuliusColtranePille

JuliusColtranePille

  • Donator

  • Sesquiplicarius
    (120 posts)

Posted 04 October 2011 - 06:06 PM

tested newest qBot on alpha 7 G...

unfortunately it does not work, getting error-messages all the time :(

anyone else the problem with the alpha 7 and QBot?
older version of Qbot functionated...
"Jazz means Freedom."

Miles Davis

#32 Linux_Eki

Linux_Eki

  • Community Members
    Pip

  • Discens
    (36 posts)

Posted 04 October 2011 - 07:16 PM

Really impressive quantumstate. Played on Oasis 2. First time in 0AD gaming history I got attacked by such large force :D I just watched bot growing base and did not pay much attention to my own growth. I made small force (5eleph, 10 bow, 5spear 4 siege) and attacked to see how it would defend itself. Defending soldiers were no match but bot had decided to make huge force quickly for attack purpose. Troops started to spawn in the middle of my small army and killed half of my remaining army and then set course to my CC. It attacked 2 times with large force.
Then I camped outside their territory with bowmen and killed every women who were going to chop some wood. Bot sent 100-150 women to death in 12 minutes.

One suggestion for bot would be it that it sends soldiers to protect women if they are attacked. I could just set stand ground for bowmen and let them shoot even buildings.
Also I did not see a single tower.

Edited by Linux_Eki, 04 October 2011 - 07:17 PM.

http://adf.ly/3o5Po My youtube channel. Videos about 0.A.D and maybe something else.

#33 quantumstate

quantumstate

  • WFG Programming Team

  • Primus Pilus
    (1,072 posts)

Posted 04 October 2011 - 08:17 PM

View PostJuliusColtranePille, on 04 October 2011 - 06:06 PM, said:

tested newest qBot on alpha 7 G...

unfortunately it does not work, getting error-messages all the time :(

anyone else the problem with the alpha 7 and QBot?
older version of Qbot functionated...

Sorry, I have been submitting patches for the game to enable features which I am using in my AI. qBot isn't significantly better than JuBot (if at all) for the versions which will work so I don't consider it worthwhile to mark a release for alpha 7 compatibility. qBot will only be compatible with the svn version of the game until Alpha 8 at which point I will create a release version. My entire (not quite released) military design requires a newer game version plus some other useful more minor useful stuff (currently what breaks) is helpful.

View PostLinux_Eki, on 04 October 2011 - 07:16 PM, said:

Then I camped outside their territory with bowmen and killed every women who were going to chop some wood. Bot sent 100-150 women to death in 12 minutes.

One suggestion for bot would be it that it sends soldiers to protect women if they are attacked. I could just set stand ground for bowmen and let them shoot even buildings.
Also I did not see a single tower.

I just asked my friend to play-test a couple of hours ago and he hit upon the same strategy. The AI had trained (and lost) about 300 women by the end of the game. I will add towers (crudely placed) now since it is a trivial modification, I am not sure why I haven't done it before. I have actually written a defensive module, unfortunately it doesn't yet release the soldiers from its control so my AI never attacks when it is enabled. I should get it finished soon (time permitting).

Edit: Just committed the towers plus quite a few other military improvements. I managed to make a complete mess with git branches but eventually it is all back correctly into the master branch.

Edited by quantumstate, 04 October 2011 - 10:42 PM.

Jonathan Waller [ aka quantumstate ]

Wildfire Games AI Scripter
Contact me: jonathanmarkwaller at gmail dot com


Support Wildfire Games!


#34 Linux_Eki

Linux_Eki

  • Community Members
    Pip

  • Discens
    (36 posts)

Posted 05 October 2011 - 08:55 PM

More challenge this time. I rushed them but the amount of women is so stunning that I can never kill all those with 20-28 soldiers. I can't even stop wood gathering which would stop soldier production. There were one tower already when I came. I destroyed it and some reinforcements that bot made but then bot started to build 3 towers and it was gg. Lost my men and had to concentrate my poor economy. Final solution was to make some rams and quickly destroy CC. Then towers and barracks.
I played on random badlands and bot tried to build in top of some hill which was not accessible by troops. It didn't halt building production luckily.

Edited by Linux_Eki, 05 October 2011 - 08:55 PM.

http://adf.ly/3o5Po My youtube channel. Videos about 0.A.D and maybe something else.

#35 quantumstate

quantumstate

  • WFG Programming Team

  • Primus Pilus
    (1,072 posts)

Posted 05 October 2011 - 11:17 PM

I have just enabled my newer military code. It can now defend the town so it also sets the citizen soldiers to work, making the economy even stronger. Other big effects are that it now builds towers and advanced buildings and trains advanced troops from those buildings.

Jonathan Waller [ aka quantumstate ]

Wildfire Games AI Scripter
Contact me: jonathanmarkwaller at gmail dot com


Support Wildfire Games!


#36 Mythos_Ruler

Mythos_Ruler

  • 0 A.D. Project Leader

  • Megas Philhellene
    (13,782 posts)

Posted 06 October 2011 - 01:32 AM

Tested the latest iteration. Very nice. It gave me a few surprises and did better than Jubot has done against me, overall. I would look into how Jubot places Mills and see if you can't emulate that and improve upon it. I think the big thing lacking with qbot economically is the fact it doesn't place Mills. I think Jubot just searches for nearby Stone Mines and Metal Mines and places a Mill nearby. One thing that Jubot does too is that when it sends some soldiers to attack, the column will occasionally respond to being attacked.
Michael D. Hafer [aka Mythos_Ruler]

Wildfire Games Project Leader
Contact me: michaeldhafer[at]gmail.com
Support Wildfire Games!


0 A.D.

#37 JuliusColtranePille

JuliusColtranePille

  • Donator

  • Sesquiplicarius
    (120 posts)

Posted 06 October 2011 - 04:05 PM

so cool to hear all that,

pity that it won't work with alpha 7 build 2588.

keep on the good work; thumbs up
"Jazz means Freedom."

Miles Davis

#38 UV_Completion

UV_Completion

  • Community Members
    Pip

  • Discens
    (16 posts)

Posted 08 October 2011 - 09:02 PM

I tested the latest GIT and hit some problem in the tree map code:

ERROR: JavaScript error: simulation/ai/common-api/base.js line 36
TypeError: name is undefined
  ((void 0))@simulation/ai/common-api/base.js:36
  ([object Object],[object Object])@simulation/ai/common-api/entity.js:177
  ([object Object],[object Array])@simulation/ai/qbot/economy.js:267
  ([object Object],[object Object],[object Array])@simulation/ai/qbot/economy.js:330
  ()@simulation/ai/qbot/qbot.js:70
  ([object Object])@simulation/ai/common-api/base.js:91
  @:0

I was playing against two JuBots and a qBot on a random map.

#39 quantumstate

quantumstate

  • WFG Programming Team

  • Primus Pilus
    (1,072 posts)

Posted 08 October 2011 - 11:13 PM

View PostUV_Completion, on 08 October 2011 - 09:02 PM, said:

I tested the latest GIT and hit some problem in the tree map code:

ERROR: JavaScript error: simulation/ai/common-api/base.js line 36
TypeError: name is undefined
  ((void 0))@simulation/ai/common-api/base.js:36
  ([object Object],[object Object])@simulation/ai/common-api/entity.js:177
  ([object Object],[object Array])@simulation/ai/qbot/economy.js:267
  ([object Object],[object Object],[object Array])@simulation/ai/qbot/economy.js:330
  ()@simulation/ai/qbot/qbot.js:70
  ([object Object])@simulation/ai/common-api/base.js:91
  @:0

I was playing against two JuBots and a qBot on a random map.

Thanks for the report, I have committed a patch which should fix this. I am unable to reproduce the bug so am not entirely sure about the fix so please say if it crops up again.

For future reference it is sometimes helpful to know what map and roughly what stage of the game you were in. It would be nice to have but any bug report is better than none :).

Jonathan Waller [ aka quantumstate ]

Wildfire Games AI Scripter
Contact me: jonathanmarkwaller at gmail dot com


Support Wildfire Games!


#40 Mythos_Ruler

Mythos_Ruler

  • 0 A.D. Project Leader

  • Megas Philhellene
    (13,782 posts)

Posted 09 October 2011 - 12:06 AM

Check out the angle which the bot constructs buildings. Jubot has it correct.
Michael D. Hafer [aka Mythos_Ruler]

Wildfire Games Project Leader
Contact me: michaeldhafer[at]gmail.com
Support Wildfire Games!


0 A.D.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users