AI preferences

PC : Turn based WW2 goodness in the mold of Panzer General. This promises to be a true classic!

Moderators: Slitherine Core, Panzer Corps Moderators, Panzer Corps Design

Post Reply

What kind of AI do you prefer?

I like 'stupid' AI and it makes me feel good fighting against its weaknesses.
2
7%
I like 'smart' AI and eventual difficulty issues should be addressed by other means.
25
93%
 
Total votes: 27

uran21
Panzer Corps Map Designer
Panzer Corps Map Designer
Posts: 2318
Joined: Thu Dec 02, 2010 8:34 pm

AI preferences

Post by uran21 »

This may seem like an odd question but from time to time I hear theory how people actually prefer week AI because they stand out more against such an opponent.
I disagree with that point of view. There is no doubt difference in AI makes difference in difficulty but difficulty itself is not primary purpose of AI. Interaction is purpose of AI.
AI is simulated behavior and as such it should be fun and challenging. Any increase in difficulty that violates rules of fun and challenge should also be avoided like constant fascination with killing of units or preventing victory by spam of numerous non varied unit types. Basis of good AI would be advanced interaction with environment and objects in it. With map and all of its terrain, with friendly and enemy units in it.
KeldorKatarn
Lieutenant Colonel - Panther D
Lieutenant Colonel - Panther D
Posts: 1294
Joined: Fri Jan 13, 2012 2:22 am

Re: AI preferences

Post by KeldorKatarn »

Well I cannot really pick one answer here because I disagree with both of them. Panzer Corps as a hexfield strategy game is as such very close to a board game. In fact it could be played as one even though the combat would be pretty tiresome to do via dice considering all the values, but possible.

In a computerized version of a board game or board game principle like chess I think the AI is the foremost way of scaling the difficulty. In fact in such a game the opponent should be 99% of where the challenge is. So I do not like dumb AI and I also don't think difficulty needs to be adressed by other means. On the contrary. Difficulty needs to be primarily adressed with AI improvement. And I mean improvement of the actual intelligence, not it cheating or getting advantages over the player.
uran21
Panzer Corps Map Designer
Panzer Corps Map Designer
Posts: 2318
Joined: Thu Dec 02, 2010 8:34 pm

Re: AI preferences

Post by uran21 »

In this case second answer could suit you because adressing difficulty is covered only for eventual difficulty issues. For example fighting against more advanced AI could mean less predeployed AI units on the map while duration of scenario stays the same.
boredatwork
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 314
Joined: Sat Jan 15, 2011 5:39 pm

Re: AI preferences

Post by boredatwork »

No vote.

For me personally this question is tied to the reform units / losing core units questions.

In the current PzC "smarter" AI is IMO a bad thing as it innevitably means higher turnover in core units.

Modified the way I suggested in the other thread (less penalty for death, but much more frequent death) then smarter AI would be a very good thing.
bebro
Slitherine
Slitherine
Posts: 4576
Joined: Sun Nov 19, 2006 12:50 pm

Re: AI preferences

Post by bebro »

IMO smarter AI is preferable in any case, because a too weak AI means a lot less replay value since everything becomes boring quickly. That being sad, I consider myself a routined player, but not an excellent one - some of the higher difficulties sometimes simply mean too much "work" for me, esp. when I have limited time for playing (note to self: maybe should do a little less modding instead ;)). That's why I'm thankful for difficulty levels and/or the option to customize them.

But even in lower difficulties I'd be annoyed soon by an AI that acts too simplistic, foreseeable or simply stupid.
Kamerer
2nd Lieutenant - Elite Panzer IVF/2
2nd Lieutenant - Elite Panzer IVF/2
Posts: 749
Joined: Wed May 02, 2012 6:27 am

Re: AI preferences

Post by Kamerer »

I appreciate a more difficult AI. I think the changes in 1.10 helped quite a bit. For example:

a) artillery fire order
b) recon movement order change

On the downside, AI infantry units now (post 1.10) seem more aggressive, and thus disregard entrenchment and terrain. They now are more quick to attack and leave terrain they would be wiser to sit in and defend - so some changes have made the game slightly easier once you learn to manipulate them. It would be nice to see in the future the AI act more "human" in regards to massing artillery, defending close terrain with infantry, and combining artillery and air-to-ground attacks.
Razz1
Panzer Corps Moderator
Panzer Corps Moderator
Posts: 3308
Joined: Tue Jan 18, 2011 4:49 am
Location: USA

Re: AI preferences

Post by Razz1 »

Artillery has not been fixed, but improved.

