Giter Site home page Giter Site logo

catsfc's Introduction

CATSFC version 1.36, 2013-06-16

A Super Nintendo emulator for the Supercard DSTWO.

Based on:

  • Snes9x 1.43, by the Snes9x team (with research by the ZSNES folks, anomie, zsKnight, etc.)
  • NDSSFC 1.06, by the Supercard team (porting to the MIPS processor)
  • BAGSFC, by BassAceGold (improving over NDSSFC)
  • CATSFC, by ShadauxCat and Nebuleon (improving over BAGSFC)

Contains:

  • Language files written by the GBAtemp community: Dutch by Aeter, French by Nebuleon, German by SignZ, Portuguese (Brazilian) by Diego Liberal, Spanish by Boriar
  • Language files written by GitHub users: Italian by alexinfurs

Installing

(If you got the source code and want to compile it, see the Compiling section at the end of the file.)

To install the plugin to your storage card, copy catsfc.plg, catsfc.ini and catsfc.bmp from the release archive to the card's _dstwoplug directory. Then, copy the CATSFC subdirectory to the root of the card.

Cheats

The format accepted by the "Load a cheat file" function is equivalent to the old format used in Mightymo's BSNES Cheat Code Pack.

  1. Download the BSNES Cheat Code Pack at http://www.mightymo.net/downloads.html. It will be a zip archive.
  2. Open the zip file, with WinZip, WinRAR or the built-in zip extension in the operating system on your computer.
  3. In the zip file, open the folder called BSNES Cheat Code Pack, then the one called BSNES v0.51-0.74 Cheat Code Pack.
  4. Open your storage card's CATSFC folder, then descend into gamecht.
  5. Drag the cheat code files from the zip archive to the card's gamecht folder.

To add cheats to the menu in a game, first load the game, then use the Cheats menu's "Load a cheat file" option.

Frame skipping

In the Video & audio menu, the Frame skipping option allows you to select a number of frames to skip between rendered frames.

As of version 1.29, the default is - (Keep up with the game). For most games, this setting keeps video and audio fluid, without the sudden slowdowns of previous versions when many sprites fill the screen. The DS controller buttons are also responsive at this setting.

For some games, you may need to adjust frame skipping.

  • If a game runs at 5 frames per second, like Yoshi's Island, Kirby Super Star, Star Fox or Super Mario RPG, setting frame skipping to 1 will allow you to jump, move or shoot at the right times.
  • If you want to show more frames per second in a game that already shows 20, setting frame skipping to 1 or 0 will cause more frames to appear, but your DS button input may stop responding for 2 entire seconds every so often. The audio may also be stretched. (This is similar to NDSGBA.)
  • Setting this to 10 will skip 10 frames and render one, but this will severely desynchronise the audio. You will also find yourself unable to perform actions during the correct frame with the DS buttons. It is advised to set frame skipping to the lowest value with which you can play a game.

Fluidity

Fluidity is an option you can find under the Video & audio menu in a game. By default, video fluidity is preferred over audio fluidity in games.

  • Preferring video fluidity makes audio skip certain notes, up to 23 milliseconds, in order to render more video. In many games, this difference is not audible, but you may hear certain audio glitches if a game depends highly on timing for its audio. Use this option if you want to play games that require fluid imagery more than precise audio emulation. You can also use this option when watching game introductions, endings and cutscenes.
  • Preferring audio fluidity makes video skip certain images, up to 46 milliseconds, in order to render audio closer to 32,000 times per second. Use this option if you want to play games mainly for their soundtracks, or in a game's sound test mode. You can also use this option to experiment with the green berry glitch in Super Mario World that makes TIME go over and under 100 units constantly and makes the music play very fast.

Hotkeys

You can set buttons to press to perform certain actions. For each action, there is a global hotkey and a game-specific override hotkey. You might, for example, want to have the R button bound to Temporary fast-forward, but a specific game uses R for something important. In that case, you can set the global hotkey to R and make an override with X for that game.

