.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Space Empires: IV & V (http://forum.shrapnelgames.com/forumdisplay.php?f=20)
-   -   Eliminating Resupply Depots... =) (http://forum.shrapnelgames.com/showthread.php?t=28330)

Wenin April 7th, 2006 07:41 PM

Re: Eliminating Resupply Depots... =)
 
Good point.

I'll design that

Wenin April 8th, 2006 12:31 PM

Re: Eliminating Resupply Depots... =)
 
Is there a way to prevent an AI from building a structure?

The Capital facility I built is super expensive (48 years to build) and the AIs are trying to build them in their systems. It has the resupply depot, and resource conversion ability.

I've added the Resupply Depot back to the mod.

Wenin April 8th, 2006 12:47 PM

Re: Eliminating Resupply Depots... =)
 
Found outit was the Combat Modifier - System ability I gave it.

I'm giving all of the standard facilities with that ability an AI Tag 01. Then replacing the Combat Modifier - System in the AI_Construction_Facilities file with AI Tag 01.

Fyron April 8th, 2006 01:47 PM

Re: Eliminating Resupply Depots... =)
 
Yes. Add AI Tag ## abilities to the facilities you actually want them to build. Next, go into each Mod\Pictures\Races\Racename\Racename_AI_Constructi on_Facilities.txt file and do a find/replace operation of the offending ability with the new AI tag.

This is necessary for any ability with values (ie: not space port or resupply). With valueless abilities, you can fool the AI into thinking the facility you want them to build is more advanced by making it require more total tech levels. They can be redundant.

This method does not require any editing of AI files, so is generally preferable for valueless abilities. Valued abilities only use the value of the ability in question when determining what is "more advanced," whereas valueless abilities are compared by total levels of tech reqs. Last position in the file is a tie breaker in both cases.

For example, you could make Space Port appear to require 5 tech levels thusly:

Name := Space Port
...
Tech Area Req 1 := Cargo
Tech Level Req 1 := 1
Tech Area Req 2 := Cargo
Tech Level Req 2 := 1
Tech Area Req 3 := Cargo
Tech Level Req 3 := 1
Tech Area Req 4 := Cargo
Tech Level Req 4 := 1
Tech Area Req 5 := Cargo
Tech Level Req 5 := 1


A possibly cleaner way is to add an AI Tech tech area with, say, 15 levels. Set its start and raise levels to 15. Make it so that it is unremovable, since you will never want it to be removed. It is only meant to be used to fool AI into using the correct facility. Humans will have AI Tech too, but this is fine because it will allow the ministers to function properly. With the same 5 tech levels example above, it would more cleanly look like:

Name := Space Port
...
Tech Area Req 1 := Cargo
Tech Level Req 1 := 1
Tech Area Req 2 := AI Tech
Tech Level Req 2 := 4

These redundant tech reqs do not change anything in-game; the facilities appear in the same place in the tech tree.


All times are GMT -4. The time now is 02:35 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.