Page 1 of 1

The Ground Combat Tech Level Multiplier

Posted: Thu May 01, 2008 5:16 pm
by Gowron
While researching how to tame the insta-terraforming exploit, I accidentially found the ground combat tech level multiplier in trek.exe.

How Ground Combat works:
viewtopic.php?name=Forums&file=viewtopic&t=56

The tech level influence is expressed by the factor
1 + 0.1 * [current weapon tech level]

The 0.1 is stored in trek.exe.
position: 0x178B04
length: 8 bytes

--------------
Update:

There's a second instance of the ground combat tech level multiplier at position 0x178A4C. It is only used during ground combat calculation and therefore not visible in the game. But since this one is a shared multiplier, changing it could have negative side effects.
Instead, you can change the critical reference to the second instance of the multiplier to a reference to the primary multiplier by changing
"4C AC 57 00"
to
"04 AD 57 00"
at position 0x6670E in trek.exe. This way you can be sure that your changes are consistent.
(this will also be done for BoP asap)
--------------

Negative values are possible and can lead to a negative ground combat strength. For some strange reason, this did not cause a crash when I tested it. I successfully conquered Bynaus (Ground Defense 15) with a Cardassian TT2 that had a Ground Combat value of -25. Funny ^^



The actual task has become a lot harder to reach, unfortunately. As if there weren't enough ties and bounds regarding the work rates of TTs and Colony Ships, there's another problem to deal with:
As you probably know, the work rate of a TT is divided by 10 when calculating its ground combat strength. But that's not the problem. The point is that the remainder is discarded. So a TT must have a work rate of 10 at the least, or it will have zero strength, no matter how high the race-specific constant is. Now this really sucks.

I've tested every 0.01, 0.1, 10.0 and 100.0 in trek.exe, but this issue didn't change. I've also tested about 70% of all occurences of "0A00" (=10) in trek.exe, with no result as well. I'll not test the other 30% - too many crashes, a few times trek.exe even deleted my stbof.ini while crashing :?

Posted: Thu May 01, 2008 7:01 pm
by sean_west
The ideas you have found while working with trek.exe are great, but way over my head. are you planning to create and editor so us mere mortals can "play"?

Posted: Fri May 02, 2008 2:06 pm
by Gowron
Ask DCER, he's the editor guy ;) :D

No, the problem is, as always, time. I hardly find any time to work on my BotF mod, let alone starting any new projects like an editor.

Posted: Wed May 07, 2008 7:45 am
by DCER
If a colony ship has a production value of 9 and a TT 10, then the insta-terraforming shouldn't be such a problem anymore. Adding TT's to the task force would be roughly the same as adding additional colony ships.

One would only need to modify the combat multipliers and outpost/starbase industry costs.

Posted: Wed May 07, 2008 1:36 pm
by Gowron
DCER wrote:If a colony ship has a production value of 9 and a TT 10, then the insta-terraforming shouldn't be such a problem anymore. Adding TT's to the task force would be roughly the same as adding additional colony ships.

One would only need to modify the combat multipliers and outpost/starbase industry costs.
Correct. That's almost exactly what I did in Balance of Power ;)

In addition, I made TTs about twice expensive as colony ships.

Re: The Ground Combat Tech Level Multiplier

Posted: Sun May 24, 2009 6:57 am
by Spocks-cuddly-tribble
Gowron wrote:the work rate of a TT is divided by 10 when calculating its ground combat strength. But that's not the problem. The point is that the remainder is discarded. So a TT must have a work rate of 10 at the least, or it will have zero strength, no matter how high the race-specific constant is. Now this really sucks.

I've tested every 0.01, 0.1, 10.0 and 100.0 in trek.exe, but this issue didn't change. I've also tested about 70% of all occurences of "0A00" (=10) in trek.exe, with no result as well. I'll not test the other 30% - too many crashes, a few times trek.exe even deleted my stbof.ini while crashing :?
:arrow: Is in trek.exe at 0x49C5C // asm code loc_44A835

Be careful not "accidentially" to replace "idiv" with "imul".:wink:

Posted: Sun May 24, 2009 11:17 am
by Gowron
Thank you :)

This little bugger had been able to hide for more than a year, but now it's one more closed gap :)

Posted: Sun Aug 01, 2010 10:24 am
by Gowron
A small but important update.
(see the first posting)