News:

11 March 2016 - Forum Rules

Main Menu

NES RoboCop with Arcade sprites

Started by SomeOldGuy, November 02, 2019, 05:54:49 PM

Previous topic - Next topic

SomeOldGuy

ShadowOne333, yes Sir, the hack has officially been added to the site (Apologies for the late reply)!  ;D

stevebarn, really glad you enjoy the hack!  :happy:

So, the flame thrower guy: not sure why there is no death animation.  I'll have to see if I can figure out how to make him fall out of the window like the guy with the pistol does.   

flying armored guy: The explosion graphics should be displayed when you defeat him now.  As for the green color, in order to give him more detail, 2 palettes were used.  His armor uses palette 1 (RoboCop's palette) and his arms use either palette 3 or 4 (I forget which).  This is why when RoboCop takes damage the flying guy turns green as well (all sprites using palette 1 will turn green).

Boss sprite's entirely black:  I may have over written this palette with 0F 0F 0F 0F (all black).  Will check and see, this might be an easy fix.   

Weapons: OK, I understand what you mean now.  Agreed, it would be really cool if he would switch guns automatically like the arcade game but unfortunately they are just added to his arsenal. You have to pause the game and press up/down to switch his weapon.  Would love to change this but don't have the programming skills. ::)

I'll get to work fixing what I can.  ;D   


Thanks sics!  Can't wait to see what you're cooking up for 2022.  Happy new year!  :beer:
Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

SomeOldGuy

Hey Everybody!  ;D

Figured out how to add color to the cut scenes. I'll post an update once they're finished.

   

Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

Noside

Woah! this is mindblowing! looks fantastic! :woot!:

sics

Great! :beer: By the way, by any chance, could you share the original images you used to create the new cinematics, so we can better appreciate your adaptations? I was always curious about them ;)
Linktree  | Better a small finished project than a thousand giant ideas stuck in your system.

SomeOldGuy

Thanks Noside!

Hey sics!

Well, the Arcade and NES game are the same resolution, 256 x 240, so it was pretty much a pixel for pixel copy.  I just had to reduce the number of colors used in the Arcade version down form ?? to 3 + black for the NES (initially).  Then when I discovered how to load all 8 pallets for the scene, that number jumped to 24 + black possible colors for the NES.  Just wish the NES palette wasn't so limited.
 
Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

Fray

Quote from: SomeOldGuy on March 23, 2022, 08:07:39 PM
Thanks Noside!

Hey sics!

Well, the Arcade and NES game are the same resolution, 256 x 240, so it was pretty much a pixel for pixel copy.  I just had to reduce the number of colors used in the Arcade version down form ?? to 3 + black for the NES (initially).  Then when I discovered how to load all 8 pallets for the scene, that number jumped to 24 + black possible colors for the NES.  Just wish the NES palette wasn't so limited.
 


First of all, SomeOldGuy, I want to thank you for your brilliant work, and speaking of it can I ask you if once finished you can post some step-by-step pictures of what you did? Or at least can you tell me where I can find some guides to better understand the process you used? Since I am using Nes Screen Tool and would like to know how to add some sprites to the image to add a little more color.

SomeOldGuy

Absolutely Fray, I can do that! ;D   Don't know of any guides, I've had to ask for help in this thread and just figure things out.  I think creating a guide/video tutorial is a great idea though and have been wanting to put something together for a while now.

Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

CryinOnion

Quote from: SomeOldGuy on March 21, 2022, 06:06:00 PM
Hey Everybody!  ;D

Figured out how to add color to the cut scenes. I'll post an update once they're finished.

   



