Smarter Orcs (a FfH II mod)

xanaqui42 any news ?
I'm waiting eagerly a stable .22 version as I don't see the point of playing against dumb AI

I've looked through the source code differences between 0.21 and 0.22; they aren't all that large, and few (if any) of them directly impact the AI. That means that the merge itself would be relatively easy to do (with luck, it would take a few days). However, there are two problems:

1) Stability. I've concluded that the fastest way to address the stability issues is with a debugger, and I've ordered the appropriate software. Unfortunately, the delivery time is dragging (at least perceptually).

2) Present source. At the moment, only 0.22d sources are released (0.22f is the present version). I'm expecting at least one more source change release (0.22g?) before the source is pretty stable.

Now, if you (or at least someone) found the original release playable, I'd be willing to do a merge between that and 0.22x (where x >=f) once said sources are available (assuming that occurs first). Otherwise, I'll work on planning for the next change or two until the debugger comes.
 
The second release is out. Note that this is a mod for FfH II version 0.21f. It is not for the present version of Fall From Heaven II. Barring the fixing of a major defect, I expect that a merge with the 0.22 code will be the next release.
 
Release 3 is out. It is for FfH II 0.22h. Let me know about any problems, particularly any stability problems, although this version seems pretty stable in local testing.

I'd like to thank Bringa :clap: for his work on the XML, in particular. The XML changes are arguably more complex than the code changes at the present time (and they were ready weeks ahead of the code).
 
Will this mod be compatible with save games, if so I can't wait to use it.
I just hope it doesn't slow down the game too much (but even if it does it may be worth it)
 
Tiny, Fractal, Warlord, Doviello

Played around 400 turns without any errors, full screen. It did start to take a few minutes on the AI turns around 300(progressive since ~100), but enjoyed the fight with Kandros. I'll probably continue this to see how the elohim do, parked across the sea. Thanks for the big undertaking, look forward to .04
 
Will this mod be compatible with save games, if so I can't wait to use it.
I just hope it doesn't slow down the game too much (but even if it does it may be worth it)

If you don't rename the folder, I think that it is compatible with save games. Warning, however: I haven't actually tried it. This probably won't be the case forever, but I'm pretty certain that we've yet to attack anything that affects saving.
 
Tiny, Fractal, Warlord, Doviello

Played around 400 turns without any errors, full screen. It did start to take a few minutes on the AI turns around 300(progressive since ~100), but enjoyed the fight with Kandros. I'll probably continue this to see how the elohim do, parked across the sea. Thanks for the big undertaking, look forward to .04

Yeah; as much as I want to work on new features, the slow-down is crimping my playtesting. Changing the hash algorithm and avoiding its usage (since even a perfect algorithm would take significant time) have both helped a bit, but I'm going to have to attack the python (which I've avoided up until now) and/or path finding (there are a few improvements to the latter in 0.03) to get the type of speed-ups I'd like.
 
It will be a few days before I'm ready to serious work on the next significant speed improvement, so I figured I'd release.

The speed improvements in this release should be noticeable, but not huge. In my very tiny sample, I perceived around a 20% or so improvement.

The feature is what I'm most excited about- in my opinion the lack of the ability to trade for mana 2+ has been a problem in FfHII for a long time. Note, however, that the AI's estimate for the value of such resources is a rough draft; it will likely undergo major changes within the next couple releases.
 
One thing you could work on, which would seriously improve their warfare abilities, is to redesign the way the AI creates groups. Cause atm, the AI groups their units into a group of X individual units, but the group acts as 1 unit. When it comes to movement at least.

So if the AI has a group containing 1 warrior and 1 hunter, and I place a worker 2 tiles away from them. They will move to that worker 1 tile at a time. They won't separate and take the worker with the hunter, since the group has 1 movement, not two.

The good things with their groups is that they seem to examine their odds on a per group basis. So they will attack if their group have a good chance to win, even if they have to sacrifice a couple of units, just like a player would/might.

But stacking different move units with each other hurts their ability to use mobile units.

The same is true with stacking a warrior with a worker for instance, that will slow the worker down. Or a hero with a worker...
 
