Outpost/Starbase for free bug-fix

Outpost/Starbase for free bug-fix; support/discussion/questions

Moderator: thunderchero

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

Outpost/Starbase for free bug-fix

Post by Spocks-cuddly-tribble » Wed Dec 01, 2010 6:34 pm

Instant Outpost/Starbase for free upgrading-fix


This is a two-in-one bug fix: :)


1.) Instant station for free (i.e. build / upgrade incomplete station)

2.) Instant repair of all hull damage when autoupgrading stations


The old hull points are kept (i.e. upgraded station will regenerate to new nominal hull).

This is also recommended for upgraded ships, btw. :wink:

Note the Outpost/Starbase self-repair bug (fix) :idea:


Code: Select all

In trek.exe at 0x4971E
replace (39 bytes):
DB 84 24 20 01 00 00 31 C0 DD 59 38 66 8B 84 24 14 01 00 00 89 41 48 DD 41 38 8B 84 24 A8 00 00 00 DD 59 40 89 41 4C
with:
DD 41 40 DC 59 38 DF E0 9E DB 84 24 20 01 00 00 72 03 DD 51 40 DD 59 38 0F B7 84 24 14 01 00 00 89 41 48 90 90 90 90


44A31E     DD41 40              FLD QWORD [ECX+40] // production invested
44A321     DC59 38              FCOMP QWORD [ECX+38] // old build cost
44A324     DF E0                fnstsw  ax
44A326     9E                   SAHF
44A327     DB8424 20010000      FILD [ESP+120] // build cost new
44A32E     72 03                JB SHORT 44A333 // if unfinished skip next
44A330     DD51 40              FST QWORD [ECX+40] // set new production invested
44A333     DD59 38              FSTP QWORD [ECX+38] // set build cost new
44A336     0FB78424 14010000    MOVZX EAX,WORD[ESP+114] // scan range
44A33E     8941 48              MOV DWORD [ECX+48], EAX // set scan range
44A341     90909090             NOP
Alternatively, removing this statement, turns off auto-upgrades for stations:

Code: Select all

4526D8     E8 B37BFFFF     CALL 44A290

Funny side note:

DCER today updated the BotF Wiki starBaseInfo with the same data I discovered for this fix. So I was a bit confused, cause I didn't remember entering, until I noticed it's a fresh update by DCER. :)
Last edited by Spocks-cuddly-tribble on Sat Dec 11, 2010 6:55 am, edited 1 time in total.
On the verge of a nervous breakdown? Try the relaxing tribble sounds.

User avatar
DCER
Code Master
Code Master
Posts: 683
Joined: Sat Apr 26, 2008 2:00 am

Post by DCER » Thu Dec 02, 2010 6:41 pm

Funny :)

I found those when I was trying to figure out how botf stores outpost completion so I could display/set it in UE.

I'm glad you're updating it (too :) ). That wiki is my goto for save game info.

Post Reply

Return to “Outpost/Starbase for free bug-fix”

Who is online

Users browsing this forum: No registered users