Jump to content

Is the AI already playing the game in Real-Time in CM1?


SteveP

Recommended Posts

Steve, much of this can be explained away by the AI using covered arcs. You say you're sure there are no arcs, but I'm not. Your examples of AI behavior are textbook examples of covered arcs in action. Now, without word from BFC, we can't really know, but I think you're dismissing arcs to quickly. On what basis are you doing this?

Link to comment
Share on other sites

Originally posted by juan_gigante:

Steve, much of this can be explained away by the AI using covered arcs. You say you're sure there are no arcs, but I'm not. Your examples of AI behavior are textbook examples of covered arcs in action. Now, without word from BFC, we can't really know, but I think you're dismissing arcs to quickly. On what basis are you doing this?

Two ways: one is deductive, the other is inductive (I hope I've got that right. It's been awhile since I studied these things. ;) ) Also a heavy dose of Ockham's Razor.

First, consider the difficulty of programming the AI to figure out when to use covered arcs and in what manner. Do you extend them a full 180 degrees or less (or more for that matter)? Do you extend them all the way across open terrain or something less (or more). On what criteria would the AI decide to use a covered arc one time and choose not to use it in exactly the same situation another? Just think of all the factors you consider when deciding to use a covered arc. The fact is that the OpsAI/StratAI are not state-of-the-art. BFC has acknowledged that they only created enough there to give us an opponent that could do the basic things. After all, if they couldn't program the AI to use indirect fire from onboard mortars, how could they have programmed it to properly use covered arcs? I don't believe the AI ever used ambush markers in CMBO, and that would certainly have been easier to program than covered arcs.

Moreover, BFC designed the TacAI to be the module primarily (even exclusively except for that damned Hide command) responsible for deciding when to open fire. A covered arc, like the Hide command, preempts the TacAI. Although they apparently programmed the OpsAI to give all units a Hide command at the beginning of the game (heaven only knows why :D ), the OpsAI does not give its units a Hide command later in the game after they've come out of hiding. Therefore, it was clear that they only intended this preemption at the beginning of the game. I can't think of any reason why they would have the OpsAI routinely and frequently preempt the TacAI with covered arcs, even if they could program it to do so.

Finally, on this point, if they programmed the OpsAI to use covered arcs, it would have to be in some reasonably consistent and predictable way. Virtually everything the OpsAI and StratAI does follows this pattern.

Which leads me to my tests. I've already mentioned one of them: running a green platoon across 100m of open terrain into a trench manned by a crack HMG. Most of the time, the MG never opened fire until the squads were right in the trench with them. When it did open fire, the point at which is opened fire varied significantly -- from the moment the squads left cover to a point halfway across the open terrain. So why did it choose to use a covered arc sometimes and not most of the time or all of the time? When it did choose to set a covered arc, why set it at the edge of the cover one time and in the middle of the open area another?

Even humans don't tend to have this kind of variability (unless they are trying to outfox an opponent they've played before -- but this kind of deviousness is beyond the AI). I think they tend to use covered arcs in some fairly standardized way. So would the AI.

You may want to believe that BFC has in fact created a very sophisticated AI decision-making capability (and if they did, why are we all complaining about how badly it does so many things) and/or that they introduced some inexplicable randomness into the decision-making in order to keep players off balance -- while at the same time making sure the AI still functioned in a way that didn't produce outlandish results (instead of being merely clueless smile.gif ). But Ockham's razor tells me that the simplest explanation is that the AI plays in RT.

My question would be: why resist the idea? Just because BFC never admitted that the AI plays in RT doesn't mean anything. No one asked them before. :D

Link to comment
Share on other sites

Thanks for the AI lesson there Steve, but you still haven't sold me. And come on, do you really beleive the Tac AI is the way to go in first turn defensive battles. That is what you were implying right. That using coverd arcs in the open, outside of cover is a worse move then letting the TacAI open fire anytime the unit is spotted, no matter what cover or range the enemy is at. Since I never said always, "over use", your term, is not a problem. In fact, my opinion is "under use" is more prevelent. But that is why they gave the human player choice so each can play the way he wants.