Hotkeys are sent to the current game as well as to their corresponding action. The criterion for a hotkey is met when at least all of its buttons are held. Additional keys are sent to the game and can trigger another hotkey. For example, setting a hotkey to L and another to R+X, then pressing L+R+X+Y will trigger both and send L+R+X+Y to the game.

Available actions are:

  • Go to main menu. In addition to tapping the Touch Screen to return to the main menu, you can set a hotkey to do the same.
  • Temporary fast-forward. While this hotkey is held, the fast-forward option will be forced on.
  • Toggle sound. Each time this hotkey is held, the sound will be disabled if it's currently enabled, and vice-versa.
  • Save state #1. Each time this hotkey is held, saved state #1 will be written, without confirmation if it exists.
  • Load state #1. Each time this hotkey is held, saved state #1 will be loaded.
  • Toggle full-screen. Each time this hotkey is held:
    • If the current display mode is a full-screen mode, then the display mode is set to 3 (Middle, square pixels) and the top and bottom will be cut off.
    • If the current display mode is not a full-screen mode, then the display mode is set to 4 (Entire screen, smoothed).

The font

The font used by CATSFC is similar to the Pictochat font. To modify it, see source/font/README.txt.

Translations

Translations for CATSFC may be submitted to the author(s) under many forms, one of which is the Github pull request. To complete a translation, you will need to do the following:

  • Open CATSFC/system/language.msg.
  • Copy what's between STARTENGLISH and ENDENGLISH and paste it at the end of the file.
  • Change the tags. For example, if you want to translate to Japanese, the tags will become STARTJAPANESE and ENDJAPANESE.
  • Translate each of the messages, using the lines starting with #MSG_ as a guide to the context in which the messages will be used.

If you are not comfortable editing C code, or cannot compile CATSFC after your changes, you may instead test your translation in the English block and submit it. That allows you to look for message length issues and to align the option names and values to your liking with spaces.

If you wish to also hook your language into the user interface, you will need to do the following:

  • Edit source/nds/message.h. Find enum LANGUAGE and add the name of your language there. For the example of Japanese, you would add this at the end of the list:
      ,
      JAPANESE
    
  • Still in source/nds/message.h, just below enum LANGUAGE, you will find extern char* lang[ some number ]. Add 1 to that number.
  • Edit source/nds/gui.c. Find char *lang[ some number ] =. Add the name of your language, in the language itself. For the example of Japanese, you would add this at the end of the list:
      ,
      "日本語"
    
  • Still in source/nds/gui.c, find char* language_options[], which is below the language names. Add an entry similar to the others, with the last number plus 1. For example, if the last entry is , (char *) &lang[7], yours would be , (char *) &lang[8].
  • Still in source/nds/gui.c, find case CHINESE_SIMPLIFIED. Copy the lines starting at the case and ending with break, inclusively. Paste them before the }. Change the language name and tags. For the example of Japanese, you would use:
      case JAPANESE:
      	strcpy(start, "STARTJAPANESE");
      	strcpy(end, "ENDJAPANESE");
      	break;
    

Compile again, copy the plugin and your new language.msg to your card under CATSFC/system, and you can now select your new language in CATSFC!

Compiling

Compiling CATSFC is best done on Linux. Make sure you have access to a Linux system to perform these steps.

The DS2 SDK

To compile CATSFC, you need to have the Supercard team's DS2 SDK. The Makefile expects it at /opt/ds2sdk, but you can move it anywhere, provided that you update the Makefile's DS2SDKPATH variable to point to it.

For best results, download version 0.13 of the DS2 SDK, which will have the MIPS compiler (gcc), extract it to /opt/ds2sdk, follow the instructions, then download version 1.2 of the DS2 SDK and extract its files into opt/ds2sdk, overwriting version 0.13.

Additionally, you will need to add the updated zlib, DMA (Direct Memory Access) and filesystem access routines provided by BassAceGold and recompile libds2a.a. To do this:

sudo rm -r /opt/ds2sdk/libsrc/{console,core,fs,key,zlib,Makefile} /opt/ds2sdk/include sudo cp -r sdk-modifications/{libsrc,include} /opt/ds2sdk sudo chmod -R 600 /opt/ds2sdk/{libsrc,include} sudo chmod -R a+rX /opt/ds2sdk/{libsrc,include} cd /opt/ds2sdk/libsrc sudo rm libds2a.a ../lib/libds2a.a sudo make

