Age of Empires II (2013)

Age of Empires II (2013)

Logbot v1.11 - Custom AI Script
76 kommentarer
Asu Maciuc 30. juni 2018 kl. 15:33 
can beat BruceForced Ai ?
Loggy  [ophavsmand] 22. dec. 2015 kl. 3:13 
This is the most recent version. I'm not really sure how well it works any more.
Johnj_es 21. dec. 2015 kl. 21:01 
please update this one for the latest aoe 2 hd forgotten patch ?
CheeseOnToast  [udvikler] 24. juli 2015 kl. 13:17 
In UserPatch its possible tho, AI's like Barbarian are able to do.transport villagers to other Islands, even on maps like Migration!
Loggy  [ophavsmand] 24. juli 2015 kl. 9:01 
That's impossible with AoE2's AI system sadly.
Ruuqo sudo rm -rf / 24. juli 2015 kl. 8:38 
Ive yet to see any AoE AI do this, but on Islands, they should know to send a few villagers to other islands to start growing more and more rapidly. This would make things far more interesting! Will be trying this AI in conjunction with BF in an FFA Islands match today
CheeseOnToast  [udvikler] 31. okt. 2014 kl. 15:31 
np Loggy <3
Loggy  [ophavsmand] 31. okt. 2014 kl. 15:30 
Weird. But then again, there are a number of things in AI and RMS scripting like that which make absolutely no sense sometimes.

I'll give it a go and see if it helps, thanks!
CheeseOnToast  [udvikler] 31. okt. 2014 kl. 15:21 
I find that (idle-farm-count == 0) breaks the farm building, (idle-farm-count < 1) doesn't.
Loggy  [ophavsmand] 31. okt. 2014 kl. 15:20 
Thanks for the farm paste by the way, it feels like everyone's farm building is more complicated than mine [pastebin.com]...
Loggy  [ophavsmand] 31. okt. 2014 kl. 15:15 
Watch towers have been notoriously buggy ever since the game's release. There's no way to accurately count them, watch-tower-line is bugged and guard-tower and keep don't work. In the end i just attached the build command to my minute timer.

If you want to see how broken it is now (apparently it was this way in AoK even) make a scenario and a test script to try counting them using various values. I gave up trying in the end, and instead rely on their arrows and up-get-threat-data to see what's attacking me.
CheeseOnToast  [udvikler] 31. okt. 2014 kl. 14:04 
I've noticed this issue with BruteForce and the current new AI can't detect game modes correctly. (for example, Wonder Race) and BruteForce likes to get stuck when using escrow resources and spams towers cus it thinks (up-pending-objects c: watch-tower < 1) is always 0 so I had to remove it.


Your farm issue sounds more like a scripting issue indeed, my AI no longer does it.
http://pastebin.com/tKcckvLp prehaps this might be insightful.
Loggy  [ophavsmand] 31. okt. 2014 kl. 9:39 
Hmm. I haven't ever noticed anything going wrong with that, actually.

The only peculiarities I've seen has been my resource counter producing negative values for one pass, but I think that happened whenever it freed escrow which messes stuff up.

