Use memory card 251 for games that cannot use large memory cards
add setting to game inis to use memory card 251 for games that cannot use large memory cards
Merge pull request #226 from LPFaint99/Issue6753

Use a 251 block Memory card for games that do not work with larger cards. Fixes Issue 6753
move memorycard handling to its own class
first implementation of memcard from directory, creates a memory card from USERDIR/GC/<REGION>/Card <A/B>
Savestates include the entire memorycard, but the only saves that should be modified are the ones that are directly modified by the game
the others are preserved merely to avoid changing the memory card header during the game as some games (Zelda) refuse to save

This is the 2nd commit message:

Implement DMA r/w for memcard.
Skips programming buffer for writes

This is the 3rd commit message:

small cleanup, remove duplicated functions

remove old comment

This is the 4th commit message:

bump the save state version, and fix a stupid mistake I made while cleaning up

This is the 5th commit message:

Add a migration feature that auto imports all saves from your default memcard to the new memcard dir if it doesn't exist.

remove a debug message that I inadvertently added last commit

This is the 6th commit message:

check region of GCI files when loading, notify user of save files that do not belong to this region

fix issues caused by rebase

This is the 7th commit message:

create the full save file even if some blocks are never written to. prevents creating invalid gci files (ex: last two blocks are never used because it is for file 3,  most tools will still expect the gci file to be BLOCK_SIZE*block count + gciheader size)

Actually "delete" save files by renaming to s/*.gci/*.gci.deleted/

This is the 8th commit message:

don't assume contiguous blocks in memcard dir access.

probably insignificant slowdown compared to contiguous access, but prevents the user from shooting themselves in the foot by somehow forcing a fragmented file (deleting/moving files around in IPL/SysMenu) and destroying it because we assumed it was contiguous.
Tested with an artificially fragmented save due to the ease compared to causing the fragment within an emulated state

This is the 9th commit message:

add some sanity checking to loading gci files. reject files whose filesize does not match size recorded in header, duplicated internal filenames, and files whose recorded block count is larger than the largest possible memory card.

clear save data and used blocks when a file is deleted

This is the 10th commit message:

more sanity checking. ensure that no more blocks are loaded than are available on the virtual memorycard

This is the 11th commit message:

move common code to a single function

This is the 12th commit message:

move clearBlock to be next to the similar Read and Write functions

This is the 13th commit message:

read/write DMA blocks in order, check for write errors when flushing gci files to disc

This is the 14th commit message:

implement/fix DMAWrite

This is the 15th commit message:

Merge old gcifolder changes with refactored raw memorycard access

This is the 16th commit message:

simplify directory writing, fixes bug where certain games cannot save.

only store valid saves in the m_saves vector

Use a 251 block Memory card for games that do not work with larger cards with gci folder

fix exporting all gci files and move migration to GCMemcardDirectory
rename setup functions,
mark a few alerts as translatable,
remove trailing ws

fix includes
Move MemoryCardBase to GCMemcard
Move GCMemcardDirectory defines to own file
fix build
warning fix