News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!  (Read 1290 times)

filler

  • RHDN Patreon Supporter!
  • Hero Member
  • *****
  • Posts: 812
  • "WINNERS DON'T SELL REPROS"
    • View Profile
    • Filler's Translation Projects
[Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« on: October 11, 2018, 11:48:47 pm »
Looking for a willing ROM hacker to insert the already English translated script, and perform necessary tasks to ensure all Japanese text appears in English, for Crayon Shin-chan: Taiketsu! Kantam Panikku!! for the Sega Game Gear.

English translated script and some notes available here: http://mattsmessyroom.com/uploads/crayon_shinchan_gg_script_package.7z

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #1 on: October 12, 2018, 04:37:17 am »
I know I should probably finish Zoids first, but the amount of text in this game seems pretty small, so I'll have a look. If I want to go ahead with it, I'll let you know, but anyone else is welcome to try, too.

filler

  • RHDN Patreon Supporter!
  • Hero Member
  • *****
  • Posts: 812
  • "WINNERS DON'T SELL REPROS"
    • View Profile
    • Filler's Translation Projects
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #2 on: October 12, 2018, 12:58:02 pm »
Thanks for taking a look. :)

filler

  • RHDN Patreon Supporter!
  • Hero Member
  • *****
  • Posts: 812
  • "WINNERS DON'T SELL REPROS"
    • View Profile
    • Filler's Translation Projects
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #3 on: November 30, 2018, 03:52:02 pm »
Any luck with this?

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #4 on: December 02, 2018, 05:21:10 am »
Sorry, when I said "I'll have a look", what I should've said was "I'll have a look for five minutes then forget about it". :-[ Still, I spent 20 minutes or so this morning and came up with this:



Thankfully, because the game doesn't have much text and uses a 4Mbit game cart, there's no consideration for space saving, which makes hacking a breeze. I suppose I should finish what I've started now. :D

filler

  • RHDN Patreon Supporter!
  • Hero Member
  • *****
  • Posts: 812
  • "WINNERS DON'T SELL REPROS"
    • View Profile
    • Filler's Translation Projects
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #5 on: December 02, 2018, 09:33:14 pm »
 :woot!: Woohoo! Now you've done it. ;)

EDIT: FYI In case you take a stab at the title screen, the title is Crayon Shin-chan Showdown! Quantum Panic!!

I used to watch fansubs of this back in the day and it was always transliterated as "Kantam" and the theory was that it was just an altered parody of "Gundam". However, more modern online Japanese resources provide a translation of "kantam" as "quantum" and thus the show in Crayon Shin-chan is called "Quantum Robo" which totally sounds like a giant robot show. The only reason I mention this is that I just looked at the readme again, and I happened to leave it as "kantam" in one instance so I wanted to avoid confusion.

Also I might be wrong anyway because Japanese. :D
« Last Edit: December 02, 2018, 09:48:39 pm by filler »

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #6 on: December 03, 2018, 04:49:16 pm »
I spoke too soon about a lack of compression. :-\

For reasons best known to the programmers, instead of using the full kana set which is sitting uncompressed in the ROM, it goes through a decompression routine of some description. I suppose when the text is just two colour, there's a degree of compression available - but there are TWO uncompressed kana sets in the ROM! The mini game descriptions uses one of them, but the story mode goes through this nonsense.

Hopefully I can reverse engineer the decompression and figure out how to put my alphabet in that format. But it's a pain.

EDIT: Well, I think I've cracked the compression. Still don't know why they did it, but whatever.

Basically instead of using 32 bytes per tile, the game uses 16 bytes, but instead of storing the bytes as they will appear in VRAM, it loads the first byte as normal, then uses it to XOR against the next byte in order to get the correct byte. Why?! It doesn't save any space, it doesn't seem to serve any purpose aside from making it appear unreadable in Tile Molester. What baffles me more is that, due to the font being only 1bpp, they could've easily halved it again to 8 bytes per tile.

So, now I just need to use an XOR calculator online to go through every tile, and I should be on my way. Hmm, maybe OpenOffice Calc has an XOR function, that'd save time...
« Last Edit: December 04, 2018, 06:13:51 am by Psyklax »

dr.slump

  • Jr. Member
  • **
  • Posts: 12
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #7 on: December 04, 2018, 08:35:59 pm »
:woot!: Woohoo! Now you've done it. ;)

EDIT: FYI In case you take a stab at the title screen, the title is Crayon Shin-chan Showdown! Quantum Panic!!

I used to watch fansubs of this back in the day and it was always transliterated as "Kantam" and the theory was that it was just an altered parody of "Gundam". However, more modern online Japanese resources provide a translation of "kantam" as "quantum" and thus the show in Crayon Shin-chan is called "Quantum Robo" which totally sounds like a giant robot show. The only reason I mention this is that I just looked at the readme again, and I happened to leave it as "kantam" in one instance so I wanted to avoid confusion.

Also I might be wrong anyway because Japanese. :D
Just to say I don't see any grounds for translating it as "Quantum" when it' clearly just a parody of "Gundam".
The obvious choice would be...
https://kenjiurban.blogspot.com/2007/09/cuntam-robo.html
 ;D

filler

  • RHDN Patreon Supporter!
  • Hero Member
  • *****
  • Posts: 812
  • "WINNERS DON'T SELL REPROS"
    • View Profile
    • Filler's Translation Projects
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #8 on: December 05, 2018, 01:21:42 am »
I spoke too soon about a lack of compression. :-\

For reasons best known to the programmers, instead of using the full kana set which is sitting uncompressed in the ROM, it goes through a decompression routine of some description. I suppose when the text is just two colour, there's a degree of compression available - but there are TWO uncompressed kana sets in the ROM! The mini game descriptions uses one of them, but the story mode goes through this nonsense.

Hopefully I can reverse engineer the decompression and figure out how to put my alphabet in that format. But it's a pain.

EDIT: Well, I think I've cracked the compression. Still don't know why they did it, but whatever.

Basically instead of using 32 bytes per tile, the game uses 16 bytes, but instead of storing the bytes as they will appear in VRAM, it loads the first byte as normal, then uses it to XOR against the next byte in order to get the correct byte. Why?! It doesn't save any space, it doesn't seem to serve any purpose aside from making it appear unreadable in Tile Molester. What baffles me more is that, due to the font being only 1bpp, they could've easily halved it again to 8 bytes per tile.

So, now I just need to use an XOR calculator online to go through every tile, and I should be on my way. Hmm, maybe OpenOffice Calc has an XOR function, that'd save time...

Glad you made some headway! This made me think of that thread where I asked why so many of these games have multiple fonts and weirdness. I forget if you commented there, but it just seems like random folks worked on different aspects of these games and did whatever they felt like at the time. The lower budget the game, the more those issued seem to crop up.

Just to say I don't see any grounds for translating it as "Quantum" when it' clearly just a parody of "Gundam".
The obvious choice would be...
https://kenjiurban.blogspot.com/2007/09/cuntam-robo.html
 ;D

Lol! I assume you're just playing this for laughs, but if you do want to see support for the "quantum" argument, I think the sample sentences here are quite compelling. https://ejje.weblio.jp/content/%E3%82%AB%E3%83%B3%E3%82%BF%E3%83%A0

Orochi Kusanagi

  • Jr. Member
  • **
  • Posts: 59
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #9 on: December 05, 2018, 01:33:33 am »
The Chogokin figure box says Kantam Robo for what it's worth. I don't think Quantum is a bad choice either though, it just makes it sound like a super robot parody instead of a Gundam one. And truthfully, it doesn't look like a Gundam.

The only one I can't really get behind is Kuntam Robo... considering it is similar to a very profane word.

dr.slump

  • Jr. Member
  • **
  • Posts: 12
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #10 on: December 05, 2018, 02:20:50 am »
Lol! I assume you're just playing this for laughs, but if you do want to see support for the "quantum" argument, I think the sample sentences here are quite compelling. https://ejje.weblio.jp/content/%E3%82%AB%E3%83%B3%E3%82%BF%E3%83%A0
No, I was being serious. Although obviously the connotations of "Cuntam" for English speakers are problematic. Those sentences look like they're all from patents; it's not in common use by any means (quantum would usually be rendered クオンタム) and the JP audience will instantly recognize the name as a Gundam reference.

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #11 on: December 05, 2018, 03:55:43 am »
Okay, allow me to weigh in on the issue.

Although it has been transliterated as Kantam or Cuntam (lol), a Google search shows that there are clearly companies with Quantum in their name which use カンタム as the Japanese version.

Another point in Filler's favour: the Xbox game Quantum Redshift is known in Japan as カンタム レッドシフト 超高速空間 バトルレース. So, again, カンタム equals Quantum.

To be honest I don't really care either way. :D To avoid any arguments about this rather trivial point, I'm happy to make two patches, one with Quantum and one with Kantam.

Back to the hacking. The compression was doing more than I expected, but I'll explain here for the benefit of any interested parties - I always think it's good to talk openly about these things for the sake of getting information on record, for those who are learning to hack or who encounter similar issues.

Each 8x8 tile begins with 4 bytes explaining how the 8 pairs will be. A 3 means it's a new value, a 0 means it's the same as the previous value. This is done in two sets, so the first two bytes detail the first four byte pairs, the second two bytes detail the other four pairs. It's assumed that we're starting at zero, so if the first byte pair is zero, you can say it's a repeat of the previous one.