I see the AI firing last allot of times.
Longasc
Lieutenant Colonel - Panther D
Lieutenant Colonel - Panther D
Posts: 1255
Joined: Sat Jul 16, 2011 6:38 pm

Re: AI preferences

Post by Longasc »

So far everyone voted for "smart" AI.

Here is the issue: Even the "smarter" AI is not really THAT smart and has certain weaknesses and flaws that experienced players can predict and exploit.
So who wants really even dumber AI?
KeldorKatarn
Lieutenant Colonel - Panther D
Lieutenant Colonel - Panther D
Posts: 1294
Joined: Fri Jan 13, 2012 2:22 am

Re: AI preferences

Post by KeldorKatarn »

Well game AI is not really "AI" in the academic sense. So there is a limit to how smart it can be. it is basically just a bunch of basic algorithms to appear smart and immitate humans, but no game AI e.g. is able to truly lern. That ability can be programmed but probably takes way too much processing power to implement (or would simply not justify the cost involved). So of course it will always have weaknesses and patterns one can exploit, simply because it doesn't truly freely adjust itself.

But I guess that's where multiplayer comes in :) A true AI would be boring anyway because it would adjust very fast and make no mistake twice. Such a true AI would be nearly unbeatable.
uran21
Panzer Corps Map Designer
Panzer Corps Map Designer
Posts: 2318
Joined: Thu Dec 02, 2010 8:34 pm

Re: AI preferences

Post by uran21 »

AI constitutes part of scenario design considerations and that is why creating or significantly changing AI for already existing content has no much sense.
AI also constitutes part of difficulty considerations but in my opinion the reason why all people, those who seek for more challenge and those who seek for relaxing fun,
would like to see better AI is because it is an interactive element in the game. It is the one that reacts on players actions. It gives feedback and it is the element with which
player does communicate with even if that communication is only trough conflict. So interaction is the word IMO.
AI design considerations should place it on the hot spot between tedious and frustrating where the whole fun and challenge is.
Multiplayer undoubtedly offers more interaction and, depending on opponent, more challenge but it doesn't offer Campaign play benefits like Core force progression and this is the reason why AI is and it will stay important game design element.
ThvN
Panzer Corps Moderator
Panzer Corps Moderator
Posts: 1408
Joined: Fri Jul 06, 2012 8:55 pm

Re: AI preferences

Post by ThvN »

Long post ahead…

I agree that the AI is vitally important for the purposes of interaction and communication. Making the AI flawless might increase the difficulty but will reduce immersion I think. Making it very bad will make the game very easy and reduce immersion as well. One thing that also reduces immersion for me is predictability of the AI moves, which is more or less independent of its difficulty.

In Panzer Corps this is not as noticable because of the random combat results, but I still see some patterns emerging. In more chess-like games this pattern can be frustrating because I sometimes feel like I have to play a game by reacting and anticipating the AI ‘rules’. In Panzer Corps, I can remember one silly example of a pattern which has happened to me several times now. I’m moving troops next to an entrenched AI infantry, let’s say I put a slightly weakened infantry unit next to this strong enemy unit, but my unit is covered by an artillery unit. The artillery will help supress and prevent counterattack by the AI, and it stays put. So far, so good.

But then the weather changes next turn (rain), reducing the spotting range. The AI can only see my weakened infantry unit, an has apparantly forgotten that there was a big gun parked right behind it which has fired at it during the last turn. I’ve seen plenty of times that the AI will suddenly attack my unit, my artillery will supress/kill half of it and often the AI will not even inflict a point of strenght on my unit but get beaten badly. In clear weather, it can see my artillery, no attack, suddenly spotting gets reduced and out they come. In this case I wouldn’t mind if the AI would be given a large percentage chance to ‘remember’ the force composition next to it, to reduce the chance for such silly attacks. A human player would sometimes forget and/or gamble on an attack, but I’ve seen it happen many times against the AI.

And the AI is very poor in scouting and screening, if it cannot see anything, AI troops will embark trucks and because these trucks are faster, they will drive past their own tank support straight in front of my positions. I especially noticed this in AfrikaKorps and the new Western DLC, where the AI is more on the attack over larger distances. Another AI exploit is the ‘no airfields’ problem, where the AI will remain stationary with its air units after it loses all its airfields. I think it does this to conserve fuel, waiting for an airfield to become available? Anyway, while this may be a valid ‘conservative’ strategy, it would make sense that the AI would at least try on occasion to do something more useful with them. I am often tempted to quickly grab all airfields before pushing towards the last victory hexes, to neutralize the AI air forces.