The MIPS compiler (gcc)

You also need the MIPS compiler from the DS2 SDK. The Makefile expects it at /opt/mipsel-4.1.2-nopic, but you can move it anywhere, provided that you update the Makefile's CROSS variable to point to it.

Making the plugin

To make the plugin, catsfc.plg, use the cd command to change to the directory containing your copy of the CATSFC source, then type make clean; make. catsfc.plg should appear in the same directory.

catsfc's People

Contributors

alexinfurs avatar boriar avatar derpking avatar jomaper avatar nebuleon avatar rickvdwetering avatar taelis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

catsfc's Issues

Cheat selection freeze.

After changing the cheats enabled for a game and playing the game, upon attempting to change a second time the emulator will either fail to apply the cheats, or will lock up.

This seems to be an issue dating from the official version of the emulator as well.

Game freeze upon CATSFC menu open

Version: CATSFC 1.28
Game: Final Fantasy IV (J) [Translation patched]
Steps to produce:

  1. Load game
  2. Loaded save state (manual)
  3. Restarted ROM from menu
  4. Load from SRAM
  5. Played ~5min
  6. Saved game to SRAM
  7. Pressed tap-area with thumb to bring up CATSFC menu

Upon step 7, emulation froze. Menu did not appear, and neither taps nor buttons functioned. Closing lid did not trigger sleep mode (which was implemented recently even for CATSFC menu). Upon DS hard reset, I was able to reload SRAM from step 6.

Could not reproduce; simply posted for your convenience. Feel free to close the issue if you find it might simply have been bad luck on my part.

File Browser Limitation

I have a large amount of games on my sd card, and when I go to browse its directory (../roms/snes) CATSFC locks up. I've let it sit for more than 5 minutes with no activity. I also noticed this bug is present in TEMPGBA. I haven't done enough testing to determine if theres a magic number, but if I only have about 20 games versus about 1000 (for either TEMPGBA or CATSFC) everything works fine.

Single Cheat codes displayed as multiple code

Any way to get the cheat codes with multiple codes to appear as one code. Currently anything with 2+ codes entered as "########+########+########" will output as multiple different codes you have to enable separately. It becomes a major hassle when some of the codes have 13+ lines. Thank you for your time.

Button Remapping

I will be adding the option to re-map the controls if desired. Along with this, I'll add the ability to map buttons to emulator functions when they aren't used in-game - for example, the L and R buttons can be used to scroll the screen instead of the stylus. The button map settings will be game-specific. Additionally, any button or setting will be mappable to a combination of buttons instead of a single button, so, for example, "Toggle Rapid Fire A" could be mapped to "L+R+A," or "Quick Save" could be mapped to "L+R+A+B+X+Y".

Does not go into sleep mode.

The DS does not go into sleep mode when the emulator is running, neither in-game or when in a menu. This is another inherited issue from older versions.

Wonder Project J english patch (1.04)

On a SNES Next emulator the Wonder Project J rom patched with English works fine. Just when I load it, and go to 'new game', it starts garbling, and then when I start into the name screen, it freezes with more garble.

I'm told it works fine on a higan accuracy v094.

It doesn't seem to load all that well on the BSNES either, for that matter.

Responsiveness of input is delayed

I just switched from NDSSFC to CATSFC, and found that the button and screen input are delayed a bit more than they were in NDSSFC. It feels like the response time is delayed by at least a hundredth of a second more than on the official emulator.

Not only that, the touch screen input is ignored if you tap it too quickly. On NDSSFC, the menu will pop up immediately.

EDIT: I find that the delay occasionally makes the buttons "double press" or not press at all during gameplay. This makes it more difficult to navigate through game menus and such.

This might have something to do with decreased performance of the emulator in general - Hourai High (with hardpatched translation) now frameskips much more than before, even on CPU frequency 5.

Sound in save states

If you disable the sound in a game, then create a save state and load to activate the sound is not heard

Slow but near perfect emulation.

Super Bomberman 2 (Slow)
Donkey Kong Country 2 (Slow with a sound distortion on overworld maps)

Shadaux? I didn't know how you wanted ROM compatibility formatted. There's probably a better way.

Timing is off from a real SNES by up to 3%

As of CATSFC 1.31, the emulation timing is off from a real SNES by up to 3%.

On the map screen for World 1 in Super Mario All-Stars's Super Mario Bros. 3, the emulation is too slow by 2%.

Rydian on GBAtemp remarked, with wave files, that the introduction screen for Legend of Zelda: A Link to the Past ran successively too fast, then too slow, by around 3%.

Some other wave files proved that Final Fantasy 6 also ran too slow by around 1%.

I need to investigate the timing catch-up code in automatic frameskipping and in audio rendering. Seeing as the audio rendering times itself on the frame rendering, it's probably more about the frame timing.

Issues when loaded via arg

When loaded using an arg command, no save states are shown and the settings such as frequency and scale are defaulted.

Screen scrolling with stylus

To fix the shortcomings of the various display modes, we will replace display modes 1-3 with a single display mode that will allow movement of the screen by scrolling with the stylus to move the screen up and down. Accessing the menu will still be achieved through a simple tap.

Graphics Options

In order to aid in adjusting performance, I will add a few options to the video and audio menu that will allow the user to enable or disable certain settings, such as transparency, in order to improve performance.

Quick save and quick load

I will be adding a configurable option to enable a "quick save" and "quick load" button combination - L+R+Start to quick save, L+R+Select to quick load. (These will become customizable with the introduction of the button mapping feature in v1.4) Pushing this button combination in-game will automatically save your game to slot 10, or load from slot 10 (if it exists), as is appropriate.

Manual Frame Skip Selection

I will be adding an option to change between automatic frame skipping and manual frame skipping, which can be set at any level from 0 to 10 (and possibly higher).

Ability To hotkey access to Real-Time menu to buttons

It would be nice if you could hotkey the real time menu to buttons, similar to that of the normal DS games real time menu where when you press L+R+Start it will bring you to the real time menu. Instead of hitting the bottom touchscreen to bring it up because sometimes you hit it by accident when playing games which will pause your game, it would be better if access to it can be hotkeyed or set to some button combination.

Dual screen display mode for full SNES screen access

Suggesting this as a feature request.

Hey, I'm wondering if it is possible to implement a display mode where both screens -top and bottom- are used for the viewport. Since currently one of the screens will always go unused while in play mode.

The special "pixel squishing" display mode which shows full screen is good to have, but makes many games harder to play than it needs to be - SNES games were thought and created to be played in front of a big screen TV, and for games like Mario Kart and the DKC series the squishing doen't really keep playability at reasonable levels unless you are playing on a (3)DS XL, I guess. The other modes keep the full resolution at the expense of cropping which, if I recall correctly, is not configurable as a per-game setting, meaning you have to re-configure each time you fire up a new game.

A display mode that uses both screens would provide the best of both worlds plus some extra benefits. It would allow playing at "natural" resolution, without missing any information on screen. If the section of the game screen to be split off is configurable as a per-game setting, best case it would allow for some games that keep only / mostly scores or health bars in the top / bottom part of the screens to have those parts be split off and function as an HUD of sorts.

I'm visualizing this potential feature in my head as a screen mode not unlike "EPIC MODE" for Mario 3 on the NesDS:

"EPIC MODE" in NesDS

Image source

I'm not experienced in programming for the DS but I would guess that a cursory implementation of this feature would be about the same complexity to implement as the viewport cropping display modes? Since the only thing that changes is that the part of the screen that was "discarded" is still sent to the system to be drawn.

Game Genie codes not supported.

The emulator does not currently support Game Genie codes (only PAR codes), this limits what can be done with it.

I wish I could find the original document I used for instructions on how GG codes are encoded, but I can't find it right now so this PHP code will have to do as it's all I have handy.
http://pastebin.com/8XUVfUZY