Let's use an example instead of confusing you further.
33 33 33 33
This means that every byte pair that is to follow is unique, so it's followed by 8 byte pairs (16 bytes), but remember that they go through that stupid XOR routine that I can't get to do in OpenOffice Calc.
30 33 33 03
This means the first byte pair is 00 00, because zero means it's the same as the previous. Oh, did I mention it's little-endian? Yeah, it is. Note that if in this example, the fourth byte pair is 7E 7E, and so is the fifth, it is still 3 because it only does four at a time, so for the fifth, we're back to zero again. And byte pair 8 is the same as byte pair 7, because little-endian. So now you only need 6 byte pairs because we eliminate the two repeaters.

Confused yet? Well, it took me a few hours to piece all this together, but now I've got it sussed. I just have to look at the 8 bytes I need, decide which ones repeat, then put the 4-byte header and the necessary byte pairs (after going through the XOR process with an online calculator since I don't think Windows' calculator does it) into the ROM. I've done a few letters successfully, but it would be good to automate the process somehow.

All this makes me think... WHY?! They don't even need a pair! Each pair is identical! Look, if each pair is unique, you have a 4-byte header plus 16 bytes for the tile. That's 20 bytes which could be done in just 8 with no real compression whatsoever!! Honestly, why do they do this to me... especially when there's two perfectly good kana sets sitting in the ROM. Ugh...

Anyway, I continue. ::)

dr.slump

  • Jr. Member
  • **
  • Posts: 12
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #12 on: December 05, 2018, 04:44:56 am »
I'm happy to make two patches, one with Quantum and one with Kantam.
I think Cuntam deserves its own patch too, tbh.

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #13 on: December 05, 2018, 11:48:05 am »
Whew boy, at last, I've put the font into the format the game desires, so we end up with this:


I hope you don't mind that I've expanded on your original translation a tad, because thanks to the way this game does the screens, I have the entire screen space to play with, so I might as well make it sound better. Now I just need to put your (rewritten) script in there, and it's off to mess with the graphics. Hopefully that won't cause me such a headache, since it looks like everything is uncompressed.

Maybe we need to shift this thread from Help Wanted to Personal Projects at this point? :D

EDIT: I'm making a habit of speaking too soon on this project. :)

So that compression scheme used for the font... it's also used for the title screen, and maybe some other stuff too. Strangely the graphics for Shin-chan saying "press button 2" when you hang around on the game explanation screen is uncompressed, so I've already edited that. But this compression scheme was relatively simple to deal with when it was a 1-bit font, but this is full colour. The whole XOR process is going to cause me some real headaches.

The game has the graphics compressed in the ROM, and naturally it decompresses it into VRAM when it loads the game, so that's not a problem. I also know precisely how the decompression works, and how the header works. I just need a way to compress the graphics I want to use to put them into the ROM, and for that I think I'll need to write a program.

The funny thing is that with minor modifications, the decompression routine in the game can basically compress rather easily: XOR works both ways. So XORing 66 with 99 gives FF, but then XORing FF with 99 gives 66, so you don't even have to modify the code much. You just have to do it in reverse order, but that's relatively simple. Hopefully I'll figure out an elegant solution.
« Last Edit: December 05, 2018, 03:33:37 pm by Psyklax »

dr.slump

  • Jr. Member
  • **
  • Posts: 12
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #14 on: December 05, 2018, 09:19:02 pm »
Let me know if you'd like the script proofread - I took a brief look and noticed ハイグレギャル was translated differently in different parts, for instance.

Also, I guess it probably won't be a problem but it would be nice to ensure compatibility with this:
http://www.smspower.org/Hacks/CrayonShinChan-GG-GG2SMS

Psyklax

  • Hero Member
  • *****
  • Posts: 778
    • View Profile
    • Psyklax Translations
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #15 on: December 06, 2018, 04:53:58 am »
Let me know if you'd like the script proofread - I took a brief look and noticed ハイグレギャル was translated differently in different parts, for instance.

Filler knows what he's doing, so he has a perfectly good reason for doing that. If you check my history, you'll see that I'm perfectly able to work with Japanese myself.

Also, I guess it probably won't be a problem but it would be nice to ensure compatibility with this:
http://www.smspower.org/Hacks/CrayonShinChan-GG-GG2SMS

I see no reason why it would be a problem, since I'm not doing anything the base game doesn't do itself. Though to be honest I don't think this game benefits from GG2SMS at all, unlike something like Coca-Cola Kid. It's only useful if you have a Mega Everdrive and simply must play it on real hardware with crappy colours. :D

Anyway, I've made a new thread in Personal Projects, so future discussion can continue there:
http://www.romhacking.net/forum/index.php?topic=27444.0

dr.slump

  • Jr. Member
  • **
  • Posts: 12
    • View Profile
Re: [Techinical][GG] Crayon Shin-chan: Taiketsu! Kantam Panikku!!
« Reply #16 on: December 07, 2018, 12:04:37 am »
Filler knows what he's doing, so he has a perfectly good reason for doing that. If you check my history, you'll see that I'm perfectly able to work with Japanese myself.
Haha, OK - just offering to help. No one is above making mistakes and most translators like having their work proofread.  :thumbsup: