MangudAI-all-in

Upload your latest creations here.
Please note that by posting comments to posts in this forum you forfeit your personal copyright on whatever you post. AI Scripters reserves the right to re-use objective comments in script reviews without requiring the posting author's permission. Credit, where appropriate will be given in such cases.
Bandit1990
Swami
Posts: 103
Joined: Tue May 03, 2022 2:38 am

Re: MangudAI-all-in

Post by Bandit1990 »

Hi Wattle,

It’s a cool concept, as a player I really under-utilise Mangudai so it’s interesting seeing what they can do :)

I suspect what happened was Bambi destroyed an existing blacksmith or market - MangudAI had just reached castle but it never built more despite having the resources. I think in that game the space had been used up so I don’t think town size needs to change, it was doing just fine :)

Maybe add a rule of something like this?

(Defrule
(up-research-status c: castle-age >= research-pending)
(Dropsite-min-distance-stone > 3)
(Building-type-count-total mining-camp < 10)
(can-build mining-camp)
=>
(build mining-camp)
)

/apologies for the mixed caps, typing on phone and autocorrect is kicking in :p

You would then have a backup so that as long as you’ve clicked up you can go back to mining stone without fear of being stuck in feudal. To be fair this may have been a rare occasion but I hope it helps.

Thanks, I’ve got time to work on Bright Spark over this week so hoping to make some big changes that I’ve wanted to make for a while and not had the time.

Look forward to seeing what comes next for MangudAI once you get time and I’m always happy to do tests if you need :)

User avatar
wattle
Swami
Posts: 218
Joined: Fri Aug 15, 2014 1:06 pm
Location: Germany

Re: MangudAI-all-in

Post by wattle »

Thanks for the reply, that case wasn't considered by my logic :lol:
Will be added.
I wish it had Immortals quick-wall skills and defensive capabilities to survive better under feudal pressure, but TheMaximalBeing hasn't made an easy to implement snippet for those yet, so I blame partly him :lol:
MangudAI-all-in (wip, to be continued, when I retire from work :P )
Btw, thank you s64 for your effort. Was a pleasure to cross your way. Have a good time.

User avatar
MrElephant
Swami
Posts: 125
Joined: Sun Dec 20, 2020 6:28 am

Re: MangudAI-all-in

Post by MrElephant »

Wattle,

I know you already have seen this post, but it may be time for you to revisit- and think about including in your script.

viewtopic.php?f=3&t=3515
Author of Charon, Reactionary, Ahulane, and BlackKnight!

User avatar
wattle
Swami
Posts: 218
Joined: Fri Aug 15, 2014 1:06 pm
Location: Germany

Re: MangudAI-all-in

Post by wattle »

MrElephant wrote:
Tue Aug 23, 2022 2:03 pm
Wattle,

I know you already have seen this post, but it may be time for you to revisit- and think about including in your script.

viewtopic.php?f=3&t=3515
Yes its been a while. Indeed, quick-walling would be a great feature. I don't think I'm there yet, knowledge wise, but hopefully I can include that someday. Still trying to look into rather basic things at the weekend when I have time.

One rather simple issue, that I would like to change amongst others, a more compact base with the castle near by. Atm it builds the castle rather forward. I know there is up-build with placement type and build-line, but havent looked enough into how that works exactly.
Also getting more familiar with goals.

I would say, the list of todos and would-like-to-know/understand keeps growing at a faster pace than I can takle.
MangudAI-all-in (wip, to be continued, when I retire from work :P )
Btw, thank you s64 for your effort. Was a pleasure to cross your way. Have a good time.

User avatar
wattle
Swami
Posts: 218
Joined: Fri Aug 15, 2014 1:06 pm
Location: Germany

Re: MangudAI-all-in

Post by wattle »

Update 0.3
• added FireBalls deer luring (haven't veryfied/thought through in detail if some code could interfere with the boarhunting)
Thank you so much :rolleyes:
• Added/fixed up-build place-control:
  - Castles should now be placed in front of and near to TC as intended
  - Other buildings should be placed near to TC, siege workshop in front of the castle
• limited farm building to save wood for other buildings, when already up and use idle-farm-count = 0 for now, to prevent too many farms early on
   this also seems to help forcing some food gatherers to berries earlier
• adjusted some gathering percentages and dropsite rules, for ideally quicker or more reliable fc
• increased camp-size in imp, to gather further away resources in late game
• Changed TSA somewhat. The way it was before didn't completely make sense to me, now that I tried to fully understand what it does.
   Still needs better coordination with the Mangudai attack/retreat
• first 2 houses should be building right at once
• should create rams more reliably, by checking for higher wood-count when training Mangudais, esp. when enemy-building-in-town
• sn-allow-adjacent-dropsites 1 for LC (can be good to not replace LC as fast, or bad because of vill blocking)
• sn-disable-builder-assistance 1 (not sure, but can't see atm why assistance from other builders would be beneficial)

There could still a lot be done, but I think the change and hopefully improvement is big enough for an update. Maybe someone likes to test if there are some issues other than those listed in the script.
I like quite a bit the build-order, considering there is no duc involved. It think it mostly manages to go up to castle with 26+2 or +3 vills and drop the castle pretty much immediately.
Attachments
MangudAI-all-in_0.3.zip
(35.32 KiB) Downloaded 367 times
Last edited by wattle on Tue Aug 29, 2023 2:51 pm, edited 1 time in total.
MangudAI-all-in (wip, to be continued, when I retire from work :P )
Btw, thank you s64 for your effort. Was a pleasure to cross your way. Have a good time.

GamesGod
Swami
Posts: 118
Joined: Fri May 20, 2016 4:01 am
Location: Russia

Re: MangudAI-all-in

Post by GamesGod »

Good news :)
Developer of GamesGod AI

Bandit1990
Swami
Posts: 103
Joined: Tue May 03, 2022 2:38 am

Re: MangudAI-all-in

Post by Bandit1990 »

Hi wattle,

Great update! It's good seeing MangudAI continuing to evolve.

First look is that it seems a lot smoother aging up and I'm not sure which change has done this, but it is more resilient in feudal age as well - Bright Spark has had its butt kicked a couple of times because MangudAI has been able to absorb an early M@A rush and then pick a whole group off with a couple of mangudai with that micro. Once MangudAI raids it's basically GG XD.

Well done! Thank you for the hard work! :)

