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

Author Topic: Mortal Kombat NES hack: separated color for each select screen portrait?  (Read 2792 times)

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Well, I wanna ask whether how can I change, then separate the palette of each select screen portraits.
Example: https://i.ytimg.com/vi/XnYSNJ-eZC4/hqdefault.jpg

Liu Kang, Cage, Shao Kahn, Jax, Kintaro, Baraka, and Raiden have red-color portrait.
BUT: I want Liu Kang to have green palette for example. How can I do that? With simple hack or only ASM code (I don't want to waste my time with learning ASM codes!).

Help me.


EDIT: Same goes for Mortal Kombat II NES.


Example: http://emu-russia.net/gdb/nes/Mortal_Kombat_2_2.png

Here, I want Scorpion to have red-colored portrait.

Psyklax

  • Hero Member
  • *****
  • Posts: 1056
    • View Profile
    • Psyklax Translations
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #1 on: December 16, 2018, 07:27:25 pm »
I don't want to waste my time with learning ASM codes!

Welcome to ROMhacking.net. ;)

Here's your answer - and the game he was referring to, ladies and gents, is:
GoodNES: Mortal Kombat II Special (Unl) [!].nes
CRC32: 99D81100

Change $8CE2 to 0F and $8CE9 to 00. Liu Kang's portrait is now green. :)

How did I find that out? Well, wasting my time learning ASM codes certainly could've helped, but actually it was very easy. I changed some values in the palette section of VRAM ($23C0 to $23FF, in case you didn't know) and found the bit that covers Liu Kang's portrait. Then I did a write breakpoint to the two addresses I needed, found the instruction immediately, thereby found the ROM address where the palette table is stored, changed it to use a different palette. Easy peasy.

You know, I'm a little confused at your attitude towards assembly, since it seems that you've done quite a few NES hacks yourself (including of this game). Ah well, hopefully this will help you anyway. :)

EDIT: oh, and your other game, which is:
GoodNES: Mortal Kombat II (Unl) [!].nes
CRC32: B0BA55CF

Change $9016 to 00 and $901D to F0. Scorpion is now red.

dACE

  • Sr. Member
  • ****
  • Posts: 353
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #2 on: December 16, 2018, 08:09:20 pm »
(I don't want to waste my time with learning ASM codes!).

Wait...
...if you don’t want to waste your time...
...and I don’t want to waste my time...
- who IS going to do your work for you?

/dACE

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #3 on: December 17, 2018, 02:50:25 am »
Quote
You know, I'm a little confused at your attitude towards assembly, since it seems that you've done quite a few NES hacks yourself (including of this game). Ah well, hopefully this will help you anyway. :)

Well, it depends on what game(s) I know and what tools are for them (that I can surely use). And as for my attitude to ASM coding, I would need a lots of time and believe me, I'm not a programmer. :D


Quote
Wait...
...if you don’t want to waste your time...
...and I don’t want to waste my time...
- who IS going to do your work for you?

I already know what I want + I have help as well.


EDIT: @Psyklax, could you also tell me the VS screen portrait palette value as well (Liu Kang and Scorpion)? Because I tested and the value you told me only changed the select screen portrait palette, not the VS screen one.
« Last Edit: December 17, 2018, 03:12:40 am by szemigi »

Psyklax

  • Hero Member
  • *****
  • Posts: 1056
    • View Profile
    • Psyklax Translations
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #4 on: December 17, 2018, 03:24:26 am »
If the Vs portrait is still red, it must be somewhere else in the ROM. I just told you how to find what I found, so if you do the same thing, you'll find it. :)

And trust me, I'm not a programmer, but learning assembly is much easier than you think, and will really improve your hacking skills.
« Last Edit: December 17, 2018, 03:40:21 am by Psyklax »

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #5 on: December 17, 2018, 03:25:08 am »
Alright, thanks. :D

Psyklax

  • Hero Member
  • *****
  • Posts: 1056
    • View Profile
    • Psyklax Translations
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #6 on: December 17, 2018, 05:04:48 am »
If you are having problems, I told you where the palette is stored in PPU memory, so doing a write breakpoint to that area will open the debugger when it is written to. In the debugger, the instruction to write to the PPU memory is preceded by an instruction to load the correct value into the accumulator, and that's where you find the value in RAM (and from there, ROM).

How exactly did you do all those other hacks for the NES? You already hacked this game to change the colour of one of the stages, didn't you?

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #7 on: December 17, 2018, 07:24:55 am »
The problem is that I barely know Mortal Kombat NES version's RAM/ROM map. I only know Super Mario Bros. and such.

Psyklax

  • Hero Member
  • *****
  • Posts: 1056
    • View Profile
    • Psyklax Translations
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #8 on: December 17, 2018, 08:21:12 am »
The problem is that I barely know Mortal Kombat NES version's RAM/ROM map. I only know Super Mario Bros. and such.

Right, but you have submitted six different patches for Mortal Kombat II on the NES, which makes me think you would know how to do this. Unless you didn't actually make those patches, which would be strange since there's no credit for them except you.

Besides, I don't know the memory map either, but I solved it in 60 seconds because I know how the NES works. If you really want, I can spend 5 minutes when I get home later and get everything working how you want, but I'm not at home right now.

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #9 on: December 17, 2018, 09:19:42 am »
Quote
Unless you didn't actually make those patches, which would be strange since there's no credit for them except you.

I made the patches. ;)


Quote
You have submitted six different patches for Mortal Kombat II on the NES, which makes me think you would know how to do this.

Yeah, I'm aware of (only) basic things (but not RAM, ASM coding, or such).


Quote
If you really want, I can spend 5 minutes when I get home later and get everything working how you want, but I'm not at home right now.

Could you do it for me? Because I tried it, but no result.
(Do it for Mortal Kombat 2 Special - example is Liu Kang, Mortal Kombat 1 NES - example is Scorpion, in short: what I mentioned before.)
« Last Edit: December 17, 2018, 10:01:57 am by szemigi »

Psyklax

  • Hero Member
  • *****
  • Posts: 1056
    • View Profile
    • Psyklax Translations
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #10 on: December 17, 2018, 05:59:58 pm »
Again, referring to your PMs (can you just write in the thread, I'll just delete your messages anyway):

Liu Kang in the first game I mentioned:
$8CE2 change AF to 0F
$8CE9 change AA to 00
$192AF change AF AA to 0F 00

Scorpion in the second game I mentioned:
$9016 change AA to 00
$901D change FA to F0
$BA71 change 7F EF BB EE to 3F CF 33 CC

Now learn how I did it. Go to $23C0 to $23FF in PPU memory (not $32C0, that's a mirror). Find the address of the portrait's palette. Set write breakpoint. When I go to the Vs screen again, it breaks several times, once with the value I need, $AF. The instruction it breaks on is the one that writes to the PPU_DATA register: the one directly before it loads $AF into the accumulator (the A register). FCEUX tells me where it got that from, so I go there in RAM, right-click "go there in ROM". Change it. Done. Now you can click "save ROM as", choose a file, and it's saved.

Now you can do it too for all the other characters. :)

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #11 on: December 18, 2018, 02:44:37 pm »
I tried the Liu Kang thing you mentioned, but when I changed Liu Kang's VS portrait palette to green, Johnny Cage's VS portrait became green as well for example. Mistake?

EDIT: Scorpion thing was the same. Sonya's VS portrait became red (but not on the select screen).
« Last Edit: December 18, 2018, 02:49:40 pm by szemigi »

RealGaea

  • Full Member
  • ***
  • Posts: 153
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #12 on: December 20, 2018, 01:32:21 pm »
I tried the Liu Kang thing you mentioned, but when I changed Liu Kang's VS portrait palette to green, Johnny Cage's VS portrait became green as well for example. Mistake?

EDIT: Scorpion thing was the same. Sonya's VS portrait became red (but not on the select screen).

To save colors on screen, some characters share the same palette on the roster.

szemigi

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Re: Mortal Kombat NES hack: separated color for each select screen portrait?
« Reply #13 on: December 20, 2018, 02:31:23 pm »
I know this myself, too, but I didn't exactly know it'll result that.