If I am tempted to pre-empt the AI due to these patterns, this means I will end up using a different playing style vs AI than vs humans. This is not necessarily bad but too much is not a good thing. Some elements of randomness to AI behaviour are nice, or some different flavours of AI to simulate different tactical mindsets of the armies you’re facing. For example, some AI flavours prefer more airpower or tanks over artillery. Or one type of AI concentrates its attacks more than others who attack over broader fronts.

A few off-hand comments in general about a few personal experiences with modding AI:

Background info, I’ve modded the AI for a couple of old first-person shooters, which had dreadful AI out of the box (Battlefield 1942 and Battlefield Vietnam). I still play these games on LAN with a couple of my friends, mostly coop human-AI against a full AI opponent.

What is quite interesting to me is that they are a very mixed crew but their comments are not. I have been experimenting a lot, helped by the fact that they were often unaware of the changes I put in, so the feedback was not very biased at all. I started to notice some patterns, and distilled some personal ‘rules’ which I used as a guide when modding.

Rule no. 1: AI that is perceived as cheating or plays by different rules is mostly frowned upon, even if the advantage is relatively slight.

If the AI is given an ‘invisible’ advantage, people tend to notice this and assume the AI is a cheating bastard. I can fill the skies with AI planes, give them double the amount of tanks, and there will be some eyebrows raised but hostilities will resume with the usual vigour as long as there is not an overwhelming opponent.
But as soon as the AI shows any signs of supernatural abilities the complaining begins, and people feel cheated. If AI can spot targets at longer ranges than humans, remember their positions too well or shows amazing accuracy it gets noticed very quickly. Advantages of about 5-10% are already noticed sometimes.

Rule no.2: Perception and bias are more important than reality.

If you cheat on people sometimes and only in a few small areas, they will assume they are being cheated always and everywhere. When I explained some of these things to them they will usually accept, but if I updated a version to remove a small error somewhere I usually got comments like: ‘I am getting hit from further away again, did you change something again?’ Nope, but their bias was skewed because they knew it was possible/likely that things had changed. So any perceived change will trigger paranoid reactions.

Same as with the combat results in Panzer Corps, the negative deviations (more losses than predicted) are more readily noticed and remembered than the positives (better results than predicted). It’s called ‘confirmation bias’ in the psychological field.

I now often play Panzer Corps against one of my friends, and it is very noticable when messaging about the turn results, that you both feel that the other guy gets all the luck, but in reality it usually evens out, rarely are there ‘game-changing’ combat results or ‘one-sided’ battles.

When I modded AI I got the most positive feedback when the AI behaved the most human-like. I could only achieve this with some very careful cheating for the AI, but strangely this was accepted as long as the AI does not show obvious signs of using these cheats. So a few percent extra here and there actually improved immersion, but there was a lot of critisism if I went slightly too far. If I got compliments I explained what cheats I used to make the AI behave that way, and they were usually accepted because the result was to their liking. But they trusted me, which makes a big difference in their willingness to except my explanations and adjustments, an advantage that game developers often do not have.

Rule no 3.: Imperfection must be perfect, averages don’t work.

If you make AI very human-like (and therefore imperfect), people generally like it best, but if you make something very good any deviation from what the player expects gets them more upset than if the AI already was a bit wonky. Apparently lower expectations cause a higher tolerance level overall.
If I had modeled something almost perfectly this went almost unnoticed and was taken for granted, but any small flaw was picked on a lot. If a certain map already was a bit wonky, people were more tolerant overall towards these small flaws. Strange but true, so I couldn’t average out good and bad points for the overall experience, the bar is set within a certain bandwidth and anything too far below that bandwidth gets critisized, and the higher the bar is set the smaller the bandwidth of tolerance was.

So, strangely, unless something is really broken and annoying towards the player, a game with higher overal perceived quality will in my experience receive relatively more critisism than a game with a lower perceived quality. This cannot be remedied by improving things which are already very good, one must focus attention on those relatively small problems for the best overall result.

Like a luxury car with a poor radio or seats, you can better improve the radio and the seats, not add 100 horsepower and a remote control for the (still poor) radio. And then tell the customer that the car has been improved, and react surprised when the complaints seem to get even worse.

Human-like AI is good, but may require adjustments that conflict with rule no. 1. This allows for only a very small margin of error in judging how your players will react to this, so rule no. 2 and 1 create a small grey area where they overlap and conflict (rule no. 3).
If I misjudged this grey area the reactions/feedback might indicate I got it completely wrong, while some small adjustments might bring it back to universally accepted standards. I never had much trouble with this because I only made the mods for me and a few friends and feedback was usually polite, but the internet culture is a very unforgiving one which over-amplifies extreme opinions.

