JESTER V 2.0 & Forthwind V 2.1

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.
Post Reply
screamingkoos
Forumer
Posts: 33
Joined: Wed Feb 05, 2020 6:27 pm

JESTER V 2.0 & Forthwind V 2.1

Post by screamingkoos »

*Please read the last post of this thread for the most recent updates for Jester & Forthwind! Thanks :) *

Hey everyone!

This is literally my first post, and I wanted to share an AI I have been working on since the HD days (on and off). I was able to learn so much about AI creation from this site over the years, and I religiously use the ScriptEd program for my Forthwind.AI. So in a way of giving back, I present to you Forthwind!

GENERAL FEATURES:

- Can play 1vs1's or in team games (utilizes pocket, or flank strategies).
- Has an array of strategies for every age. It utilizes different strategies for each age, such as scouts or eagles in feudal age, to knights or crossbows in the castle age and beyond!
- Uses most of the new units in DE as well as from previous DLC's (i.e. steppe lancers, battle elephants, condottiero and more!)
- Can play all land maps, including nomad and MegaRandom maps decently well! Mixed water maps are supported too (islands isn't efficient enough yet, and forget about migration lol).
- Responds to an array of taunts like request for resources, strategy change-up, build a market at the flared location, and more.
- Uses some userpatch features (basic ones, as I'm still learning!) This includes the AI retreating from TC arrows, towers, or castle fire (only reacts to the first one it sees until it is destroyed for some reason).
- is up to date, meaning that it supports all civs (including the new burgundians and sicilians). Forthwind can play most settings and will be updated as new updates come out.

MORE DETAILS:

Forthwind is a random map ai that uses an element of random strategies along with adaptive/reactive strategies. What this means is Forthwind will actually commit to a strategy other than archers in the feudal age, such as scouts into skirms, eagles, trush, fast castle, and more. In the castle age Forthwind will randomly select from a select number of strategies as well. All the while doing this, he will react to what strategy you are going. This could be something like prebuilding towers to counter your archers, training spearmen, skirms, and other counter units if you train alot of a certain class of unit etc. I have created the AI in this way to help keep the game interesting and not have it feel like you're NOT playing the same game every time.

Forthwind has come a long way since the HD days, and I only committed to uploading him to the other site, aok.blacksmith, once I thought he was stable enough for other people to enjoy. One large reason I committed to creating an AI was due to BRUTAL internet, as well as not so long ago I was rocking a 10 year old asus gaming laptop and it was hardly good enough for multiplayer, and I recently figured maybe other people are in the same boat as I was in! Hope people can have fun with it.

Anyway, if you'd like to know more about this ai, it's really not too shabby. In no way is it a barbarian or top tier ai like that, but I have spent hundreds of hours in creating an efficient ai that uses much less rules than those AI's. It currently can play any land or mixed water maps, including nomad and megarandom efficiently (please no migration). It is a very "new" ai, meaning it's already been updated to support the new Burgundian and Sicilian civs! This also includes support for the new maps in the recent patch as well.

Give Forthwind a try in a 1v1, or a team game! There is a readme.txt file, as well as an update.txt that includes more detailed information about Forthwind and is updated every new release! Please note this AI is ONLY tested on the Definitive Edition version of Age of Empires 2! Use other versions at your own risk.

Thanks for checking out my AI!
As always, GL HF!

;================Newest Updates:

;================*Forthwind Version 2.1 and Jester 1.1 (Released January 18, 2022):

Version 2.1 is out now! Another large update here, so please read the "update.txt" file that comes with the download for all the new details!

Hey everyone!
It's been a few months since I have provided an update for Forthwind. I have been busy so the updates will certainly be minimal after this point. I invite you to read the updates.txt file for more information on that that is attached in the zip file.

There are now 2 ai's in this download with 2 different names. To sum it up, you all know Forthwind, this ai is the same AI as it was before just with new version 2.0 updates.

Jester on the other hand is the most up-to-date version of the old "Forthwind [T]" version that I made before. This version is similar to Forthwind, but different and I didn't like the name before (Forthwind [T]), so I changed it to something new!

Currently, Jester plays somewhat differently than Forthwind, usually making wiser decisions sometimes, and is generally a little more difficult than Forthwind. I had hopes to make this like my new "go-to" ai, but lost interest in the project. So for now just think of it as the "next-generation Forthwind" :lol:

For Version 2.1 (Forthwind) and Version 1.1 (Jester) there will be a post going over the update details. Happy 1 year of Forthwind updates! :dance

Kind regards,

- ScreamingKoos
Attachments
Jester.zip
JESTER V 2.0
(127.87 KiB) Downloaded 32 times
JESTER V.1.1.zip
JESTER V 1.1
(130.45 KiB) Downloaded 345 times
FORTHWIND V.2.1.zip
FORTHWIND V 2.1
(133.82 KiB) Downloaded 390 times
Last edited by screamingkoos on Sun Nov 26, 2023 2:35 pm, edited 32 times in total.

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

Re: Forthwind.AI (Version 1.2)

Post by wattle »

Hi :)
Nice to have yet another DE AI. Maybe that could also take part in Esty's DE AI tournament when it happens.

I watched a couple games on extreme difficulty of your AI vs the Beginner AI and the DE AI.
It had some trouble with Beginners aggressive style (I'm not sure if the default Beginner does cheat on extreme).
It did hold not too bad vs the DE AI until late castle age.
While I'm not a great player, it seemed to me, that Forthwind did lure its boars mostly rather late. Sometimes at pop 27, is that intended.
Do maps influence its playstyle/early build apart from nomad start and watermaps?
It has the normal sheep killing behavior, where it kills multiple sheep under the TC. I guess it requires DUC to eat only one sheep at a time, do you have that on your list maybe?
I liked it milled the shorefish in a small pond, don't know if that is default AI behavior (I'm no AI scripter myself).
Nice to see it can handle nomad start.

Good readme, btw I wouldn't mind if you include some of the key info in your first post.

Did you consider/try to upload Forthwind as a DE AI mod, so more people may find it?

I assume you are not in the AIscripters discord, or are you? If not you may want join that, since it is more active than the forum, esp. for quick feedback. https://discord.gg/5Zea68s
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.

screamingkoos
Forumer
Posts: 33
Joined: Wed Feb 05, 2020 6:27 pm

Re: Forthwind.AI (Version 1.2)

Post by screamingkoos »

Hey Wattle,

Thanks for the feedback! AI tournaments? That would be fun! Initially Forthwind was not created to be competitive, but rather just most compatible with newer versions of the game for "semi-noob" human sort of performance. I would create maybe a seperate AI file if I ever were to submit him into a competitive AI competition.

Yes, so AI's like beginner and even the extreme DE will have no issue eventually out microing my ai, but on some maps Forthwind will never just "bug out" kind of thing (like on nomad or megarandom maps and is compatible with all civs currently now). There are many details I could include about what makes up Forthwind, I just didn't want to fill my first post with too many words lol!

Haha, yes you're not wrong for pointing out the bad boar rules. It used to have some actually pretty decent boar rules but while further testing them awhile ago I accidentally messed them up and just haven't got around to fixing them. I literally just learned what DUC (direct-unit control) was the other day so I'm quite new to some of the userpatch (UP) features. I've been slowly adding in more userpatch features for Forthwind as I test them and find they are stable enough for a release. So yes, DUC is on the list.

For the milling, yes I have it programmed currently to build a max of 2 mills. The first mill is built near a stable source of food (like berries), and a second is usually built by food that is a little further away (example: a mill near the deer on arabia-type maps). There is also an "emergency mill" rule that fires if Forthwind hasn't found any food at all and thinks he needs farms.

I'm not aware of where that is, but I will certainly look into it (about the DE AI mod).

I truly appreciate all of your feedback and for sure I'll check out the discord! Thanks wattle!

User avatar
marathon
Waheguru
Posts: 1984
Joined: Fri May 14, 2010 2:30 pm

Re: Forthwind.AI (Version 1.2)

Post by marathon »

I ran into issues with constants. I use WK (Userpatch 1.5) but the issues were unrelated.
I believe I can easily make this AI compatible with UP and WK, so that I can test it.

Welcome to the world of :head
(although you are an oldie, as it seems, but a proper welcome is imperative)

screamingkoos
Forumer
Posts: 33
Joined: Wed Feb 05, 2020 6:27 pm

Re: Forthwind.AI (Version 1.2)

Post by screamingkoos »

Oh man, the legend himself! (hint: marathon) ;)

Thanks for the welcome! I haven't played WK before but if you are able to get it up and running then by all means! For now I'm only testing Forthwind on DE as that's what I play.

(I've been around for a bit but was a fly on the wall simply observing for a long time, now I'm hoping to be more involved)

I'm very excited about the continuous :head it's what I'm here for, lol.

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

Re: Forthwind.AI (Version 1.2)

Post by wattle »

I forgot to mention, I noticed Forthwind walls at some point (not sure if always) and it can lead to hurting itself (which is ofc why many AI don't do it), but also it happend to send vills to its death, because it was stubborn to try complete its wall, while the enemy was in full charge. Also it even walled on arena, which was kinda funny :) like double wall arena 11, but that cost it many vills. At least for arena should be disabled.
I guess you use the default wall building method (like aoc/petersen AI), using UP features for defining wall and gate position is probably not too easy.

https://www.dropbox.com/s/kpuclvq3aq3vz ... d_wall.png

Btw did you base your script on something existing like the petersen AI or create it from scratch?
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.

screamingkoos
Forumer
Posts: 33
Joined: Wed Feb 05, 2020 6:27 pm

Re: Forthwind.AI (Version 1.2)

Post by screamingkoos »

Hey Wattle!

I'm not sure how to @ you (if that's possible on this site, I really don't know).

But yes Forthwind does wall, he builds on the "perimeter 2" wall (so the outer wall when compared to perimeter wall 1). There are several rules regarding when he specifically walls. For one, he walls when he senses his military is outnumbered by a decent amount. There is no timer or anything regarding these rules. For actually building the walls there are like 10 to 15 rules affecting walling. I know what you mean though by how he kills himself, it's because the wall foundation is placed and Forthwind is extremely stubborn about building it at all costs. There are a few strategic numbers that come to mind that I may change in a future update (i.e., setting dynamic values for sn-percent-building-cancellation depending on enemy strength etc) to counter this behaviour.

I know there must be a way to sense these situations (vils under attack while building a wall) and then canceling the foundations by using UP commands, I just don't know UP commands well enough yet. Once I can figure something out though (including for other buildings) I will incorporate it into Forthwind. Currently when Forthwind is under attack he "pauses" wall building, but by that time there are already 10+ wall foundation tiles placed down, so he continues heading out to them.

You're right! I need to actually change some of the wall rules too now (they are from a long time ago like a year or more lol). I'll figure out how to disable wall building on "wall maps" once I sit down and revise the rules.

Honestly I don't know who or what peterson AI is, but I built my script and files from scratch. There are certainly bits and parts that have been influenced from other AI's, but I have been working on Forthwind for over like 2 years (very casually, on and off). I started from the bottom and I'm happy I could finally share Forthwind with other people (or even AI's to fight).