I really thought the decision to suppress the color in the intro was strange, but now I see that it was only a temporary solution and I'm glad. The new screens look fantastic, once again, closer to an early 16-bit conversion than an NES game. I don't know how far you plan to go with the project, but go ahead! PS If you consider that I could help you in any way to advance the project just mention it (I'm tempted to replace our friend from "Bad Dudes" with the old T-800).

SomeOldGuy

Quote(I'm tempted to replace our friend from "Bad Dudes" with the old T-800).

CryinOnion I think this would be pretty cool!  By all means, if you want, go ahead!  ;D


So, what was the process for the cut scenes? 

Well, the first step was re-creating the Arcade versions using only 3 colors, giving them a kinda black and white look.  This was done initially because, without the use of sprites and all 8 palettes, it would be impossible to draw these scenes in color.

Only YYCHR and a screen shot from the Arcade game were used to do this.  I started off by making the background dark blue (0C).  This made it easy to draw the outlines of the characters, action lines, speckles, etc. in black (0F).  Once the black areas were completed, I drew in the mid-tone grey (00) shapes, and finished off the scene by adding the highlights (3D).  Still need to finish Clarence's hair.



The end product came out OK, but I wanted to see them in color.  To do this I'd have to figure out how to load the needed sprites and their palettes.
 
Keep in mind, I'm no programmer.  What I'm about to show you, while functional, is probably going look pretty disgusting to all y'all coders out there.  You have been warned!  ;D
   
The first step was to fire up the Code/Data Logger in FCEUX and find the code for this particular scene and try to decipher what it says.  The code below was found at location 0x3FEC0 in ROM (it would later be moved). 

I then organized the code according to patterns I could recognize.  For example 20 followed by 2 values (D9 C0).  I learned that 20 is the opcode to Jump to a Sub Routine (JSR) and the 2 values were the pointer to that Sub Routine.  Then there's A9 followed by a value, then 85 followed by a value.  A9 34 85 13 means that the value 34 will be stored in the location 0x13 in NES memory.

Below is what I was able figure out:
       
20 D9 C0................
20 37 C0 ................
A9 34 85 13 ........... Loads the first bank of tiles for the background
A9 8C 85 14 ........... Loads the second bank of tiles for the background
A9 00 ...................
20 3E C3 ...............
A2 93 A0 79 .......... Pointer to the Name Table @ 0x1389 in ROM
20 23 C1 ...............
A9 00 ...................
20 3E C3 ...............
A2 90 A0 2C .......... Pointer to the Text @ 0x103C in ROM
20 B4 C7 ...............
20 C2 C1 ...............
20 C9 C1 ...............
E6 11 ....................
4C 76 D0...............

And this is what the PPU viewer and NES memory look like in FCEUX:


I added the following code in purple.

20 D9 C0................
20 37 C0 ................
A9 34 85 13 ........... Loads the first bank of tiles used for the background
A9 8C 85 14 ........... Loads the second bank of tiles used for the background
A9 00 ...................
20 3E C3 ...............
A2 93 A0 79 .......... Pointer to the Name Table @ 0x1389 in ROM
20 23 C1 ...............
A9 00 ...................
20 3E C3 ...............
A2 90 A0 2C .......... Pointer to the Text @ 0x103C in ROM
20 B4 C7 ...............
A2 1F ................... Allows you to load all 8 palettes.  If new palettes aren't loaded, they are carried over from the previous scene. (Changing 1F to 1B loads 7 palettes. Changing 1F to 17 loads 6 palettes etc.) 
BD 73 9B .............. Pointer to the palettes @ 0x1B83 in ROM 
95 23 CA 10 F8 ......
A9 76 85 16 ........... Loads the second bank of tiles used for sprites into NES memory (You could load all 4 banks of tiles used for sprites here, but I only needed to use two and went with banks 2 and 4)
A9 77 85 18 ........... Loads the fourth bank of tiles used for sprites into NES memory
A9 00 85 C3 .........
A9 01 85 64 ..........
A9 BB 85 51 .......... Loads the first part of the sprite location in ROM into NES memory (sprites are @ 0x19B12 or BB02 in ROM)
A9 02 85 50 ........... Loads the second part to the sprite location in ROM into NES memory
A9 00 85 49 85 4B ..
A9 00 85 47 ...........
20 97 C6 ................

20 C2 C1 ................
20 C9 C1 ................
E6 11 .....................
4C 76 D0.................

And this is what the PPU viewer and NES memory look like in FCEUX with the above additions:


Notice that all of the palettes are being utilized, banks 2 and 4 of the sprite tiles have changed, and at address 0x200 sprites are now being drawn.   ;D

Well, That's what I have for today.  I'll admit that I have little to no clue what I'm doing when it comes to programming, so if any of y'all would like to make corrections or maybe fill in some of the gaps in the breakdown of the code above it would be greatly appreciated.
Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

Flaviogames

#209
Was there any further improvement after version 1.0? Is it possible to have a jump button instead of 2 punch buttons?

Pennywise

Flaviogames, English only please.  :police:

Flaviogames

#211
update? :-\

SomeOldGuy

Hey Everybody!  ;D

New patch below

- Adds color to cutscenes/ending
- The Emil cutscene has been redrawn
- Fixed the issue of Clarence showing up as all black in the junkyard fight
- Other minor graphics fixes

https://www.mediafire.com/file/p0q21div5r45iyg/RoboCop_-_Edit_22.ips/file
Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...

Noside

Awesome! thank you for the heads up, fantastic work as usual. :woot!:

edwinmusic

Hello bro, I congratulate you for your great work again but I don't know if I have problems with my control, but I feel that it is difficult to go down the stairs in the narcotics factory.

SomeOldGuy

Thanks Noside  ;D

edwinmusic, the stairs in this game are just kinda broken.  Minucce attempted a fix but this is what he had to say.
Quote- Stairs I can't do anything with (detection works in blocks of 8 pixels)

Are there any other issues that you've noticed with the new patch? 
Good times create weak men, weak men create hard times.  Hard times create strong men, strong men create good times...