Jump to content

Mission AI Research


mvi

Recommended Posts

Are you sure that in h9v1 atr and emp don't make that coordinated attack using units dropped by carryal? If they.use these, then it is clear why they attack in the same time

Not at all! Haven’t you played the H9v1 level yet? I bet you must’ve ;-) As I’ve already said, it doesn’t happen all the time (I mean that massive & simultaneous attack), but when it does, it usually happens to be THE VERY FIRST ATTACK from these 2 main bases of Atreides & Emperor. That means, these 2 bases won’t attack you immediately (like say, after 5 minutes from the start of the level), but they’ll hold on for a while (you’ll easily notice it, as there won’t be any enemy units coming and it’ll look like a „silence before the storm“), amass a deadly army, and then commence the attack together. If this happens, you can do virtually nothing as you won’t have the time & enough cash to build a good enough defense. However, sometimes, this massive & coordinated attack may happen LATER in the level (say, after 30 minutes). If this happens, you can usually repel it, as you’ll have more time to harvest enough spice & build a good defense, of course.

Btw, sometimes, you can be attacked in such a way also by the remaining 2 Atreides & 1 Emperor subbases. But this usually happens to be in the very beginning of the level, as the 1 Atreides subbase with the Barracks & Outpost (located in the upper left corner of the map, between the 2 main bases of Atreides & Emperor) only has a very small amount of cash (i.e. it can produce only 3 or 4 attack waves of troopers/ligh infantry before running out of cash). Anyway, when this attack occurs, it’s also difficult (if not impossible) to repel, as you’ll have to fight lots of combat / siege tanks, quads and trikes from the Atreides subbase to the left + 15-20 troopers/light infantry from the aforementioned 2nd Atreides subbase + another wave of combat /siege tanks, quads and trikes from the Emperor subbase from above.

Re: these subbases in this particular H9v1 level, it’s actually the Atreides subbase on the left that can often make such a sudden & ferocious attack, and it can happen virtually at any time. They’ll send, say, 7 quads & 7 trikes as an „appetizer“, then quickly followed by another 7-8 combat tanks & another 7-8 siege tanks (these numbers are just an example, of course). However, this attack is quite easy to repel (if you have enough rocket turrets, that is), as the quads & trikes are very easy to kill + the combat & siege tanks aren’t best suited to destroy turrets. But as I’ve already said, when you’re attacked by the 2 main bases of Atreides & Emperor, it’s, of course, a totally different story, as they have missile tanks & sonic tanks, which can be a real pain in the ass for your turrets (especially when these are occupied with firing at light infantry or some other units like trikes or quads).

Btw, I sometimes encountered this kind of attack also from the main Atreides base in the H9v2 level. It usually happens later in the level, and it is somehow easier to repel as the attack in the H9v1 level, firstly because the Atreides usually won’t do this attack together with the Emperor, and secondly because there’s a set of stones just before your base, which can be only accessed by the infantry & which forces the mechanized units to bypass it & thus prevents them from attacking you in a large simultaneous wave (i.e. they just come in 2 or 3 at a time, while the others are stuck behind those stones).

Link to comment
Share on other sites

When I gave a default AI just a barracks it does not build an army of infantry, since AI without coding pretty much builds a variety of units, it does not have a limit.

That may be true. However, when I redid the O8v1 level (you can download it here or on mvi’s site & try it, if you want), I assigned a Barracks & a Starport to Smugglers & gave them lots of cash + an AI from Atreides O9v1 level, and I can tell you they’d have no problems to train & attack you with well over 50 troopers/light infantry at any time… Btw, what do you mean by “AI without coding”? I mean, where I can find such AI? As far as I understand, every single AI in this or that particular level (as you already mentioned) is “coded”, right?

Another weird thing is the AI without coding will attack walls while ignoring some buildings, so again, they are coded to attack just buildings and units most likely.

That happens to be, for example, in the O9v1 level with Mercenaries. When you try to attack, say, the Harkonnen base together with the Mercenary units, they’ll sometimes attack walls, even when there are still some Harkonnen buildings to destroy. So does that mean that the Mercenary AI from this particular level is NOT coded? I suppose it is, or?

Link to comment
Share on other sites

I played H9V1 but not very much cuz all my tests went on Ordos and Atr final missions, so I cant tell you about that synched attack. Another thing that I can tell you is that LAN AI, if are allied, help each other. I allied 4 LAN AIs some days ago to give Masculine an interesting match. While he was rushing a red ordos AI, after masculine destroyed 2 buildings suddenly the closest ally (teal hark) came to assist red ordos. And that was NOT an attack because after he finished masculine's attack, he retreated with his units to the base. This thing happened 3 times (LOL) so masc wasnt able to finish the red AI cuz teal was helping them and the other 2 were rushing masc's base (I was allied with everybody, using my allied mod patch - so I was observer). I didnt see this thing many times (because I played this type of match some times more but from let's say 10 times it happened 3 times maximum.. )so something is really strange because Idk why they help each other (cuz westwood didnt intend to ally AIs). I repeat: of course, I can't be sure about this information, but this is what I've noticed. I will try to use a modded prac.mis to observe practice AI and try to find this result there, if it exists.

Now about the wall attacks.. Yea, I encountered that 10000 times. It's strange.. For example in my atr campaign, last mission, i have some walls.. hark or emperor, in their first attack, will harass the walls and will ignore other buildings or units until they are attacked. I'm not sure what AI I used for them because I dont remember, but probably hark AI from O9V2.

Link to comment
Share on other sites

Btw, what do you mean by “AI without coding”? I mean, where I can find such AI? As far as I understand, every single AI in this or that particular level (as you already mentioned) is “coded”, right?

What I mean is an AI that is not specifically coded in that level. For example o5v1, there are three houses, fremen, smugglers and atreides, which are all specifically coded. And lets say you put house harkonnen in there and just turn the AI on. The AI does not have specific coding on what to attack with or build, it just builds an army and attacks. Any mission file has it for a house that is not part of that level.

That happens to be, for example, in the O9v1 level with Mercenaries. When you try to attack, say, the Harkonnen base together with the Mercenary units, they’ll sometimes attack walls, even when there are still some Harkonnen buildings to destroy. So does that mean that the Mercenary AI from this particular level is NOT coded? I suppose it is, or?

Well you will see any AI attack walls but not as nearly as much as an AI that does not have coding. If you ever notice an AI player without specific coding, they will attack wall after wall regardless of how many buildings and it stops them from being efficient. The mercenaries in that level are specifically coded how ever, they are efficient with attacks, protect harvesters, attack approachers and use a pretty good army to attack etc.

Link to comment
Share on other sites

I Have found some particular bytes in MVI's new release using the Edit Segments tool that had a pretty noticeable effect. This byte is changed alot in other levels and increases as the missions get in the higher stages. its unknown 3856 and 3860. By default its 6000 and 6000. How ever I did notice raising increases the number of units that are produced and 'patrol' the base. I encourage any one to play around with those numbers and see if you can find anything.

  • Upvote 2
Link to comment
Share on other sites

And lets say you put house harkonnen in there and just turn the AI on. The AI does not have specific coding on what to attack with or build, it just builds an army and attacks. Any mission file has it for a house that is not part of that level.

What do you mean by saying „turn the AI on“? Do you mean importing an AI from, let’s say, Harkonnen in A9v1, or do you mean simply putting a Harkonnen base in the level and assign them as your enemies, WITHOUT giving them any specific AI? As far as I know, if you do the latter, the enemy AI won’t build any units (or maybe one or two), and they won’t repair their buildings as well. That’s at least what I remember from remaking the O8v1 level – when I added Fremen & Smugglers to it, they won’t attacked me at all & didn’t repair their buildings when I attacked them. But once I gave them a specific AI (from Atreides O9v1 level, to be precise), they acted as “usual” enemy would do…

Link to comment
Share on other sites

What do you mean by saying „turn the AI on“? Do you mean importing an AI from, let’s say, Harkonnen in A9v1, or do you mean simply putting a Harkonnen base in the level and assign them as your enemies, WITHOUT giving them any specific AI? As far as I know, if you do the latter, the enemy AI won’t build any units (or maybe one or two), and they won’t repair their buildings as well. That’s at least what I remember from remaking the O8v1 level – when I added Fremen & Smugglers to it, they won’t attacked me at all & didn’t repair their buildings when I attacked them. But once I gave them a specific AI (from Atreides O9v1 level, to be precise), they acted as “usual” enemy would do…

What I mean is, if you use win hex, and you go to the section of the house index lets say ordos which is 02, you turn the AI on by switching the value 00 after 02, to 01. This can be done for the player itself. Lets say in o9v2.mis file, go to the ordos section and switch the 00 to 01 (or you can import an AI segment using the mission editor and replace the ordos section with one from another mission you vs. the ordos), your entire army will be controlled by AI. Now that MVI and others helped developed the new program there is more to do with the AI, such as 'rebuild buildings, attack approachers, buy units from starport' which we could not do before for default AI codes.

What I am really aiming for at the moment is to keep the AI from creating engineers and mcv's since they are useless to them. After that, I would love to tackle the subject on how to direct the AI what to build and attack with. So far I found some on the infantry, if you check out the text file I attached in an earlier post, you can see what I did. Play around with these values and see what you can find.

Link to comment
Share on other sites

@sandworm: I've checked that file which you provided, and even though I roughly understand what to do (change some numbers, then save the file, and run the level to check how it all plays out), I'm not familiar with the hex editor at all (never worked with it), so I'll leave that task for you :P But I'm gonna try to assign an enemy AI to me as a player, just to see how it works. Very interesting idea, btw. Haven't tried it yet...

As for the topic of enemy AI, as I've already said, I'd especially love to somehow determine what units & how many of them should the enemy build & train before the attack. I'd like to see more levels like H9v1, where the enemy will amass a deadly force and ONLY THEN attack. I've noticed that, for example in the O8v1 level (I guess this applies for the other levels as well), there's a certain limit for some types of units which the enemy uses. Tried, for example, to add 10 sonic tanks to the Atreides using the mvi's editor (via the unit spawn event, of course) with the Deploy action parameter set to 2 (which meant these 10 sonic tanks would patrol around the base, but NEVER attack yours), and what happened was that the Atreides didn't build a single new sonic tank, which meant they didn't attack my base with sonic tanks at all. They had the means to do so, as they had both the Heavy Factory & Ix Research Center (as well as enough money & tech level), but, since I gave them 10 sonic tanks in the beginning (and therefore probably breached some limit, like, say, no more than 4 sonic tanks at any time) + ordered all of them to stay home and not attack me, the enemy wouldn't build any additional units of this kind at all. I guess I may sound a bit confusing, but I hope you understand what I mean.

Btw, speaking of the AI, it'd be interesting to somehow alter the behavior of the Mercenaries (which act as your ally, of course). What I mean is that, even though they receive lots of units per Starport, they, in vast majority of the cases, spend them rather quickly by simply attacking whatever is on sight, INSTEAD of sending, say, just 5-6 units to attack & leaving the REST guarding the base. What I want to say is that I'd love to make them use their units more wisely, giving a higher priority to PROTECTING THEIR BASE instead of blindly attacking whatever enemy unit that is closest to them...

Things like rebuilding buildings, I don't know. As far as I know, the enemy, whether with the original AI or with an imported AI (via mvi's editor, of course), will always rebuild a building if you destroy it, provided it has the means to do so. I've noticed that sometimes, it may take a bit longer, like if you destroy, say, 2 rocket turrets & 1 gun turret, the enemy will first rebuild, say, the gun turret, and then, after, say, 5 minutes, will rebuild the rocket turrets as well. Btw, yesterday I played the original O9v2 level, and when the enemy destroyed the Mercenary silos (they have 6 silos), the Mercenaries only rebuild 5 of them, so I'm not quite sure whether the AI will rebuild everything which you destroy, even if you give him enough time to do so...

Link to comment
Share on other sites

@skorocel Dont worry you dont need to worry too much about winhex for I think it become obsolete to use it for dune editing since mvi's toolkit release. Now to the topic in which you discussed...The enemy AI I believe in dune 2000 is simple yet complex in data. As you mentioned before about the sonic tanks, yes the AI coded for that base has a specific unit list on what It should make. The best thing to do, is use mvi's new mission editor release, and compare some different segments.

You should also experiment with player AI. Import an AI segment from another mission and give it to the players house. You will find it interesting how the AI works.

As for the mercenaries in the last mission, yes their attack power is not as powerful as the enemies per say. Im pretty sure westwood did not want the mercenaries doing all the work, HOWEVER, what I did was I gave them a light factory and barracks as well as additional starport units deployed. You will notice that the mercenaries will bring up a pretty strong army..

As for rebuilding buildings, I notice that the AI will immediately replace destroyed buildings IF the spice amount matches that of which the building costs. You will notice that over some time they will not rebuild the building due to excessive unit building or anything of that matter, but what I noticed when I put my army on AI, is that they will only build something if the spice amount matches the unit/building cost.

Heres what I suggest you do:

Using MVI's new mission editor release, import an AI segment to your player. After, try switching some segments within your players house to see what it could alter. So far I found a byte that puts a time limit when to send infantry to attack, so you may find something as well, you never know :)

Link to comment
Share on other sites

