libretro / Genesis-Plus-GX

An enhanced port of Genesis Plus - accurate & portable Sega 8/16 bit emulator
Other
75 stars 72 forks source link

[request] implement `RETRO_ENVIRONMENT_SET_MEMORY_MAPS` for SMS (and other systems) #346

Open beauxq opened 6 months ago

beauxq commented 6 months ago

In RetroArch, I've been using the network commands READ_CORE_RAM and WRITE_CORE_RAM for something that they're not intended for. And the people at RetroArch tell me I should be using READ_CORE_MEMORY and WRITE_CORE_MEMORY instead. But I can't use those if the emulator doesn't implement RETRO_ENVIRONMENT_SET_MEMORY_MAPS

From this code, it looks like it's implemented for SYSTEM_MCD, but not for SMS or other systems. But I'm not sure whether I'm understanding it correctly.

https://github.com/libretro/Genesis-Plus-GX/blob/667158b034ce860e345b13e1ed927fea9d155b96/libretro/libretro.c#L2602-L2620

It would be nice if I could use READ_CORE_MEMORY and WRITE_CORE_MEMORY with Genesis-Plus-GX (and SMS-Plus-GX), with SMS games.

negativeExponent commented 3 months ago

smsplus-gx do you mean this? https://github.com/libretro/smsplus-gx i was the one who ported this standalone fork into libretro and used to maintain it. ill see what i can do to add the RAM in memory maps instead. cant remember why i ddnt do that before.

as memory_map in genplus-gx, i also add this MegaCD memory maps, there was a reason that the main RAM was not moved into mem_map (retroarchivement? different address location?) no promises there but i can look into smsplus.

quicklook: i think it should be safe to expose entire 68K ram instead of limiting it just on mega/sega CD { mem, work_ram, 0, 0xFF0000, 0, 0, 0x10000, "68KRAM" },