pcsx2 icon indicating copy to clipboard operation
pcsx2 copied to clipboard

[Feature Request]: (QT) Memory Card Support in Custom Game Profiles (Properties)

Open jeremybris opened this issue 2 years ago • 5 comments

Description

The ability to select which memory card is in use for a game, using custom game profiles ("Properties").

(NOT creating a new memory card for each game. Choosing from the already available memory cards, under custom game profiles. See the picture below for what it would look like.)

Reason

This would solve manually swapping memory cards everytime, when switching between certain games that need it:

  1. 16 or 32 mb card in "Slot 1":

    play an early PS2 game, that only supports 8 mb memory cards. They will not recognize anything higher, such as a 32 mb card, and can not read from memory card "Slot 2". An example of this is "007: Agent Under Fire".

  2. 8 mb, 16 mb, or 32 mb card in "Slot 1":

    run out of space on that card.

  3. "Memory Card Folder" in "Slot 1":

    encounter a game that cannot read from memory card "Slot 2" and does not work with a "Memory Card Folder", #3918 , such as "SSX: On Tour".

(Alternatively, if PCSX2 supports importing .PSU/.MAX/.CBS saves into a Memory Card folder, and fixes the games that do not work with Memory Card Folders, #3918 , this issue can be closed as well, as Memory Card Folders will work fine for all games.)

Examples

What it would look like General Settings now
Screenshot 2022-07-08 135526 Screenshot 2022-07-08 135559

jeremybris avatar Jul 08 '22 18:07 jeremybris

Having separate memory cards for individual games is a waste of space on your file system and unless someone gives a strong argument for it, I don't see a reason why this would ever be a thing.

Consider using folder memory cards. Folder memory cards generate a 8 MB card on the fly and "filter" their data so only the running game and other compatible games are added to the card.

RedPanda4552 avatar Jul 08 '22 18:07 RedPanda4552

Having separate memory cards for individual games is a waste of space on your file system and unless someone gives a strong argument for it, I don't see a reason why this would ever be a thing.

Consider using folder memory cards. Folder memory cards generate a 8 MB card on the fly and "filter" their data so only the running game and other compatible games are added to the card.

  1. I only need a 32 mb and 8 mb card to house all my game saves (40 mb total). So it is not a waste of space for me. I am not saying create a new 8 mb card for each game, just reuse cards.
  2. I just tried memory card folders! I was unfamiliar with them. It does fix my two issues above. But, they seem to be sometimes glitchy, #3918 and #4870. Also, how does one import saves (from a PS2 memory card or online save) using folders? I don't know how to do that, but I have a lot of old saves, that prevent me from using this feature.

jeremybris avatar Jul 08 '22 19:07 jeremybris

For real PS2 memory cards, you can copy and paste files directly. Using uLaunchELF you can grab an entire folder, copy it, paste it to a USB drive, then paste that into your folder memory card and it will just start working. The GTA games are the only known exception to this, and it is because they have somewhat idiotic memory card code which expects their files to be in an exact order, that order being defined by when the files were created.

Folder memory cards are pretty stable these days, there are some edge cases but I'd counter by saying you can use your second memory card slot to hold a standard 8 MB file card, for those few exceptions. As for the filters issue, that's an ongoing item where we are always hunting for cases of games which let you load save data from another game. Filters are how we enable that cross-game visibility.

RedPanda4552 avatar Jul 08 '22 19:07 RedPanda4552

paste it to a USB drive, then paste that into your folder memory card and it will just start working.

I pasted my Ape Escape 2 "PSU" file inside my memory card folder, "BASLUS-20685", and it did not read it. Maybe I need to convert to another format for it to read? You can pm me too. I don't mean to blow up PCSX2's github with support questions.

you can use your second memory card slot to hold a standard 8 MB file card, for those few exceptions.

I may be mistaken, but not all games allow you to read from the second memory card? One of those exceptions (not working with "Memory Card Folders"), SSX on Tour, chooses the card slot automatically, slot 1, and does not allow the player to select the memory card in slot 2... Correct me, if I am wrong? (It's only one game, but that is a corner case example of why I need this feature.)

As for the filters issue, that's an ongoing item where we are always hunting for cases of games which let you load save data from another game. Filters are how we enable that cross-game visibility.

Ok, thank you. I did not know that! I did not understand that issue fully. That makes sense.

jeremybris avatar Jul 08 '22 19:07 jeremybris

I pasted my Ape Escape 2 "PSU" file inside my memory card folder, "BASLUS-20685", and it did not read it. Maybe I need to convert to another format for it to read? You can pm me too. I don't mean to blow up PCSX2's github with support questions.

Honestly better to do this here since at least it'll be in permanent writing for any other curious souls, since I'm mostly hitting technical details and not your specific setup.

PSU pastes from uLaunchELF are a package format used with software like MyMCPlus for importing to a file type memory card. For a folder type memory card you would do a direct copy and paste of the folder itself, no packaging or archiving. The raw files on the PS2 memory card = the raw files on a PCSX2 folder memory card.

I may be mistaken, but not all games allow you to read from the second memory card? One of those exceptions (not working with "Memory Card Folders"), SSX on Tour, chooses the card slot automatically, slot 1, and does not allow the player select the memory card in slot 2... Correct me, if I am wrong? (It's only one game, but, but that is a corner case example.)

I suppose there is some reason here to support at least slot swapping, point taken.

Ok, thank you. I did not know that! I did not understand that issue fully. That makes sense.

Yep, it's an ongoing thing so if you ever find a case of a game which is supposed to be able to read another game's data but can't, feel free to report that so it can get added, once its been identified its relatively low-tech to make those updates.

RedPanda4552 avatar Jul 08 '22 20:07 RedPanda4552

Closing as low priority/trivial since folder memory cards exist.

lightningterror avatar Oct 18 '22 19:10 lightningterror

Closing as low priority/trivial since folder memory cards exist.

As mentioned above, memory card folders don't solve the problems above.

This is not a low priority for me, as I currently can not play new games because my memory card is full, and I can not use a memory card folder because it is incompatible with my save games. So, I have to switch memory cards every time.

I think other people wanted this feature as well, as seen by the thumbs up.

jeremybris avatar Oct 18 '22 22:10 jeremybris

Some programs and certain front-ends can make per-game memcards. Though can't recall where. But yeah Folder memcards still doesn't have 100% parity with the file memcard.

RedDevilus avatar Oct 18 '22 22:10 RedDevilus

FWIW, this has been possible for months - manually add the memory card config keys to the game settings ini, and it'll work as expected. There's just no way to do it in the UI, since I never came up with a good way of showing it with inherited values.

stenzek avatar Oct 19 '22 02:10 stenzek

Thank you! :) For anyone that wants to do this:

  1. Create a config for the game, if there isn't one already created. (So, right click properties, change a global value to create a new config)
  2. Go into your PCSX2 > "gamesettings" folder.
  3. Select the correct file (the name of the game can be found in PCSX2 user interface, if you don't know it)
  4. Add these lines (change the "Mcd002.ps2" name to the name of your memory cards, if needed):
[MemoryCards]
Slot1_Enable = true
Slot1_Filename = Mcd002.ps2
Slot2_Enable = true
Slot2_Filename = Mcd001.ps2

Edit: Pre-configured inis for 200 of the most popular games (using 4 different Memory Cards): https://drive.google.com/drive/folders/1YKkMvlmOVDZdBIg2C-1-IDn7R1f2RznL?usp=share_link

jeremybris avatar Oct 19 '22 05:10 jeremybris

@stenzek

FWIW, this has been possible for months - manually add the memory card config keys to the game settings ini, and it'll work as expected. There's just no way to do it in the UI, since I never came up with a good way of showing it with inherited values.

Could it be done in a way similar to DuckStation? And any fields displaying info inherited from settings could just be grayed out. (Like the Shared Settings box in this screenshot)

duckstation-qt-x64-ReleaseLTCG - 2023-05-21 - 12-04-55

HeyItsLollie avatar May 21 '23 02:05 HeyItsLollie

I do prefer having the available cards listed, rather than the a browse box.

The easiest way would probably be an "inherit" value for each card, and reset reverts to that.

stenzek avatar May 21 '23 06:05 stenzek

That makes sense for inherited cards, it's simple and straightforward.

For selecting different cards, if you only allow cards that exist in the Memory Card folder as defined in Settings, maybe a dropdown menu would work? You'd have a pre-defined list of cards to pick from, you just have to make sure that the same card can't be selected for both slots.

HeyItsLollie avatar May 21 '23 09:05 HeyItsLollie

You'd have a pre-defined list of cards to pick from, you just have to make sure that the same card can't be selected for both slots.

I guess I could be misunderstanding, but we already have that? So yeah, indeed, it would just be a matter of handling any conflicts.

Only possible confusing thing would be when a card is set to inherit, you'd get a disabled card in the list without any indication as to why. Making the selected card name at the top, grey or bold/italics, could signify it's inherited I guess. The former is a can of worms, because grey might not appropriate for the chosen colour scheme, and we have.. erm... many of them :/

stenzek avatar May 24 '23 05:05 stenzek

I guess I could be misunderstanding, but we already have that?

Oh sorry lol, you understood correctly though, yeah. I meant to say "You'd already have [...]"

In regards to styling, you could always do a combination of all three: move inherited cards to top, "disabled" text color with italics styling (plus bold for the relevant card in Slot 1 or Slot 2). There's also the option of prefixing the card name with a label, eg: "(inherited)", "(default)", "(Slot 1)" and "(Slot 2)", etc

Out of curiosity, I did a quick and simple color test, based on a few of PCSX2's color schemes. If you're able to use the "disabled" text color in a drop-down menu, it should just work regardless of scheme. (text styling and/or prefixes would also help account for any color schemes that don't work on their own - custom schemes in particular)

PCSX2-Memory-Card-Colors

HeyItsLollie avatar May 24 '23 16:05 HeyItsLollie

I think scalability would be the main issue with a combo box - it's fine for a handful, but messy once you have say, 10-20+, where the current listbox is much more manageable.

Good point wrt the disabled colour though. I'll throw something together when I have the energy and see how it works out.

stenzek avatar May 25 '23 06:05 stenzek

Added in #8915.

stenzek avatar May 29 '23 11:05 stenzek

Added in #8915.

Thank you! I will definitely be using this feature a lot! :)

jeremybris avatar May 30 '23 18:05 jeremybris

Same - I mentioned my use-case in #8417, so I'm very happy to have a way to set cards in the frontend. Thank you!

HeyItsLollie avatar May 31 '23 03:05 HeyItsLollie