| 07-25-2004, 07:26 PM | #1 |
I've pretty much abandonded the AI editor that comes with the map editor, because it friggin blows. And now Im looking into the manual, and indeed so far what I've read sounds impressive, I've just started working on my profile/strategy... Problem is my main reason for doing this is for the additional custom units, shipyards, my expanded naga playable race and my Burning Legion race... And so far it seems like that aspect is a pretty advanced feature... Or is it easier then Im thinking? Also, do you have to give a profile favorite hero? Or if just left blank does that mean they will select a hero completely at random? |
| 07-25-2004, 09:34 PM | #2 |
Adding aditional custom units is an advanced step but is not so hard. You add custom units to standardunits.txt file or change names of original units if u want. Open in excel and it will look much nicer and easier to edit. Manual gives a nice bit of help at the last section after profile and strategy guide about some of files that can be edited. Although there are others. You do not need to provide a favourite hero if you don't want. They won't go completly at random. Favourite hero increases chance that hero is picked. In aMAI folder go to TFT/*choose a race folder*heroes.txt. That file has the proities of each hero that can be picked and includes tavern heros as well. Higher proity a hero has. more likely it is to be picked. |
| 07-26-2004, 02:45 AM | #3 |
1.) But in the editor can you add these custom units as part of a new race? Or do you have to throw theme in with another races strategies? Like the Burning Legion or Naga? I tried making a Legion and Naga directory in the TFT directory thinking it might create a Demon and Naga button in "Strategies" But it didn't. Or things like "Favorite Demon Hero" "Favorite Naga Hero" 2.) And for some reason I cannot create a new profile. I, I click on new. then it appears on the list, I edit it, rename it and click "ok" but it's name doesn't change on the list, it's still "New_Profile" and if I click edit after that, it doesn't open up... I try to compile and exit, and when I restart the program my new profile isn't even there anymore. 3.) Also in strategies, how does the ai know to build an altar? does the... call SetBuildUnit(1, hero_id[1] Is that what the automatic building feature does? If you tell it to build a unit, if it does not have the building required, it will automaticly build the building? Does it do this entirly automatic or is there a settings file that controls this? As I am using custom units, if I tell it to build a Succubus, it will automaticly know it needs to summon a Dimensional Gate to do so? 4.) Finally, what determines the strength rating of a unit? Is it entirly based on how much food the unit requires? |
| 07-26-2004, 01:28 PM | #4 |
1.) AMAI is currently restricted to 4 races. I have considered making that variable but up to now I did not have any good idea how to implement that as it likely requires a lot of changes and also a lot of work. You can still use more than 4 races, just not at the same time. Add your new units/buildings/whatever as a replacement of one of the old races though keep the old units/buildings/whatever in StandardUnits.txt (and some of the other files too). That should still keep the old scripts functional with the new common.ai and your new scripts. 2.) The name is not updated properly after renaming it but it should update by selecting another version (like RoC) and back to your current version. If that does not help then I have to look if there is a bug somewhere there. 3.) That is one of the best features of AMAI. It will build all required things for a certain build order automatically. The info for that is in StandardUnits.txt . When you enter your unit there you specify what it needs. 4.) The allround strength of a unit is determined by food value and the remaining health of the unit. The strength in certain areas of a unit (like air, piercing, ...) is specified in StandardUnits.txt . Now you might ask why the allround strength cannot be specified there too. The reason for that is that the allround strength is often needed at points in the code where you only have the unit handle and it is rather inefficient to get the AMAI internal unit type id from that which is needed to get a custom strength value. It is very cheap to get the food value on the other hand (a simple native call). |
| 07-26-2004, 05:28 PM | #5 |
Well I guess AMAI is not for me... Because of the first and most important aspect... I need more then 4 races, my burning legion and naga are there own race. And in the melee map I am building all 6 races are playable and each have 2 pre-set starting locations. Thats the main theme of the map I want to create. You stated that you cannot have more then four races using AMAI at a time... The official AI editor allows you to do this... Unfortunetly the AI editor sucks for just about everything else. |
| 07-26-2004, 11:33 PM | #6 |
Maybe I did not express myself good enough. You can have more than 4 races in the actual game, just not in the strategy editor. So you can use AMAI for your additional races. What you do is replacing one of the races in the AMAI development environment but keeping the original units in the StandardUnits.txt . Then the created common.ai will work for the original AMAI scripts and your new races scripts. |
| 07-27-2004, 01:00 AM | #7 |
Hm, I still don't think I understand you fully. It sounds like if I do this wrong, I'll end up over-writing and entire race when I make my new one. Could you give me an example? Like say, Im going to use the Undead as a basis to make my script and strategies for the Burning Legion and I don't want to accidently over-write the undead. And in doing so will I be able to save it as a specific .ai file like demon.ai... In which case I could just put demon.ai in the import manager and use triggers to load it up for that the players that would be pre-set as Burning Legion? Or is there a lot more file to AMAI that simply th .ai file, hence needing to install AMAI to each map on it's on? |
| 07-27-2004, 08:57 AM | #8 |
Heres an easy idea to do. You are not modifiying the normal human, orc, undead , elf scripts are you so save those scripts in the Scripts/TFT/ folder to somewhere else. Copy paste job. Now use undead as base replace the strategies into burning legion stuff. When compiled it will go into undead.ai scripts, but you already saved the true undead script so just rename this to legion.ai and place where you saved the other scripts. You now have 5 races. As long as u don't need to modify the original human,undead,orc,elf scripts you are fine. If you do just set make another AMAI folder. So you will have 2 folders with developer edition in. 1 to edit normal ai's. 1 to make new race ai's up to 4. Anymore races make a new folder to create another 4 ai's for those ai's. EDIT- ai has to be imported into each map in question with the appropiate common.ai as well. So its best to use the same amai folder for all the ai's otherwise some confilcts between common.ai may occur as other ai's may require something slightly different. That will be fine if you keep as AiAndy said the original units intact within standardunits.txt |
| 07-27-2004, 09:16 AM | #9 |
You are lucky. I have decided to remove those structural limits in AMAI like race number, tier number and max hero level by writing a Perl script that makes the necessary changes to the tables and scripts. If there are special limits you'd like removed in that way, tell me (apart from the already mentioned ones). |
| 07-27-2004, 05:53 PM | #10 |
I am modifying the Human, Orc, Elf and Undead scripts though... Since each race now has 2 additional units and the abilitiy to build a shipyard and ships. I'll need to include those in the ai scripts. |
| 07-28-2004, 02:24 AM | #11 |
That would still work with the method described up there but now that I work on removing the race limit in AMAI that is not really necessary any more. |
| 07-28-2004, 02:59 AM | #12 |
But that still doesn't solve one thing. This may work well for strategies, but what about in "profiles" There is no "favorite custom races hero" or "favorite custom races unit" And what do I do with the "Global Builds" in the Buildsequence.ai??? |
| 07-28-2004, 10:44 AM | #13 |
Global builds are what are built by that race no matter what ever strategy ai uses. It also sets the harass attacks to use no matter what strategy. so lets say the race you doing is demons. Just add something there to build 2 infernal. They will now always build it. Make sure you don't leave the old races stuff there. If your demons they are not going to be able to build certain items, or research or harass with footmen. Make sure you put your new heroes at the beginning of the file with the other heroes. This places them in the hero section so can be used as a custom favourite hero for that race. Make sure your hero in the file has the hero type on it. |
| 07-28-2004, 11:34 AM | #14 |
@Sardius: I don't do half things. Once I have finished the changes it will be generic. |
| 07-28-2004, 07:04 PM | #15 |
But for editing the Global Builds, I can't actually do that with the editor it self correct? I have to manually edit the buildsequence.ai, and when you say "don't forget to add your heroes" your refering to the heroes and heroskills.txt yes? anything I need to edit in RaceAggression or Commandbuilds? |