As far as AI play goes, I still contend that trying to compare AI behaviour in a single player game and the TacAI of any two player game has no practical importance. I could be wrong and if so I will stand corrected.

You contend that I am naive as to how AI play works. Maybe so. The more I think about it the more I want to stay that way. I enjoy the game and AI play is the biggest part of that. Because of my profession I can only manage a few two player games. And if thinking the AI is playing better then it is, RT or not, gives me more enjoyment; GOOD. So I will leave this at that only to say. AI functionality for me: Ignorance is Bliss.

Link to comment
Share on other sites

Hey SteveP.....maybe the AI is just picking on you!? And if the AI is playing in real time, it is either a)you are really kicking its butt and needs a little help or b)you beat it soo much that it plays in RT to try and make it a little even! In my case it doesn't have to because Im getting smeared all over the map most of the time.

Link to comment
Share on other sites

That using coverd arcs in the open, outside of cover is a worse move then letting the TacAI open fire anytime the unit is spotted, no matter what cover or range the enemy is at
Yes that is pretty much what I am saying. What you are doing when using covered arcs that way is sub-optimizing the performance of your troops, at least most of the time. You seem to think that the TacAI will open fire indiscriminately whenever it sees an enemy unit, no matter what the range or cover the enemy unit is in. A little testing will show you that this is not the case. The TacAI only opens fire when calculations show that the probability of causing some damage to the enemy unit is above some threshold value that's embedded in the code (and keep in mind that the people who put that value in there are the same ones who decided what values would be effective or not when they designed the game). One of the advantages that the TacAI has, is that it is doing these calculations constantly, in Real Time as the enemy moves around within one of your unit's LOS.

Now, let's suppose that I have, through my own calculations and intuition, decided that my HMG's fire is suitably effective out to 400m, and I set a covered arc accordingly. A juicy enemy infantry squad advances to 401m away. My MG doesn't open fire, even though the probability of doing damage to the enemy squad is virtually the same at 401m as at 400m. Even worse, I can't change my mind and open fire at that unit until the next turn. The covered arc hasn't given you any benefit -- unless it is from the feeling that you are in control and not some faceless computer program. :D

I used to use covered arcs for all my units as a standard procedure, until I figured out the above. One of things that I try to remind myself is that the covered arc command was first and foremost a replacement for the old Ambush command in CMBO. I do use covered arcs for other purposes than ambushing, but usually to offset a known quirk in the TacAI's behavior. An example would be giving arcs to units that have a move to contact order. The TacAI has a very expansive definition of "contact" and I find that the arcs tend to keep my units in motion until they have a real contact. Also I regard overwatch as the Attacker's version of ambushing, so I will often use arcs for them.

You contend that I am naive as to how AI play works. Maybe so. The more I think about it the more I want to stay that way. I enjoy the game and AI play is the biggest part of that. Because of my profession I can only manage a few two player games. And if thinking the AI is playing better then it is, RT or not, gives me more enjoyment; GOOD. So I will leave this at that only to say. AI functionality for me: Ignorance is Bliss.

Absolutely! You own the game. How you play it is entirely up to you and your personal taste. This thread was primarily aimed at CMers who are interested in "what's under the hood" as it were, and you may be wise to recognize that you are not among them at this point. smile.gif
Link to comment
Share on other sites

Originally posted by kawaiku:

Hey SteveP.....maybe the AI is just picking on you!? And if the AI is playing in real time, it is either a)you are really kicking its butt and needs a little help or b)you beat it soo much that it plays in RT to try and make it a little even! In my case it doesn't have to because Im getting smeared all over the map most of the time.

Yeah, while I didn't think it was picking on me, I did (as I mentioned in another post) actually think my system was broken -- which amounts to a nasty AI trick in my book. :D It was actually the behavior caused by the Hide command and another behavior (the fact that the AI is exempt from command delay) that made me think this. I ended up spending a lot of time before I figured out that BFC hadn't been (how shall I put this?) thoroughly comprehensive when addressing the question of whether the AI played the game differently than we do.

