Decompiling a SNES game to its source code

Deleted member 42501

Well-Known Member
OP
Member
Joined
Jun 16, 2006
Messages
1,724
Trophies
2
XP
4,259
Considering the size of these titles it should be a much easier endeavor than the larger stuff we've seen right? This recent mouse patch for Shadowrun on SNES got me thinking:

https://gbatemp.net/threads/shadowrun-mouse-patch.614185/

As it needs a special fork of SNES9x to work with the scripting meaning either that gets ported to 3DS/Vita (where stylus/touchscreen would work so well) or the game is decompiled, new controls added in and its ported as native.

Given the originality of this game I'm certain people would be happy to contribute as its generally forgotten in terms of modernization and the new games don't have the same charisma as the original pixel art (but clunky controls) version.

@FAST6191 @godreborn Any insight on this process/feasibility?
 

hippy dave

BBMB
Member
Joined
Apr 30, 2012
Messages
9,918
Trophies
2
XP
29,923
Country
United Kingdom
8 & 16 bit games were more likely to have been written in assembler in the first place, rather than a higher level language like C. So to get close to the original source you'd be disassembling rather than decompiling, and that's always been possible, it's just a much more tedious task to go through a raw assembler listing to figure out and document what each routine does. It's been done completely for some smaller games like Game Boy Tetris and old arcade games from the 8 bit era, it's equally possible but just a lot more work for bigger and more complex SNES games etc.
 

FAST6191

Techromancer
Editorial Team
Joined
Nov 21, 2005
Messages
36,798
Trophies
3
XP
28,402
Country
United Kingdom
As above most things prior to the PS1 were likely written in their respective console's assembly, or maybe a form BASIC if that was a thing for the given system* (and even then assembly was way faster so only the simplest of games are likely to be that). While some think 3d was the big jump for the PS1 then I would probably put the bigger aspect at the feet of C compilation beyond proof of concept being a possibility.

*pretty much going to be the "minicomputers" a la BBC micro, C64, vic20, amstrad, atari... some of the later stage ones of those (Amiga and whatever was happening in Japan might just have a C compiler be something worth using in anger but I would be surprised if much really used them)

There are occasional oddities https://www.pagetable.com/?p=28 but for the most part it is going to be the same manual effort as any other disassembly unless you get a leak (see also the gigaleak stuff) but those are just as likely to be wanted by the original devs as lost source is pretty much assumed these days.
 

Deleted member 42501

Well-Known Member
OP
Member
Joined
Jun 16, 2006
Messages
1,724
Trophies
2
XP
4,259
Thanks for the info, I gave you a shout as I had a feeling you'd share some insight. Thought there must've been a bit more that I thought otherwise we'd have decomps of everything.

This game in particular always seemed much more suited to mouse and keys than a limited dpad and the above tweak is awesome. Just prefer my gaming on a portable. If you haven't played it give it a try, its really quite special and stands on its own two.

 

Retro2Modern

Active Member
Newcomer
Joined
Feb 1, 2023
Messages
40
Trophies
0
Age
35
XP
121
Country
United States
This makes me wonder if it's possible to decompile ROM's of the SNES Donkey Kong Country Trilogy and translate a bit of code into C++ or C#.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • Psionic Roshambo @ Psionic Roshambo:
    Lol they exist?
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    Hmmm so Mario Does Luigi's plumbing is a bad movie? Lol
  • Psionic Roshambo @ Psionic Roshambo:
    These videos are soooo dry
  • Psionic Roshambo @ Psionic Roshambo:
    Please click all suspicious links sent your email
    +1
  • BigOnYa @ BigOnYa:
    What to do today? Cut grass for 3-4 hours, or just get drunk and play video games... Hmm
    +1
  • BigOnYa @ BigOnYa:
    I need a remote controlled mower, so I can sit on the couch and do both.
  • BigOnYa @ BigOnYa:
    Sounds good to me, video games and booze it is then.
    +1
  • denpafan @ denpafan:
    Good choice
    +1
  • BigOnYa @ BigOnYa:
    Now what to play, Starfield or Fallout4. And what to drink, beer or Whiskey and Coke. Such tough decisions.
  • BigOnYa @ BigOnYa:
    Looks like its whiskey & coke, only 4 beers left. And think ill start with Falllout. :grog:
  • rqkaiju2 @ rqkaiju2:
    THIS IMAGE IS SO SCARY WTF. THAT SURE AS HELL IS NOT A CAT THATS LIKE A FUCKING DEMON

    Untitled2.png
  • Psionic Roshambo @ Psionic Roshambo:
    Bonus points for running things over with the lawn mower?
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    Monster truck Lawn Mower extreme
    +1
  • BakerMan @ BakerMan:
    she was an apple appstore girl
    he was an uptodown boy
  • Psionic Roshambo @ Psionic Roshambo:
    He was an android boy
  • Psionic Roshambo @ Psionic Roshambo:
    She said see ya later boy lol
  • BakerMan @ BakerMan:
    something something boomer and r/im14andthisisdeep "ThAt'S tHe UnFoRtUnAtE sTaTe Of OuR mOdErN sOcIeTy"
  • BakerMan @ BakerMan:
    except they'd criticize you for having a phone in the first place lmao
  • Psionic Roshambo @ Psionic Roshambo:
    In my day we used smoke signals and liked it!!!
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    5G gives you covid!! Kills bees and lets the devil control your sperm!!! *Walks away frothing at the mouth*
    +1
  • BakerMan @ BakerMan:
    back in my day we just talked in person to communicate, and used books for entertainment, now pull yourself up by the bootstraps and develop a sense of work ethic, ya darn whippersnappers!
  • NormalCatelol @ NormalCatelol:
    "lets the devil control you sperm!!!" iwantsummadat!
    NormalCatelol @ NormalCatelol: "lets the devil control you sperm!!!" iwantsummadat!