Home World Forum
Stars! AutoHost web forums

Jump to Stars! AutoHost


 
 
Home » Stars! Clones, Extensions, Modding » Stars! Extensions » Stars! disassembly and history of 2.6jrc4
Stars! disassembly and history of 2.6jrc4 Sun, 24 February 2019 17:48 Go to next message
raptor is currently offline raptor

 
Chief Warrant Officer 1
Creator of StarsWine
Created StarsWine

Messages: 138
Registered: June 2014
Hi,

I've had disassembled both Stars! versions 2.7jRC3 (my old exe) and 2.6jRC4 the newest on the wiki. One thing I noticed is that the RC4 one is larger and seems to include some extra debug information because the disassembly has many, many more named functions in it.

Why would this be? Was the RC4 version accidentally released with extra debugging information? Or did someone from the community hack RC3 to create RC4, and in the process filled out some function names?

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Wed, 06 March 2019 22:43 Go to previous messageGo to next message
ricks03 is currently offline ricks03

 
Officer Cadet 1st Year
Creator of TotalHost and Stars! utilities
Created TotalHost and Stars! utilities

Messages: 222
Registered: January 2012
Location: NC
2.6jrc4 was released by the Jeffs. Given that it's still labeled "release candidate" I suspect it still included debug information, probably in part because it was debugging something from rC3?


https://www.irelandbybicycle.com
http://totalhost.sinister.net:999
https://github.com/ricks03/TotalHost

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Wed, 06 November 2019 18:24 Go to previous messageGo to next message
talkingbologna is currently offline talkingbologna

 
Senior Chief Petty Officer

Messages: 86
Registered: November 2016
Location: 1947
Hey Raptor,

If you don't mind me asking, how are you disassembling it?

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Wed, 06 November 2019 19:57 Go to previous messageGo to next message
raptor is currently offline raptor

 
Chief Warrant Officer 1
Creator of StarsWine
Created StarsWine

Messages: 138
Registered: June 2014
Hi,

I used 'IDA Free' (32bit) version, and I've also used the newly open-sourced 'Ghidra'. Neither are for the faint of heart. Smile

The 2.6jRC4 disassembles *much* cleaner (even with method names!) than 2.7.

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Mon, 11 November 2019 11:21 Go to previous messageGo to next message
Ron is currently offline Ron

 
Commander
Forum Administrator
Stars! AutoHost Administrator

Messages: 1231
Registered: October 2002
Location: Collegedale, TN
ricks03 wrote on Wed, 06 March 2019 22:43
2.6jrc4 was released by the Jeffs. Given that it's still labeled "release candidate" I suspect it still included debug information, probably in part because it was debugging something from rC3?

No, it does not include debug info that I know of.

I have a special debug version of the 2.6jrc4 exe file, with a password that lets me open any passworded play file.



Ron Miller
Stars! AutoHost

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Mon, 11 November 2019 15:56 Go to previous messageGo to next message
raptor is currently offline raptor

 
Chief Warrant Officer 1
Creator of StarsWine
Created StarsWine

Messages: 138
Registered: June 2014
Hi Ron,

Is your version the same download that I used that is found at the top of this wiki page?:

https://wiki.starsautohost.org/wiki/Get_Stars!

When I said I thought it was a debug version, it was specifically because the disassembled EXE contained cleaner logic (i.e. non-optimized) and the function names were not stripped out of the executable.

How is your version different?

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Mon, 11 November 2019 21:24 Go to previous messageGo to next message
Ron is currently offline Ron

 
Commander
Forum Administrator
Stars! AutoHost Administrator

Messages: 1231
Registered: October 2002
Location: Collegedale, TN
The debug exe I have is around 400kb larger than the regular 2.6jrc4 exe.


Ron Miller
Stars! AutoHost

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Wed, 18 March 2020 18:10 Go to previous messageGo to next message
platon79 is currently offline platon79

 
Chief Warrant Officer 3

Messages: 185
Registered: February 2004
Location: Norway
Heh 2.6jrc4 disassembled? How does the disassembled code look? Can it be compiled again easily in some working order? If so, how easy is it to fix some bugs and make a jrc5?.. Wink

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Sat, 18 April 2020 11:52 Go to previous messageGo to next message
raptor is currently offline raptor

 
Chief Warrant Officer 1
Creator of StarsWine
Created StarsWine

Messages: 138
Registered: June 2014
platon79 wrote on Wed, 18 March 2020 18:10
How does the disassembled code look? Can it be compiled again easily in some working order? If so, how easy is it to fix some bugs and make a jrc5?


Disassembled code is usually pretty ugly and difficult to reverse, but it depends on the language: java/C# is easy to reconstruct, C/C++/Delphi is not. Stars! was written in C or Delphi so it can't really be reconstructed that well. To see what C source code converted to assembly looks like, see here:

https://godbolt.org/

But to go in the reverse direction (called de-compiling) is quite difficult because the compiler can do all sorts of crazy things to the source code to make it more efficient, reduce the logic, and convert it to machine code. To see what a portion of Stars! looks like in disassembly, see here:

https://starsautohost.org/sahforum2/index.php?t=msg&goto =63369#msg_63369

which comes from a thread where I attempted to figure out the race file corruption by looking at the disassembly and a partial decompile.

As for converting to 32-bit - that would require the original source code and it'd have to be updated to use 32-bit Windows functions instead of the 16-bit ones.

Fixing bugs is possible - because if you can trace out the logic in the assembly you can make direct binary modifications to the file that might be able to bypass some issue or fix another. But I'm not very good at this (yet).

Report message to a moderator

Re: Stars! disassembly and history of 2.6jrc4 Sun, 19 April 2020 02:41 Go to previous message
platon79 is currently offline platon79

 
Chief Warrant Officer 3

Messages: 185
Registered: February 2004
Location: Norway
Decompiling seems like a wet dream. Seems like stars was compiled with Visual C version 1.5 if that would help someone. But I just reread what I myself had pasted from elsewhere in my 6 year old "stars 3" thread, post nr 3, https://starsautohost.org/sahforum2/index.php?t=msg&th=5 405&prevloaded=1&rid=472&start=0&rev=59916&a mp;SQ=59636dfe4b0a0c85c753ff1679c7c267&
And I realise that even with a relatively good decompilation, tweaking the game is almost impossible. Sad

Report message to a moderator

Previous Topic: Player messages fully decoded
Next Topic: X-file-sanitizer
Goto Forum:
  


Current Time: Thu Mar 28 13:28:45 EDT 2024