Knowledgebase Article 66


research specification

From version 1.15.0 on, ASC has a research system. The technologies are specified in .ASCTXT files with the following syntax:

Technology { name = "Advanced Technology 1" infotext = "some long description of the technology" id = 124 researchpoints = 1234 techlevel = 2 ; the idea behind techlevel is that it makes it easier to start a multiplayer map by ; grouping technologies into techlevels. If you start a map with techlevel 3 all technologies ; with a techlevel of 3 or less will be available to the players without any research requireEvent = false ; this technology can only be researched after a specific event enabling this tech has been triggered ; usually false TechnologiesRequired = 123, 122 ; this technology depends on the technologies with ID 122 and 123

BlockingTechnologies = 127 ; if technology 127 has been researched, this technology will not be researchable any more

BlockingOtherTechnologies = 1000 ; once this technology has been researched, it will not be possible to research the technology with ID 1000 any more. ; this option is only evaluated for technologies that have negative requirements and are so called 'root technologies' RequireAllListedTechnologies = false ; if set to yes then this technology is only researchable after all requirements listed ; in TechnologiesRequired are availabe (in this example 122 AND 123); ; if set to no only one of the TechnologiesRequired (either 122 OR 123, or both) must be available

RelatedUnitID = 20 ; if RelatedUnitID is specified, a "unit info" link will appear in the ChooseTechnology dialog ; which opens the VehicleType Information dialog for the unit specified here. This is ; useful if a technology is prerequisite for a specific unit (this wouldn't make much sense for a technology "laser weapons") } Technology

VehicleTypes, BuildingTypes and ObjectTypes can depend on research so they will be only available for construction if certain technologies have been researched. The association between VehicleTypes (Building- and ObjectType are working the same way, but are not mentioned in this article explicitly) is done using special constructs called TechAdapter, which are a seperate concept like Technologies, VehicleType or Terrain and are specified in their own .ASCTXT files.

A basic TechAdapter looks like this:

TechAdapter {
   Name = 95
   TechnologiesRequired = 123 
} TechAdapter

A more advanced one:

TechAdapter {
   Name = Bridge
   TechnologiesRequired = 124, 129-131

RequireAllListedTechnologies = false ; default is true } TechAdapter

TechAdapters are necessary to prevent a direct dependency between Technologies and VehicleTypes. If a direct connection (for example by specifying Technology-IDs in VehicleTypes) existed, it would be necessary to update the units if the Technology tree is updated, or vice versa the technologies would have to be modified if additional units are added to a unit set.

The primary characteristic of a TechAdapter is that it does not have an ID, so any number of TechAdapter with the same name can exist simultaneously. This opens a possibility that two unitsets rely on the same technology tree, or two different technology trees exist for researching the same unit set.

To specify a TechAdapter dependency for a VehicleType, ObjectType or Buildingtype, certain entries can be added to its .ASCTXT file:

   TechAdapterRequired =  Bridge
   ; for VehicleTypes the default for TechAdapterRequired is the ID of the VehicleType/BuildingType
   ; and BuildingTypes  the default is the ID prefixed by "B", for example "B95"
   ; for ObjectTypes the default is that no TechAdapter is required

RequireAllListedTechnologies = false ; this is optional and will default to true

or another example:

   TechAdapterRequired =  87 76

Research is done in buildings that have the research center attribute:

BuildingType {
   [...]

Functions = Research

MaxResourceProduction { Energy = -200 Material = -300 fuel = -50 } MaxResourceProduction ; these values are the resource consumption at nominal (!) output.

MaxResearch = 100 ; the maximum research output. Note that the resource consumption is much higher then MaxResourceProduction when running a research ouput that is higher than NominalResearch

NominalResearch = 50 ; this is the research output that this center is aimed at. Default: MaxResearch/2

MaxResearchpointsDefault = 100 ; when a building of this type is placed on a map, its maxResearch property will be set to this value. Default: MaxResearch

[...]

Last change: Fri, 2009-05-01 12:59


search knowledgebase
browse knowledgebase