Apolyton Archive  |  Preserved copy of the Apolyton Civilization Site and its forums as they stood in September 2005. Read-only; nothing here can be posted to or replied to.  |  Forum index |  About this archive |  The 1998–2001 UBB forums
Today on Apolyton WARDELL INTERVIEW PROMO A.C.S. HISTORY CHAPTER 4 GET CIV4 /w FREE PLUS! A.C.S. PHOTO GALLERY GET A.O.M. V1.1
Apolyton Civilization Forums
main| civ2| civ3| civ4| smac| ctp2| ron| moo3| galciv| galciv2| alt| about|
ApolytonPLUS | register | search | faq | new posts | pm (-/-) | upload | members
hall of fame new! | civgroups | civgroups news | interviews | the column | radio | chat | directory | news | store | PLUS
Apolyton Civilization Forums : Powered by vBulletin version 2.0.3 Apolyton Civilization Forums > Miscellaneous > Archive > CtP2-Creation/AI/Mods/Scenarios-Archive > Help needed! Adding unit categories.
Show a Printable Version | Email This Page to Someone! | Receive updates to this thread | Report this to Apolyton news!

bottom of page
  
Author
Thread    < Last Thread     Next Thread > Post New Thread     Post A Reply
WesW is offline WesW
CTP1/2 Modification Site Admin
Florence, Al., USA
Jan 1970
time: 23:14
Post  Old Post 02-12-2000 15:31 Visit WesW's homepage!
Edit/Delete Message Reply w/Quote
#1 Report this post to a moderator
Help needed! Adding unit categories. Support Apolyton, buy Civilization III: Complete

Here are a few of the lines in strategies.txt that set the percentages of unit types that the AIs build. The problem is that there are only five of them, these three below for land units, and one each for sea and air units.
I think this explains why I never saw the AI build anything other than Submarines and Bombers in my beta games. (No Battleships or Destroyers, no Intercepters).
There are another set of categories for building a set number of settlers, transports and other special units, so that is why you see those units.

// Unit Percents must total to 1 (100%)
DefensiveUnitsPercent 0.15
OffensiveUnitsPercent 0.10
RangedUnitsPercent----0.15

Anyway, I tried adding new categories, but these "tokens" are hard-coded into the executable file, and if the game finds one in strategies.txt that doesn't match one in the exe file, then it crashes.
This was not how it was in Ctp1. Five categories for all conventional units is totally inadequate, unless the game looks at something else in deciding what to build.

What I need are instructions on how to add new categories to the game, either by modifying the exe file, or maybe something in slic.
Or, if an Activisioner could explain how the five categories are sufficient to provide a well-balanced AI force, I would be very interested to hear that as well.
[This message has been edited by WesW (edited December 02, 2000).]

Azmel2 is offline Azmel2
Settler
Santa Monica, CA USA
Aug 2000
time: 05:14
Post  Old Post 05-12-2000 01:07
Edit/Delete Message Reply w/Quote
#2 Report this post to a moderator
Got spare money?


WesW,

Each category has a corresponding build list. You can specify as many different build lists as you want by adding new entries to the UnitBuildLists.txt file.
If you wanted the AI to adopt a strategy inwhich it focused on submarines, you could create a trigger to load a new strategic state that redefined the SeaUnitList from UNIT_BUILD_LIST_SEA (the generic sea unit list) to UNIT_BUILD_LIST_SEA_SUBMARINES.

The default build lists we use provide a good mix of units, but obviously a human player will be able to discern much more subtle distinctions of unit category. If as a mod maker you wish the AI to use more categories than the ones provided, you will have to do it by detecting when a situation exists that requires a special purpose build list and triggering
a new strategic state to load it.

In CTP1 you really had no categories at all. It was just a bunch of unit build lists with priorities. The AI would try to build off the highest priority build lists first, but interleave them with lower priority build lists as it became satisfied.

Using the CTP1 system you had to practically graph out the build lists and priorities to get it to interleave units properly. Do you really prefer that system over the current one? I think few people did and that our new system will make it possible for more people to customize the AI.

You also had to use the .fli system to load in different AIP files to adjust the priorities of unit build lists. This is equivalent to the loading of new strategic states in CTP2 using SLIC as I described above.

I hope this helps clarify how to use the CTP2 build lists system.

Best wishes,

-- Richard


quote:

Originally posted by WesW on 12-02-2000 05:31 AM
Here are a few of the lines in strategies.txt that set the percentages of unit types that the AIs build. The problem is that there are only five of them, these three below for land units, and one each for sea and air units.
I think this explains why I never saw the AI build anything other than Submarines and Bombers in my beta games. (No Battleships or Destroyers, no Intercepters).
There are another set of categories for building a set number of settlers, transports and other special units, so that is why you see those units.

// Unit Percents must total to 1 (100%)
DefensiveUnitsPercent 0.15
OffensiveUnitsPercent 0.10
RangedUnitsPercent----0.15