One thing you could work on, which would seriously improve their warfare abilities, is to redesign the way the AI creates groups. Cause atm, the AI groups their units into a group of X individual units, but the group acts as 1 unit. When it comes to movement at least.

So if the AI has a group containing 1 warrior and 1 hunter, and I place a worker 2 tiles away from them. They will move to that worker 1 tile at a time. They won't separate and take the worker with the hunter, since the group has 1 movement, not two.

The good things with their groups is that they seem to examine their odds on a per group basis. So they will attack if their group have a good chance to win, even if they have to sacrifice a couple of units, just like a player would/might.

But stacking different move units with each other hurts their ability to use mobile units.

The same is true with stacking a warrior with a worker for instance, that will slow the worker down. Or a hero with a worker...

I like the ideas, and I've thrown this text onto the wiki page. I should note that implementation may be difficult- one of the advantages of groups is that since they are treated as a single "unit" much of the time, it's faster to do most calculations on them. The simplest response would be to only allow stacking of identical units with each other, but I'd tend to think that that would cause more issues than the movement problem.
 
I've weird bugs with some ressources (always incense, sometime copper for now), they aren't in my city screen when connected to my cities.

.22h with Smarter Orcs 0.04, I've a CTD at end of turn
 

Attachments

ummm , wow, jsut saw this thread and i really hope its not dead.

i am not a programmer , can kinda read some of the simpler code (soem is common sense). and have not looked at programming since i was in high school many ages ago. also never would ahve been good since i am soo dyslexic it would take a team to decrypte anything i coded.

however i would really like to put in a few points of what to me seem "simple"

you guys ahve been talking about weighting actions wether it be for researching or for combat. why must you use a solid figure?

let me give a few examples from the tech tree perspective.
--calender has value of 1000 base. if you ahve any of the resources that calander provides within cultural borders add (Number^2*10) to the weighting.
--flagged in with the leader add bonuses to weighting (sheiam add 5000 to each of the techs that head toward summoning)

let me give some examples for combat (sheiam perspective again)
-- adepts need to look into a cycle like this
1 - is there any hostile within 6-12 squares (promotion dependent).
1a - summon and stand still
2 - if no hostiles are there any nodess to be built?
2a - no more then 2 adepts shoudl ever be buildign nodes at any given time
3 - if no hostiles and no nodes needed , check cities for balance (all cities should have aroudn the same number of adepts. for a max i would work with 3 per city.
4 - is upgrading an option (do we ahve the tech and the cash?) if we have the tech but not the cash upgrading is more important then teching.

i guess what i am pointing too is that the weighting needs to be variable and bonuses and penalties to things applied by civ , leader , resourses , random numbers (example some leaders are equally well down different lines , give then several weighting options to pick from at teh beginning).
 
I've weird bugs with some ressources (always incense, sometime copper for now), they aren't in my city screen when connected to my cities.
/QUOTE]


