Emulador Mega Drive/Genesis
Contingut
Introducció
Instal.lació
Descarreguem dgen-sdl-1.33.tar.gz
copiem a la RPi $ scp dgen-sdl-1.33.tar.gz pi@192.168.1.35:/home/pi
A la RPi:
$ sudo apt-get install libsdl1.2-dev $ cd dgen-sdl-1.33
Seguim les instruccions de la instal.lació:
2. If using an RPi of the 256MEG variety RPi, make sure you have the RAM split set up attributing ALL the RAM to the ARM (Use the config (sudo raspi-config))
3. Install libsdl1.2-dev dependencies (apt-get install libsdl1.2-dev)
4. CD into the directory where you uncompressed the source code and Type -
$ ./configure --disable-opengl
NOTA. Per tal de què no surti el missatge loaded de la rom, comentem la línia. Fent un find trobem:
./main.cpp: pd_message("Loaded \"%s\".", rom);
està a la línia 447, la comentem i compilem.
The Default configuration uses Open GL rendering, which DOES NOT work on the RPi! Without this addition it will run, but you will have to add a Boolean expression to turn off Open GL rendering EVERY TIME its run!!!
$ make (costa molt de compilar en la RPi) $ sudo make install (Optional, but useful in this case as running straight from Terminal (Not in X) gives a significant performance increase and negates the need for ''CDing'' into the folder when you want to use it!)
5. Exit Terminal 6. Make an appropriately named folder (I called mine dgenroms) and put any ROMS you have in it (NB DECOMPRESSED! See Above!)
Les ROMs han d'estar descomprimides. Veure el script que ho descomprimeix i reemplaça els espais en blanc per underscore.
Després de la compilació, el binari ha quedat en el mateix directori.
$ ./dgen ../roms_megadrive/Sonic\ the\ Hedgehog.zip -> no funciona perquè no admet el format comprimit. $ ./dgen dgenroms/sonic.bin
Les opcions bàsiques per llençar l'emulador:
-P Emulate 50Hz PAL mode (as used in European models of the Mega
Drive).
-r RCFILE Parse another rc file after $HOME/.dgen/dgenrc. Values in the
specified file override those in the preceding files.
-R (J|U|E) Emulator region. Without this option, DGen uses the first
region mentioned in the ROM header. It should be combined
with -P for PAL mode. See below.
-f Run fullscreen, if possible.
-g (0|1) Enable/disable OpenGL (if compiled-in).
(a mi no em cal, doncs ho he compilat sense aquesta opció)
-N NTSC (important, doncs hi ha jocs que només funcionen amb aquesta opció)
la primera prova:
$ ./dgen -R E -P -f ../roms_megadrive/Sonic\ the\ Hedgehog.bin -> funciona $ ./dgen -R E -P -f ../roms_megadrive/sonic.bin -> funciona
És a dir, puc renombrar el fitxer binari.
configuració
En el fitxer de configuració $HOME/.dgen/dgenrc tenim definida la configuració típica del teclat:
CONTROLLERS
key_pad1_up [up]
key_pad1_down [down]
key_pad1_left [left]
key_pad1_right [right]
key_pad1_a [a]
key_pad1_b [s]
key_pad1_c [d]
key_pad1_x [q]
key_pad1_y [w]
key_pad1_z [e]
key_pad1_mode [backspace]
key_pad1_start [return]
Map keys to the first Genesis controller. Each of these fields has
a corresponding "key_pad2" field, to map to the second controller.
bool_joystick [false]
Use joysticks to emulate the controllers. Note that the keyboard
keys will still work if this value is set. This field is only
available if you have joystick support enabled.
joypadX_bY
Maps button number Y, on joystick X to a Genesis controller button.
Valid button values are "a", "b", "c", "x", "y", "z", "mode", and
"start". Joystick 1 will always emulate controller 1, and joystick
2 will always emulate controller 2.
Depenent de la màquina que construeixi faré servir 3 ó 6 botons (per a la majoria de jocs, amb 3 botons n'hi ha prou, que es correspon al gamepad original de la primera versió de la mega drive).
Un exemple de fitxer dgenrc està a:
La configuració bàsica del teclat seria:
# These are the controls for pad 1 key_pad1_up = up key_pad1_down = down key_pad1_left = left key_pad1_right = right key_pad1_a = a key_pad1_b = s key_pad1_c = d key_pad1_x = q key_pad1_y = w key_pad1_z = e key_pad1_mode = backspace key_pad1_start = return # Quit dgen key_quit = escape
En la configuració de la minibartop de 7 botos (ESC + 6 botons) quedaria:
# These are the controls for pad 1 key_pad1_up = up key_pad1_down = down key_pad1_left = left key_pad1_right = right key_pad1_a = 3 key_pad1_b = 4 key_pad1_c = 5 key_pad1_x = 6 key_pad1_y = 2 key_pad1_z = d key_pad1_mode = c key_pad1_start = 1 # Quit dgen key_quit = 0
dubte: de moment no se perquè serveis la tecla de mode en el gamepad de 6 botons. Si utilitzo el botó de mode no puc utiltizar el botó de y. Renuncio al botó de mode perquè em sembla que el botó Y es fa servir bastant.
Fixem-nos que en el fitxer no hi ha cap paràmetre per dir on estar les ROMS, per tant llençaré el dgen ficant la ruta de les roms.
Un cop ja ho tinc instal.lat i configurat, ja podem jugar:
$ /usr/local/bin/dgen /home/pi/roms_megadrive/Streets_of_Rage.bin $ dgen roms_megadrive/Streets_of_Rage.bin
I en la configuració de la màquina de dos jugadors (2 joysticks + 16 botons) queda:
# These are the controls for pad 1 key_pad1_up = up key_pad1_down = down key_pad1_left = left key_pad1_right = right key_pad1_a = 3 key_pad1_b = 4 key_pad1_c = 5 key_pad1_x = 6 key_pad1_y = 7 key_pad1_z = 8 key_pad1_mode = 2 key_pad1_start = 1 # The same for pad 2 # Yes, I KNOW the default player 2 keys are awful. Pick your own! key_pad2_up = i key_pad2_down = k key_pad2_left = j key_pad2_right = l key_pad2_a = a key_pad2_b = b key_pad2_c = c key_pad2_x = d key_pad2_y = e key_pad2_z = f key_pad2_mode = 2 key_pad2_start = 9
i assegurar-se de què no hi ha cap altre paràmetre que utilitzi aquests valors.
ROMs
Descàrrega de les ROMs
Descarrego la ROM Sonic the Hedgehog.zip
Extrec el fitxer bin i el renombro a sonic.bin
$ ./dgen -R E -P -f ../roms_megadrive/sonic.bin -> funciona $ ./dgen -R E -P -f ../roms_megadrive/Sonic\ the\ Hedgehog.bin -> funciona
Descarrego Aladdin (Europe).zip, i es descomprimeix a Aladdin (Europe).md. Renombro el fitxer a Aladdin.md i funciona.
$ ./dgen -R E -P -f ../roms_megadrive/Aladdin.md -> funciona
Però en canvi les ROMs de romhustler.net no funcionen:
Snapshots de les ROMs
Jocs
Una llista de jocs completa està a:
Jocs importants
The Addams Family The Adventures of Batman & Robin Alien Soldier Battle Mania Dai Gin Jou Beyond Oasis Bubble And Squeak Castle of Illusion Starring Mickey Mouse Castlevania: Bloodlines Chiki Chiki Boys Comix Zone Contra: Hard Corps Cool Spot Crusader of Centy Decap Attack Disney's Aladdin Dune: The Battle For Arrakis Dynamite Headdy Earthworm Jim Ecco: The Tides of Time Elemental Master Eliminate Down ESWAT: City Under Siege Eternal Champions FIFA Soccer 95 Flashback: The Quest for Identity Flink Gaiares General Chaos Ghouls'n Ghosts Gley Lancer Golden Axe Gunstar Heroes Haunting starring Polterguy Hellfire Herzog Zwei Jungle Strike Kid Chameleon Landstalker: The Treasures of King Nole Lemmings Light Crusader The Lost Vikings Madden NFL '95 Marvel Land Mega Bomberman Mega-Lo-Mania Mega Turrican Mercs Micro Machines Mortal Kombat II NBA Jam NHL '94 Phantasy Star II Phantasy Star III: Generations of Doom Phantasy Star IV: The End of the Millennium Pirates! Gold Populous Pulseman Puyo Puyo-Mean Bean Machine Quackshot starring Donald Duck Ranger X The Revenge of Shinobi Ristar Road Rash II Rocket Knight Adventures Rolo to the Rescue Samurai Shodown Shadow Dancer Shadowrun Shining Force Shining Force II Shining in the Darkness Shinobi III: Return of the Ninja Master Sonic the Hedgehog Sonic the Hedgehog 2 Sonic the Hedgehog 3 Sparkster Splatterhouse 3 Starflight Street Fighter II: Special Champion Edition Streets of Rage Streets of Rage 2 Strider Sub-Terrania Super Fantasy Zone Super Hang-On Teenage Mutant Ninja Turtles: The Hyperstone Heist Thunder Force III Thunder Force IV: Lightening Force Tiny Toon Adventures: ACME All-Stars ToeJam & Earl Vectorman Virtua Racing Warsong Wiz'n'Liz Wonder Boy in Monster World YuYu Hakusho: Gaiden Zero the Kamikaze Squirrel Zero Wing Zombies Ate My Neighbors
Jocs amb problemes a la RPi
- Comix Zone:
- Shinobi III return ot the ninja master
CPO. Configuració del gamepad
Hi ha dos gamepads. El gamepad original, fins l'any 1993, té 3 botons a part del select. Més tard hi ha el gamepad de 6 botons, però això no vol dir que tots els jocs d'aquesta època necessitin els 6 botons.
The Sega Mega Drive Six Button Control Pad became the de facto controller for the Sega Mega Drive, replacing the standard Control Pad internationally around 1993/1994
Around the same time that Street Fighter 2 was launched for the Mega Drive, Sega came out with a 6-button controller and soon after a 6-button version of their Arcade stick. Only a small selection of games made full use of the extra buttons, but the ones that did are much more enjoyable with the extra 3 buttons. Fighting games in particular were able to expand beyond the limited 3 button scheme to compete properly with the SNES controllers. The 6-button controller also added a "mode" button which was used to trick the console into thinking it was a regular 3-button controller (for compatibility) except when playing 32X games where it was a fully functioning button. In addition to the list below, many Mega-CD games took advantage of the 6 button controller.
Els jocs que necessiten 6 botons en principi són:
- Ballz
- Clay Fighter
- Comix Zone
- Contra / Probotector (Limited 6 button functionality)
- Davis Cup tennis/ Davis cup world tour
- Dragon Ball Z
- Eternal Champions
- Fatal Fury 2
- Fever Pitch Soccer
- Lost Vikings
- Midways Arcade greatest Hits (robotron only)
- Mortal Kombat
- Mortal Kombat 2
- Mortal Kombat 3
- Mortal Kombat Ultimate
- Ranger X
- Shaq Fu
- Samurai Showdown
- Street Fighter 2
- Super Street Fighter 2
- Streets of Rage 3
- Technoclash
- Zombies ate my neighbours
Per tant, com que la majoria dels jocs amb tres botons en tinc prou, puc integrar aquest emulador en la mini-bartop de 7 botons (ESC + 6 botons). A més, en els jocs de 6 botons (6 botons + Start) quasi aconsegueixo la funcionaliat (me'n falta 1).