Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

does the games are decompiled ? #4

Open
SeleDreams opened this issue Nov 7, 2016 · 1 comment
Open

does the games are decompiled ? #4

SeleDreams opened this issue Nov 7, 2016 · 1 comment
Labels

Comments

@SeleDreams
Copy link

Hello, i'm a member of touhou online and we would like to translate to french the pc98 touhou games, so i've been interested in your decompilation method of the games in order to translate them, could you tell me if it's usable and how ?

@nmlgc
Copy link
Owner

nmlgc commented Nov 8, 2016

First of all, ReC98 has been dormant for the last 7 months as I've

  1. had to deal with RL issues
  2. tried to actually figure out decompilation with the horrible syntax we have to deal with here, failed, got frustrated and then
  3. ultimately decided to go back to the thcrap project. And since it's actually used by at least a 5-digit number of people, it is the more important project of the two after all. While my original goal was to support the transition to MinGW/GCC and then lay the groundwork for a native cross-platform GUI using Qt, there are still a ton of tiny bugs that plague translators, which I've been struggling to catch up with.

Right now, ReC98 doesn't help with translation at all. Its goal is to perfectly reconstruct the original source code of the games, to the point where it is impossible to disprove that ZUN didn't originally write it like that. Only once this is done, we can then write a custom engine, which is what ultimately allows the 5 games to be translated into any language, since it will use Unicode text and fonts rather than Shift-JIS. So while translation will certainly be a focus of that new engine, it won't be the main goal for quite some time. In fact, ReC98 won't even care about any game data until it has reached the modernization phase described in the Readme file. Sure, part of the source code reconstruction will involve reverse-engineering all data formats, but everything that was necessary for translation in that regard has already been done as part of the work for the static English patch years ago.

So if you only want a translation and want it now, your best bet is to do a static patch by looking at how the English patch did these things and apply them for your language. As you're from Touhou-Online, NightLunya might still have the development documentation and image conversion tools from back when I ragequit everything on 3 August, 2014. If he doesn't, just tell me, and I'll throw that up somewhere.

The only real issue for a French translation would then be the accented characters. You would have two options there:

  1. Replace some halfwidth katakana in your emulator's font ROM (FONT.BMP) with the accented letters. This is trivial and requires no changes to the game code, but then your patch won't work on a real PC-98 or on emulators that don't use your FONT.BMP. (Who cares, right?)
  2. Or you might try to squeeze them into the few gaiji slots that ZUN leaves unoccupied in each game. (TH02, TH03, TH04, TH05). Will probably require some modifications to each game's text rendering in order to get this to work for halfwidth characters. This is something that ReC98 does somewhat help with, since I've identified most calls to non-ZUN functions (which includes master.lib, which is what displays the text).

So yeah, there really is no timeline anymore for when anything about ReC98, and more importantly, the actual decompiler will get done. However, once it is, the same perfect source code reconstruction can also be done more easily for a lot of other games. Not only PC-98 ones, but anything compiled with the old Borland C/C++ compilers and is 16-bit. (This includes the PC-98 version of Policenauts, for example,)

That said, I will call out translators myself once I'm far enough with the ports and once it is possible to translate the games.

@nmlgc nmlgc added the question label Nov 8, 2016
nmlgc added a commit that referenced this issue May 12, 2020
… color #4

That's… pretty specific. The only thing on the main menu with this
color is the "1996 ZUN" text at the bottom… probably part of an
effect that we never got to see. Every other idea would be baseless
speculation, given that the snapped buffer isn't used anywhere else.

Part of P0090, funded by Yanga.
@nmlgc nmlgc closed this as completed in 9358f3e Sep 7, 2020
@nmlgc nmlgc reopened this Sep 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants