Page 2 of 2

Re: Forthwind.AI (Version 1.2)

Posted: Fri Feb 05, 2021 2:12 am
by wattle
screamingkoos wrote:
Thu Feb 04, 2021 12:26 pm
Is this how you quote someone?
yes

Re: Forthwind.AI (Version 1.2)

Posted: Fri Feb 05, 2021 3:36 pm
by marathon
up-reset-placement cancels the attempt to place a building. I have no idea if it works with walls.

Your AI has some instances of double constants. Second constant overwrites the first one in DE (as CheeseOnToast told me) but in Userpatch I simply get error and I need to fix all instances.
I believe you have good reasons to track these down. Cheese said that DE has the option to create a log with AI errors, so it would be pointless for me to restart again and again in order to give you a list of double constants.

Re: Forthwind.AI (Version 1.2)

Posted: Mon Feb 08, 2021 7:39 pm
by screamingkoos
marathon wrote:
Fri Feb 05, 2021 3:36 pm

Your AI has some instances of double constants. Second constant overwrites the first one in DE (as CheeseOnToast told me) but in Userpatch I simply get error and I need to fix all instances.
Hey Marathon,
Thanks for bringing this to my attention. I would definitely like to fix this issue on my end so it isn't alot of redoing things on your end. Are there any examples you could share with me so I have a general idea what to look for in fixing the constants.per? I'm really not sure how any AI log works so I'm a bit in the dark about that in particular. If you have any reference sources you could provide I would be very grateful! Again, thanks for letting me know, and I will look into what I can do to make the AI compatible with different game versions!

Re: Forthwind.AI (Version 1.2)

Posted: Thu Feb 11, 2021 7:32 am
by marathon
I don't know how AI logging works either. Cheese implied it is a DE feature, and I don't own DE.

Since noone else volunteered, I will try to track down the double constants myself. Perhaps in a few days.

Re: Forthwind.AI (Version 1.3)

Posted: Sat Feb 20, 2021 5:56 pm
by marathon
In my attempt to help make this AI compatible with UP, I started debugging it.

Constants defined twice:
deer
REACTIVE-GATHERING
I commented out the first instance of both.


I had to load UserPatchConst.per because in Userpatch the constants are not predefined. I see that you have a set of userpatch constants, but only a small sample. scout-mirror was missing. I don't know what else was missing because I then loaded the UP per.

camp_rules.per, on line 715 I removed the disable-self because it gave rule too long error.
Later, around line 780, I split that huge rule.
Following rule (emergency mill) I split it as well.
I also splitted the three rules about mining camps at around line 900 (by now the line count has changed due to my insertions)
Same with the "Nomad No" boar hunting rule a bit below.

gathering.per, first rule, I commented out the chat line because it was one too long.
Line 1195 I split that dark age farm rule.

Now, research.per. The horse-collar rule is just gigantic lol. Your indentations are not good (imo) so I would need to pay more attention in order to split that one.

I stopped at this point. I used the 1.3 version. If you are willing to fix up until this point and then continue, perhaps with the help of someone else, I would use your AI with userpatch.

Re: Forthwind.AI (Version 1.3)

Posted: Sun Feb 21, 2021 6:07 am
by Leif Ericson
screamingkoos, In case you're not aware, WK has a limit of 16 lines/elements per rule, while DE has a limit of 32.

Re: Forthwind.AI (Version 1.3)

Posted: Mon Mar 01, 2021 9:29 pm
by screamingkoos
Leif Ericson wrote:
Sun Feb 21, 2021 6:07 am
screamingkoos, In case you're not aware, WK has a limit of 16 lines/elements per rule, while DE has a limit of 32.
marathon wrote:
Sat Feb 20, 2021 5:56 pm
In my attempt to help make this AI compatible with UP, I started debugging it.

Constants defined twice:
deer
REACTIVE-GATHERING
I commented out the first instance of both.


I had to load UserPatchConst.per because in Userpatch the constants are not predefined. I see that you have a set of userpatch constants, but only a small sample. scout-mirror was missing. I don't know what else was missing because I then loaded the UP per.

camp_rules.per, on line 715 I removed the disable-self because it gave rule too long error.
Later, around line 780, I split that huge rule.
Following rule (emergency mill) I split it as well.
I also splitted the three rules about mining camps at around line 900 (by now the line count has changed due to my insertions)
Same with the "Nomad No" boar hunting rule a bit below.

gathering.per, first rule, I commented out the chat line because it was one too long.
Line 1195 I split that dark age farm rule.

Now, research.per. The horse-collar rule is just gigantic lol. Your indentations are not good (imo) so I would need to pay more attention in order to split that one.

I stopped at this point. I used the 1.3 version. If you are willing to fix up until this point and then continue, perhaps with the help of someone else, I would use your AI with userpatch.
Thanks guys, I was not aware that this is what was causing issues for WK (as I don't have WK currently). It'll certainly take some work to go through the whole script as I know for sure there are many rules in my ai that exceed 16 lines (as well as a few repeating constants). Thanks for letting me know! as I work through my script I will split the rules up in the hopes that it will be compatible with WK.