I've seen this behavior too, but hadn't posted it because I crossed in most of Maniac's mod and haven't taken the time to research it further(couldn't say for sure it was Smarter Orcs only).

ie Copper, mining and connecting one resource before researching Bronze Working, Copper is never delivered to cities(even well after the tech was completed). Mining another copper resource, after Bronze Working was researched, netted 1 copper to cities. Same behavior resulted in separate games with only 1 copper available in them.

ion, the speed improved a great deal :goodjob:
 
ummm , wow, jsut saw this thread and i really hope its not dead.

i am not a programmer , can kinda read some of the simpler code (soem is common sense). and have not looked at programming since i was in high school many ages ago. also never would ahve been good since i am soo dyslexic it would take a team to decrypte anything i coded.
If no one else can understand your code, that's job insurance :lol:
Seriously, code is math. Teaching code as a form of math helps a lot of dysle
however i would really like to put in a few points of what to me seem "simple"

you guys ahve been talking about weighting actions wether it be for researching or for combat. why must you use a solid figure?

let me give a few examples from the tech tree perspective.
--calender has value of 1000 base. if you ahve any of the resources that calander provides within cultural borders add (Number^2*10) to the weighting.
--flagged in with the leader add bonuses to weighting (sheiam add 5000 to each of the techs that head toward summoning)
Yes; this is the sort of thing that is presently being done on the technology side. Maniac created a lot of leader and civilization-dependent base numbers for the technologies. The present code does weigh for resources, but there are several holes in the resource values alone (the worst part is the over-valuing of mana resources, but there are many other issues). Frankly, part of the problem is that the present AI code makes a number of assumptions that are valid in Vanilla Civ, but not in FfH II. The rest of the problem is that the Vanilla Civ AI is weak in many areas (and while BetterAI helps in many of those areas, there are still large gaping weaknesses).

let me give some examples for combat (sheiam perspective again)
-- adepts need to look into a cycle like this
1 - is there any hostile within 6-12 squares (promotion dependent).
1a - summon and stand still
2 - if no hostiles are there any nodess to be built?
2a - no more then 2 adepts shoudl ever be buildign nodes at any given time
3 - if no hostiles and no nodes needed , check cities for balance (all cities should have aroudn the same number of adepts. for a max i would work with 3 per city.
4 - is upgrading an option (do we ahve the tech and the cash?) if we have the tech but not the cash upgrading is more important then teching.
You are describing quite accurately roughly what a Unit AI presently looks like. The main advantage of using a weight system (multiple variables, with different weights attached) would be a speed improvement in the worst case. A secondary advantage would be that if a particular action helped it achieve two different goals, then there may be value in doing that one, rather than an action towards a single goal. Frankly, I'll have to look at it in more detail when I seriously attack the Unit AI; at the moment, I'm just trying to optimize it so that it doesn't take long stretches of time.
i guess what i am pointing too is that the weighting needs to be variable and bonuses and penalties to things applied by civ , leader , resourses , random numbers (example some leaders are equally well down different lines , give then several weighting options to pick from at teh beginning).
I agree. Of course, figuring out the exact equations, variables, and numbers is the tough part. I've started to set up a Quiz, which I hope will give me enough information to derive reasonable values.
 
I've weird bugs with some ressources (always incense, sometime copper for now), they aren't in my city screen when connected to my cities.

.22h with Smarter Orcs 0.04, I've a CTD at end of turn
I'm not reproducing the first issue with your saved game. If you have a save, which upon re-load, has this issue, I'd be happy to look at it.

The second issue I can find, and will be fixed on next release. It seems to be a defect in the BetterAI code; CvUnitAI::AI_anyAttack no longer guarantees that there is an enemy defender in the most common case of calling it, and there is no check if the defender exists before trying to use it (which causes the crash). Good catch.
 
Version 0.05 is released. It should not break save games (on 0.04) Note that it still is for FfH II 0.22h.

The main feature is the removal of the crash defect when the AI is looking at making a general attack into a city that's not defended. A minor defect injected in 0.04 having to do with multiple mana trading evaluation was also addressed.
 
I'm not reproducing the first issue with your saved game. If you have a save, which upon re-load, has this issue, I'd be happy to look at it.

The save was for the CTD, replace the Dye by Incense and remove the Copper near my capital (I've another one near a river that isn't "working").

(edit: you're fast)

Don't you think that AI doesn't have enough unit in cities (in my game a lot of cities have only one unit) ?

And do you plan to have the next release work with .23 ?
 
The save was for the CTD, replace the Dye by Incense and remove the Copper near my capital (I've another one near a river that isn't "working").
I'll look at it.
(edit: you're fast)

Don't you think that AI doesn't have enough unit in cities (in my game a lot of cities have only one unit) ?
It seems pretty good to me, but try warring on an AI; see what you think. I find them far tougher than the regular AI. My perception is that there's a far more active defense, and a lot stronger of an offense, combined with a stronger economy backing it up. Don't get me wrong- I still find them weaker than a human player, particularly once you discount the "cheats" that the AI presently gets, but the AI feels more like weak players that don't know how to use most of the FfH II features (well or at all) than utter idiots who don't know how to play.
And do you plan to have the next release work with .23 ?
Probably not. Kael does source code releases typically a week or more after the initial release, so the first 0.23 version will be in two weeks, minimum (likely longer). I hope to do another release before then, hopefully with speed and resource improvements.
 
Have you implemented jDogg5000's AIAutoplay into this? That could be nice to see how the AI play a bit.
 
Back
Top Bottom