Thank you Wattle for your feedback and any questions at all are more than welcome! I could go on all day about AI theory ;)

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

Re: Forthwind.AI (Version 1.2)

Post by wattle »

screamingkoos wrote:
Wed Feb 03, 2021 11:27 pm
I'm not sure how to @
I don't know either, assume it is not possible here, but on discord it is.
edit: Apparently if you quote me/someone it should send a notification.

Thx for your detailed reply and I like it walls only in specific situations. For AI vs AI it might overall be stronger to not wall, but I imagine against human player there are some that even prefer to have a walled AI.

I think the default aok/aoc AI is often here referred to as petersen AI because it's been scripted by Sandy Petersen iirc.
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
Leif Ericson
Waheguru
Posts: 1421
Joined: Wed Dec 09, 2009 8:15 pm
Location: United States

Re: Forthwind.AI (Version 1.2)

Post by Leif Ericson »

Yeah, Petersen is just the CD version AI.

For your current experience level, if you want your AI to build walls then your walling rules may make sense. Making walls with UP commands is a lot harder. You could try adding in (up-assign-builders c: stone-wall-line c: 0) whenever your AI is under attack and setting it back to a number higher than 0 when the town is safe. You can also use this to assign more than one builder to the walls. https://airef.github.io/commands/comman ... n-builders

For detecting wall maps you can simply use
#load-if-not-defined ARENA-MAP
#load-if-not-defined FORTRESS-MAP

...add walling code here

#end-if
#end-if

screamingkoos
Forumer
Posts: 33
Joined: Wed Feb 05, 2020 6:27 pm

Re: Forthwind.AI (Version 1.2)

Post by screamingkoos »

Hey Wattle,
wattle wrote:
Thu Feb 04, 2021 12:02 am
screamingkoos wrote:
Wed Feb 03, 2021 11:27 pm
I'm not sure how to @
I don't know either, assume it is not possible here, but on discord it is.
edit: Apparently if you quote me/someone it should send a notification.
Is this how you quote someone?

Yeah I agree! Forthwind does like to get stuck once in awhile with lumberjacks when the wall is between a lumbercamp and a forest. Forthwind has always originally been able to wall and I guess I kept it that way cause it's nostalgic a bit. Most AI's don't wall so I enjoy it that mine does.

OH. Haha. I had no idea that was the aok ai! To answer your question from before (does my ai use the default method) then yes it does, using perimeter wall and such, but the rules implement a few goals as checks and balances (I'm also improving them before I release version 1.3).

Hey Leif,

Thank you for your comment! Forthwind builds palisade walls and gates + stone walls and gates depending on different criteria. I am currently updating the rules so they are more clean as well I I will incorporate both of your ideas here! When I was trying to define which maps NOT to build on I was having trouble getting (map-type hideout) and (map-type hillfort) to work, so using the #LOAD-IF-NOT-DEFINED commands will be super useful.

Also I found a command called up-reset-placement. Would this command be useful for temporarily resetting the wall-class and gate-class placement? I'll run some tests, and thanks for the feedback!

Really appreciate both of your replies Wattle and Leif!

Post Reply