Anyway, I tried adding new categories, but these "tokens" are hard-coded into the executable file, and if the game finds one in strategies.txt that doesn't match one in the exe file, then it crashes.
This was not how it was in Ctp1. Five categories for all conventional units is totally inadequate, unless the game looks at something else in deciding what to build.

What I need are instructions on how to add new categories to the game, either by modifying the exe file, or maybe something in slic.
Or, if an Activisioner could explain how the five categories are sufficient to provide a well-balanced AI force, I would be very interested to hear that as well.


WesW is offline WesW
CTP1/2 Modification Site Admin
Florence, Al., USA
Jan 1970
time: 23:14
Post  Old Post 05-12-2000 09:29 Visit WesW's homepage!
Edit/Delete Message Reply w/Quote
#3 Report this post to a moderator
Increase Your PM Length

Thanks for your reply, Richard, though it is disappointing to hear that slic will be required to do what was a simple addition to the aips in Ctp1.
Am I interpreting your comments corretly to mean that there can never be more than five categories active at any one time?

Yes, I do prefer the Ctp1 system. The priorities in Ctp1 were like the goals in Ctp2. You could set whether an AI built offensive or defensive units first, and more importantly what supporting and special units were built before others. You based the numbers of each type upon the number of cities, so all I had to do was ask myself "About how many Battleships do I usually have when I have about 15 cities?" Divide this number by 15, and there you have it. You didn't have to figure out how many offensive units you had compared to flanking units, and all other types, and making this sum to 100% like in Ctp2. (I ended up with specifying 01% Paratroopers in my proposed Ctp2 model.) And again, you could specify as many unit categories as you wanted.
Whomever designed the flis and aips tried to construct a very elaborate and elegant system. With the flis, they bit off more than they could chew, so to speak, but I found that the aips worked very well once you understood them, and that the elegance was largely achieved.

One thing I do like about the new system is the unit count token, where you can specify an exact number of certain units to build. This was sorely needed in Ctp1 for settlers.

Locutus is offline Locutus
ACS CTP1/2 Manager & Civ4 Co-Manager
Hengelo, The Netherlands
Nov 1999
time: 06:14
  Old Post 05-12-2000 17:23 Visit Locutus<br><img src=/forums/images/staff-icon.gif>'s homepage!
Edit/Delete Message Reply w/Quote
#4 Report this post to a moderator
Support Apolyton, buy Alpha Centauri

Well, I for one like the new system better. I agree it would have been nicer to have more than 5 build lists active at the same time, but linking the AI files to SLIC probably made it much more powerful. One example is being able to specify the exact number of units: if it wasn't possible already, you could have used SLIC to make it possible, which wasn't the case in CtPI. Though I agree that the CtPI system was very good and could have been even better if it had been more worked out and refined, I think the CtPII system will be even more powerful.

The thing is that in CtPI you could improve the AI by just experimenting a lot, more or less randomly try different values for different settings and see how it affects the AI in the game. With the CtPII system, you'll much more have to *design* the AI. First, carefully think about how you want the AI to behave under certain circumstances and then program it in (with SLIC). In the end, this gives you much more control over what you're doing and over your results.

The only problem with this is of course that it will require more thinking and (relatively) less experimenting and that you'll have to either learn SLIC yourself or 'hire' someone to do the dirty work for you

------------------
"The most likely way for the world to be destroyed, most experts agree, is by accident. That's where we come in; we're computer professionals. We cause accidents." - Nathaniel Borenstein

  < Last Thread     Next Thread > Post New Thread     Post A Reply
All times are GMT. The time now is 05:14.
Apolyton Time is 00:14.
    top of page
Rate This Thread:
archivepost
Forum Jump:
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
 




Contact Us - Apolyton Civilization Site - Support Us!

Building a better Apolyton through better information. Click here and take our poll!
Non-US visitors, click here!

Powered by: vBulletin Version 2.0.3
Copyright ©2000, 2001, Jelsoft Enterprises Limited.

Page generated in 0.0311 seconds (88.23% PHP - 11.77% MySQL) with 31 queries
Page Loading Time:

Support Apolyton: Amazon USA | Amazon UK | Amazon DE | Amazon FR |
Support Apolyton and get FREE PLUS, Buy from Chips&Bits: Galactic Civilizations | Galactic Civilizations: Deluxe Edition | Call to Power 2 | Civilization: The Boardgame | GURPS/ Alpha Centauri | Alpha Centauri | Civilization IV | Civilization III: Complete |


Front Page | Civilization IV | Civilization III | Civilization II | Call to Power II | Alpha Centauri | Master of Orion III
Rise of Nations | Galactic Civilizations | Galactic Civilizations II | Misc
Alt.Civs | Civ I | C:CtP I | About | News | Directory | Apolyton Store | Forums | Chat | Columns | Interviews | Newsletter
Scenario League | CSC | Clash of Civs | Spanish Site | CtP Maps | Cradle of Civ | WesW's Ctp1/2 Site | Civ3 Haven

apolyton.net | apolyton.com | civilization2.net | civilization3.net | civilization4.net | civilizationiv.info | calltopower.net | galciv.net | galciv2.net | moo3.net