| ▲ | Show HN: NES Contra (1987) port (ASM –> C and then C –> WebAssembly)(epoyraz.github.io) |
| 21 points by tevlon 2 hours ago | 14 comments |
| Based on vermiceli's annotated disassembly of Contra: https://github.com/vermiceli/nes-contra-us. Thanks for the great work. I ported it in two steps. First to C: the game logic is translated routine by routine from the 6502 assembly, and checked frame by frame against the original in the Mesen emulator. Then the C code to WebAssembly so it runs in the browser. The cherry on top: online multiplayer, so two players can play co-op over the internet. Source: https://github.com/epoyraz/nes-contra-us |
|
| ▲ | raldi 33 minutes ago | parent | next [-] |
| But the Japanese Contra was so much better! https://www.youtube.com/shorts/CiXzONyCDW0 |
|
| ▲ | gwbas1c an hour ago | parent | prev | next [-] |
| One of the things that I'm curious about: How easy / hard is it to use the same NES game with higher resolution / color graphics, and sample-based sound? Are there any emulators out there that let you swap in higher resolution assets so a game can be freshened without a complete port? |
| |
| ▲ | vunderba 42 minutes ago | parent | next [-] | | You might like 3dSen, which came out several years ago. It does some pretty crazy stuff, converting NES games into essentially 3D voxel environments. https://store.steampowered.com/app/1147940/3dSen_PC | | | |
| ▲ | BSPtree an hour ago | parent | prev | next [-] | | I would not think so, at least not in a meaningful way. That would require to edit the cartridge data thus the ROM, as all sprite data was contained within the cartridge. Sample based sound is impossible natively, as NES and older game consoles don't work with digital data but synthesizers. You could perhaps synthesize the music to WAV files and then enchance it. But then again, NES and thus its emulators have no way of playing digitized audio! | | |
| ▲ | cowlevel an hour ago | parent | next [-] | | The NES in particular is probably not too difficult to upscale, because the graphics data is stored on its own ROM chip (sometimes RAM) in a well structured layout. SMB1 just uses a ROM chip containing many tile graphics which the CPU code addresses by tile index. It would be really easy for an emulator to use the same tile indices to address any arbitrary set of tiles loaded from a PNG. Some games use RAM, which makes it harder as you'd have to index the PNG by hash or something. | |
| ▲ | pantelisk an hour ago | parent | prev [-] | | Compute motion vectors, faux depth, and add DLLS5 to it maybe? Could be pretty cool, or pretty horrific. Only one way to find out :) |
| |
| ▲ | unleaded an hour ago | parent | prev | next [-] | | Mesen has texture packs. Don't know about sound, you'd have to reverse each game's sound driver first. https://vgmpf.com/Wiki/index.php?title=Famicom/NES_Sound_Dri... | |
| ▲ | kekebo an hour ago | parent | prev [-] | | Idk about swapping assets but zsnes used to have a range of video filters that could improve the experience on a modern screen quite a bit. Edit: For SNES, not NES, my bad. |
|
|
| ▲ | BSPtree 2 hours ago | parent | prev | next [-] |
| Cool, how did you build the multiplayer mode? And how much AI was used? |
| |
|
| ▲ | einpoklum an hour ago | parent | prev [-] |
| Most of the keys aren't working for me in Firefox though :-( |
| |