Only other time I can think about this is the mysterious case of the farm-sticking where the AI suddenly forgets how to build farms until they are all gone (but I added a rule to delete them with excess wood). Then again, I have never observed the default AI suffer from this so it's probably something I'm doing rather than an engine issue.
CheeseOnToast  [udvikler] 31. okt. 2014 kl. 7:17 
It also returns false values, say for example (building-type-count-total wonder >= 1) (even if it didn't have a wonder it would still set the value as 1) and (up-pending-objects c: house < 1) returns false values too which means some buildings don't build at all as that's set to 1. It's a weird bug but the devs are looking into solving the issue, I believe no cause has been found yet, it's quite irratating. I'm sure this includes (unit-type-count-total) values and such.
Loggy  [ophavsmand] 31. okt. 2014 kl. 3:49 
Hmm, I just saw your post on the Resonance4g. I haven't actually noticed this, but I have a lot of layers of indirection in my stuff: I tend to set something up that reads real quantities into goals and then just do comparisons on that for a fair number of things.

I haven't seen anything flat out fail to work correctly in that respect. The stuff I know that's messed up with the AI engine is...

- (up-remaining-boar-amount) is both == 0 and != 0 when there is no active lure.
- Using g:> and s:<= etc instead of normal comparison operators with non-up functions causes undefined behaviour. It seems to follow no pattern about whether it's true or false and randomly switches. Saying that, I haven't tried for a couple of patches and the default AI uses it so it might be worth giving it a go again.
- up-chat-data-to-self prints weird characters if you use "Some value: %d%" and the like.
Loggy  [ophavsmand] 31. okt. 2014 kl. 2:45 
What is the 3.8 AI bug? I know that something was going around, but beyond the freezing units (which I have yet to see) I haven't noticed anything playing up. I'm happy about the spectator fix though.

I've seen people commenting on the fact that the AI can't detect certain things, but nobody's actually posted any specifics anywhere as far as I know.
CheeseOnToast  [udvikler] 30. okt. 2014 kl. 20:19 
Also, are you aware of the 3.8 AI bug?
CheeseOnToast  [udvikler] 30. okt. 2014 kl. 18:52 
That's great :P
Loggy  [ophavsmand] 30. okt. 2014 kl. 16:57 
After watching Logbot be destroyed so many times, this is so sweet. But if promisory advances a couple of minutes faster then it can't keep up with villagers as its percentages are all over the place. Ah well, I seem to have actually made some progress!
CheeseOnToast  [udvikler] 30. okt. 2014 kl. 16:41 
That really sucks, but all part of making a good AI :P
Loggy  [ophavsmand] 30. okt. 2014 kl. 16:35 
Turned it up to double and it seems to have helped quite a bit. I'll need to try a few more times tomorrow though, and no doubt rebalance all my gatherer percentages again...
Loggy  [ophavsmand] 30. okt. 2014 kl. 16:27 
When compared with the default AI, villager numbers are maybe a tiny bit behind. But regardless of deaths due to boar luring, resource counts are more or less equal until ~20 mins.

Time to explore the avenue of having loads of lumber camps...
CheeseOnToast  [udvikler] 30. okt. 2014 kl. 16:04 
It's not losing villagers for silly reasons is it? like failed boar luring? villagers getting stuck on resources or bad scouting?
Loggy  [ophavsmand] 30. okt. 2014 kl. 14:46 
Still as stumped as I was over a week ago. I've tried all sorts of of things, I just can't seem to figure out how it's done, and trying to survive whilst being a few thousand resources behind isn't exactly possible.
Loggy  [ophavsmand] 21. okt. 2014 kl. 15:05 
The default AI seems to gather resources 5-10% faster than Logbot once reaching Castle. I still can't figure out why. Similar villager counts, research progress... Dropoff distances don't look remarkably different, either.
Loggy  [ophavsmand] 19. okt. 2014 kl. 15:17 
Update: I'm starting to find it difficult to track down the reasons why I'm falling behind the standard AI. For the strategies I've made Logbot can at least put up some kind of fight on hardest, but I still have to dabble in water maps and add difficulty levels... and it still loses most of the time.

(I'm tempted to forget water maps for the moment, and may leave that bit out at least for a first version)
CheeseOnToast  [udvikler] 25. sep. 2014 kl. 15:57 
Adding (up-retask-gatherers food c: 5) before or after (in userpatch version before works) (up-request-hunters c: 5) should make it more certain to add more hunters.
Loggy  [ophavsmand] 25. sep. 2014 kl. 15:51 
Sure enough, (up-request hunters c: 5) helps a lot.
Loggy  [ophavsmand] 25. sep. 2014 kl. 15:47 
The game seems to ignore sn-minimum-number-hunters when adding the hunt group, or rather it won't retask villagers to it as per the usual retask limit. Maybe that's what up-request-hunters is for...

I'll have a little play around and see if I can find something less harmful to my poor little villagers' health. Thanks!
CheeseOnToast  [udvikler] 25. sep. 2014 kl. 15:39 
Well I noticed when the AI sometimes garrisons villagers into the TC, It doesn't continue the boar hunt with that villager, instead it assigns it to something else, the extra boar hunter villagers seem to not garrison at all to protect themselves ending up in death. I'm pretty sure it would happen on 2.0 speeds too.
Loggy  [ophavsmand] 25. sep. 2014 kl. 15:28 
I've never seen it lose quite that many before - though it's something I'm keeping an eye on. I'm not sure whether it's a product of running at 8x speed or whether assigning more lurers/hunters would help it.
CheeseOnToast  [udvikler] 25. sep. 2014 kl. 15:19 
I think it lost around 3 villagers on that lure which hurt it's dark age eco, assigning some extra boar lurers might be beneficial. This isn't a final planned strategy is it?
Loggy  [ophavsmand] 25. sep. 2014 kl. 14:55 
Logbot is getting there - I'm relatively happy with this [puu.sh] game, but its slow castling and resigning in particular still need attention it seems...
Loggy  [ophavsmand] 24. sep. 2014 kl. 14:36 
Well, it's here, and nothing exciting except the spectator command fixes. I'm not much further forward, and honestly not sure I'm going to be as real life is going to pick up in a few days...
Loggy  [ophavsmand] 21. sep. 2014 kl. 2:01 
Depends what they're going to add. If it's anything like the last smaller updates then they might enable a few new SNs and that's all there really is to change.

It's questionable whether I'll actually be ready to put anything on the workshop by then anyway...
CheeseOnToast  [udvikler] 20. sep. 2014 kl. 12:32 
Loggy, patch 3.8 is coming soon, maybe you should wait till then?
Loggy  [ophavsmand] 20. sep. 2014 kl. 12:27 
I currently have a flushing Britons strategy which can put up a fight with the current hardest AI without cheating, but it can't handle water maps yet. I'm thinking of refining my fast castling strategy until I have something which can compete with the standard AI on land maps only and putting that up on the workshop sometime.

Compared to the standard AI, Logbot should offer far better adaptive tendancies. Or at least, I hope so!
I quit. Peace. 20. sep. 2014 kl. 6:44 
Compared to the new standard AI computer, bruteforce and resonance bot, all on hardest, logbot is the lowest in skill. Still it's pretty good, but I hope you can better it.
Fion 1. sep. 2014 kl. 17:37 
This is definitely way more better then Bruteforce. This AI is far the best I have seen!
CheeseOnToast  [udvikler] 27. aug. 2014 kl. 11:42 
That's awesome news, great to see that LogBot is still alive :)
Loggy  [ophavsmand] 26. aug. 2014 kl. 14:11 
A little update: I'm still working on it, though I've taken quite some time away from scripting as I simply haven't felt like doing anything with it. I'm now more or less at the stage where I have one strategy that can compete with the normal AI on hardest and it doesn't cheat.

I'm definitely a lot further ahead than this version, but I'm not ready to release anything just yet!
DragonMaster8011 7. juli 2014 kl. 6:55 
mind if I add you as a friend ?
Loggy  [ophavsmand] 7. juli 2014 kl. 6:54 
I don't know anything about AoE3 AI scripting, but seeing as they're so different they are almost certainly incompatible.

I'm not sure whether it's possible to create an AI that would assist a human, as the AI tends to task anything you try to move away rather quickly. You'd probably have to fight over the game for control of your units at times, and you'd have no control over where it decided to build things, but aside from that you could create units and maybe direct them without too many problems.
DragonMaster8011 7. juli 2014 kl. 6:46 
Or if it's possible , can AoE III's AI ( where you don't have to build lumber camps or mining camps and farms ) be used in AoE II ?
DragonMaster8011 7. juli 2014 kl. 6:41 
I would like to focus on building my military instead of having to micro-manage everything all at once , 5 per resource is enouph to me , that way it leaves room for a larger army to desimate my foes !
Loggy  [ophavsmand] 5. juli 2014 kl. 8:20 
That seems wrong. Its wonder race was terrible when I was testing it.
I quit. Peace. 5. juli 2014 kl. 8:03 
Funny, Logbot was the fastest in a Wonder race.
Loggy  [ophavsmand] 5. juli 2014 kl. 6:33 
What do you mean?

If you want an AI that only builds houses and gathers, it's pretty straightforward. But it's difficult to determine how many villagers to task on each resource if you have no strategy in mind.
DragonMaster8011 4. juli 2014 kl. 9:49 
can you reccomend any AI's that make the villagers auto build homes and resources ?
Loggy  [ophavsmand] 30. juni 2014 kl. 15:10 
Logbot is getting closer...

Slowly.