In any event, the programming for the TacAI is IMHO impressive, and obviously the pride and joy of its designers. To the extent that you are playing a scenario or QB in which the OpsAI and StratAI aren't doing much of anything, the computer can be a pretty satisfying opponent. That's why the AI is stronger when on defense, because the only thing the OpsAI and StratAI do is orient the units in the direction of the enemy and -- and this often proves to be a stupid AI trick -- "organize" a counterattack when it loses control of a flag. When the computer is the attacker or it's a meeting engagement, the OpsAI and StratAI have a lot more to do, and things can break down pretty quickly -- especially if the AI's side has a lot of ground they have to advance across before the actual combat starts.

Link to comment
Share on other sites

One of the things I’ve been trying to figure out is why the AI is designed to give an automatic Hide command to its units when on defense. My first theory was that when they were designing CMBO, Steve and Charles thought this would be more or less SOP for everyone playing the game (the text in the user manuals suggests that), and they wanted as much as possible for the AI to be following “good” tactics.

However, I now have a different theory that I like better. It goes something like this:

One day, Steve and Charles are discussing the problem of making the AI into a satisfying opponent.

“You know,” says Steve, “the Ambush command is one of the best game play features we’ve come up with, but unless we get the AI to use it, players are going to feel like there’s not much excitement for them in the game.”

“Of course,” says Charles, “but you know I’ve tried everything I could think of in the way of an algorithm that would get the AI to use that command in some reasonably sensible and consistent way. I could spend the next ten years doing that, and I might never get it to work.”

“No, no, that’s no good. We have to eat, after all. What we need is something that will feel like being ambushed to the player, without actually making the AI use the Ambush command,” Steve says. “How about this? Suppose we have the AI automatically Hide its units when on defense. Then when they do start firing, it will seem like the fire came out of nowhere.”

Charles shakes his head. “Won’t work. The AI is programmed to unHide any units as soon as they have LOF to an enemy, so that the TacAI can evaluate whether or not to fire. And since the AI is playing in Real Time …”

“Shhh,” says Steve, looking around the room. “I’ve told you never to say that. You know how paranoid gamers are. As soon as they find out that the AI is playing in you-know-what, we’ll get all sorts of complaints about how the AI is cheating and every other kind of nonsense.”

“Alright, already. Don’t be such a nag about it. I was just going to say that because the AI is playing in you-know-what, the AI will give the unHide command immediately every time. The effect would be no different than if the AI hadn’t given the Hide command in the first place.”

Silence settles on the room, as the two ponder this dilemma. Then Steve says, “I’ve got it. The Hide command would be given only once during a battle, at the very beginning. Therefore, the unHide command is given only once. What if we put a random factor – a big one – into the rule that the AI uses to trigger an unHide order. Then the first time a player comes into LOF of AI units, there will be lot of unpredictability in the way that the AI appears to respond. Players will jump to the conclusion that the AI is setting ambushes.”

Charles nods. “I like it. It won’t matter that the AI is reacting sometimes in ways that don’t make a lot of sense tactically, because the players won’t realize it and it will only happen once in a battle.”

Steve nods too, looking particularly satisfied. “Yeah. I bet it will be years before anyone comes along who figures out what’s really going on.” After that the two return to haggling over the unresolved issue of how best to split the enormous profits from the game, once it’s published.

The End.

Link to comment
Share on other sites

SteveP: I don't have time for testing, I just play the game. But I know that the TacAI does not always pick the appropriate target. It seems to pick the easiest, like say a panicked truck behind your juicy squad, etc.

And as far as your HMG example, there are alot of variables left out, but I can think of many benefits. Perhaps the greatest is to be in control. I mean why else do you play the game. You could just watch someone's movie. One more. By not firing you have lost nothing but a few seconds. You have not given away your position and since squads rarely attack alone, on the next turn you can pull your arc back. Thus giving the juicy squad a pass in an attempt to catch the entire platoon in the open. Or you can open fire on them immediately, you still have the drop on him. There are more, but there are many more variables, that can change everthing. That's why it is fun.

As far as your last post all I can say is "wow".

Link to comment
Share on other sites

I don't see the need to postulate an 'in-turn' unhide command for the AI but unavailable to the human player, since its behaviour can be explained fully by known properties of the TacAI. I.e. unhiding is influenced by unit experience and being in command (but not by covered arcs, which I agree with Steve are too sophisticated to be used by the AI).