@mvi: Thank you very much for these links, but I'm afraid I won't become any hex editor ace anytime soon, firstly because (as you may've noticed from my previous post to sandworm) I'm just too lazy to do any research, and secondly because I've ALWAYS sucked at maths or anything of that kind :(

Link to comment
Share on other sites

As for the mercenaries in the last mission, yes their attack power is not as powerful as the enemies per say. Im pretty sure westwood did not want the mercenaries doing all the work, HOWEVER, what I did was I gave them a light factory and barracks as well as additional starport units deployed. You will notice that the mercenaries will bring up a pretty strong army..

The Mercs can bring up a strong army even without light factory / barracks / additional starport units - it's just that they (in most of the cases) spend their units rather quickly, without thinking too much about protecting their base. Would be cool if you could give them a some sort of order which would make them attack the enemy bases only if they had, say, at least 50 units, AND with, say, a maximum of 20 units (i.e. 20 units would go outside for hunt, whilst the remaining 30 would protect the base).

Speaking about the AI, btw, I've noticed that sometimes the enemy can make pretty strange things. For example their harvesters: normally, the enemy would have 2 harvesters per refinery (i.e. if he has, say, 2 refineries, he will have no more than 4 harvesters at any time, and if you destroy him one, he will quickly rebuild it, if you destroy him 2, he will rebuild 2, etc.) But sometimes, he'd, for some unknown reason, simply order 5 harvesters per starport, even if he has just 2 refineries (and therefore 4 harvesters to go with it).

Link to comment
Share on other sites

Yes Skorocel I did notice that an AI player would order many harvesters via starport, how ever they wont build extra from the heavy factory at least.

As for the AI im pretty sure there is data on either how often, or how strong an AI's army has to be before it decides to attack. Ive been playing around with the parameters alot in the new mission editor, so far ive discovered a couple things if you looked at my research.txt file

Link to comment
Share on other sites

Didn’t know where to post this, but anyway, here are 2 "new things" which somehow got my attention when playing the D2K recently:

1. Why do the enemy stealth fremen appear “visible” when walking near the infantry units from the other enemy clans? Seems weird, isn’t it?

2. Also, in the levels where the Ordos play together with the Mercs, why, once you get that message: „We’ve lost too many men! We must withdraw our support!”, do the Mercs let their base to be destroyed by the other clans, which are supposed to be “neutral” to the Mercs? As far as I understand, the Mercs become “neutral” to all houses whilst all houses become “neutral” to Mercs as well WHEN this message appears, but what’s pretty common is that, by the time of this message, the Mercs are fighting against this or that house’s unit (or some house’s unit is about to attack their base or unit), but what’s strange is that they, once being attacked, don’t respond to the enemy fire at all (i.e. they still consider the attackers as “neutral”, whilst the attackers certainly don’t consider the Mercs to be “neutral”). They simply won’t do anything and will let their base to be destroyed without firing one single shot at the attackers… I mean it’s OK when they, once they become “neutral” to you and all the other houses, stop receiving those Starport deliveries (which is perfectly understandable as it would be of no use to them when they aren’t fighting with anyone anymore), but this is strange… If they become “neutral” to you and you, by an accident, attack them, they’ll automatically become your enemies (which is logical), but when they’re attacked by the other clans, they’ll ignore their fire…

Link to comment
Share on other sites

@sandworm & aKaFedaYkin:

Stupid me, I take it back! Was too lazy to check the .mis files, you know 8) You’re both right about the Mercs. They indeed ally with the other houses when the casualties grow, so if the Harkonnen or Atreides decide to destroy their base, it’s actually good for the player, as it draws their attention away for a minute or two…

Re: the stealth fremen & saboteurs, they of course get spotted by the infantry, but what I meant is that they also get “visible” when walking near an LI / trooper / sardaukar who belong to a house which is ALLIED to them. That’s what I found weird on it… If they’re allied with these units, why should they reveal themselves, isn’t it?

Link to comment
Share on other sites

As for the AI im pretty sure there is data on either how often, or how strong an AI's army has to be before it decides to attack. Ive been playing around with the parameters alot in the new mission editor, so far ive discovered a couple things if you looked at my research.txt file

Cool if it can be modded. I just discovered how to switch faction with mission editor: for example in Harkonnen 4 just switch the index with Fremen and you will be Fremen....the Harkonnen will be in Fremen place, but even if you add buildings they won't build anything because AI don't want to.

Link to comment
Share on other sites

Great topic! Good job with these tools. I'm a a huge fan of Dune 2000 and having the option to build missions (even without custom AI) is a dream!

Now, the remaining: the AI. Thank you all the community for the knowledge share and the tools!

Hope this has future! :D

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.
Note: Your post will require moderator approval before it will be visible.

Guest
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...