Slashdot Mirror


Reverse Engineering Large Software Projects?

stalebread queries: "Me and a team of other students have been tasked with reverse engineering a massive C/C++ (mostly C) computer game of about half a million lines. We have most of the source, but no clue of how to approach a task of this magnitude. Anyone have suggestions of programs, or techniques we could use to understand the structure of the game?"

5 of 104 comments (clear)

  1. It could help... by itistoday · · Score: 2, Insightful

    To understand how games are made in the first place. What kind of a game is it? Is it a single player game, or multiplayer game? If it's multiplayer you'll have to watch out for code designed to keep the game logic at a fixed rate; all other code will be built on top of that. Singly player games on the other hand don't have to worry about all the intricacies of keeping the various game clients in sync.

    So it really depends on the kind of game it is. Since I'm assuming you know this, I would suggest trying to first think how you would write the game yourself, and then see if you find any similarities between your ideas for the engine structure and the games.

  2. WTF? by jericho4.0 · · Score: 1, Insightful
    It looks like I get to be the first one to call you on this. WTF are you talking about!? You don't 'reverse engineer' something you have the code for. Maybe you mean 'port' or 'complile'.

    If you wish to start getting a handle on a chunk of code, start by reading main() along with a profilers output. Grep is your friend.

    --
    "A language that doesn't affect the way you think about programming, is not worth knowing" - Alan Perlis
    1. Re:WTF? by kisielk · · Score: 3, Insightful

      Just because you have the code doesn't mean you know how the system is assembled and how all the components work together. "Reverse Engineering" is a pretty loosely defined, but if you take it literally, it's just that.. reversing the engineering process. From the description of the question, the poster is looking to take the finished product (the source for this game..) and move back up the high level design phase. This means analyzing the module interconnections, class hierarchy, and that sort of stuff. It doesn't necessarily mean they want to "port" or "compile" it.

  3. Have most of the code? by mnmn · · Score: 2, Insightful

    It is not 'reverse engineering' if you already have the code. So you'll be reverse engineering the part that you dont have a code for, and making sense out of the code that you do have.

    Draw flow charts. Then assign a seperate person for each module to make sense out of it. Next you'll do what you plan to do....

    Make mods for it? Make a clone? Rewrite the code and sell the code? Recompile and port to Linux?

    --
    "Give orange me give eat orange me eat orange give me eat orange give me you." -Nim Chimpsky
  4. Re:Legal? by Macphisto · · Score: 3, Insightful

    "Human capital"? What are you, an alien overlord of some sort?