The AI seems to pay some attention to command for units that have an organic HQ. I.e. it can deploy a platoon in such a way as to have all or at least most squads in command of the HQ. The AI does not know how to put units that do not have their own HQ under the control of others.

Thus, things like MGs and guns often, but not always, find themselves out of command and will therefore be more prone to breaking fire discipline. This explains some of the randomness observed. The rest is caused by the randomness of spotting itself, which is probably quite high for a hidden unit.

This explains your example of the green platoon charging the crack MG. Two random parameters are at work there : one determining whether the MG has spotted the charging platoon, the other determining whether it will override hide orders to open fire. Since you chose a crack MG, the tendency for it to override orders will be low, which is why the platoon frequently makes it into the trench before the MG has even opened fire. If you put the MG under control of an HQ, it would probably happen even more. However, spotting ability also increases with experience, so while the crack unit will be less willing to ignore orders, it has a better chance of spotting the advancing enemy sooner. A less experienced MG crew would have a smaller chance of spotting the enemy (though probably not dramatically so), but would be tempted to open up more easily. The interplay of these two factors is all you need to explain the variance in what you see happening. Overall, I'd expect you to have less success with the charging platoon in that test if you reduce the experience of the MG.

I would say the most likely reason the AI hides all its units on turn 1 is to limit damage from opening barrages. They probably came up with that for CMBB, where it would matter to an Axis AI which doesn't know any better but to control the flags by deploying on top of them and faces a human player with oodles of cheap heavy artillery at his disposal.

The AI could also hide its units during the setup phase, but then it passes up the chance to spot any enemy units that are visible right off the bat. With that, the AI would waste its best chance of using its artillery effectively, which is pre-planned against units spotted right after the setup phase.

So, the AI starts the game 'up' to try and spot any easy artillery targets, then goes 'down' immediately to minimize damage from opening barrages for itself.

Subsequent unhides are handled by the TacAI as they would be for a human player who did not give any orders to his units.

[ February 26, 2006, 01:44 AM: Message edited by: Sgt_Kelly ]

Link to comment
Share on other sites

Originally posted by Mudhugger:

You have not given away your position and since squads rarely attack alone, on the next turn you can pull your arc back. Thus giving the juicy squad a pass in an attempt to catch the entire platoon in the open. Or you can open fire on them immediately, you still have the drop on him.

Withholding fire with a covered arc (or a Hide command for that matter) because you don't want to prematurely give away your position is, to my mind, one of the definitions of an ambush -- which is what covered arcs are primarily for. Keep in mind, though, that there is also the possibility of relying too much on ambushes. Just one of the dangers is that you are letting enemy troops get closer to your own troops than they otherwise could, or at least sooner and packing more heat. Your FP may be greater at the closer range, but so is the enemies'.

As for your point about the benefit of feeling like you are in control: perfectly fine. It's your game. Enjoy it. smile.gif

Link to comment
Share on other sites

Sgt. Kelly: Glad to see that someone is still trying to fight the good fight, even though responding means I have to repeat a few things.

I don't see the need to postulate an 'in-turn' unhide command for the AI but unavailable to the human player, since its behaviour can be explained fully by known properties of the TacAI. I.e. unhiding is influenced by unit experience and being in command (but not by covered arcs, which I agree with Steve are too sophisticated to be used by the AI).
I'm not sure why people are having trouble with this one, but it's certainly worth trying again:

If the behavior is the result of the TacAI doing what it normally should be doing, then it will do it whether it's for units in my control or for units in the computer's control.

Let me put that another way: if the computer's units are unHiding because the TacAI is reacting to something and making them unHide, then the TacAI will have the same reactions and take the same actions for the units in my forces. That is what I expected to see. When I didn't see that is what led to this investigation (after I replaced CMBB and did a bunch of other unnecessary stuff, as mentioned before :rolleyes: )

Now if someone wants to postulate that the TacAI works differently for the computer than it does for the player, then that's fine. I don't think so. Moreover, I think it's a distinction without a difference (or is it the other way around. Oh, well).

The AI seems to pay some attention to command for units that have an organic HQ. I.e. it can deploy a platoon in such a way as to have all or at least most squads in command of the HQ. The AI does not know how to put units that do not have their own HQ under the control of others.

Thus, things like MGs and guns often, but not always, find themselves out of command and will therefore be more prone to breaking fire discipline. This explains some of the randomness observed. The rest is caused by the randomness of spotting itself, which is probably quite high for a hidden unit.

If you think that the AI actually tries to keep platoons together, you are playing a different version of the AI than I am. :D But that's neither here nor there for purposes of this thread. Happy to stipulate to that. Let me say, however, that when I first discovered the odd behavior, the same idea occurred to me, and in fact, one of the first things I tested was whether having the MG (to use the same example) in command made a difference. It didn't. I also tried it by putting some other friendly units in the area (maybe the MG was lonely and pining in the bottom of its trench). No effect.

Let me also say what I've said before, I have now seen this behavior in a very wide range of scenarios/QBs, without exception.

Also, and again I don't know why this isn't sinking in: spotting has nothing to do with it. If it were that simple, this thread wouldn't exist. Yes, hiding does reduce spotting ability to some extent (which is another reason why this is a stupid AI trick), but not that much. And besides all the tests I did were designed to eliminate spotting as an explanation. When I control the MG and give it a hide command, it will spot the enemy units. Every time. Therefore, when the computer is controlling the MG, it is spotting the units. Every time. Unless of course, BFC decided to give the AI a handicap in that regard, and wouldn't that be a hoot!

This explains your example of the green platoon charging the crack MG.
Don't get too hung up on trying to explain away one single test case. That particular test, among others, was designed to put to rest the notion that this behavior could be explained by covered arcs. Yes, you are correct, if the MG is green, he will open fire before the green squads get to the trench. That is, as you recognize, because the TacAI is programmed to make them get trigger happy when they are closely threatened. However -- and let me emphasize this -- this behavior by the TacAI works the same and with the same consistency whether or not the MG is being controlled by the computer or by me!

This behavior -- the fight or flight reaction, if I can call it that -- does not explain the randomness which occurs at a range of 300m, say. And even if it did, it should do it the same for computer as for me. And it doesn't. It's really as simple as that.

I would say the most likely reason the AI hides all its units on turn 1 is to limit damage from opening barrages. They probably came up with that for CMBB, where it would matter to an Axis AI which doesn't know any better but to control the flags by deploying on top of them and faces a human player with oodles of cheap heavy artillery at his disposal.
First of all, the AI's units are quite invisible whether or not they are hidden. You can test that for yourself by playing a scenario hot seat, if you want to be absolutely convinced. After all, when you play defense, do you hide your units? If so, you should reconsider (unless of course you are laying an ambush where you want the enemy to get particularly close). CMBB actually made this protection for defenders stronger than it was in CMBO (I think even the user manual says something about a presumption of camouflage for defenders).

Second, the behavior started with CMBO. It wasn't added in CMBB -- like the AI's exemption from command delay, which probably was because of the change that caused waypoints to incur delay.

The AI could also hide its units during the setup phase, but then it passes up the chance to spot any enemy units that are visible right off the bat. With that, the AI would waste its best chance of using its artillery effectively, which is pre-planned against units spotted right after the setup phase.
Don't know if this is true or not, but I don't have any quibble with it. I think the AI shouldn't be hiding them in the first place. :D

Subsequent unhides are handled by the TacAI as they would be for a human player who did not give any orders to his units.
If this were true, this thread wouldn't exist. The computer does unhide its units in a way that is different than the TacAI does for the human. Too repeat the point one more time: if the player gives his units a Hide order it will stay hidden until one of two things happens: the player unHides the units at the beginning of a subsequent turn, or the unit is threatened by the close proximity of an enemy (the definition of "close" varying by the experience level of the hidden unit certainly, but never as far away as 300m). However the computer is able to unHide its units for some third reason and it is able to do this in real time.

And by the way, did I mention that the computer can also give units new move orders in the middle of a turn???

So, there we go folks. Happy to stay in the batter's box on this one. Does anyone have a different sort of curveball they want to throw? smile.gif

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...