User avatar
wattle
Swami
Posts: 218
Joined: Fri Aug 15, 2014 1:06 pm
Location: Germany

Re: MangudAI-all-in

Post by wattle »

Update 0.3a
• prevent the mangudais from shooting at walls and gates
• make the mangudais shoot wolfs
• doesn't set dificulty-parameter anymore, since apparently that messes with the Mangudai ranged micro code by FireBall
• changed the general starting attack system (which is meant for the rams) to attack-now instead of TSA, since the TSA interfered with the Mangudai-micro I believe
   change to TSA once it reaches more than 30 Mangudais and Mangudai-micro is disabled
   (it seems to me that I liked the TSA-rams better, esp. vs walls. Needs testing and probably optimization/change)
• changed mangudai/ram-production rules to hopefully better ensure a good mangudai/ram-ratio aka more reliable ram training
   -> needs testing, I'm not sure if it works as intended
• drop forward castles on arena
• stop at 29 vills to click up faster/more reliably to castle
• added (dropsite-min-distance wood/gold/stone < 255) to prevent dropsite spam in late game
   -> needs testing, could still happen if no res found in current camp-size area!

As before, it can't really handle a flush and its doomed if the forward castle on arena gets denied.
Attachments
MangudAI-all-in_0.3a.zip
(38.64 KiB) Downloaded 348 times
Last edited by wattle on Sun Aug 06, 2023 4:53 am, edited 2 times in total.
MangudAI-all-in (wip, to be continued, when I retire from work :P )
Btw, thank you s64 for your effort. Was a pleasure to cross your way. Have a good time.

spadetwo
Forumer
Posts: 7
Joined: Tue Jul 19, 2022 5:11 am

Re: MangudAI-all-in

Post by spadetwo »

Hi!
During my testing with DE AI, I found some features to be optimized.
  • It's really weak when stones are forward. When flush is coming, the game is almost over. So maybe building some towers to protect forward mining camps would work.
  • Ballistics and chemistry are important for Mangudais.
  • When opponent spam skirmishers, it's really hard to deal with only Mangudais.
  • Diving into a firing TC is a fatal problem.

User avatar
wattle
Swami
Posts: 218
Joined: Fri Aug 15, 2014 1:06 pm
Location: Germany

Re: MangudAI-all-in

Post by wattle »

spadetwo wrote:
Mon Sep 12, 2022 1:50 am
Thank you for your feedback :)
I agree its weak when dropsites are forward or exposed and weak vs flush in general. It has no real defense. If the castle doesn't go up, its pretty much over. The gather percentages for stone and in general are pretty hardcoded.
I thought about towers and now that I'm aware of up-build place-control that might be even relatively easy and somewhat effective be implemented.
On the other hand it would delay the mangudai rush. Ideally it would detect an enemy flush or pressure, but I'm not there yet.
Ideally I would learn more about DUC and than take rather precise measures against flush or preasure. Favor back dropsites for example, maybe even wall a bit with palisades. That could be in some cases sufficient to get the Mangudai-rush rolling.

I agree with Ballistics and this is definitely not optimized. The pieces of escrow use are not really set up in an optimal way and I am looking into how I can ensure intended priories to gather and spent the resources, but I'm not sure when I will be able to learn and think that through to change that.

I'm aware that skirms are hard to deal for Mangudais when its somewhat equal. Usual strategies would add light cav vs them esp with mongols. How ever in my own play I dislike using them and go for all out micro. I believe in the Mangudai-all-in-strategy to be at least decent in many cases and would rather like to optimize it so far, that it can handle many situations. That being said if a top AI, let alone pro human, goes all for a counter to that strategy, it wont stand a chance pretty sure.

This AI uses the RangedMicro snippet by Fireball, which I appreciate a lot, since I don't know when or if I will be able to script such duc micro myself.
It allows to reduce the distance to TC when to retreat and I think it can be beneficial if the Mangudais are not too scared of the TC, since they otherwise won't make any progress. Ofc its bad to get shot, but its also bad if the group constantly retreats from TC and doesn't get forward nor disturb the enemy eco.
I noticed however it likes to dive towards the TC (and maybe that is what you meant) and retreat without shooting at all, multiple times. Which is surely not optimal, but I'm not sure when I will be able to look into and understand that part of code enough to change it for a better.
Ideally I would like it to also consider if a TC or Tower is garrisoned or not, but same, not sure when I will know enough about that.
MangudAI-all-in (wip, to be continued, when I retire from work :P )
Btw, thank you s64 for your effort. Was a pleasure to cross your way. Have a good time.

Post Reply