If you're not willing to implement them directly, it's possible for you to just change the PAR code handling to accept memory banks other than RAM (7E) so people could use the PAR equal to Game Genie codes (online converters are available and the CHT pack/converter I've made for this emulator would be updated to include those converted codes).

Rapid Fire

I will be adding an option to enable rapid-fire for any or all keys through the in-game menu.

MSU1 support

The emulator its just hilarious, but it needs MSU1 support, I really wanna enjoy Zelda 3 and Super Metroid with CD quality on my 3DS.

French translation

I want to propose myself to translate the interface in french...

So if you can contact me to give me everything i need to translate ^^

See you

DSTWO sound output causes FPS to go insane

Per above.

I've tested this in a few games, including my fave, Super Mario World. Complex frames, with lots of OBJs and BGs, are drawn out to the screen, but then sound output via the DSTWO slows down the game to about 4 FPS.

Disabling the sound output, by emptying S9xGenerateSound and S9xProcessSound (before commit c01a2a4 (2012-12-28)) or by going into the Video & Audio settings to disable sound (after that commit), gets the frame rate to acceptable levels without deviation.

Editing source/nds/ds2sound.h to use 11025 Hz audio oddly improves the FPS to become very acceptable, but deteriorates the sound severely (obviously). 22050 Hz and up have this problem.

a) It may have to do with the reduced buffer size. However, setting 22050 Hz and up to use a reduced buffer size causes underflows.
b) I've tried to use code similar to the DS2SDK Example Plugin's src/wave.c to replace S9xProcessSound. That code can safely assume it can read more waveform data ahead of time, for 16 buffers worth of 2048 samples (32768 samples ~ 0.75 second). When used in Snes9x, it causes underflows and glitches.

Always loads savestate automatically

The emulator is hard-coded to auto-load the latest savestate it can find. This can lead to issues like in this post by SparroHawc: http://www.snes9x.com/phpbb3/viewtopic.php?f=6&t=5584#p32588

Perhaps this could be a configurable option? A checkbox with "Load latest savestate automatically"

A slightly more complicated solution could be to include the SRAM date in the calculation for the latest thing to load. If the SRAM file is newest than the latest savestate, ignore the savestate and load the SRAM as normal.

Low Pitch Sound?

CATSFC seems to emulate games' sound at a lower pitch than it should be. It seems to be happening in every game I try, such as Super Mario World and Donkey Kong Country. The Supercard team version of NDSSFC doesn't seem to have this issue. Is it supposed to sound like this, could some setting be wrong, or might it be installed wrong?

Mode5

Background Mode 5 currently doesn't work. Rather than displaying the entire 8x16 or 16x16 tile, CATSFC only displays the top left 8x8 square.

Secret of Mana, menu fonts display incorrectly.

Secret of Mana has had an issue through every version of the DStwo emulator (it exists in Snemulds too I believe) where the emulator fails to correctly display the narrower font used in the menu screens, see the image below for an example:

SoMfontproblem

Save menu adjustments

The save menu will be re-worked so that the "save state" item works the same way as the "load state" item - a list of boxes that allow you to choose your save spot simply by double clicking on any of said boxes. As such, saving state will not always put the save in the first empty box, but will let you choose which box to save in. If you save in a box that's full, you will be given the option to overwrite that save or cancel.

Settings are not saved properly

CatSFC should be able to save and remember user defined audio / video settings and CPU frequency properly.

And it should be possible to save custom user settings, currently the startup settings also differ from settings after using "restore default settings".

Secret Of Mana bugs

Hi,

please forgive me for my english, i'm french ^^

I tried Secret Of Mana (Seiken Densetsu 2) with different graphic modes...

I can't find one where the text is displayed correctly.
As Well there's an issue with the layers.

How can we help to improve the compatibility with more games ?

Interface redesign

I will be redesigning the entire interface with a new loading screen, new icons, a new background, and so on, to give CATSFC a visual identity separate from the original NDSSFC.

No PAL mode. European games play too fast

The emulator does not have support to PAL mode. It means that when the game is European it will play too fast. Of course you can always pick the American version. Unfortunately, some games do not have an American version, so they are unplayable.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.