Page 2 of 46 FirstFirst 12345678910111227 ... LastLast
Results 21 to 40 of 908

Thread: ReallyBadAI Battle System +Hardcore + Settlements v5.7 >Oct 17< ###quality taken to next level###

  1. #21

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    "Thanks to Point Blank who featured it as default in RR/RC/CBUR(...)"
    ...Little bit confused, isnt "ThesavageAI" the standard in the actual version of RR/RC??

    Edit: Ah...this is BattleAI only, i see... noob out lol
    Last edited by algorath; April 25, 2009 at 02:41 AM.

  2. #22

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    @Germanicu5
    I'm sure patient alright, just hoped for an answer to give me something to think about.

    AI seems to be doing a good job now (RRRC no radical).
    Cavalry seems to know their place, seems like a well thought job.
    Even infantry try to flank...

    P.s - i dont think no one will get perfect results, you already done more than enough.

  3. #23
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Quote Originally Posted by wolfslayer View Post
    No, descr_formations_ai.txt is parsed once at game start and kept in memory. The two BAI files (config_ai*/ battle_config*) are reloaded every battlemap start/replay.
    As I stated before, it all sounds logical and I've just looked into logs (both files are parsed each time, as you stated), but I did more tests and the results are:
    battle_config.xml changes don't work... but
    config_ai_battle.xml do, cool thing.

    I had only tested battle_config.xml before and assumed the result would be the same for both files (yea, I still don't know why it isn't).

    Thanks for being stubborn . So in theory we could script the use of alternative AI files during the campaign (damn, we will I mean).

    Regards
    Last edited by Germanicu5; April 25, 2009 at 07:13 AM.
    SS 7.0 - The work continues

  4. #24
    wolfslayer's Avatar Senator
    Join Date
    Oct 2007
    Location
    Lexington, South Carolina
    Posts
    1,170

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Quote Originally Posted by Germanicu5 View Post

    battle_config.xml changes don't work... but
    config_ai_battle.xml do, cool thing.
    And what changes did you test?

    When you make claims like this, with no details whatsoever on what basis you lay that claim, it raises valid questions about the veracity of your testing.

    I just confirmed battle_config.xml changes most definitely do take effect when restarting a battle.

    And I had to take the time to run these tests, after reading your post, because I knew your statement was incorrect.

    Otherwise, your claim is presumed to be "fact", and remains archived as such for the duration of this forum's existence, until proven otherwise.

    ******************************

    I used the stock Teutonic 1.5 xml in my SS6 folder and ran a village siege attack, confirming the plaza timer at default 3 mins. Then changed to 8 mins, saved and restarted the battle...(see pic)

    I used the most basic file (stock Kingdoms) as the basis for my tests, before determining if changes to battle_config.xml are used when reloading a battle.

    Another quick test with stock hit rate (1.75) and 1 on 1 armoured sergeants. Melee dragged on for 3-4 minutes before I ended, changed hit rate (91.75) and restarted. The battle was over in about 1.5 mins, most soldiers going down on the first strike.

    Which raises the question: If the core encounters unusable code, does it skip it and continue to utilize the usable code. Does it use part of the xml and part of the core exe or does it revert totally to default (exe) for that battle?
    ______________________________________________________________


    Viewing and editing MTW2 textures with MWthumb and DXTbmp









  5. #25
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Quote Originally Posted by wolfslayer View Post
    And what changes did you test?

    When you make claims like this, with no details whatsoever on what basis you lay that claim, it raises valid questions about the veracity of your testing.

    I just confirmed battle_config.xml changes most definitely do take effect when restarting a battle.

    And I had to take the time to run these tests, after reading your post, because I knew your statement was incorrect.

    Otherwise, your claim is presumed to be "fact", and remains archived as such for the duration of this forum's existence, until proven otherwise.

    ******************************
    Firstly, I respect others even when I have different test results or views on a discussed subject.

    Initially I had tested only skirmish distances for battle_config.xml and posted info that the values didn't reload, I had no reason to believe inconsistency in parsing both AI files, since tracing shows they're both reloaded each time (which I never denied).
    Second testing round proved changes I made to config_ai_battle.xml were effective (but now I think it should not be automatically extended to all values represented there).
    I also run a siege test like you suggested and I can confirm changing plaza timer in battle_config.xml indeed takes effect.

    Overall tests prove inconsistent results for parsing of the same file, which isn't too optimistic and couldn't be foreseen at all, there is no logical explanation to ignoring some settings at reloading both AI files.
    So we were both right and wrong in the same time and I definitely gave my best efforts to verify the case without any offensive presumptions.

    Secondly, I mentioned battle_config.xml tested values Here before you performed your tests (this thread).
    And some general testing hints Here (this thread - so the general methodology was known)
    and some methodical tests Here,
    which I linked to in this posts (this thread again):Here

    So the testing setup was:
    Kingdoms 1.05 SS+RR-RC, flat map, vh difficulty, AI file with vanilla-style tags (aka my AI file), changes commenced before and after the initial battle finished (just to make sure), campaign tested over 2 turns for skirmishing values, same result, multiple attempts.
    - 3 AI missile units vs 3 spear for testing skirmish distances (due to easily measurable results of tests), skirmishing distance changed between 0 and 150 for both values - no success - missile units were withdrawing or not withdrawing at all strictly depending on initial settings
    - 4 foot, 2 cav on AI side vs 3 spear for testing engage distance, values set to 0 and 100, changes took result after restarting battles (again easily visible due to AI units standing at set assault-dist and doing nothing with "0" set)
    - 2 cav vs AI peasants for village assault

    Which raises the question: If the core encounters unusable code, does it skip it and continue to utilize the usable code. Does it use part of the xml and part of the core exe or does it revert totally to default (exe) for that battle?
    Answer is in this thread too (posted right after creating it): Here
    I can add that deleting <min-range> line makes the core revert to default values for both <min-range> and <min-stopping-range>.

    Regards
    Last edited by Germanicu5; April 25, 2009 at 02:57 PM. Reason: cleaned links up
    SS 7.0 - The work continues

  6. #26
    wolfslayer's Avatar Senator
    Join Date
    Oct 2007
    Location
    Lexington, South Carolina
    Posts
    1,170

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    I should mention file cache settings may be a factor with making BAI changes ingame, without adding this to your .cfg, the 2 existing BAI files will load and cache on game start.

    [io]
    file_first = true
    disable_file_cache = true

    With this entry added, the BAI files only be accessed on battle start/restart. With the entry completely removed, the game defaults to disable_file_cache = false.
    ______________________________________________________________


    Viewing and editing MTW2 textures with MWthumb and DXTbmp









  7. #27
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    @wolfslayer
    Yea, log show both files are loaded only before battle with this setting.
    I quickly tested skirmish distances (5 custom battles, usual setup) - changes weren't commenced again. I'd prefer the game to be more predictable :/.

    Regards
    SS 7.0 - The work continues

  8. #28
    Gorrrrrn's Avatar Citizen
    Join Date
    Jan 2007
    Location
    here
    Posts
    5,546

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Did a selection of open field - grassy plain battles over the weekend.

    I'm using SS6.2 RC4 with 110AD sub-mod for english roster.

    Used 2 full (20 unit armies) - so I get to see if the AI attacks different types of units etc. 10,000 florins exactly, no upgrades or experience. all eras.

    Roster 1: English: 1 late GB; 4 yeoman archers; 2 heavy billmen; 2 dismounted kings men (men-at-arms); 4 heavy spears; 2 crossbow militia; 2 hobilars; 2 arquebusiers, 1 city guards (voulge miltia)

    Roster 2: Cumans: 1 late GB; 4 horse archers; 2 mounted cossack gunners; 2 archer militia; 2 nomad archers; 5 spear militia; 2 cuman heavy infantry; 2 pecheneg guard (spear)

    I played both English and Cumans once using the 0.71 and restarted game to test 0.72 radical, both medium and very hard level.

    I laid out the forces more or less the same way each time:

    English with 4 heavy spears in centre, 2 yeoman archers on each flank of them with stakes, outside them arquebusiers. in front on heavy spears crossbow militia. Behind heavy spear city guard and GB, behind yeoman archers 1 dis KM, 1 Heavy billman on each flank. Hobilars back behind arquebusiers. All skirmishing troops on skirmish (as AI usually starts that way too.)

    Cumans with 5 spear miltia in front with cossak gunners and horse archers on flanks. archers start in front on spear militia on skirmish. the cuman heavies and pecheneg guard 1 per flank. 1 GB centrally in rear.

    AI draws up its forces in symetrically regards cavalry but in order they are listed regards infantry and archers -so you get nomads on one flank and archer militia on other.

    Weather - I restarted from scratch every time weather was either too foggy or thunderstorm as these might affect comparisons.

    In every battle the AI attacked, throwing its archers etc forwards quite quickly and following up with infantry at walking pace. AI deploys its horse archers further away from infantry than I do, but as they are skirmishing they usually end up about the same distance away. AI Infantry seems to go for its opposite numbers, but usually has a couple of units in reserve. AI GB charges the archers (as do english hobilars when the AI uses them.) But they withdraw after contact with spears. (There is a constant problem with ordering skirmishers to move - if you order a line of 4 units to retire behind other troops at least will just stand there and get clobbered. I always turn skirmishing off once they have retired behind heavier infantry, or else they retire so far they do nothing. AI keeps its archers well back but active - seems to use fire arrows a lot more than I do.) Several times the AI GB outflanked my infantry and caught my back-line of archers and it sometimes managed to collapse a flank of my infantry as well. It seems the survival of the GB is key to winning the battle if it is closely fought. The one battle I lost was down to the AI GB having the general as sole survivor whilst my GB which had engaged it was destroyed. AI General then attacked my routing troops stopping them from re-grouping. Equally other battles swung in my favour once the AI General had died. AI GB was very good at destroying lines of arquebusiers - but they sometimes survived well enough to shoot the AI GB. Cuman horse archers and cossack gunners were the only troops I had left in one battle. I actually lost more troops but somehow the HA and gunners managed to see off the remaining english infantry. (The AI seems more reluctant than I am to order HA to attack routing troops, rather than keep a distance and fire at them. The only difference with VH vs M is the AI gets a morale boost as far as I can see.) As for difference between 0.71 and 0.72 radical - I think the 0.72 does a better job at outflanking - but how easy it is to outflank is difficult to tell when one side has horse archers on the flanks - I tried to keep my cossack gunners close to my infantry but they sometimes get very spread out. (Not a problem with this BAI - it happens with all of them I think.) The AI loses between 10-15% of its missile troops simply by advancing into contact. If the AI waited for the human to advance it might do better in some battles.

    I'll post a spreadsheet with numbers lost etc a bit later once I've done it.

    And here it is - used 7-zip and saved in.xls format (done using open office)
    Attachment 39335
    Last edited by Gorrrrrn; April 27, 2009 at 07:44 AM. Reason: update, spelling

  9. #29
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    @Rozanov
    Wow... nice determination there, but I knew I could count on that since you first posted in this thread, thanks for help.

    I'll post new AI with minor bugfixes later on.

    ****************

    I've been researching AI scripting possibilities for the past 2 days, we can surely script some conditions for general unit (like I_IsUnitUnderFire, I_IsUnitEngaged etc) and make it take some appropriate action. Or we could spawn custom battles (like Pavia) for human players during the campaign.
    For now I'm posting a useful campaign-script addition, extension-ready and tested.
    ***********************
    AI stakes deployment script v0.1:

    - executed over multiple battles and turns, doesn't slow down the game (monitor_event used)
    - AI deploys stakes during defensive day open battles provided that it's not succesfully ambushed (incl crossing battles and sally-out batles too)*
    - no siege defense stakes**
    - timer for stakes deployment (1 minute atm)
    *conditions editable, I could include stakes in night batles, that'd be some fun, we could feel like dumb AI for once
    ** although they really rock - a pity AI's own cav impales on them so easily and that there isn't much space to deploy them inside a settlement, cities are pretty decent though

    If anyone thinks it's interesting and would like to integrate it with a campaign, just ask. Ofc no limits on private use or integrating it with basic SS or RR/RC.

    Installation: Copy the code to your campaign script file anywhere between "script" and "wait_monitors+end_script" lines, preferably in the bottom of the file. Needs campaign restart.

    known limitations: stakes not deployed on roads

    Regards

    New versions downloadable via 1st post.
    Last edited by Germanicu5; May 08, 2009 at 09:49 PM.
    SS 7.0 - The work continues

  10. #30
    Caesar Clivus's Avatar SS Forum Moderator
    Join Date
    May 2007
    Location
    Australia
    Posts
    12,847

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Wait...you got the AI to deploy stakes??? Wow that is going to totally change battlefield tactics. Nice work.

    BftB2 UPDATED 22nd DECEMBER. Member of the Complete Byzantine Unit Roster team

  11. #31
    blbrotto's Avatar Libertus
    Join Date
    Apr 2009
    Location
    Curitiba, Brazil
    Posts
    68

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Hi Germanicu!

    I'm using your BAI and I'm loving it.. despite somethings, like when the AI uses the ballistas and cattapults on a siege but doesn't withdrawn with them if lose the battle and, when the gate is open (or openned by catapults or rams) the enemy drops all their siege equipment (sometimes they don't drop the ladders and attack the walls too...) and run to the gate like crazy! If you have good spearmen soldiers there, is an easy task to kill them... ah, and it's sad because the AI sends first the cavalry (even the general) in charge to the gate... could be a good ideia, if the infantry wasn't too far away to suport the cavalry....

    On open battles, the AI is great, you have to choice carefull what kind of infantry you send to engage, because the AI is using now the Elite units to outflank you, or hold the middle if it's outnumbered, while their cavalry combats your own cavalry.. if you lose the batlle cav vs cav, then they will charge into your rear or flank... and you will be *&%... XD

    Ah, I have a sugestion too.... I was thinking if is possible to your units lose morale when your city is under siege and the enemy hit your buldings (like houses, markets...) I think this would represent better the "fear" of your soldiers from an enemy with a strong tecnology...

    Please! Sorry about my english! XD, I'm from Brazil...

    PS: And about the AI, I know no one can do a miracle, but I apreciate your work! Keep going

    PS 2: And to the guys who think the AI should be invencible, try to "help" the AI, if you are under siege, and the enemy is winning the battle for the gates, think like the medieval general on the battle (if the general is not good with comand, try to play more "easy") ... but like a medieval soldier too... what you would do if the cavalry is charging uppon you and you are only a levy spearmen??? of course you will run to the central square and try to regroup, or to another position more tight! XD Of course this is my opinion and way to play... you will lose some battles... but the game will be very more fun... XD!

    Bye!
    Last edited by blbrotto; April 27, 2009 at 09:27 PM.

  12. #32
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,738

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Stakes for AI... wow man, very impressive!

  13. #33
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Update: stakes deployment dependant on AI general's distance from the nearest player unit. We can actually make archers approach our units and stick their stakes under player's nose now.

    @CC
    Dooh... tyvm
    @blbrotto
    Thanks, AI behaviour is really hard to model, there aren't many settings available via 2 battle AI files, I'm currently working on changing that by making scripts.
    As for morale related to building damage... that's doable I think.

    Regards
    SS 7.0 - The work continues

  14. #34
    Gorrrrrn's Avatar Citizen
    Join Date
    Jan 2007
    Location
    here
    Posts
    5,546

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Re AI using stakes.

    Quick question - given the AI puts its cavalry on wings (usually) but attacks missile troops (even if in the centre)
    where are you going to get it put its archers with stakes ability?

    If a human counters advancing archers by advancing with its own archers, then its probable that the AI will charge the human archers - through its own stakes?

    Can we get the AI to advance at a walk until much close to their target - if the target is stationary anyway. You can walk through stakes without casualties.

    (btw - the AI gets to plant stakes AFTER the set-up phase (ie during the battle?))

  15. #35
    Caesar Clivus's Avatar SS Forum Moderator
    Join Date
    May 2007
    Location
    Australia
    Posts
    12,847

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Quote Originally Posted by Rozanov View Post
    (btw - the AI gets to plant stakes AFTER the set-up phase (ie during the battle?))
    Oh really? Ouch!

    BftB2 UPDATED 22nd DECEMBER. Member of the Complete Byzantine Unit Roster team

  16. #36
    Germanicu5's Avatar Will buy spare time...
    Join Date
    Feb 2009
    Location
    Not Zee Germany
    Posts
    2,104

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    @Rozanov and CC
    Yea, the stakes are deployed 60 secs after battle starts in the first version (I mean real battle time, excluding pauses) and as soon as any enemy unit reaches 100m distance from AI's general unit in the alternative one.
    This is due to AI often adjusting formation in the beginning of the battle, like reforming to a certain distance during sally-out battles or even in the beginning of normal open battles.
    Stakes are currently deployed by missile units according to their place in formation, so in the middle, cav is put on flanks and it's possible it may impale on them while maneuvering under some circumstances, but that's a matter of battle files adjustment and maybe writing a script (I've been looking into that already, it may not be that easy, but it's doable).

    ad. "Can we get AI (...)" I believe the alternative script somehow answers that, actually it'd suit attacking AI too, so I'll make some amendments and release another version soon.

    Btw, I named it v0.1 only because this is the first released version, I've been testing it a lot and I've tried many scripting possibilities and these two are the most compact and reliable ones.

    Regards
    Last edited by Germanicu5; April 28, 2009 at 09:11 AM.
    SS 7.0 - The work continues

  17. #37
    Gorrrrrn's Avatar Citizen
    Join Date
    Jan 2007
    Location
    here
    Posts
    5,546

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    thanks for info!

    Look forward to testing this later this week.

  18. #38

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Wow that is really something, what you've done with the AI stakes! That's definitely going in the next RR/RC

    Very interesting that the config files are loaded before the battle too, opens the door to variable AI script selection before each battle.
    Last edited by Point Blank; April 28, 2009 at 12:02 PM.

  19. #39

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    I've never seen AI stake deployment ever in MTW2 so if you manage to succeed then hats off to you sir!
    member of S.I.N.

  20. #40
    blbrotto's Avatar Libertus
    Join Date
    Apr 2009
    Location
    Curitiba, Brazil
    Posts
    68

    Default Re: ReallyBadAI - Stainless Steel, RR/RC battle AI development and discussion

    Hi again Germanicu!

    I have some feedback to you!

    On my England campaing, the Scots are having a boring problem with the Scots militia pike...
    When the enemy militia pike is about 50~100m from you, they go to "phalanx" formation... but, too far away to engage your units quickly... causing a hole on the enemy front line.
    Ah, sometimes this unit also stop on the middle of battle, doing nothing, even if attacked with artillery

    The other thing I would like to ask, did you try the Darth Mod 1.4D? (the last one he did before he retired from Medieval II), because his mod had an interesting feature, the "forced march advance" (or something like this XD) what makes the AI to try, sometimes, forced pass into your lines... trying a break. This is nice because the battle can be more realistic, especially when the AI uses a superior or elite unit to try a forced break on an average or militia unit from you.
    Of course, this is a sugestion.. but when I played the MT2 with the Darth Mod, (before the Kingdoms be released) this behaviour of the AI was very interesting, I lost some battles too....

    Again, sorry for my english! But I'm trying to contribute with your work, ( I think so... XD)

    Keep going, great work!

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •