# Talk:Research Technical Details

## Research Time Bugs?

It seems odd to me that all the research projects are evenly divisible by 10 except for the live aliens (everything except for the Sectoid Commander) and the Power Suit. The Sectoid Commander has a time of 190 man-days which is probably the value that the programmers wanted for all the other aliens (currently 192 man-days). As for the Power Suit, it has a time of 205 man-days. I was at a loss to explain this until I wondered what the average time was between Personal Armor and the Flying Suit. Those have research times of 180 and 430 man-days respectively for an average of 305 man-days for the Power Suit (compare this to the current value of 205). This kinda throws up some red-flags to me indicating a possible typo or data entry problem. Just wondering what you guys think of this? --Zombie 17:45, 11 November 2009 (EST)

Edit: Nevermind about the Power Suit being off by 100. Seems I used 174,1 (430 decimal) instead of 74,1 (330 decimal) for the Flying Suit time. Thus the anticipated average for the Power Suit would be 255 (which is now off by 50). Still, it has a 5 at the end and could have been a mistype. Coincidence? --Zombie 22:21, 12 November 2009 (EST)

It makes sense to me. Notice that the progress ratings are almost twice as much as the previous one (8%, 14%, 26%) ... then notice that 330 is almost twice 180. Mid-way between this would be 255... but 250 would be almost halfway between. I think that the 205 is probably a typo of 250.
Also, it doesn't make any sense to have the Sectoid Commander (the second highest-ranking alien) lower than all other aliens, which are all at some incongruous value. It seems pretty clear that some screw-up was copied to all aliens, but probably caught and corrected for the Sectoid Commander... they probably all should've been 190. Compare how all terrorists are 170, and all corpses are 180.
So, agreed. Good points, Zombie. -MikeTheRed 11:17, 3 September 2012 (EDT)

## Nice tables etc

Great work, Mike, thanks for this. It's very useful. User:Spike 07:20 6 September 2012 (EDT)

## Addendum on Project Timeline Milestones

Research project timelines lend themselves to a little more analysis. But I've placed this on the Talk page because, ultimately, it can't be put to much practical use. (Milestones can be charted, but all you really need to know is on the main Research Details page.)

The following is a table of the amount of time (min, average, and max) needed to finish research projects, depending on progress rating and whether the project was initially unknown or known (or regardless, i.e., plain Average). It also includes the corresponding inefficiency, which is equal to (Progress_Rating_Percent / 2) / Percent_of_Average.

This can be used this for:

• Initially-Known projects: The minimum project time is 50%, average 58%, max 67%.
• Average projects in general (without regard for Known or Unknown): Minimum is 50%, average is 100%, maximum 150%.
• Initially Unknown projects: Minimum is 67%, average is 108%, max is 150%.
• These can also be considered from the perspective of, after having crossed from Unknown to Known (i.e., Since Known). As of the point that 67% of the research is done: you are at the minimum time to complete an Unknown project (duh), average time left is 41.67% of a priori 100% average (13 - 8 = 5 twelfths), and the max time left is 83% (18 - 8 = 10 twelfths).
Project Timeline Milestones versus Completion Days and Efficiency
Progress

Rating

% Ave.

Assigned

50.00% 58.33% 66.67% 100.00% 108.33% 150.00% 41.67% 83.33%
Minimum Known

Average

Known

Boundary

Average Unknown

Average

Maximum Since Known
Ave. Max.
Max. Days to Complete with Min. Scientists for Progress Rating
Excellent 26% 1.92 2.24 2.56 3.85 4.17 5.77 1.60 3.21
Good 14% 3.57 4.17 4.76 7.14 7.74 10.71 2.98 5.95
Average 8% 6.25 7.29 8.33 12.50 13.54 18.75 5.21 10.42
Inefficiency
Excellent Same

as Above

26.0% 22.3% 19.5% 13.0% 12.0% 8.7% 31.2% 15.6%
Good 14.0% 12.0% 10.5% 7.0% 6.5% 4.7% 16.8% 8.4%
Average 8.0% 6.9% 6.0% 4.0% 3.7% 2.7% 9.6% 4.8%

While these values can be charted, they don't contribute much that is of practical use. So I've relegated them here. -MikeTheRed 13:40, 8 September 2012 (EDT)

## How does RESEARCH update PRODUCT and FACIL?

Do we know how the game knows how to update PRODUCT.DAT and FACIL.DAT? The game must set byte 16 in the relevant record of PRODUCT.DAT to 0 for newly manufacturable items. Presumably it does this about the same time it pops up the We Can Now Manufacture screen. And it must do something similar to FACIL.DAT for newly buildable facilities. But in the file descriptions of RESEARCH.DAT I don't see how it knows which PRODUCT.DAT or FACIL.DAT entry to modify. There is a pointer to UP.DAT to unlock the UFOPedia reference - can that also be used as a pointer into PRODUCT.DAT and FACIL.DAT somehow? Facilities are category 4 in UP.DAT, Human and Alien Weapons and Equipment are categories 2 and 3 respectively. Human and Alien Equipment references into UP.DAT explicitly provide the OBDATA.DAT reference - could that then be used to determine the correct PRODUCT.DAT reference? Or (somewhat crazily) find the correct BASE.DAT reference and work back from that to the PRODUCT.DAT reference? Even then that would not apply to Craft equipment and SWS ammo, neither of which have OBDATA.DAT references. Or is there a "shared order" being used here, rather than an explicit index into another file?

Does anyone know how this works - is this relationship between RESEARCH and PRODUCT/FACIL stored in executable code, rather than in a data file? Spike 20:00, 10 September 2012 (EDT)