Tech Level Bonuses for Ships

Tech Level Bonuses for Ships; support/discussion/questions

Moderator: thunderchero

Post Reply
User avatar
Spocks-cuddly-tribble
Code Master
Code Master
Posts: 1883
Joined: Sun Apr 27, 2008 2:00 am

Tech Level Bonuses for Ships

Post by Spocks-cuddly-tribble »

usane wrote:The tech levels really influence anything? And how. I mean for example: every level on energy tech tree is increase shield strength or sg like that.
I read in some topic it works but if it works then how. What are the rules? Have u found the code? I couldnt find it in modding section.
I think the shield rule is maybe simple, but what about weapon? Is the weapon efficiency affected by the weapon tech tree? And the others?
The future tech topic should be quite informative for you. It lists ALL (yes, we know them all!) tech level effects:
viewtopic.php?f=9&t=96

For ships is no current-tech-bonus feature implemented (excepting for ground combat of TTs), but it can be done. It's not complicated, even an ASM-noob could do it, but a time-consuming, boring work and needs to be done very accurate (2 times if also for stations).

Here are some technical hints how to do it:

-> get raceID from Gshiplist entry (see wiki)

call 453710 raceEAX_techinfo_entry_to_[eax]
-> byte [eax+4+8*techID] = current techlevel (f.e.+14h/construction)
or alternatively: call 453680 raceEAX_techIdEDX__TechLevel_to_eax

call 46F940 shipTech_sst_entry_shipIdEAX_to_[edx]
-> byte [edx+8+techID] = tech-area requirement of the ship

Tech IDs:

0 - Biotech
1 - Computer
2 - Construction
3 - Energy
4 - Propulsion
5 - Weapon
6 - Lowest Tech level (for all tech req.)


Subtract [tech requirement] (since already implemented in shipstats) from [current owner techlevel] and add result as bonus to the desired ship values.

F.e. Computer*3 (resp. *2 torpedo) to beam accuracies, Energy*2 to shield recharge, Weapon to damage values...



sub_520D70 -> set combat abilities of ships, stations & monsters

esp -> shiplist_sst entry

[esp+1B8h] -> address of Gshiplist entry

Results gets written to the ds:[597864] entry of the ship:

[esp+12Ch] -> address of ds:597864 entry of ship/station/monster

The inefficient code can be shortened to free up code for the new features. For ships I'd start at 00521290 -> plasma accuracy, 002139F -> phaser accuracy, 0052149E -> torpedo accuracy, 00521581 -> shield recharge...

(some ds:597864 infos from an old note pad)
+14C agility ?
+1DC owner race ID
+1EC Shield Strength

+228 plasma minimum distance?
+230 plasma max range...
+234 ...
+25C plasma accuracy (+EPs bonus -> same as beam)
+260 plasma shots
+264 plasma Multiplier
+268 plasma damage
+26C plasma Shield Penetration
+270 [4 - exp level] * 65536 / plasma shots

+2B4 beam accuracy (+EPs bonus)
+2B8 phaser shots
+2BC beam multiplier
+2C0 beam damage
+2C4 shield penetration ?
+2C8 [4 - exp level] * 65536 / phaser shots

+308 torpedo accuracy

+328 current Shield Strength
+32C nominal Shield Strength
+330 shield level
+334 Shield Recharge
+338 current hull points
+33C nominal hull
+340 defense (+EPs bonus)
+344 damage control
I don't know how many bugs is too many but that point is reached somewhere before however many in BotF is.
Post Reply

Return to “Tech Level Bonuses for Ships”