I think that game developers will have a harder time explaining some of these necessary adjustments, esp. seeing the recent complaints about the retreating mechanism (which Rudankort had already explained, but it took another gamer (deducter) with pictures too prove the point.) To be honest, I am very pleasantly surprised by the helpful online community here on the Panzer Corps forums, both from the developers and the users.
uran21
Panzer Corps Map Designer
Panzer Corps Map Designer
Posts: 2318
Joined: Thu Dec 02, 2010 8:34 pm

Re: AI preferences

Post by uran21 »

Thanks for sharing your experiences. It is very useful indeed.

Placing focus only on how AI should deny victory to the player or how it should make greater damage to the player and in the same time neglecting its interactive value and role can be missleading in development process. Predictability, not only, in "obviously stupid" situations can also be a result of searching for optimal solutions where one action is chosen as optimal for all situations. An example, AI can hit three units. Attacking first unit causes one point of damage but in terms of prestige it is the most expensive one. Attacking second unit causes two points of damage and it kills unit because it was understrength. Attacking third unit causes three or more points of damage and it reduces unit significantly. This is very easy solution to achieve because it takes only randomness factor on top of decision making where decision is to attack a unit if odds are favourable. What is much harder to achieve would be a decision between killing a unit and blocking the path to a unit which is about to enter last victory hex thus potentially ending scenario. Parameters that are taken into account in decision making is the hard part but even without it in the sphere of already possible realm there is much much more room for improvement when it comes to unpredictability.

Situation you described with attacking unit supported with artillery during bad weather can be applied for any situation on the edge of fog of war. Bomber is visible but escorting fighter is hidden. AI will attack bomber and suffer casualties but what it should do is "deselect" itself to observe the area first and than calculate how favourable shot is. This example is also good on showing AI with human-like characteristics. No doubt AI should use this tactic but certain percentage of randomness, like 10% or 20%, in "forgetting" about it would create human-like error.

Anyway I am of opinion that investing in areas that do not seem so attractive on the first look like AI and its interaction with terrain as precondition to its interaction with friendly units around it and finally its interaction with enemy units in terms of positioning against them would create good foundation to build upon. Without a single shot fired so far... Varied iteration sequences, combat and a little bit of memory but not for cheating would be the next step. It would be interesting to see the difference between shortest route to objective is "obviously" optimal route as well as it would be challenging creating something different.
ThvN
Panzer Corps Moderator
Panzer Corps Moderator
Posts: 1408
Joined: Fri Jul 06, 2012 8:55 pm

Re: AI preferences

Post by ThvN »

uran21 wrote:Thanks for sharing your experiences. It is very useful indeed.
You're welcome, I wasn't sure if my personal anecdotes were any good, because those are real-time first-person shooters designed for multiplay, which is as far as it can get game-wise from Panzer Corps.
Placing focus only on how AI should deny victory to the player or how it should make greater damage to the player and in the same time neglecting its interactive value and role can be missleading in development process. Predictability, not only, in "obviously stupid" situations can also be a result of searching for optimal solutions where one action is chosen as optimal for all situations. An example, AI can hit three units. Attacking first unit causes one point of damage but in terms of prestige it is the most expensive one. Attacking second unit causes two points of damage and it kills unit because it was understrength. Attacking third unit causes three or more points of damage and it reduces unit significantly. This is very easy solution to achieve because it takes only randomness factor on top of decision making where decision is to attack a unit if odds are favourable. What is much harder to achieve would be a decision between killing a unit and blocking the path to a unit which is about to enter last victory hex thus potentially ending scenario. Parameters that are taken into account in decision making is the hard part but even without it in the sphere of already possible realm there is much much more room for improvement when it comes to unpredictability.
That is a very good explanation, yes, it's relatively easy to let the AI calculate odds for single, seperate engagements but very hard to get it to execute a 'battle plan'. I'm not very experienced in the desired 'human-like' and imperfect behaviour vs. optimization strategies when programming AI, but one of the friends I play with has a degree in Artificial Intelligence, so I have a bit of experience discussing this subject. As further examples, other typical human behaviours that seem hard to replicate would be things like a 'sacrificial' attack by one or more units to gain a long-term advantage for other units, diversionary attacks to draw away enemy resources, or a premature withdrawal into a better position to contain (potential) breakthroughs.
Situation you described with attacking unit supported with artillery during bad weather can be applied for any situation on the edge of fog of war. Bomber is visible but escorting fighter is hidden. AI will attack bomber and suffer casualties but what it should do is "deselect" itself to observe the area first and than calculate how favourable shot is. This example is also good on showing AI with human-like characteristics. No doubt AI should use this tactic but certain percentage of randomness, like 10% or 20%, in "forgetting" about it would create human-like error.
Yes, good example, I recognize the situation, I always try to attach fighter escort where the AI will have the worst chance of spotting it. This 'forgetfullness' percentage of randomness can also be used to adjust the AI flavour or in other cases to adjust the difficulty. Although, as a side-remark, in the current game 'deselecting before firing' can be modded out in the gamerules.pzdat (depends on settings the modder enters), so every extra AI ability added could require a lot of extra testing or force the developers to limit those sort of player-selectable options which might complicate AI decision-making too much.

Which brings me to my other point, proper AI coding seems to require a lot of testing, and is harder to perfect than just adding extra tanks and maps to a game. So if developers have limited resources it appears to me that it is economically unattractive to spent a lot of time and money on it, if the game content is reduced too much as a result. This extra investment will pay itself back much later, because than map designers won't have to spent hours redesigning map triggers/zones or rewrite AI rules everytime a new type of unit gets introduced. But that means a game has to be economically viable first, so initially spending a lot of resources on AI optimization always seems have a worse risk/reward ratio than simply add more content.

This is the 'quality vs. quantity' argument, which ultimately depends on opinions and economics. I am a perfectionist, so I tend to go for quality, but in a lot of situations, I am a 'macro-perfectionist' where I look for the most long-term cost-effective solution for a problem. This is usually actually more dificult than just selecting the option which will give me the best quality, because the time I spent on achieving this quality will degrade my abilities to solve other problems equally well. Which is why, I think, it is easy to make AI like a perfectionist, but making the AI as a 'macro-perfectionist' will be very hard, because it will need planning/timing skills and long-term risk assesment (for example it needs to evaluate the chance of a possible weather change).

I'm not sure if it is true, but my experiences with PC games during the years give me the impression that progress towards real AI sophistication seems almost at a standstill, the biggest improvements seem that, with the increased computing powers, more advanced calculations can be made (better, faster choices when presented with more options) and being able to do that for more AI game-entities at the same time. But really sophisticated, adaptive abilities still seem far away. On the contrary, scripting the AI to make it seem clever is as popular as ever, which can produce impressive results, but only once, usually. Once again, I am not sure, it just seems that way to me.
Anyway I am of opinion that investing in areas that do not seem so attractive on the first look like AI and its interaction with terrain as precondition to its interaction with friendly units around it and finally its interaction with enemy units in terms of positioning against them would create good foundation to build upon. Without a single shot fired so far... Varied iteration sequences, combat and a little bit of memory but not for cheating would be the next step. It would be interesting to see the difference between shortest route to objective is "obviously" optimal route as well as it would be challenging creating something different.
I agree with your opinion, this would also give the AI a lot more built-in flexibility to deal with extra content or user-made maps. Without having to provide the scenario files with all kinds of different AI 'rules' for each specific situation that could occur during scenarios this would save time in the long run as map-making and unit balancing would be far easier I suspect.

About the use of terrain and routes to objectives, a nice example of that is in the final map of the latest DLC West 42-43, Volturno Line. I encountered a typical situation which could have been solved by the sort of attention to AI interaction with friendly units and terrain which you describe. On this map, Casserta (6,22) gets attacked by the AI by many units in two waves. The terrain layout around the hex is very good for defending, the AI has to cross a river, and there are swamps on the northern side. I could repeatedly stop them crossing the river with just four units, one in the city hex, one in the hex against the river, both were covered by a single artillery and the artillery was covered by anti-aircraft or a fighter.

The AI mostly entered the river hex, and stopped, did not attack because they would lose badly. They were easily destroyed, because their artillery would not move up (traffic jam), and the only problem I had was running out of ammo. They would sometimes try to cross the river one hex further away, but with the same results. The funny thing is, four hexes away, at Castel Volturo (2,25) there was a similar crossing, but although the AI captured everything around Naples, they usually would never seriously try to cross there. I could actually sent a tank over the river at that point for hit-and-run attacks on vulnerable units. There was never an attempt to flank Casserta or make a simultaneous attack on both crossings. This could be simulated by carefully placed triggers and orders, but I agree that is would be far better, and in the long term more efficient, to make the AI capable of applying these skills on its own. Then it would have attacked repeatedly in a single turn to deplete my ammo, making it possible to damage my units, or keep me occupied at the main crossing while sending fast units around the flank.
Post Reply

Return to “Panzer Corps”